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

Unified Diff: src/code-factory.cc

Issue 2608883002: [builtins] Move several CodeStub-based ICs to builtins (Closed)
Patch Set: Created 3 years, 12 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/builtins/builtins-utils.h ('k') | src/code-stubs.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/code-factory.cc
diff --git a/src/code-factory.cc b/src/code-factory.cc
index 7a89f8a30e1dc1b3782588e28090cfae8ddb74ff..e7221c98c4020e1a4646583047b7eaeebf7f9720 100644
--- a/src/code-factory.cc
+++ b/src/code-factory.cc
@@ -29,8 +29,8 @@ Handle<Code> CodeFactory::RuntimeCEntry(Isolate* isolate, int result_size) {
// static
Callable CodeFactory::LoadIC(Isolate* isolate) {
- LoadICTrampolineStub stub(isolate);
- return make_callable(stub);
+ return Callable(isolate->builtins()->LoadICTrampoline(),
+ LoadDescriptor(isolate));
}
// static
@@ -41,8 +41,8 @@ Callable CodeFactory::ApiGetter(Isolate* isolate) {
// static
Callable CodeFactory::LoadICInOptimizedCode(Isolate* isolate) {
- LoadICStub stub(isolate);
- return make_callable(stub);
+ return Callable(isolate->builtins()->LoadIC(),
+ LoadWithVectorDescriptor(isolate));
}
// static
@@ -60,14 +60,14 @@ Callable CodeFactory::LoadGlobalICInOptimizedCode(Isolate* isolate,
// static
Callable CodeFactory::KeyedLoadIC(Isolate* isolate) {
- KeyedLoadICTrampolineTFStub stub(isolate);
- return make_callable(stub);
+ return Callable(isolate->builtins()->KeyedLoadICTrampoline(),
+ LoadDescriptor(isolate));
}
// static
Callable CodeFactory::KeyedLoadICInOptimizedCode(Isolate* isolate) {
- KeyedLoadICTFStub stub(isolate);
- return make_callable(stub);
+ return Callable(isolate->builtins()->KeyedLoadIC(),
+ LoadWithVectorDescriptor(isolate));
}
// static
@@ -93,29 +93,36 @@ Callable CodeFactory::CallICInOptimizedCode(Isolate* isolate,
// static
Callable CodeFactory::StoreIC(Isolate* isolate, LanguageMode language_mode) {
- StoreICTrampolineStub stub(isolate, StoreICState(language_mode));
- return make_callable(stub);
+ return Callable(language_mode == STRICT
+ ? isolate->builtins()->StoreICStrictTrampoline()
+ : isolate->builtins()->StoreICTrampoline(),
+ StoreDescriptor(isolate));
}
// static
Callable CodeFactory::StoreICInOptimizedCode(Isolate* isolate,
LanguageMode language_mode) {
- StoreICStub stub(isolate, StoreICState(language_mode));
- return make_callable(stub);
+ return Callable(language_mode == STRICT ? isolate->builtins()->StoreICStrict()
+ : isolate->builtins()->StoreIC(),
+ StoreWithVectorDescriptor(isolate));
}
// static
Callable CodeFactory::KeyedStoreIC(Isolate* isolate,
LanguageMode language_mode) {
- KeyedStoreICTrampolineTFStub stub(isolate, StoreICState(language_mode));
- return make_callable(stub);
+ return Callable(language_mode == STRICT
+ ? isolate->builtins()->KeyedStoreICStrictTrampoline()
+ : isolate->builtins()->KeyedStoreICTrampoline(),
+ StoreDescriptor(isolate));
}
// static
Callable CodeFactory::KeyedStoreICInOptimizedCode(Isolate* isolate,
LanguageMode language_mode) {
- KeyedStoreICTFStub stub(isolate, StoreICState(language_mode));
- return make_callable(stub);
+ return Callable(language_mode == STRICT
+ ? isolate->builtins()->KeyedStoreICStrict()
+ : isolate->builtins()->KeyedStoreIC(),
+ StoreWithVectorDescriptor(isolate));
}
// static
« no previous file with comments | « src/builtins/builtins-utils.h ('k') | src/code-stubs.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698