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 154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
165 // Set a frame element to a constant. The index is frame-top relative. | 165 // Set a frame element to a constant. The index is frame-top relative. |
166 void SetElementAt(int index, Handle<Object> value) { | 166 void SetElementAt(int index, Handle<Object> value) { |
167 Result temp(value, cgen_); | 167 Result temp(value, cgen_); |
168 SetElementAt(index, &temp); | 168 SetElementAt(index, &temp); |
169 } | 169 } |
170 | 170 |
171 void PushElementAt(int index) { | 171 void PushElementAt(int index) { |
172 PushFrameSlotAt(elements_.length() - index - 1); | 172 PushFrameSlotAt(elements_.length() - index - 1); |
173 } | 173 } |
174 | 174 |
| 175 void StoreToElementAt(int index) { |
| 176 StoreToFrameSlotAt(elements_.length() - index - 1); |
| 177 } |
| 178 |
175 // A frame-allocated local as an assembly operand. | 179 // A frame-allocated local as an assembly operand. |
176 Operand LocalAt(int index) const { | 180 Operand LocalAt(int index) const { |
177 ASSERT(0 <= index); | 181 ASSERT(0 <= index); |
178 ASSERT(index < local_count_); | 182 ASSERT(index < local_count_); |
179 return Operand(ebp, kLocal0Offset - index * kPointerSize); | 183 return Operand(ebp, kLocal0Offset - index * kPointerSize); |
180 } | 184 } |
181 | 185 |
182 // Push a copy of the value of a local frame slot on top of the frame. | 186 // Push a copy of the value of a local frame slot on top of the frame. |
183 void PushLocalAt(int index) { | 187 void PushLocalAt(int index) { |
184 PushFrameSlotAt(local0_index() + index); | 188 PushFrameSlotAt(local0_index() + index); |
(...skipping 295 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
480 Result RawCallCodeObject(Handle<Code> code, RelocInfo::Mode rmode); | 484 Result RawCallCodeObject(Handle<Code> code, RelocInfo::Mode rmode); |
481 | 485 |
482 bool Equals(VirtualFrame* other); | 486 bool Equals(VirtualFrame* other); |
483 | 487 |
484 friend class JumpTarget; | 488 friend class JumpTarget; |
485 }; | 489 }; |
486 | 490 |
487 } } // namespace v8::internal | 491 } } // namespace v8::internal |
488 | 492 |
489 #endif // V8_VIRTUAL_FRAME_IA32_H_ | 493 #endif // V8_VIRTUAL_FRAME_IA32_H_ |
OLD | NEW |