| 271 | } |
| 272 | |
| 273 | void butex_destroy(void* butex) { |
| 274 | if (!butex) { |
| 275 | return; |
| 276 | } |
| 277 | Butex* b = static_cast<Butex*>( |
| 278 | container_of(static_cast<butil::atomic<int>*>(butex), Butex, value)); |
| 279 | butil::return_object(b); |
| 280 | } |
| 281 | |
| 282 | // if TaskGroup tls_task_group is belong to tag |
| 283 | inline bool is_same_tag(bthread_tag_t tag) { |