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

Side by Side Diff: runtime/vm/constants_x64.h

Issue 14812005: Cleanup deoptimization code to make it architecture independent (in progress). (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/constants_mips.h ('k') | runtime/vm/deopt_instructions.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 (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 #ifndef VM_CONSTANTS_X64_H_ 5 #ifndef VM_CONSTANTS_X64_H_
6 #define VM_CONSTANTS_X64_H_ 6 #define VM_CONSTANTS_X64_H_
7 7
8 namespace dart { 8 namespace dart {
9 9
10 enum Register { 10 enum Register {
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 92
93 // Exception object is passed in this register to the catch handlers when an 93 // Exception object is passed in this register to the catch handlers when an
94 // exception is thrown. 94 // exception is thrown.
95 const Register kExceptionObjectReg = RAX; 95 const Register kExceptionObjectReg = RAX;
96 96
97 // Stack trace object is passed in this register to the catch handlers when 97 // Stack trace object is passed in this register to the catch handlers when
98 // an exception is thrown. 98 // an exception is thrown.
99 const Register kStackTraceObjectReg = RDX; 99 const Register kStackTraceObjectReg = RDX;
100 100
101 101
102 // TODO(regis): Move these constants to stack_frame_x64.h.
102 // Dart stack frame layout. 103 // Dart stack frame layout.
103 static const int kLastParamSlotIndex = 2; 104 static const int kLastParamSlotIndex = 2; // From fp.
104 static const int kFirstLocalSlotIndex = -2; 105 static const int kFirstLocalSlotIndex = -2; // From fp.
106 static const int kPcSlotIndexFromSp = -1;
107
108 /* X64 Dart Frame Layout
109
110 | | <- TOS
111 Callee frame | ... |
112 | current ret addr | (PC of current frame)
113 +-------------------+
114 Current frame | ... | <- RSP of current frame
115 | first local |
116 | PC Marker | (current frame's code entry)
117 | caller's RBP | <- RBP of current frame
118 | caller's ret addr | (PC of caller frame)
119 +-------------------+
120 Caller frame | last parameter |
121 | ... |
122 */
105 123
106 124
107 enum ScaleFactor { 125 enum ScaleFactor {
108 TIMES_1 = 0, 126 TIMES_1 = 0,
109 TIMES_2 = 1, 127 TIMES_2 = 1,
110 TIMES_4 = 2, 128 TIMES_4 = 2,
111 TIMES_8 = 3, 129 TIMES_8 = 3,
112 TIMES_16 = 4, 130 TIMES_16 = 4,
113 TIMES_HALF_WORD_SIZE = kWordSizeLog2 - 1 131 TIMES_HALF_WORD_SIZE = kWordSizeLog2 - 1
114 }; 132 };
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 }; 184 };
167 185
168 186
169 // The largest multibyte nop we will emit. This could go up to 15 if it 187 // The largest multibyte nop we will emit. This could go up to 15 if it
170 // becomes important to us. 188 // becomes important to us.
171 const int MAX_NOP_SIZE = 8; 189 const int MAX_NOP_SIZE = 8;
172 190
173 } // namespace dart 191 } // namespace dart
174 192
175 #endif // VM_CONSTANTS_X64_H_ 193 #endif // VM_CONSTANTS_X64_H_
OLDNEW
« no previous file with comments | « runtime/vm/constants_mips.h ('k') | runtime/vm/deopt_instructions.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698