131 } |
131 } |
132 |
132 |
133 // Maximum number of elements allowed in the queue. This is two less |
133 // Maximum number of elements allowed in the queue. This is two less |
134 // than the actual queue size, for somewhat complicated reasons. |
134 // than the actual queue size, for somewhat complicated reasons. |
135 uint max_elems() { return N - 2; } |
135 uint max_elems() { return N - 2; } |
|
136 |
|
137 // Total size of queue. |
|
138 static const uint total_size() { return N; } |
136 }; |
139 }; |
137 |
140 |
138 template<class E> class GenericTaskQueue: public TaskQueueSuper { |
141 template<class E> class GenericTaskQueue: public TaskQueueSuper { |
139 private: |
142 private: |
140 // Slow paths for push, pop_local. (pop_global has no fast path.) |
143 // Slow paths for push, pop_local. (pop_global has no fast path.) |