equal
deleted
inserted
replaced
211 }; |
211 }; |
212 |
212 |
213 class ShenandoahSATBThreadsClosure : public ThreadClosure { |
213 class ShenandoahSATBThreadsClosure : public ThreadClosure { |
214 private: |
214 private: |
215 ShenandoahSATBBufferClosure* _satb_cl; |
215 ShenandoahSATBBufferClosure* _satb_cl; |
216 int _thread_parity; |
216 uintx _claim_token; |
217 |
217 |
218 public: |
218 public: |
219 ShenandoahSATBThreadsClosure(ShenandoahSATBBufferClosure* satb_cl) : |
219 ShenandoahSATBThreadsClosure(ShenandoahSATBBufferClosure* satb_cl) : |
220 _satb_cl(satb_cl), |
220 _satb_cl(satb_cl), |
221 _thread_parity(Threads::thread_claim_parity()) {} |
221 _claim_token(Threads::thread_claim_token()) {} |
222 |
222 |
223 void do_thread(Thread* thread) { |
223 void do_thread(Thread* thread) { |
224 if (thread->claim_oops_do(true, _thread_parity)) { |
224 if (thread->claim_threads_do(true, _claim_token)) { |
225 ShenandoahThreadLocalData::satb_mark_queue(thread).apply_closure_and_empty(_satb_cl); |
225 ShenandoahThreadLocalData::satb_mark_queue(thread).apply_closure_and_empty(_satb_cl); |
226 } |
226 } |
227 } |
227 } |
228 }; |
228 }; |
229 |
229 |