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

Unified Diff: runtime/vm/coverage.cc

Issue 982873004: Thread/Isolate refactoring: new(Isolate) -> new(Zone) (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/constant_propagator.cc ('k') | runtime/vm/dart_entry.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/coverage.cc
===================================================================
--- runtime/vm/coverage.cc (revision 44266)
+++ runtime/vm/coverage.cc (working copy)
@@ -55,7 +55,9 @@
void CodeCoverage::CompileAndAdd(const Function& function,
const JSONArray& hits_arr,
const GrowableArray<intptr_t>& pos_to_line) {
- Isolate* isolate = Isolate::Current();
+ Thread* thread = Thread::Current();
+ Zone* zone = thread->zone();
+ Isolate* isolate = thread->isolate();
if (!function.HasCode()) {
// If the function should not be compiled or if the compilation failed,
// then just skip this method.
@@ -71,7 +73,7 @@
return;
}
const Error& err = Error::Handle(
- isolate, Compiler::CompileFunction(isolate, function));
+ zone, Compiler::CompileFunction(thread, function));
if (!err.IsNull()) {
return;
}
@@ -80,7 +82,7 @@
// Print the hit counts for all IC datas.
ZoneGrowableArray<const ICData*>* ic_data_array =
- new(isolate) ZoneGrowableArray<const ICData*>();
+ new(zone) ZoneGrowableArray<const ICData*>();
function.RestoreICDataMap(ic_data_array);
const Code& code = Code::Handle(function.unoptimized_code());
const PcDescriptors& descriptors = PcDescriptors::Handle(
« no previous file with comments | « runtime/vm/constant_propagator.cc ('k') | runtime/vm/dart_entry.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698