Changes between Initial Version and Version 1 of Ticket #4209, comment 5


Ignore:
Timestamp:
Apr 26, 2011, 11:42:07 PM (12 years ago)
Author:
jch
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #4209, comment 5

    initial v1  
    55The version in r12378 puts all the tests inline, and hence avoids making any function calls when the tests don't trigger.  A non-local function call costs around 10ns (assuming the target is already in cache).  At 1MB/s, you should expect to be receiving around 5000 µTP packets per second (including acks).  (Recall that µTorrent sends small-sized µTP packets, which Transmission does not, by design.)  So that's some 50ms/s, or 0.5% of CPU time.
    66
    7 Another, possibly better, solution would be to reorder the tests in order of decreasing likelihood, i.e. µTP first, DHT second, and UTP tracker last.
     7Another, possibly better, solution would be to reorder the tests in order of decreasing likelihood, i.e. µTP first, DHT second, and UDP tracker last.
    88
    99--jch