Commit 1ae2ea08 authored by vitalyr@chromium.org's avatar vitalyr@chromium.org

Remove more TLS hurting Dromaeo DOM.

Patch by Dmitry Lomov.

Review URL: http://codereview.chromium.org/6745029


git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7380 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent fb6d7e17
......@@ -3240,14 +3240,16 @@ int Function::GetScriptLineNumber() const {
int String::Length() const {
if (IsDeadCheck(i::Isolate::Current(), "v8::String::Length()")) return 0;
return Utils::OpenHandle(this)->length();
i::Handle<i::String> str = Utils::OpenHandle(this);
if (IsDeadCheck(str->GetIsolate(), "v8::String::Length()")) return 0;
return str->length();
}
int String::Utf8Length() const {
if (IsDeadCheck(i::Isolate::Current(), "v8::String::Utf8Length()")) return 0;
return Utils::OpenHandle(this)->Utf8Length();
i::Handle<i::String> str = Utils::OpenHandle(this);
if (IsDeadCheck(str->GetIsolate(), "v8::String::Utf8Length()")) return 0;
return str->Utf8Length();
}
......
......@@ -619,7 +619,7 @@ void Logger::ApiNamedPropertyAccess(const char* tag,
class_name_obj->ToCString(DISALLOW_NULLS, ROBUST_STRING_TRAVERSAL);
SmartPointer<char> property_name =
String::cast(name)->ToCString(DISALLOW_NULLS, ROBUST_STRING_TRAVERSAL);
LOGGER->ApiEvent("api,%s,\"%s\",\"%s\"\n", tag, *class_name, *property_name);
ApiEvent("api,%s,\"%s\",\"%s\"\n", tag, *class_name, *property_name);
#endif
}
......@@ -631,7 +631,7 @@ void Logger::ApiIndexedPropertyAccess(const char* tag,
String* class_name_obj = holder->class_name();
SmartPointer<char> class_name =
class_name_obj->ToCString(DISALLOW_NULLS, ROBUST_STRING_TRAVERSAL);
LOGGER->ApiEvent("api,%s,\"%s\",%u\n", tag, *class_name, index);
ApiEvent("api,%s,\"%s\",%u\n", tag, *class_name, index);
#endif
}
......@@ -641,7 +641,7 @@ void Logger::ApiObjectAccess(const char* tag, JSObject* object) {
String* class_name_obj = object->class_name();
SmartPointer<char> class_name =
class_name_obj->ToCString(DISALLOW_NULLS, ROBUST_STRING_TRAVERSAL);
LOGGER->ApiEvent("api,%s,\"%s\"\n", tag, *class_name);
ApiEvent("api,%s,\"%s\"\n", tag, *class_name);
#endif
}
......@@ -649,7 +649,7 @@ void Logger::ApiObjectAccess(const char* tag, JSObject* object) {
void Logger::ApiEntryCall(const char* name) {
#ifdef ENABLE_LOGGING_AND_PROFILING
if (!log_->IsEnabled() || !FLAG_log_api) return;
LOGGER->ApiEvent("api,%s\n", name);
ApiEvent("api,%s\n", name);
#endif
}
......
......@@ -7585,9 +7585,9 @@ MaybeObject* JSObject::GetElementWithInterceptor(Object* receiver,
// callbacks or interceptor calls.
AssertNoContextChange ncc;
HandleScope scope(isolate);
Handle<InterceptorInfo> interceptor(GetIndexedInterceptor());
Handle<Object> this_handle(receiver);
Handle<JSObject> holder_handle(this);
Handle<InterceptorInfo> interceptor(GetIndexedInterceptor(), isolate);
Handle<Object> this_handle(receiver, isolate);
Handle<JSObject> holder_handle(this, isolate);
if (!interceptor->getter()->IsUndefined()) {
v8::IndexedPropertyGetter getter =
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment