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

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

Issue 652363006: [turbofan] First step towards correctified 64-bit addressing. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Fixes2 Created 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/compiler/simplified-lowering.cc ('k') | src/compiler/x64/instruction-codes-x64.h » ('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/compiler/node-properties-inl.h" 10 #include "src/compiler/node-properties-inl.h"
(...skipping 16 matching lines...) Expand all
27 27
28 Immediate InputImmediate(int index) { 28 Immediate InputImmediate(int index) {
29 return ToImmediate(instr_->InputAt(index)); 29 return ToImmediate(instr_->InputAt(index));
30 } 30 }
31 31
32 Operand InputOperand(int index) { return ToOperand(instr_->InputAt(index)); } 32 Operand InputOperand(int index) { return ToOperand(instr_->InputAt(index)); }
33 33
34 Operand OutputOperand() { return ToOperand(instr_->Output()); } 34 Operand OutputOperand() { return ToOperand(instr_->Output()); }
35 35
36 Immediate ToImmediate(InstructionOperand* operand) { 36 Immediate ToImmediate(InstructionOperand* operand) {
37 Constant constant = ToConstant(operand); 37 return Immediate(ToConstant(operand).ToInt32());
38 if (constant.type() == Constant::kInt32) {
39 return Immediate(constant.ToInt32());
40 }
41 UNREACHABLE();
42 return Immediate(-1);
43 } 38 }
44 39
45 Operand ToOperand(InstructionOperand* op, int extra = 0) { 40 Operand ToOperand(InstructionOperand* op, int extra = 0) {
46 DCHECK(op->IsStackSlot() || op->IsDoubleStackSlot()); 41 DCHECK(op->IsStackSlot() || op->IsDoubleStackSlot());
47 // The linkage computes where all spill slots are located. 42 // The linkage computes where all spill slots are located.
48 FrameOffset offset = linkage()->GetFrameOffset(op->index(), frame(), extra); 43 FrameOffset offset = linkage()->GetFrameOffset(op->index(), frame(), extra);
49 return Operand(offset.from_stack_pointer() ? rsp : rbp, offset.offset()); 44 return Operand(offset.from_stack_pointer() ? rsp : rbp, offset.offset());
50 } 45 }
51 46
52 static int NextOffset(int* offset) { 47 static int NextOffset(int* offset) {
(...skipping 967 matching lines...) Expand 10 before | Expand all | Expand 10 after
1020 } 1015 }
1021 } 1016 }
1022 MarkLazyDeoptSite(); 1017 MarkLazyDeoptSite();
1023 } 1018 }
1024 1019
1025 #undef __ 1020 #undef __
1026 1021
1027 } // namespace internal 1022 } // namespace internal
1028 } // namespace compiler 1023 } // namespace compiler
1029 } // namespace v8 1024 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/simplified-lowering.cc ('k') | src/compiler/x64/instruction-codes-x64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698