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

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

Issue 1389353004: Remove isolate argument from handle allocation: Part II (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: c Created 5 years, 2 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
« no previous file with comments | « runtime/vm/symbols.cc ('k') | no next file » | 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) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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/tags.h" 5 #include "vm/tags.h"
6 6
7 #include "vm/isolate.h" 7 #include "vm/isolate.h"
8 #include "vm/json_stream.h" 8 #include "vm/json_stream.h"
9 #include "vm/native_entry.h" 9 #include "vm/native_entry.h"
10 #include "vm/runtime_entry.h" 10 #include "vm/runtime_entry.h"
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
138 for (intptr_t i = 1; i < VMTag::kNumVMTags; i++) { 138 for (intptr_t i = 1; i < VMTag::kNumVMTags; i++) {
139 arr.AddValue64(counters_[i]); 139 arr.AddValue64(counters_[i]);
140 } 140 }
141 } 141 }
142 } 142 }
143 143
144 144
145 const char* UserTags::TagName(uword tag_id) { 145 const char* UserTags::TagName(uword tag_id) {
146 ASSERT(tag_id >= kUserTagIdOffset); 146 ASSERT(tag_id >= kUserTagIdOffset);
147 ASSERT(tag_id < kUserTagIdOffset + kMaxUserTags); 147 ASSERT(tag_id < kUserTagIdOffset + kMaxUserTags);
148 Isolate* isolate = Isolate::Current(); 148 Zone* zone = Thread::Current()->zone();
149 const UserTag& tag = 149 const UserTag& tag =
150 UserTag::Handle(isolate, UserTag::FindTagById(tag_id)); 150 UserTag::Handle(zone, UserTag::FindTagById(tag_id));
151 ASSERT(!tag.IsNull()); 151 ASSERT(!tag.IsNull());
152 const String& label = String::Handle(isolate, tag.label()); 152 const String& label = String::Handle(zone, tag.label());
153 return label.ToCString(); 153 return label.ToCString();
154 } 154 }
155 155
156 156
157 } // namespace dart 157 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/symbols.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698