summaryrefslogtreecommitdiff
path: root/runtime/interpreter/interpreter_switch_impl.cc
diff options
context:
space:
mode:
author Vladimir Marko <vmarko@google.com> 2018-05-22 15:33:48 +0100
committer Vladimir Marko <vmarko@google.com> 2018-05-23 13:48:31 +0100
commit6ec2a1bf1cbecf17546df780dd0ad769042e1874 (patch)
tree09f7430f020e04dc892ff2c2152bb773cd45c0dd /runtime/interpreter/interpreter_switch_impl.cc
parent2d3065e6ca0bd707bc998b7d260bb8e8ec07cf87 (diff)
ObjPtr<>-ify UnstartedRuntime, fix 2 stale reference uses.
Test: Rely on TreeHugger. Bug: 31113334 Change-Id: I35f76c3e3b94dfca18dbe67aba065a1270f4e5ee
Diffstat (limited to 'runtime/interpreter/interpreter_switch_impl.cc')
-rw-r--r--runtime/interpreter/interpreter_switch_impl.cc17
1 files changed, 9 insertions, 8 deletions
diff --git a/runtime/interpreter/interpreter_switch_impl.cc b/runtime/interpreter/interpreter_switch_impl.cc
index 5c7838cd66..27626295c1 100644
--- a/runtime/interpreter/interpreter_switch_impl.cc
+++ b/runtime/interpreter/interpreter_switch_impl.cc
@@ -24,6 +24,7 @@
#include "jit/jit.h"
#include "jvalue-inl.h"
#include "safe_math.h"
+#include "shadow_frame-inl.h"
namespace art {
namespace interpreter {
@@ -299,7 +300,7 @@ void ExecuteSwitchImplCpp(SwitchImplContext* ctx) {
PREAMBLE();
ObjPtr<mirror::Throwable> exception = self->GetException();
DCHECK(exception != nullptr) << "No pending exception on MOVE_EXCEPTION instruction";
- shadow_frame.SetVRegReference(inst->VRegA_11x(inst_data), exception.Ptr());
+ shadow_frame.SetVRegReference(inst->VRegA_11x(inst_data), exception);
self->ClearException();
inst = inst->Next_1xx();
break;
@@ -514,7 +515,7 @@ void ExecuteSwitchImplCpp(SwitchImplContext* ctx) {
if (UNLIKELY(s == nullptr)) {
HANDLE_PENDING_EXCEPTION();
} else {
- shadow_frame.SetVRegReference(inst->VRegA_21c(inst_data), s.Ptr());
+ shadow_frame.SetVRegReference(inst->VRegA_21c(inst_data), s);
inst = inst->Next_2xx();
}
break;
@@ -527,7 +528,7 @@ void ExecuteSwitchImplCpp(SwitchImplContext* ctx) {
if (UNLIKELY(s == nullptr)) {
HANDLE_PENDING_EXCEPTION();
} else {
- shadow_frame.SetVRegReference(inst->VRegA_31c(inst_data), s.Ptr());
+ shadow_frame.SetVRegReference(inst->VRegA_31c(inst_data), s);
inst = inst->Next_3xx();
}
break;
@@ -542,7 +543,7 @@ void ExecuteSwitchImplCpp(SwitchImplContext* ctx) {
if (UNLIKELY(c == nullptr)) {
HANDLE_PENDING_EXCEPTION();
} else {
- shadow_frame.SetVRegReference(inst->VRegA_21c(inst_data), c.Ptr());
+ shadow_frame.SetVRegReference(inst->VRegA_21c(inst_data), c);
inst = inst->Next_2xx();
}
break;
@@ -556,7 +557,7 @@ void ExecuteSwitchImplCpp(SwitchImplContext* ctx) {
if (UNLIKELY(mh == nullptr)) {
HANDLE_PENDING_EXCEPTION();
} else {
- shadow_frame.SetVRegReference(inst->VRegA_21c(inst_data), mh.Ptr());
+ shadow_frame.SetVRegReference(inst->VRegA_21c(inst_data), mh);
inst = inst->Next_2xx();
}
break;
@@ -570,7 +571,7 @@ void ExecuteSwitchImplCpp(SwitchImplContext* ctx) {
if (UNLIKELY(mt == nullptr)) {
HANDLE_PENDING_EXCEPTION();
} else {
- shadow_frame.SetVRegReference(inst->VRegA_21c(inst_data), mt.Ptr());
+ shadow_frame.SetVRegReference(inst->VRegA_21c(inst_data), mt);
inst = inst->Next_2xx();
}
break;
@@ -681,7 +682,7 @@ void ExecuteSwitchImplCpp(SwitchImplContext* ctx) {
HANDLE_PENDING_EXCEPTION();
break;
}
- shadow_frame.SetVRegReference(inst->VRegA_21c(inst_data), obj.Ptr());
+ shadow_frame.SetVRegReference(inst->VRegA_21c(inst_data), obj);
inst = inst->Next_2xx();
}
break;
@@ -698,7 +699,7 @@ void ExecuteSwitchImplCpp(SwitchImplContext* ctx) {
if (UNLIKELY(obj == nullptr)) {
HANDLE_PENDING_EXCEPTION();
} else {
- shadow_frame.SetVRegReference(inst->VRegA_22c(inst_data), obj.Ptr());
+ shadow_frame.SetVRegReference(inst->VRegA_22c(inst_data), obj);
inst = inst->Next_2xx();
}
break;