diff options
author | 2016-10-04 19:06:30 -0700 | |
---|---|---|
committer | 2016-10-05 13:02:53 -0700 | |
commit | 8778c521de4f686118549ef7b20ae497e53b9e93 (patch) | |
tree | 18e82a5860cf7c7d388f314615ba66e9a3ac4521 /runtime/java_vm_ext.cc | |
parent | 2f61867045ffbd0c38a4ecec5f59632004f7efff (diff) |
Change indirect reference table to use ObjPtr
Bug: 31113334
Test: test-art-host
Change-Id: I340fdf430897ebd790ea4e35f94bcee776e98445
Diffstat (limited to 'runtime/java_vm_ext.cc')
-rw-r--r-- | runtime/java_vm_ext.cc | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/runtime/java_vm_ext.cc b/runtime/java_vm_ext.cc index 215f2b3ddf..ecd6b524df 100644 --- a/runtime/java_vm_ext.cc +++ b/runtime/java_vm_ext.cc @@ -641,7 +641,7 @@ void JavaVMExt::BroadcastForNewWeakGlobals() { } mirror::Object* JavaVMExt::DecodeGlobal(IndirectRef ref) { - return globals_.SynchronizedGet(ref); + return globals_.SynchronizedGet(ref).Ptr(); } void JavaVMExt::UpdateGlobal(Thread* self, IndirectRef ref, mirror::Object* result) { @@ -669,7 +669,7 @@ mirror::Object* JavaVMExt::DecodeWeakGlobal(Thread* self, IndirectRef ref) { // if MayAccessWeakGlobals is false. DCHECK_EQ(GetIndirectRefKind(ref), kWeakGlobal); if (LIKELY(MayAccessWeakGlobalsUnlocked(self))) { - return weak_globals_.SynchronizedGet(ref); + return weak_globals_.SynchronizedGet(ref).Ptr(); } MutexLock mu(self, weak_globals_lock_); return DecodeWeakGlobalLocked(self, ref); @@ -682,7 +682,7 @@ mirror::Object* JavaVMExt::DecodeWeakGlobalLocked(Thread* self, IndirectRef ref) while (UNLIKELY(!MayAccessWeakGlobals(self))) { weak_globals_add_condition_.WaitHoldingLocks(self); } - return weak_globals_.Get(ref); + return weak_globals_.Get(ref).Ptr(); } mirror::Object* JavaVMExt::DecodeWeakGlobalDuringShutdown(Thread* self, IndirectRef ref) { @@ -695,7 +695,7 @@ mirror::Object* JavaVMExt::DecodeWeakGlobalDuringShutdown(Thread* self, Indirect if (!kUseReadBarrier) { DCHECK(allow_accessing_weak_globals_.LoadSequentiallyConsistent()); } - return weak_globals_.SynchronizedGet(ref); + return weak_globals_.SynchronizedGet(ref).Ptr(); } bool JavaVMExt::IsWeakGlobalCleared(Thread* self, IndirectRef ref) { |