Merge lp:~vkolesnikov/pbxt/pbxt-locklist into lp:pbxt

Proposed by Vladimir Kolesnikov
Status: Merged
Merge reported by: Paul McCullagh
Merged at revision: not available
Proposed branch: lp:~vkolesnikov/pbxt/pbxt-locklist
Merge into: lp:pbxt
To merge this branch: bzr merge lp:~vkolesnikov/pbxt/pbxt-locklist
Reviewer Review Type Date Requested Status
PBXT Core Pending
Review via email: mp+3038@code.launchpad.net
To post a comment you must log in.
Revision history for this message
Vladimir Kolesnikov (vkolesnikov) wrote :

Thread lock lists. Currently auto-enabled in debug mode. Controlled by XT_THREAD_LOCK_INFO macro. Interface located in locklist_xt.h

lp:~vkolesnikov/pbxt/pbxt-locklist updated
534. By Vladimir Kolesnikov

fixed a problem in locklist

Revision history for this message
Vladimir Kolesnikov (vkolesnikov) wrote :

Ok, I pushed the update. Please note that to keep the list of thread lock I use a statically allocated array inside of the XTThread structure. This is needed because memory allocation code uses locks and I didn't want to make any exclusions in lock accounting. Strictly speaking, it would be possible to allocate several slots at at time so subsequent slot allocation requests don't require calls to malloc code, but that looked a bit overcomplicated for me... After all, I don't think a thread will ever keep more than 3-4 locks... At the moment there is place for 50 locks (pointers) per thread.

Subscribers

People subscribed via source and target branches