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

Unified Diff: src/type-feedback-vector.cc

Issue 2673383002: [ic] Encode LoadGlobalIC's typeof mode in slot kind instead of code object's flags. (Closed)
Patch Set: Created 3 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
Index: src/type-feedback-vector.cc
diff --git a/src/type-feedback-vector.cc b/src/type-feedback-vector.cc
index 525a18e09497ab1ee70736f3774a4864367170b9..449273b84d132dee9252f511dda1f5a382049ef7 100644
--- a/src/type-feedback-vector.cc
+++ b/src/type-feedback-vector.cc
@@ -149,8 +149,10 @@ const char* TypeFeedbackMetadata::Kind2String(FeedbackVectorSlotKind kind) {
return "CALL_IC";
case FeedbackVectorSlotKind::LOAD_IC:
return "LOAD_IC";
- case FeedbackVectorSlotKind::LOAD_GLOBAL_IC:
- return "LOAD_GLOBAL_IC";
+ case FeedbackVectorSlotKind::LOAD_GLOBAL_INSIDE_TYPEOF_IC:
+ return "LOAD_GLOBAL_INSIDE_TYPEOF_IC";
+ case FeedbackVectorSlotKind::LOAD_GLOBAL_NOT_INSIDE_TYPEOF_IC:
+ return "LOAD_GLOBAL_NOT_INSIDE_TYPEOF_IC";
case FeedbackVectorSlotKind::KEYED_LOAD_IC:
return "KEYED_LOAD_IC";
case FeedbackVectorSlotKind::STORE_SLOPPY_IC:
@@ -215,7 +217,8 @@ Handle<TypeFeedbackVector> TypeFeedbackVector::New(
Object* extra_value = *uninitialized_sentinel;
switch (kind) {
- case FeedbackVectorSlotKind::LOAD_GLOBAL_IC:
+ case FeedbackVectorSlotKind::LOAD_GLOBAL_INSIDE_TYPEOF_IC:
+ case FeedbackVectorSlotKind::LOAD_GLOBAL_NOT_INSIDE_TYPEOF_IC:
array->set(index, isolate->heap()->empty_weak_cell(),
SKIP_WRITE_BARRIER);
break;
@@ -304,7 +307,8 @@ void TypeFeedbackVector::ClearSlotsImpl(SharedFunctionInfo* shared,
nexus.Clear(shared->code());
break;
}
- case FeedbackVectorSlotKind::LOAD_GLOBAL_IC: {
+ case FeedbackVectorSlotKind::LOAD_GLOBAL_INSIDE_TYPEOF_IC:
+ case FeedbackVectorSlotKind::LOAD_GLOBAL_NOT_INSIDE_TYPEOF_IC: {
LoadGlobalICNexus nexus(this, slot);
nexus.Clear(shared->code());
break;
@@ -368,12 +372,6 @@ void TypeFeedbackVector::ClearSlotsImpl(SharedFunctionInfo* shared,
}
-// static
-Handle<TypeFeedbackVector> TypeFeedbackVector::DummyVector(Isolate* isolate) {
- return isolate->factory()->dummy_vector();
-}
-
-
Handle<FixedArray> FeedbackNexus::EnsureArrayOfSize(int length) {
Isolate* isolate = GetIsolate();
Handle<Object> feedback = handle(GetFeedback(), isolate);

Powered by Google App Engine
This is Rietveld 408576698