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

Unified Diff: runtime/vm/intermediate_language_ia32.cc

Issue 2504693002: Mark lazily-patched native calls correctly as patchable. (Closed)
Patch Set: Created 4 years, 1 month 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
« no previous file with comments | « runtime/vm/intermediate_language_arm64.cc ('k') | runtime/vm/intermediate_language_mips.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/intermediate_language_ia32.cc
diff --git a/runtime/vm/intermediate_language_ia32.cc b/runtime/vm/intermediate_language_ia32.cc
index 2e94f653c7b960dc09947859c864665d2b53f896..c90b2c52d8fd2e0f4dbb60b6c3854b37104c1130 100644
--- a/runtime/vm/intermediate_language_ia32.cc
+++ b/runtime/vm/intermediate_language_ia32.cc
@@ -848,15 +848,17 @@ void NativeCallInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
if (link_lazily()) {
stub_entry = StubCode::CallBootstrapCFunction_entry();
__ movl(ECX, Immediate(NativeEntry::LinkNativeCallEntry()));
+ compiler->GeneratePatchableCall(token_pos(), *stub_entry,
+ RawPcDescriptors::kOther, locs());
} else {
stub_entry = (is_bootstrap_native())
? StubCode::CallBootstrapCFunction_entry()
: StubCode::CallNativeCFunction_entry();
const ExternalLabel label(reinterpret_cast<uword>(native_c_function()));
__ movl(ECX, Immediate(label.address()));
+ compiler->GenerateCall(token_pos(), *stub_entry, RawPcDescriptors::kOther,
+ locs());
}
- compiler->GenerateCall(token_pos(), *stub_entry, RawPcDescriptors::kOther,
- locs());
__ popl(result);
}
« no previous file with comments | « runtime/vm/intermediate_language_arm64.cc ('k') | runtime/vm/intermediate_language_mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698