OLD | NEW |
1 // Copyright 2009 the V8 project authors. All rights reserved. | 1 // Copyright 2009 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
85 static const int kMarkerOffset = -2 * kPointerSize; | 85 static const int kMarkerOffset = -2 * kPointerSize; |
86 static const int kContextOffset = -1 * kPointerSize; | 86 static const int kContextOffset = -1 * kPointerSize; |
87 static const int kCallerFPOffset = 0 * kPointerSize; | 87 static const int kCallerFPOffset = 0 * kPointerSize; |
88 static const int kCallerPCOffset = +1 * kPointerSize; | 88 static const int kCallerPCOffset = +1 * kPointerSize; |
89 static const int kCallerSPOffset = +2 * kPointerSize; | 89 static const int kCallerSPOffset = +2 * kPointerSize; |
90 }; | 90 }; |
91 | 91 |
92 | 92 |
93 class JavaScriptFrameConstants : public AllStatic { | 93 class JavaScriptFrameConstants : public AllStatic { |
94 public: | 94 public: |
| 95 // FP-relative. |
95 static const int kLocal0Offset = StandardFrameConstants::kExpressionsOffset; | 96 static const int kLocal0Offset = StandardFrameConstants::kExpressionsOffset; |
96 static const int kSavedRegistersOffset = +2 * kPointerSize; | 97 static const int kSavedRegistersOffset = +2 * kPointerSize; |
97 static const int kFunctionOffset = StandardFrameConstants::kMarkerOffset; | 98 static const int kFunctionOffset = StandardFrameConstants::kMarkerOffset; |
98 | 99 |
| 100 // Caller SP-relative. |
99 static const int kParam0Offset = -2 * kPointerSize; | 101 static const int kParam0Offset = -2 * kPointerSize; |
100 static const int kReceiverOffset = -1 * kPointerSize; | 102 static const int kReceiverOffset = -1 * kPointerSize; |
101 }; | 103 }; |
102 | 104 |
103 | 105 |
104 class ArgumentsAdaptorFrameConstants : public AllStatic { | 106 class ArgumentsAdaptorFrameConstants : public AllStatic { |
105 public: | 107 public: |
106 static const int kLengthOffset = StandardFrameConstants::kExpressionsOffset; | 108 static const int kLengthOffset = StandardFrameConstants::kExpressionsOffset; |
107 }; | 109 }; |
108 | 110 |
109 | 111 |
110 class InternalFrameConstants : public AllStatic { | 112 class InternalFrameConstants : public AllStatic { |
111 public: | 113 public: |
112 static const int kCodeOffset = StandardFrameConstants::kExpressionsOffset; | 114 static const int kCodeOffset = StandardFrameConstants::kExpressionsOffset; |
113 }; | 115 }; |
114 | 116 |
115 | 117 |
116 inline Object* JavaScriptFrame::function_slot_object() const { | 118 inline Object* JavaScriptFrame::function_slot_object() const { |
117 const int offset = JavaScriptFrameConstants::kFunctionOffset; | 119 const int offset = JavaScriptFrameConstants::kFunctionOffset; |
118 return Memory::Object_at(fp() + offset); | 120 return Memory::Object_at(fp() + offset); |
119 } | 121 } |
120 | 122 |
121 } } // namespace v8::internal | 123 } } // namespace v8::internal |
122 | 124 |
123 #endif // V8_X64_FRAMES_X64_H_ | 125 #endif // V8_X64_FRAMES_X64_H_ |
OLD | NEW |