Index: src/ia32/lithium-codegen-ia32.cc |
diff --git a/src/ia32/lithium-codegen-ia32.cc b/src/ia32/lithium-codegen-ia32.cc |
index ca3a6400b284be0612a504847f08efa315672534..6762a6c6612abca46ac0c58303cb07a430a16720 100644 |
--- a/src/ia32/lithium-codegen-ia32.cc |
+++ b/src/ia32/lithium-codegen-ia32.cc |
@@ -2836,6 +2836,15 @@ void LCodeGen::DoLoadGlobalGeneric(LLoadGlobalGeneric* instr) { |
ASSERT(ToRegister(instr->result()).is(eax)); |
__ mov(LoadIC::NameRegister(), instr->name()); |
+ if (FLAG_vector_ics) { |
+ Register vector = ToRegister(instr->temp_vector()); |
+ ASSERT(vector.is(LoadIC::VectorRegister())); |
+ __ mov(vector, instr->hydrogen()->feedback_vector()); |
+ // No need to allocate this register. |
+ ASSERT(LoadIC::SlotRegister().is(eax)); |
+ __ mov(LoadIC::SlotRegister(), |
+ Immediate(Smi::FromInt(instr->hydrogen()->slot()))); |
+ } |
ContextualMode mode = instr->for_typeof() ? NOT_CONTEXTUAL : CONTEXTUAL; |
Handle<Code> ic = LoadIC::initialize_stub(isolate(), mode); |
CallCode(ic, RelocInfo::CODE_TARGET, instr); |
@@ -2970,6 +2979,15 @@ void LCodeGen::DoLoadNamedGeneric(LLoadNamedGeneric* instr) { |
ASSERT(ToRegister(instr->result()).is(eax)); |
__ mov(LoadIC::NameRegister(), instr->name()); |
+ if (FLAG_vector_ics) { |
+ Register vector = ToRegister(instr->temp_vector()); |
+ ASSERT(vector.is(LoadIC::VectorRegister())); |
+ __ mov(vector, instr->hydrogen()->feedback_vector()); |
+ // No need to allocate this register. |
+ ASSERT(LoadIC::SlotRegister().is(eax)); |
+ __ mov(LoadIC::SlotRegister(), |
+ Immediate(Smi::FromInt(instr->hydrogen()->slot()))); |
+ } |
Handle<Code> ic = LoadIC::initialize_stub(isolate(), NOT_CONTEXTUAL); |
CallCode(ic, RelocInfo::CODE_TARGET, instr); |
} |
@@ -3210,6 +3228,16 @@ void LCodeGen::DoLoadKeyedGeneric(LLoadKeyedGeneric* instr) { |
ASSERT(ToRegister(instr->object()).is(LoadIC::ReceiverRegister())); |
ASSERT(ToRegister(instr->key()).is(LoadIC::NameRegister())); |
+ if (FLAG_vector_ics) { |
+ Register vector = ToRegister(instr->temp_vector()); |
+ ASSERT(vector.is(LoadIC::VectorRegister())); |
+ __ mov(vector, instr->hydrogen()->feedback_vector()); |
+ // No need to allocate this register. |
+ ASSERT(LoadIC::SlotRegister().is(eax)); |
+ __ mov(LoadIC::SlotRegister(), |
+ Immediate(Smi::FromInt(instr->hydrogen()->slot()))); |
+ } |
+ |
Handle<Code> ic = isolate()->builtins()->KeyedLoadIC_Initialize(); |
CallCode(ic, RelocInfo::CODE_TARGET, instr); |
} |