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

Unified Diff: runtime/vm/stub_code_ia32.cc

Issue 335443002: Setup R10/EDX to be valid Oops before stub calls (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 6 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/stub_code_ia32.cc
diff --git a/runtime/vm/stub_code_ia32.cc b/runtime/vm/stub_code_ia32.cc
index 8815879285d8884ebc95c7e7ff4f8e854d0b166b..e5b1bb91e69163ef597432f42c4d058cde20cfaa 100644
--- a/runtime/vm/stub_code_ia32.cc
+++ b/runtime/vm/stub_code_ia32.cc
@@ -37,7 +37,7 @@ DECLARE_FLAG(bool, enable_debugger);
// ESP + 4*EDX : address of first argument in argument array.
// ESP + 4*EDX + 4 : address of return value.
// ECX : address of the runtime function to call.
-// EDX : number of arguments to the call.
+// EDX : number of arguments to the call as Smi.
// Must preserve callee saved registers EDI and EBX.
void StubCode::GenerateCallToRuntimeStub(Assembler* assembler) {
const intptr_t isolate_offset = NativeArguments::isolate_offset();
@@ -46,6 +46,7 @@ void StubCode::GenerateCallToRuntimeStub(Assembler* assembler) {
const intptr_t retval_offset = NativeArguments::retval_offset();
__ EnterFrame(0);
+ __ SmiUntag(EDX);
// Load current Isolate pointer from Context structure into EAX.
__ movl(EAX, FieldAddress(CTX, Context::isolate_offset()));

Powered by Google App Engine
This is Rietveld 408576698