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

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

Issue 2473643002: Revert of [turbofan] Support variable size argument popping in TF-generated functions (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 | « src/code-stubs.cc ('k') | src/compiler/arm64/code-generator-arm64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/arm/code-generator-arm.cc
diff --git a/src/compiler/arm/code-generator-arm.cc b/src/compiler/arm/code-generator-arm.cc
index d3ee44a6bc0d8db645ea3a3611fe3f531f343b82..4cdb6da56c0f08f86627c67c5eeec9c99025a8cc 100644
--- a/src/compiler/arm/code-generator-arm.cc
+++ b/src/compiler/arm/code-generator-arm.cc
@@ -744,7 +744,7 @@
break;
}
case kArchRet:
- AssembleReturn(instr->InputAt(0));
+ AssembleReturn();
DCHECK_EQ(LeaveCC, i.OutputSBit());
break;
case kArchStackPointer:
@@ -1737,7 +1737,8 @@
}
}
-void CodeGenerator::AssembleReturn(InstructionOperand* pop) {
+
+void CodeGenerator::AssembleReturn() {
CallDescriptor* descriptor = linkage()->GetIncomingDescriptor();
int pop_count = static_cast<int>(descriptor->StackParameterCount());
@@ -1761,33 +1762,19 @@
unwinding_info_writer_.MarkBlockWillExit();
- ArmOperandConverter g(this, nullptr);
if (descriptor->IsCFunctionCall()) {
AssembleDeconstructFrame();
} else if (frame_access_state()->has_frame()) {
- // Canonicalize JSFunction return sites for now unless they have an variable
- // number of stack slot pops.
- if (pop->IsImmediate() && g.ToConstant(pop).ToInt32() == 0) {
- if (return_label_.is_bound()) {
- __ b(&return_label_);
- return;
- } else {
- __ bind(&return_label_);
- AssembleDeconstructFrame();
- }
+ // Canonicalize JSFunction return sites for now.
+ if (return_label_.is_bound()) {
+ __ b(&return_label_);
+ return;
} else {
+ __ bind(&return_label_);
AssembleDeconstructFrame();
}
}
-
- if (pop->IsImmediate()) {
- DCHECK_EQ(Constant::kInt32, g.ToConstant(pop).type());
- pop_count += g.ToConstant(pop).ToInt32();
- } else {
- __ Drop(g.ToRegister(pop));
- }
- __ Drop(pop_count);
- __ Ret();
+ __ Ret(pop_count);
}
void CodeGenerator::AssembleMove(InstructionOperand* source,
« no previous file with comments | « src/code-stubs.cc ('k') | src/compiler/arm64/code-generator-arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698