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

Unified Diff: src/compiler/ia32/code-generator-ia32.cc

Issue 1263033004: [turbofan] Various fixes to allow unboxed doubles as arguments in registers and on the stack. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 4 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
« no previous file with comments | « no previous file | src/compiler/linkage.cc » ('j') | src/compiler/x64/code-generator-x64.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/ia32/code-generator-ia32.cc
diff --git a/src/compiler/ia32/code-generator-ia32.cc b/src/compiler/ia32/code-generator-ia32.cc
index 298627b55bd35dfb1ba40d35da6b49fa16eca1f6..22a7ea99a66f6b44924ca81061b535ebd3170f8f 100644
--- a/src/compiler/ia32/code-generator-ia32.cc
+++ b/src/compiler/ia32/code-generator-ia32.cc
@@ -1325,31 +1325,26 @@ void CodeGenerator::AssembleReturn() {
}
}
__ pop(ebp); // Pop caller's frame pointer.
- __ ret(0);
} else {
// No saved registers.
__ mov(esp, ebp); // Move stack pointer back to frame pointer.
__ pop(ebp); // Pop caller's frame pointer.
- __ ret(0);
}
} else if (descriptor->IsJSFunctionCall() || needs_frame_) {
// Canonicalize JSFunction return sites for now.
if (return_label_.is_bound()) {
__ jmp(&return_label_);
+ return;
} else {
__ bind(&return_label_);
__ mov(esp, ebp); // Move stack pointer back to frame pointer.
__ pop(ebp); // Pop caller's frame pointer.
- int pop_count = static_cast<int>(descriptor->StackParameterCount());
- if (pop_count == 0) {
- __ ret(0);
- } else {
- __ Ret(pop_count * kPointerSize, ebx);
- }
}
- } else {
- __ ret(0);
}
+ size_t pop_size = descriptor->StackParameterCount() * kPointerSize;
+ // Might need ecx for scratch if pop_size is too big.
+ DCHECK_EQ(0, descriptor->CalleeSavedRegisters() & ecx.bit());
+ __ Ret(static_cast<int>(pop_size), ecx);
}
« no previous file with comments | « no previous file | src/compiler/linkage.cc » ('j') | src/compiler/x64/code-generator-x64.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698