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

Side by Side Diff: runtime/vm/base_isolate.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 | « runtime/vm/allocation.cc ('k') | runtime/vm/exceptions.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 #ifndef VM_BASE_ISOLATE_H_ 5 #ifndef VM_BASE_ISOLATE_H_
6 #define VM_BASE_ISOLATE_H_ 6 #define VM_BASE_ISOLATE_H_
7 7
8 #include "vm/globals.h"
9
8 namespace dart { 10 namespace dart {
9 11
10 class HandleScope; 12 class HandleScope;
11 class StackResource; 13 class StackResource;
12 class Zone; 14 class Zone;
13 15
14 // A BaseIsolate contains just enough functionality to allocate 16 // A BaseIsolate contains just enough functionality to allocate
15 // StackResources. This allows us to inline the StackResource 17 // StackResources. This allows us to inline the StackResource
16 // constructor/destructor for performance. 18 // constructor/destructor for performance.
17 class BaseIsolate { 19 class BaseIsolate {
18 public: 20 public:
19 StackResource* top_resource() const { return top_resource_; } 21 StackResource* top_resource() const { return top_resource_; }
20 void set_top_resource(StackResource* value) { top_resource_ = value; } 22 void set_top_resource(StackResource* value) { top_resource_ = value; }
23 static intptr_t top_resource_offset() {
24 return OFFSET_OF(BaseIsolate, top_resource_);
25 }
21 26
22 // DEPRECATED: Use Thread::current_zone. 27 // DEPRECATED: Use Thread::current_zone.
23 Zone* current_zone() const { return current_zone_; } 28 Zone* current_zone() const { return current_zone_; }
24 void set_current_zone(Zone* zone) { current_zone_ = zone; } 29 void set_current_zone(Zone* zone) { current_zone_ = zone; }
25 30
26 HandleScope* top_handle_scope() const { 31 HandleScope* top_handle_scope() const {
27 #if defined(DEBUG) 32 #if defined(DEBUG)
28 return top_handle_scope_; 33 return top_handle_scope_;
29 #else 34 #else
30 return 0; 35 return 0;
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
124 #endif 129 #endif
125 int32_t no_callback_scope_depth_; 130 int32_t no_callback_scope_depth_;
126 131
127 private: 132 private:
128 DISALLOW_COPY_AND_ASSIGN(BaseIsolate); 133 DISALLOW_COPY_AND_ASSIGN(BaseIsolate);
129 }; 134 };
130 135
131 } // namespace dart 136 } // namespace dart
132 137
133 #endif // VM_BASE_ISOLATE_H_ 138 #endif // VM_BASE_ISOLATE_H_
OLDNEW
« no previous file with comments | « runtime/vm/allocation.cc ('k') | runtime/vm/exceptions.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698