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

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

Issue 12381034: Second codegen test passing on ARM (simulated). (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 9 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/stack_frame_arm.cc ('k') | runtime/vm/stack_frame_mips.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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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/globals.h" 5 #include "vm/globals.h"
6 #if defined(TARGET_ARCH_IA32) 6 #if defined(TARGET_ARCH_IA32)
7 7
8 #include "vm/instructions.h" 8 #include "vm/instructions.h"
9 #include "vm/isolate.h" 9 #include "vm/isolate.h"
10 #include "vm/stack_frame.h" 10 #include "vm/stack_frame.h"
11 11
12 namespace dart { 12 namespace dart {
13 13
14 // The constant kExitLinkOffsetInEntryFrame must be kept in sync with the 14 // The constant kExitLinkOffsetInEntryFrame must be kept in sync with the
15 // code in the InvokeDartCode stub. 15 // code in the InvokeDartCode stub.
16 static const int kSavedContextOffsetInEntryFrame = -5 * kWordSize; 16 static const int kSavedContextOffsetInEntryFrame = -5 * kWordSize;
17 static const int kExitLinkOffsetInEntryFrame = -4 * kWordSize; 17 static const int kExitLinkOffsetInEntryFrame = -4 * kWordSize;
18 static const int kPcAddressOffsetFromSp = -1 * kWordSize; 18 static const int kPcAddressOffsetFromSp = -1 * kWordSize;
19 static const int kEntrypointMarkerOffsetFromFp = -1 * kWordSize;
19 static const int kSpOffsetFromPreviousFp = 2 * kWordSize; 20 static const int kSpOffsetFromPreviousFp = 2 * kWordSize;
20 21
21 22
22 intptr_t StackFrame::PcAddressOffsetFromSp() { 23 intptr_t StackFrame::PcAddressOffsetFromSp() {
23 return kPcAddressOffsetFromSp; 24 return kPcAddressOffsetFromSp;
24 } 25 }
25 26
26 27
28 intptr_t StackFrame::EntrypointMarkerOffsetFromFp() {
29 return kEntrypointMarkerOffsetFromFp;
30 }
31
32
27 uword StackFrame::GetCallerSp() const { 33 uword StackFrame::GetCallerSp() const {
28 return fp() + kSpOffsetFromPreviousFp; 34 return fp() + kSpOffsetFromPreviousFp;
29 } 35 }
30 36
31 37
32 uword StackFrame::GetCallerFp() const { 38 uword StackFrame::GetCallerFp() const {
33 return *(reinterpret_cast<uword*>(fp())); 39 return *(reinterpret_cast<uword*>(fp()));
34 } 40 }
35 41
36 42
(...skipping 17 matching lines...) Expand all
54 void StackFrameIterator::SetupNextExitFrameData() { 60 void StackFrameIterator::SetupNextExitFrameData() {
55 uword exit_address = entry_.fp() + kExitLinkOffsetInEntryFrame; 61 uword exit_address = entry_.fp() + kExitLinkOffsetInEntryFrame;
56 uword exit_marker = *reinterpret_cast<uword*>(exit_address); 62 uword exit_marker = *reinterpret_cast<uword*>(exit_address);
57 frames_.fp_ = exit_marker; 63 frames_.fp_ = exit_marker;
58 frames_.sp_ = 0; 64 frames_.sp_ = 0;
59 } 65 }
60 66
61 } // namespace dart 67 } // namespace dart
62 68
63 #endif // defined TARGET_ARCH_IA32 69 #endif // defined TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « runtime/vm/stack_frame_arm.cc ('k') | runtime/vm/stack_frame_mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698