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

Unified Diff: src/ia32/full-codegen-ia32.cc

Issue 408183003: Express LoadIC extra ic state with LoadIC::State (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Ports. Created 6 years, 5 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/full-codegen.cc ('k') | src/ia32/lithium-codegen-ia32.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ia32/full-codegen-ia32.cc
diff --git a/src/ia32/full-codegen-ia32.cc b/src/ia32/full-codegen-ia32.cc
index a4b4c6dd6f3894c2cc4cc1ebe960e2b00903fceb..cc9bf74b4fa4e38f16404af13af9bbb87bc37c12 100644
--- a/src/ia32/full-codegen-ia32.cc
+++ b/src/ia32/full-codegen-ia32.cc
@@ -1344,11 +1344,7 @@ void FullCodeGenerator::EmitLoadGlobalCheckExtensions(VariableProxy* proxy,
Immediate(Smi::FromInt(proxy->VariableFeedbackSlot())));
}
- ContextualMode mode = (typeof_state == INSIDE_TYPEOF)
- ? NOT_CONTEXTUAL
- : CONTEXTUAL;
-
- CallLoadIC(mode);
+ CallLoadIC(typeof_state);
}
@@ -1430,7 +1426,7 @@ void FullCodeGenerator::EmitVariableLoad(VariableProxy* proxy) {
__ mov(LoadIC::SlotRegister(),
Immediate(Smi::FromInt(proxy->VariableFeedbackSlot())));
}
- CallLoadIC(CONTEXTUAL);
+ CallLoadIC(NOT_INSIDE_TYPEOF);
context()->Plug(eax);
break;
}
@@ -2056,7 +2052,7 @@ void FullCodeGenerator::VisitYield(Yield* expr) {
__ mov(LoadIC::SlotRegister(),
Immediate(Smi::FromInt(expr->DoneFeedbackSlot())));
}
- CallLoadIC(NOT_CONTEXTUAL); // result.done in eax
+ CallLoadIC(); // result.done in eax
Handle<Code> bool_ic = ToBooleanStub::GetUninitialized(isolate());
CallIC(bool_ic);
__ test(eax, eax);
@@ -2070,7 +2066,7 @@ void FullCodeGenerator::VisitYield(Yield* expr) {
__ mov(LoadIC::SlotRegister(),
Immediate(Smi::FromInt(expr->ValueFeedbackSlot())));
}
- CallLoadIC(NOT_CONTEXTUAL); // result.value in eax
+ CallLoadIC(); // result.value in eax
context()->DropAndPlug(2, eax); // drop iter and g
break;
}
@@ -2233,9 +2229,9 @@ void FullCodeGenerator::EmitNamedPropertyLoad(Property* prop) {
if (FLAG_vector_ics) {
__ mov(LoadIC::SlotRegister(),
Immediate(Smi::FromInt(prop->PropertyFeedbackSlot())));
- CallLoadIC(NOT_CONTEXTUAL);
+ CallLoadIC(INSIDE_TYPEOF);
} else {
- CallLoadIC(NOT_CONTEXTUAL, prop->PropertyFeedbackId());
+ CallLoadIC(INSIDE_TYPEOF, prop->PropertyFeedbackId());
}
}
@@ -4059,9 +4055,9 @@ void FullCodeGenerator::VisitCallRuntime(CallRuntime* expr) {
if (FLAG_vector_ics) {
__ mov(LoadIC::SlotRegister(),
Immediate(Smi::FromInt(expr->CallRuntimeFeedbackSlot())));
- CallLoadIC(NOT_CONTEXTUAL);
+ CallLoadIC(INSIDE_TYPEOF);
} else {
- CallLoadIC(NOT_CONTEXTUAL, expr->CallRuntimeFeedbackId());
+ CallLoadIC(INSIDE_TYPEOF, expr->CallRuntimeFeedbackId());
}
// Push the target function under the receiver.
@@ -4414,9 +4410,8 @@ void FullCodeGenerator::VisitForTypeofValue(Expression* expr) {
__ mov(LoadIC::SlotRegister(),
Immediate(Smi::FromInt(proxy->VariableFeedbackSlot())));
}
- // Use a regular load, not a contextual load, to avoid a reference
- // error.
- CallLoadIC(NOT_CONTEXTUAL);
+ // We don't want a reference error if the load fails on the global object.
+ CallLoadIC(INSIDE_TYPEOF);
PrepareForBailout(expr, TOS_REG);
context()->Plug(eax);
} else if (proxy != NULL && proxy->var()->IsLookupSlot()) {
« no previous file with comments | « src/full-codegen.cc ('k') | src/ia32/lithium-codegen-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698