Opened 11 years ago

Closed 11 years ago

Last modified 11 years ago

#3950 closed Enhancement (fixed)

use libevent's cached gettimeofday() value when appropriate

Reported by: jordan Owned by: jordan
Priority: Normal Milestone: 2.20
Component: libtransmission Version: 2.13
Severity: Minor Keywords:
Cc:

Description

gettimeofday() shows up pretty high in transmission-daemon's profiling. In particular, we call it in each socket read/write callback to tell the tr_bandwidth objects when the bandwidth was consumed.

libevent has a cached value of this that we can use. It wouldn't be good for all uses, but when called within the libevent callbacks the accuracy should be acceptable.

Attachments (1)

gettimeofday.diff (3.8 KB) - added by jordan 11 years ago.

Download all attachments as: .zip

Change History (7)

Changed 11 years ago by jordan

comment:1 Changed 11 years ago by jordan

  • Milestone changed from Sometime to 2.30
  • Status changed from new to assigned

comment:2 Changed 11 years ago by jordan

  • Milestone changed from 2.30 to 2.21

comment:3 Changed 11 years ago by jordan

  • Milestone changed from 2.21 to 2.20

Promoting to 2.20 for a third beta, based on feedback from the other transmission devs

comment:4 Changed 11 years ago by jordan

  • Resolution set to fixed
  • Status changed from assigned to closed

r11783: added to trunk

comment:5 Changed 11 years ago by jordan

  • Severity changed from Normal to Minor

comment:6 Changed 11 years ago by jordan

followup ticket: #4047

Note: See TracTickets for help on using tickets.