[tor-bugs] #9682 [Tor]: Better work queue implementation for cpuworkers

Tor Bug Tracker & Wiki blackhole at torproject.org
Fri Feb 14 01:36:25 UTC 2014


#9682: Better work queue implementation for cpuworkers
-----------------------------+---------------------------------------------
     Reporter:  nickm        |      Owner:
         Type:  enhancement  |     Status:  needs_review
     Priority:  normal       |  Milestone:  Tor: 0.2.5.x-final
    Component:  Tor          |    Version:
   Resolution:               |   Keywords:  tor-relay performance cpuworker
Actual Points:               |  Parent ID:
       Points:               |
-----------------------------+---------------------------------------------

Comment (by andrea):

 Review, part 2:

 066770588292696ea3d20b3beeaa82521746e192:
  - Looks fine to me.

 461ace08feb4d40653532e7078981ead7f750058:
  - Looks fine to me.

 2921b6fb7eb93955053d01e4b1e54de8f33447b3:
  - Looks fine to me.

 764eb698a4f6dcaaa02f3343589fc9ae763133ff:
  - Where is SPIN_COUNT used?

 05a184ce130856be553985dbdac1d4df8d36902c:
  - Wait, pthread_cond_timedwait() wants an absolute time()? Really? How
 many
    ways can this horribly break if the system time changes at the wrong
 moment?

 ffb48b392271b459ef81ab1f80084bc7f829c07b:
  - Ah, good, you caught that too. :)

 456c0bd480f34b53e809db4282afc042b5fe6a77:
  - This looks okay to me.

 6db4d6b6ec0ffffd8184cabc83ec3f8c2f9c7948:
  - This looks okay to me.

 e343a5b6d4c5e609a0531959cf700ffeabdea95a:
  - So we're using threadpool_queue_for_all() to shut threads down.

 a26ebecd3e6424d7a07b50c5e4c6e76acecd7c12
  - This looks okay to me.

 1ffbef76792a3b40e4a05ca01e63d4e009574c1b:
  - Good catch.

 7f746b3f7fe7a7f25d05ab47d49fc788ab7ff4df:
  - Looks okay to me.

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/9682#comment:9>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list