Skip to content

Separate UDP GSO and GRO controls for Linux (--gso and --gro options) #2037 - #2038

Open
roaoliver wants to merge 6 commits into
esnet:masterfrom
roaoliver:master
Open

roaoliver wants to merge 6 commits into
esnet:masterfrom
roaoliver:master

Conversation

@roaoliver

@roaoliver roaoliver commented May 20, 2026 •

Copy link
Copy Markdown

PLEASE NOTE the following text from the iperf3 license. Submitting a
pull request to the iperf3 repository constitutes "[making]
Enhancements available...publicly":

You are under no obligation whatsoever to provide any bug fixes, patches, or
upgrades to the features, functionality or performance of the source code
("Enhancements") to anyone; however, if you choose to make your Enhancements
available either publicly, or directly to Lawrence Berkeley National
Laboratory, without imposing a separate written license agreement for such
Enhancements, then you hereby grant the following license: a non-exclusive,
royalty-free perpetual license to install, use, modify, prepare derivative
works, incorporate into other computer software, distribute, and sublicense
such enhancements or derivative works thereof, in binary and source code form.

The complete iperf3 license is available in the LICENSE file in the
top directory of the iperf3 source tree.

Comment thread src/iperf_api.c Outdated
Comment on lines +1814 to +1815
test->settings->gso = 1;
test->settings->gro = 0;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggest to set only gso, so --gso --gro will be equivalent to --gsro.

Comment thread src/iperf_api.c Outdated
Comment on lines +1821 to +1822
test->settings->gso = 0;
test->settings->gro = 1;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggest to set only gro, so --gso --gro will be equivalent to --gsro.

@davidBar-On

Copy link
Copy Markdown
Contributor

To reduce number of iperf3 options, instead of adding --gso and --gro it may be better to add a flag to --gsro. E.g --gsro/s will set only gso and --gsro/r will set only gro.

@roaoliver

Copy link
Copy Markdown
Author

Suggestion implemented in the code.

image

@biergaizi

biergaizi commented Aug 29, 2026 •

Copy link
Copy Markdown

For your information, the high CPU usage was caused by busy-polling via MSG_DONTWAIT, this has been root-caused by @kvasana in #2069, once #2069 is merged this workaround is no longer necessary in your use case (high CPU usage at receiver).

That being said, I still support supporting separate GSO and GRO options. In some test setups the server and client processing speeds are not symmetric, so it's still useful to isolate a sender or receiver side bottleneck.

This branch has not been deployed

No deployments
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.

3 participants