Index: src/ia32/ic-ia32.cc |
diff --git a/src/ia32/ic-ia32.cc b/src/ia32/ic-ia32.cc |
index 1cd7549f6e516af9cf40ade15f69a6edc0fb4a26..1168932057fb59aa36b3725be9017ee163f9672d 100644 |
--- a/src/ia32/ic-ia32.cc |
+++ b/src/ia32/ic-ia32.cc |
@@ -860,10 +860,10 @@ void KeyedStoreIC::GenerateGeneric(MacroAssembler* masm, |
// The generated code does not accept smi keys. |
// The generated code falls through if both probes miss. |
-static void GenerateMonomorphicCacheProbe(MacroAssembler* masm, |
- int argc, |
- Code::Kind kind, |
- Code::ExtraICState extra_ic_state) { |
+void CallICBase::GenerateMonomorphicCacheProbe(MacroAssembler* masm, |
+ int argc, |
+ Code::Kind kind, |
+ Code::ExtraICState extra_state) { |
// ----------- S t a t e ------------- |
// -- ecx : name |
// -- edx : receiver |
@@ -873,11 +873,11 @@ static void GenerateMonomorphicCacheProbe(MacroAssembler* masm, |
// Probe the stub cache. |
Code::Flags flags = Code::ComputeFlags(kind, |
MONOMORPHIC, |
- extra_ic_state, |
+ extra_state, |
NORMAL, |
argc); |
- Isolate::Current()->stub_cache()->GenerateProbe(masm, flags, edx, ecx, ebx, |
- eax); |
+ Isolate* isolate = masm->isolate(); |
+ isolate->stub_cache()->GenerateProbe(masm, flags, edx, ecx, ebx, eax); |
// If the stub cache probing failed, the receiver might be a value. |
// For value objects, we use the map of the prototype objects for |
@@ -903,9 +903,9 @@ static void GenerateMonomorphicCacheProbe(MacroAssembler* masm, |
// Check for boolean. |
__ bind(&non_string); |
- __ cmp(edx, FACTORY->true_value()); |
+ __ cmp(edx, isolate->factory()->true_value()); |
__ j(equal, &boolean); |
- __ cmp(edx, FACTORY->false_value()); |
+ __ cmp(edx, isolate->factory()->false_value()); |
__ j(not_equal, &miss); |
__ bind(&boolean); |
StubCompiler::GenerateLoadGlobalFunctionPrototype( |
@@ -913,8 +913,7 @@ static void GenerateMonomorphicCacheProbe(MacroAssembler* masm, |
// Probe the stub cache for the value object. |
__ bind(&probe); |
- Isolate::Current()->stub_cache()->GenerateProbe(masm, flags, edx, ecx, ebx, |
- no_reg); |
+ isolate->stub_cache()->GenerateProbe(masm, flags, edx, ecx, ebx, no_reg); |
__ bind(&miss); |
} |
@@ -1044,7 +1043,7 @@ void CallICBase::GenerateMiss(MacroAssembler* masm, |
void CallIC::GenerateMegamorphic(MacroAssembler* masm, |
int argc, |
- Code::ExtraICState extra_ic_state) { |
+ Code::ExtraICState extra_state) { |
// ----------- S t a t e ------------- |
// -- ecx : name |
// -- esp[0] : return address |
@@ -1055,9 +1054,10 @@ void CallIC::GenerateMegamorphic(MacroAssembler* masm, |
// Get the receiver of the function from the stack; 1 ~ return address. |
__ mov(edx, Operand(esp, (argc + 1) * kPointerSize)); |
- GenerateMonomorphicCacheProbe(masm, argc, Code::CALL_IC, extra_ic_state); |
+ CallICBase::GenerateMonomorphicCacheProbe(masm, argc, Code::CALL_IC, |
+ extra_state); |
- GenerateMiss(masm, argc, extra_ic_state); |
+ GenerateMiss(masm, argc, extra_state); |
} |
@@ -1159,10 +1159,8 @@ void KeyedCallIC::GenerateMegamorphic(MacroAssembler* masm, int argc) { |
__ bind(&lookup_monomorphic_cache); |
__ IncrementCounter(counters->keyed_call_generic_lookup_cache(), 1); |
- GenerateMonomorphicCacheProbe(masm, |
- argc, |
- Code::KEYED_CALL_IC, |
- Code::kNoExtraICState); |
+ CallICBase::GenerateMonomorphicCacheProbe(masm, argc, Code::KEYED_CALL_IC, |
+ Code::kNoExtraICState); |
// Fall through on miss. |
__ bind(&slow_call); |