hotspot/src/share/vm/gc/g1/g1OopClosures.inline.hpp
changeset 36572 bdbf53032b6a
parent 35943 e726308008c0
child 37258 d5fb0ee5e41a
--- a/hotspot/src/share/vm/gc/g1/g1OopClosures.inline.hpp	Sun Mar 06 19:07:57 2016 -0500
+++ b/hotspot/src/share/vm/gc/g1/g1OopClosures.inline.hpp	Mon Mar 07 10:36:50 2016 +0300
@@ -171,14 +171,7 @@
 #ifdef ASSERT
   // can't do because of races
   // assert(obj == NULL || obj->is_oop(), "expected an oop");
-
-  // Do the safe subset of is_oop
-#ifdef CHECK_UNHANDLED_OOPS
-  oopDesc* o = obj.obj();
-#else
-  oopDesc* o = obj;
-#endif // CHECK_UNHANDLED_OOPS
-  assert((intptr_t)o % MinObjAlignmentInBytes == 0, "not oop aligned");
+  assert(check_obj_alignment(obj), "not oop aligned");
   assert(_g1->is_in_reserved(obj), "must be in heap");
 #endif // ASSERT