src/hotspot/share/utilities/globalCounter.inline.hpp
changeset 51511 eb8d5aeabab3
parent 50429 83aec1d357d4
child 51548 35a6956f4243
--- a/src/hotspot/share/utilities/globalCounter.inline.hpp	Thu Aug 23 12:57:40 2018 -0700
+++ b/src/hotspot/share/utilities/globalCounter.inline.hpp	Thu Aug 23 18:14:53 2018 -0400
@@ -31,16 +31,16 @@
 
 inline void GlobalCounter::critical_section_begin(Thread *thread) {
   assert(thread == Thread::current(), "must be current thread");
-  assert(thread->is_VM_thread() || thread->is_Java_thread(), "must be VMThread or JavaThread");
-  assert((*thread->get_rcu_counter() & COUNTER_ACTIVE) == 0x0, "nestled critical sections, not supported yet");
+  assert(thread->is_Named_thread() || thread->is_Java_thread(), "must be NamedThread or JavaThread");
+  assert((*thread->get_rcu_counter() & COUNTER_ACTIVE) == 0x0, "nested critical sections, not supported yet");
   uintx gbl_cnt = OrderAccess::load_acquire(&_global_counter._counter);
   OrderAccess::release_store_fence(thread->get_rcu_counter(), gbl_cnt | COUNTER_ACTIVE);
 }
 
 inline void GlobalCounter::critical_section_end(Thread *thread) {
   assert(thread == Thread::current(), "must be current thread");
-  assert(thread->is_VM_thread() || thread->is_Java_thread(), "must be VMThread or JavaThread");
-  assert((*thread->get_rcu_counter() & COUNTER_ACTIVE) == COUNTER_ACTIVE, "must be in ctitical section");
+  assert(thread->is_Named_thread() || thread->is_Java_thread(), "must be NamedThread or JavaThread");
+  assert((*thread->get_rcu_counter() & COUNTER_ACTIVE) == COUNTER_ACTIVE, "must be in critical section");
   // Mainly for debugging we set it to 'now'.
   uintx gbl_cnt = OrderAccess::load_acquire(&_global_counter._counter);
   OrderAccess::release_store(thread->get_rcu_counter(), gbl_cnt);