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

Side by Side Diff: src/compiler/x64/code-generator-x64.cc

Issue 1269913002: [turbofan] Simplifying handling of callee-cleanup stack area. (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 unified diff | Download patch
« no previous file with comments | « src/compiler/ppc/code-generator-ppc.cc ('k') | src/compiler/x87/code-generator-x87.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/compiler/code-generator.h" 5 #include "src/compiler/code-generator.h"
6 6
7 #include "src/compiler/code-generator-impl.h" 7 #include "src/compiler/code-generator-impl.h"
8 #include "src/compiler/gap-resolver.h" 8 #include "src/compiler/gap-resolver.h"
9 #include "src/compiler/node-matchers.h" 9 #include "src/compiler/node-matchers.h"
10 #include "src/scopes.h" 10 #include "src/scopes.h"
(...skipping 1551 matching lines...) Expand 10 before | Expand all | Expand 10 after
1562 __ ret(0); 1562 __ ret(0);
1563 } 1563 }
1564 } else if (descriptor->IsJSFunctionCall() || needs_frame_) { 1564 } else if (descriptor->IsJSFunctionCall() || needs_frame_) {
1565 // Canonicalize JSFunction return sites for now. 1565 // Canonicalize JSFunction return sites for now.
1566 if (return_label_.is_bound()) { 1566 if (return_label_.is_bound()) {
1567 __ jmp(&return_label_); 1567 __ jmp(&return_label_);
1568 } else { 1568 } else {
1569 __ bind(&return_label_); 1569 __ bind(&return_label_);
1570 __ movq(rsp, rbp); // Move stack pointer back to frame pointer. 1570 __ movq(rsp, rbp); // Move stack pointer back to frame pointer.
1571 __ popq(rbp); // Pop caller's frame pointer. 1571 __ popq(rbp); // Pop caller's frame pointer.
1572 int pop_count = descriptor->IsJSFunctionCall() 1572 int pop_count = static_cast<int>(descriptor->StackParameterCount());
1573 ? static_cast<int>(descriptor->JSParameterCount())
1574 : (info()->IsStub()
1575 ? info()->code_stub()->GetStackParameterCount()
1576 : 0);
1577 if (pop_count == 0) { 1573 if (pop_count == 0) {
1578 __ Ret(); 1574 __ Ret();
1579 } else { 1575 } else {
1580 __ Ret(pop_count * kPointerSize, rbx); 1576 __ Ret(pop_count * kPointerSize, rbx);
1581 } 1577 }
1582 } 1578 }
1583 } else { 1579 } else {
1584 __ Ret(); 1580 __ Ret();
1585 } 1581 }
1586 } 1582 }
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after
1773 __ Nop(padding_size); 1769 __ Nop(padding_size);
1774 } 1770 }
1775 } 1771 }
1776 } 1772 }
1777 1773
1778 #undef __ 1774 #undef __
1779 1775
1780 } // namespace internal 1776 } // namespace internal
1781 } // namespace compiler 1777 } // namespace compiler
1782 } // namespace v8 1778 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/ppc/code-generator-ppc.cc ('k') | src/compiler/x87/code-generator-x87.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698