Changeset 7157


Ignore:
Timestamp:
Nov 26, 2008, 2:57:32 AM (12 years ago)
Author:
charles
Message:

(libT) performance tweaks

Location:
trunk/libtransmission
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/bandwidth.c

    r7154 r7157  
    257257    const double pulses_per_history = (double)HISTORY_MSEC / period_msec;
    258258    const double min = desired_bytes_per_pulse * 0.90;
    259     const double max = desired_bytes_per_pulse * 1.50;
     259    const double max = desired_bytes_per_pulse * 1.20;
    260260    const double next_pulse_bytes = desired_bytes_per_pulse * ( pulses_per_history + 1 )
    261261                                  - ( current_bytes_per_pulse * pulses_per_history );
  • trunk/libtransmission/iobuf.c

    r7154 r7157  
    127127    short what = EVBUFFER_READ;
    128128    struct tr_iobuf * b = arg;
    129     const size_t howmuch = tr_bandwidthClamp( b->bandwidth, TR_DOWN, 2048 );
     129    const size_t howmuch = tr_bandwidthClamp( b->bandwidth, TR_DOWN, b->session->so_rcvbuf );
    130130
    131131    assert( isBuf( b ) );
Note: See TracChangeset for help on using the changeset viewer.