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

Unified Diff: src/runtime.cc

Issue 6538089: [Isolates] Speed up Context::Lookup by avoiding implicit TLS reads. (Closed)
Patch Set: Created 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/contexts.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/runtime.cc
diff --git a/src/runtime.cc b/src/runtime.cc
index 3c40896f742cf8bd23de10f79f6e5f9ad73fabc0..4d430c3651978cab63c1dfd70b0134d2ffa3a494 100644
--- a/src/runtime.cc
+++ b/src/runtime.cc
@@ -5444,7 +5444,7 @@ static MaybeObject* Runtime_StringToArray(RUNTIME_CALLING_CONVENTION) {
isolate->heap()->AllocateUninitializedFixedArray(length);
if (!maybe_obj->ToObject(&obj)) return maybe_obj;
}
- elements = Handle<FixedArray>(FixedArray::cast(obj));
+ elements = Handle<FixedArray>(FixedArray::cast(obj), isolate);
Vector<const char> chars = s->ToAsciiVector();
// Note, this will initialize all elements (not only the prefix)
@@ -7893,7 +7893,7 @@ static ObjectPair Runtime_ResolvePossiblyDirectEval(
Handle<Object> receiver; // Will be overwritten.
// Compute the calling context.
- Handle<Context> context = Handle<Context>(isolate->context());
+ Handle<Context> context = Handle<Context>(isolate->context(), isolate);
#ifdef DEBUG
// Make sure Isolate::context() agrees with the old code that traversed
// the stack frames to compute the context.
@@ -7914,9 +7914,10 @@ static ObjectPair Runtime_ResolvePossiblyDirectEval(
// reached.
if (attributes != ABSENT || context->IsGlobalContext()) break;
if (context->is_function_context()) {
- context = Handle<Context>(Context::cast(context->closure()->context()));
+ context = Handle<Context>(Context::cast(context->closure()->context()),
+ isolate);
} else {
- context = Handle<Context>(context->previous());
+ context = Handle<Context>(context->previous(), isolate);
}
}
@@ -7938,7 +7939,7 @@ static ObjectPair Runtime_ResolvePossiblyDirectEval(
receiver = Handle<Object>(context->get(index), isolate);
} else if (receiver->IsJSContextExtensionObject()) {
receiver = Handle<JSObject>(
- isolate->context()->global()->global_receiver());
+ isolate->context()->global()->global_receiver(), isolate);
}
return MakePair(*callee, *receiver);
}
« no previous file with comments | « src/contexts.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698