- if (pending_[tid_]->head - rcu_last_posted_[tid_][tid_] < RCU_POST_THRESHOLD)
- return;
- TRACE("r0", "rcu_defer_free: posting %llu", pending_[tid_]->head, 0);
- int next_thread_id = (tid_ + 1) % num_threads_;
- rcu_[next_thread_id][tid_] = rcu_last_posted_[tid_][tid_] = pending_[tid_]->head;
+ if (pending_[thread_index]->head - rcu_last_posted_[thread_index][thread_index] >= RCU_POST_THRESHOLD) {
+ TRACE("r0", "rcu_defer_free: posting %llu", pending_[thread_index]->head, 0);
+ int next_thread_index = (thread_index + 1) % num_threads_;
+ rcu_[next_thread_index][thread_index] = pending_[thread_index]->head;
+ rcu_last_posted_[thread_index][thread_index] = pending_[thread_index]->head;
+ }