Revert "Revert "Use IsMarked instead of Mark for profiling info.""
Bug in the original change was that we were infitely looping on the
same inline cache entry, expecting null when it was actually an old
pointer to a GC'ed class object.
bug: 37693252
This reverts commit 3afefba4b5558f5f726338485c1f6ddc7f107719.
Change-Id: I12a86afe6163809b19f43927543eb9dd898454f0
diff --git a/runtime/read_barrier.h b/runtime/read_barrier.h
index cbc2697..2964090 100644
--- a/runtime/read_barrier.h
+++ b/runtime/read_barrier.h
@@ -64,6 +64,11 @@
GcRootSource* gc_root_source = nullptr)
REQUIRES_SHARED(Locks::mutator_lock_);
+ // Return the mirror Object if it is marked, or null if not.
+ template <typename MirrorType>
+ ALWAYS_INLINE static MirrorType* IsMarked(MirrorType* ref)
+ REQUIRES_SHARED(Locks::mutator_lock_);
+
static bool IsDuringStartup();
// Without the holder object.