Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement S/G IO for batched sends and eliminate another frame copy #2874

Merged
merged 4 commits into from
Jul 19, 2024

Conversation

cgutman
Copy link
Collaborator

@cgutman cgutman commented Jul 17, 2024

Description

This is the final part of #2867 which implements scatter/gather IO for platf::send_batch() and eliminates the frame copy in fec::encode() by FEC encoding and sending directly out of the payload buffer. This is done by introducing support for payload buffer lists containing multiple contiguous payloads buffers (necessary because data and parity shards are in different buffers). It also introduces the ability to begin sending messages from a specified offset which avoids having to adjust the buffer lists when we send a FEC block in multiple parts for frame pacing.

Testing checklist:

  • Linux sendmsg() + encryption
  • Linux sendmmsg() + encryption
  • Linux sendmsg() + no encryption
  • Linux sendmmsg() + no encryption
  • Windows WSASendMsg() + encryption
  • Windows WSASendMsg() + no encryption
  • Unbatched sends + encryption
  • Unbatched sends + no encryption

Screenshot

Issues Fixed or Closed

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Dependency update (updates to dependencies)
  • Documentation update (changes to documentation)
  • Repository update (changes to repository files, e.g. .github/...)

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added or updated the in code docstring/documentation-blocks for new or existing methods/components

Branch Updates

LizardByte requires that branches be up-to-date before merging. This means that after any PR is merged, this branch
must be updated before it can be merged. You must also
Allow edits from maintainers.

  • I want maintainers to keep my branch updated

Copy link

codecov bot commented Jul 17, 2024

Codecov Report

Attention: Patch coverage is 0% with 113 lines in your changes missing coverage. Please review.

Project coverage is 9.19%. Comparing base (16f6243) to head (99b2c8d).

Additional details and impacted files
@@            Coverage Diff            @@
##           master   #2874      +/-   ##
=========================================
- Coverage    9.22%   9.19%   -0.04%     
=========================================
  Files          97      97              
  Lines       17451   17523      +72     
  Branches     8300    8331      +31     
=========================================
+ Hits         1610    1611       +1     
- Misses      12964   15105    +2141     
+ Partials     2877     807    -2070     
Flag Coverage Δ
Linux 6.96% <0.00%> (-0.04%) ⬇️
Windows 4.51% <0.00%> (-0.02%) ⬇️
macOS-12 10.30% <0.00%> (-0.02%) ⬇️
macOS-13 10.20% <0.00%> (-0.02%) ⬇️
macOS-14 10.53% <0.00%> (-0.02%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
src/crypto.h 0.00% <ø> (ø)
src/crypto.cpp 0.81% <0.00%> (ø)
src/platform/common.h 34.44% <0.00%> (-5.30%) ⬇️
src/platform/windows/misc.cpp 2.17% <0.00%> (-0.05%) ⬇️
src/stream.cpp 3.37% <0.00%> (+0.04%) ⬆️
src/platform/linux/misc.cpp 8.40% <0.00%> (-0.51%) ⬇️

... and 28 files with indirect coverage changes

@cgutman cgutman marked this pull request as ready for review July 17, 2024 04:23
ReenigneArcher
ReenigneArcher previously approved these changes Jul 17, 2024
@cgutman cgutman merged commit 3935d30 into LizardByte:master Jul 19, 2024
46 of 47 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants