Anonymous user
Metered concurrency: Difference between revisions
m
→{{header|C}}: comment
(→{{header|C}}: using actual semaphore) |
m (→{{header|C}}: comment) |
||
Line 131:
int count = 3;
/* the whole point of a semaphore is that you don't count it:
* p/v are atomic. Unless it's locked while you are doing
* something with the count, the value is only informative */
#define getcount() count
void acquire()
|