Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(140)

Unified Diff: runtime/vm/intermediate_language_arm64.cc

Issue 1248113003: VM: Fix more places with isolate embedded into unoptimized code. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: minor cleanup in stub_code* Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: runtime/vm/intermediate_language_arm64.cc
diff --git a/runtime/vm/intermediate_language_arm64.cc b/runtime/vm/intermediate_language_arm64.cc
index 1f1274493810259b9761b8616149f6b4f050f369..fdd8a13aad4d878db1d69dea0910f09127681cb0 100644
--- a/runtime/vm/intermediate_language_arm64.cc
+++ b/runtime/vm/intermediate_language_arm64.cc
@@ -2646,8 +2646,13 @@ void CheckStackOverflowInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
CheckStackOverflowSlowPath* slow_path = new CheckStackOverflowSlowPath(this);
compiler->AddSlowPathCode(slow_path);
- __ LoadImmediate(TMP, Isolate::Current()->stack_limit_address(), PP);
- __ ldr(TMP, Address(TMP));
+ if (compiler->is_optimizing()) {
+ __ LoadImmediate(TMP, Isolate::Current()->stack_limit_address(), PP);
+ __ ldr(TMP, Address(TMP));
+ } else {
+ __ LoadIsolate(TMP);
+ __ ldr(TMP, Address(TMP, Isolate::stack_limit_offset()));
+ }
__ CompareRegisters(SP, TMP);
__ b(slow_path->entry_label(), LS);
if (compiler->CanOSRFunction() && in_loop()) {

Powered by Google App Engine
This is Rietveld 408576698