Performance enhancements

Misc topics about I2P
Post Reply
jogger
Posts: 45
Joined: 19 Feb 2018 09:00

Performance enhancements

Post by jogger »

Those of you following trac have seen me contributing to bug fixes and performance enhancements. These are crucial to me as I mainly use the ARM32 platform. I am glad of i2p progress over the last year, fixing many long standing issues.

However I have developed some enhancements, most available on trac, that I fear will not make it into mainline soon. If you are interested I could publish my source or a diff against 0.9.41 or a simple i2pupdate.zip on MuWire. Most of it is especially useful for low end platforms. Every mod has been tested long time and its superiority over stock i2p or other suggestions has been proven by measuring billions of function calls. It would contain the following:

- losslessly compressed graphics, eliminating up to 83% bloat (27% avg.)
- reducing # of threads to 1 each except Job Queue Runner (for cosmetic reasons) and NTCP Reader (needed for ARM) set to 2.
- improved clock functions shaving off 200k / sec kernel calls for about 10% overall speed gain.
- eliminated Tunnel GW Pumper. This is not the double priority pumping I suggested on trac, furthermore putting local traffic on par with the "directdispatch" that has prioritzed participating traffic for years.
- eliminated timestamping and stats calls in the UDP transport (50k calls / sec). UDP transport is the main bottleneck and these calls go to the clock or take clock functions as their parameter.
- improved UDP packet pusher, eliminating a delayed sending bug and focusing on sending data ASAP by employing a continously updated sliding send window and prioritizing ready traffic (99% case) over housekeeping. Other mods may save a little bit of CPU, but send slower.
- improved NTCP Event pumper, eliminating a cause for elevated CPU usage, removing forced sleep. This version makes sure an action is taken every loop through the pumper and data is actually moved forward at least every second loop. Builds on top of the less CPU intensive version on trac, but does never sleep.
- i2pupdate.zip requires Java 11+, if you are still using 8 you are obviously not interested in performance and stability on ARM.
User avatar
zzz
Posts: 155
Joined: 31 Mar 2018 13:15

Re: Performance enhancements

Post by zzz »

Thanks for the summary. We appreciate your contributions. There's various reasons why some changes haven't made it in yet, some of them are technical disagreement, confusion on our part, inability to reproduce your results, or simply lack of time or other things that are higher priority. There's certainly more improvements to be made in our transports code and I'm hopeful we can get more of your changes into upcoming releases. Thanks for your patience and persistence.
Post Reply