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

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

Issue 944783002: Save top StackResource in entry frame. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 5 years, 10 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 | « no previous file | runtime/vm/allocation.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 #ifndef VM_ALLOCATION_H_ 5 #ifndef VM_ALLOCATION_H_
6 #define VM_ALLOCATION_H_ 6 #define VM_ALLOCATION_H_
7 7
8 #include "platform/assert.h" 8 #include "platform/assert.h"
9 #include "vm/base_isolate.h" 9 #include "vm/base_isolate.h"
10 #include "vm/globals.h" 10 #include "vm/globals.h"
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 BaseIsolate::AssertCurrent(isolate_); 58 BaseIsolate::AssertCurrent(isolate_);
59 } 59 }
60 #endif 60 #endif
61 } 61 }
62 62
63 // We can only create StackResources with Isolates, so provide the original 63 // We can only create StackResources with Isolates, so provide the original
64 // isolate to the subclasses. The only reason we have a BaseIsolate in the 64 // isolate to the subclasses. The only reason we have a BaseIsolate in the
65 // StackResource is to break the header include cycles. 65 // StackResource is to break the header include cycles.
66 Isolate* isolate() const { return reinterpret_cast<Isolate*>(isolate_); } 66 Isolate* isolate() const { return reinterpret_cast<Isolate*>(isolate_); }
67 67
68 // Destroy stack resources of isolate from top until stack_pointer, exclusive. 68 // Destroy stack resources of isolate until top exit frame.
69 static void Unwind(Isolate* isolate, uword stack_pointer); 69 static void Unwind(Isolate* isolate) { UnwindAbove(isolate, NULL); }
70 // Destroy stack resources of isolate above new_top, exclusive. 70 // Destroy stack resources of isolate above new_top, exclusive.
71 static void Unwind(Isolate* isolate, StackResource* new_top); 71 static void UnwindAbove(Isolate* isolate, StackResource* new_top);
72 72
73 private: 73 private:
74 BaseIsolate* const isolate_; // Current isolate for this stack resource. 74 BaseIsolate* const isolate_; // Current isolate for this stack resource.
75 StackResource* previous_; 75 StackResource* previous_;
76 76
77 DISALLOW_ALLOCATION(); 77 DISALLOW_ALLOCATION();
78 DISALLOW_IMPLICIT_CONSTRUCTORS(StackResource); 78 DISALLOW_IMPLICIT_CONSTRUCTORS(StackResource);
79 }; 79 };
80 80
81 81
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
116 // deallocated by invoking DeleteAll() on the zone they live in. 116 // deallocated by invoking DeleteAll() on the zone they live in.
117 void operator delete(void* pointer) { UNREACHABLE(); } 117 void operator delete(void* pointer) { UNREACHABLE(); }
118 118
119 private: 119 private:
120 DISALLOW_COPY_AND_ASSIGN(ZoneAllocated); 120 DISALLOW_COPY_AND_ASSIGN(ZoneAllocated);
121 }; 121 };
122 122
123 } // namespace dart 123 } // namespace dart
124 124
125 #endif // VM_ALLOCATION_H_ 125 #endif // VM_ALLOCATION_H_
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/allocation.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698