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

Side by Side Diff: runtime/vm/locations.cc

Issue 14925005: Remove stack_frame_<arch>.cc files. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « runtime/vm/intermediate_language_x64.cc ('k') | runtime/vm/parser.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 (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/locations.h" 5 #include "vm/locations.h"
6 6
7 #include "vm/assembler.h" 7 #include "vm/assembler.h"
8 #include "vm/il_printer.h" 8 #include "vm/il_printer.h"
9 #include "vm/intermediate_language.h" 9 #include "vm/intermediate_language.h"
10 #include "vm/flow_graph_compiler.h" 10 #include "vm/flow_graph_compiler.h"
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 ConstantInstr* constant = value->definition()->AsConstant(); 83 ConstantInstr* constant = value->definition()->AsConstant();
84 return (constant != NULL) 84 return (constant != NULL)
85 ? Location::Constant(constant->value()) 85 ? Location::Constant(constant->value())
86 : Location::Any(); 86 : Location::Any();
87 } 87 }
88 88
89 89
90 Address Location::ToStackSlotAddress() const { 90 Address Location::ToStackSlotAddress() const {
91 const intptr_t index = stack_index(); 91 const intptr_t index = stack_index();
92 if (index < 0) { 92 if (index < 0) {
93 const intptr_t offset = (kLastParamSlotIndex - index - 1) * kWordSize; 93 const intptr_t offset = (kParamEndSlotFromFp - index) * kWordSize;
94 return Address(FPREG, offset); 94 return Address(FPREG, offset);
95 } else { 95 } else {
96 const intptr_t offset = (kFirstLocalSlotIndex - index) * kWordSize; 96 const intptr_t offset = (kFirstLocalSlotFromFp - index) * kWordSize;
97 return Address(FPREG, offset); 97 return Address(FPREG, offset);
98 } 98 }
99 } 99 }
100 100
101 101
102 const char* Location::Name() const { 102 const char* Location::Name() const {
103 switch (kind()) { 103 switch (kind()) {
104 case kInvalid: return "?"; 104 case kInvalid: return "?";
105 case kRegister: return Assembler::RegisterName(reg()); 105 case kRegister: return Assembler::RegisterName(reg());
106 case kFpuRegister: return Assembler::FpuRegisterName(fpu_reg()); 106 case kFpuRegister: return Assembler::FpuRegisterName(fpu_reg());
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
172 172
173 if (!out().IsInvalid()) { 173 if (!out().IsInvalid()) {
174 f->Print(" => "); 174 f->Print(" => ");
175 out().PrintTo(f); 175 out().PrintTo(f);
176 } 176 }
177 177
178 if (always_calls()) f->Print(" C"); 178 if (always_calls()) f->Print(" C");
179 } 179 }
180 180
181 } // namespace dart 181 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/intermediate_language_x64.cc ('k') | runtime/vm/parser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698