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

Unified Diff: src/bootstrapper.cc

Issue 1475953002: [stubs] A new approach to TF stubs (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Merge with ToT Created 5 years 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/bootstrapper.h ('k') | src/code-stubs.h » ('j') | src/code-stubs.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/bootstrapper.cc
diff --git a/src/bootstrapper.cc b/src/bootstrapper.cc
index a263fbce91b561cf2edf1c00375a5e7c6d8cd53a..5e7f4c0633afe9125810371f3cddfdf64b01a67c 100644
--- a/src/bootstrapper.cc
+++ b/src/bootstrapper.cc
@@ -59,7 +59,6 @@ template Handle<String> Bootstrapper::SourceLookup<ExperimentalNatives>(
template Handle<String> Bootstrapper::SourceLookup<ExperimentalExtraNatives>(
int index);
template Handle<String> Bootstrapper::SourceLookup<ExtraNatives>(int index);
-template Handle<String> Bootstrapper::SourceLookup<CodeStubNatives>(int index);
void Bootstrapper::Initialize(bool create_heap_objects) {
@@ -130,7 +129,6 @@ void Bootstrapper::TearDown() {
DeleteNativeSources(ExtraNatives::GetSourceCache(isolate_->heap()));
DeleteNativeSources(
ExperimentalExtraNatives::GetSourceCache(isolate_->heap()));
- DeleteNativeSources(CodeStubNatives::GetSourceCache(isolate_->heap()));
extensions_cache_.Initialize(isolate_, false); // Yes, symmetrical
}
@@ -341,26 +339,6 @@ Handle<Context> Bootstrapper::CreateEnvironment(
}
-bool Bootstrapper::CreateCodeStubContext(Isolate* isolate) {
- HandleScope scope(isolate);
- SaveContext save_context(isolate);
- BootstrapperActive active(this);
-
- v8::ExtensionConfiguration no_extensions;
- Handle<Context> native_context = CreateEnvironment(
- MaybeHandle<JSGlobalProxy>(), v8::Local<v8::ObjectTemplate>(),
- &no_extensions, THIN_CONTEXT);
- isolate->heap()->SetRootCodeStubContext(*native_context);
- isolate->set_context(*native_context);
- Handle<JSObject> code_stub_exports =
- isolate->factory()->NewJSObject(isolate->object_function());
- JSObject::NormalizeProperties(code_stub_exports, CLEAR_INOBJECT_PROPERTIES, 2,
- "container to export to extra natives");
- isolate->heap()->SetRootCodeStubExportsObject(*code_stub_exports);
- return InstallCodeStubNatives(isolate);
-}
-
-
static void SetObjectPrototype(Handle<JSObject> object, Handle<Object> proto) {
// object.__proto__ = proto;
Handle<Map> old_map = Handle<Map>(object->map());
@@ -1574,20 +1552,6 @@ bool Bootstrapper::CompileExperimentalExtraBuiltin(Isolate* isolate,
}
-bool Bootstrapper::CompileCodeStubBuiltin(Isolate* isolate, int index) {
- HandleScope scope(isolate);
- Vector<const char> name = CodeStubNatives::GetScriptName(index);
- Handle<String> source_code =
- isolate->bootstrapper()->SourceLookup<CodeStubNatives>(index);
- Handle<JSObject> global(isolate->global_object());
- Handle<JSObject> exports(isolate->heap()->code_stub_exports_object());
- Handle<Object> args[] = {global, exports};
- bool result =
- CompileNative(isolate, name, source_code, arraysize(args), args);
- return result;
-}
-
-
bool Bootstrapper::CompileNative(Isolate* isolate, Vector<const char> name,
Handle<String> source, int argc,
Handle<Object> argv[]) {
@@ -2600,16 +2564,6 @@ bool Genesis::InstallDebuggerNatives() {
}
-bool Bootstrapper::InstallCodeStubNatives(Isolate* isolate) {
- for (int i = CodeStubNatives::GetDebuggerCount();
- i < CodeStubNatives::GetBuiltinsCount(); i++) {
- if (!CompileCodeStubBuiltin(isolate, i)) return false;
- }
-
- return true;
-}
-
-
static void InstallBuiltinFunctionId(Handle<JSObject> holder,
const char* function_name,
BuiltinFunctionId id) {
« no previous file with comments | « src/bootstrapper.h ('k') | src/code-stubs.h » ('j') | src/code-stubs.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698