Remove data dependency of push/pop shadow frame.
Change-Id: I883a1082190084ddfa4a09b8953ac9dafa256e7e
diff --git a/src/compiler_llvm/jni_compiler.cc b/src/compiler_llvm/jni_compiler.cc
index 4b9fb05..c76c80d 100644
--- a/src/compiler_llvm/jni_compiler.cc
+++ b/src/compiler_llvm/jni_compiler.cc
@@ -136,7 +136,8 @@
// Push the shadow frame
llvm::Value* shadow_frame_upcast = irb_.CreateConstGEP2_32(shadow_frame_, 0, 0);
- irb_.CreateCall(irb_.GetRuntime(PushShadowFrame), shadow_frame_upcast);
+ llvm::Value* old_shadow_frame =
+ irb_.CreateCall(irb_.GetRuntime(PushShadowFrame), shadow_frame_upcast);
// Get JNIEnv
llvm::Value* jni_env_object_addr =
@@ -271,7 +272,7 @@
kTBAARuntimeInfo);
// Pop the shadow frame
- irb_.CreateCall(irb_.GetRuntime(PopShadowFrame));
+ irb_.CreateCall(irb_.GetRuntime(PopShadowFrame), old_shadow_frame);
// Return!
if (return_shorty != 'V') {