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

Refactor epoll Send Path #3274

Merged
merged 19 commits into from
Dec 17, 2022
Merged

Refactor epoll Send Path #3274

merged 19 commits into from
Dec 17, 2022

Conversation

nibanks
Copy link
Member

@nibanks nibanks commented Dec 8, 2022

Description

Lots of refactoring for the epoll send path.

Testing

Existing CI

Documentation

N/A

src/test/lib/MtuTest.cpp Outdated Show resolved Hide resolved
src/platform/datapath_epoll.c Outdated Show resolved Hide resolved
@nibanks nibanks marked this pull request as ready for review December 9, 2022 20:51
@nibanks nibanks requested a review from a team as a code owner December 9, 2022 20:51
Datapath->SendIoVecCount = 1;
} else {
const uint32_t SendDataSize =
sizeof(CXPLAT_SEND_DATA) + (CXPLAT_MAX_BATCH_SEND - 1) * sizeof(struct iovec);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Technically this should be FIELD_OFFSET(CXPLAT_SEND_DATA, Iovs) + CXPLAT_MAX_BATCH_SEND * sizeof(struct iovec) since Iovs[1]; isn't required to be aligned to the end of the struct.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So the code I have might just allocate a bit more because of possible padding? I'm fine with that.

@nibanks nibanks merged commit 250b1df into main Dec 17, 2022
@nibanks nibanks deleted the nibanks/refactor-epoll-send-path branch December 17, 2022 01:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants