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

Unified Diff: src/code-factory.cc

Issue 1912633002: [ic] Split LoadIC into LoadGlobalIC and LoadIC. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebasing Created 4 years, 6 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/code-factory.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 a2397437dba6370197eee217629425bfa741a52e..0be0ae77afea27c79125b2bae72ca69caad90f1d 100644
--- a/src/code-factory.cc
+++ b/src/code-factory.cc
@@ -12,12 +12,12 @@ namespace internal {
// static
-Callable CodeFactory::LoadIC(Isolate* isolate, TypeofMode typeof_mode) {
+Callable CodeFactory::LoadIC(Isolate* isolate) {
if (FLAG_tf_load_ic_stub) {
- LoadICTrampolineTFStub stub(isolate, LoadICState(typeof_mode));
+ LoadICTrampolineTFStub stub(isolate, LoadICState(NOT_INSIDE_TYPEOF));
return Callable(stub.GetCode(), LoadDescriptor(isolate));
}
- LoadICTrampolineStub stub(isolate, LoadICState(typeof_mode));
+ LoadICTrampolineStub stub(isolate, LoadICState(NOT_INSIDE_TYPEOF));
return Callable(stub.GetCode(), LoadDescriptor(isolate));
}
@@ -28,13 +28,25 @@ Callable CodeFactory::ApiGetter(Isolate* isolate) {
}
// static
-Callable CodeFactory::LoadICInOptimizedCode(Isolate* isolate,
- TypeofMode typeof_mode) {
+Callable CodeFactory::LoadICInOptimizedCode(Isolate* isolate) {
auto code = LoadIC::initialize_stub_in_optimized_code(
- isolate, LoadICState(typeof_mode).GetExtraICState());
+ isolate, LoadICState(NOT_INSIDE_TYPEOF).GetExtraICState());
return Callable(code, LoadWithVectorDescriptor(isolate));
}
+// static
+Callable CodeFactory::LoadGlobalIC(Isolate* isolate, TypeofMode typeof_mode) {
+ LoadGlobalICTrampolineStub stub(isolate, LoadICState(typeof_mode));
+ return Callable(stub.GetCode(), LoadDescriptor(isolate));
+}
+
+// static
+Callable CodeFactory::LoadGlobalICInOptimizedCode(Isolate* isolate,
+ TypeofMode typeof_mode) {
+ auto code = LoadGlobalIC::initialize_stub_in_optimized_code(
+ isolate, LoadICState(typeof_mode).GetExtraICState());
+ return Callable(code, LoadWithVectorDescriptor(isolate));
+}
// static
Callable CodeFactory::KeyedLoadIC(Isolate* isolate) {
« no previous file with comments | « src/code-factory.h ('k') | src/code-stubs.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698