Index: src/code-stubs.h |
diff --git a/src/code-stubs.h b/src/code-stubs.h |
index 515f2e578e613470e9a228826df201f7bba6d116..ac373f018be8ec60bf27c90007325a01a3ee10b7 100644 |
--- a/src/code-stubs.h |
+++ b/src/code-stubs.h |
@@ -2114,23 +2114,36 @@ |
class LoadDictionaryElementStub : public HydrogenCodeStub { |
public: |
- explicit LoadDictionaryElementStub(Isolate* isolate) |
- : HydrogenCodeStub(isolate) {} |
+ explicit LoadDictionaryElementStub(Isolate* isolate, const LoadICState& state) |
+ : HydrogenCodeStub(isolate) { |
+ minor_key_ = state.GetExtraICState(); |
+ } |
CallInterfaceDescriptor GetCallInterfaceDescriptor() override { |
return LoadWithVectorDescriptor(isolate()); |
} |
+ LanguageMode language_mode() const { |
+ return LoadICState::GetLanguageMode(MinorKey()); |
+ } |
+ |
DEFINE_HYDROGEN_CODE_STUB(LoadDictionaryElement, HydrogenCodeStub); |
}; |
class KeyedLoadGenericStub : public HydrogenCodeStub { |
public: |
- explicit KeyedLoadGenericStub(Isolate* isolate) : HydrogenCodeStub(isolate) {} |
+ explicit KeyedLoadGenericStub(Isolate* isolate, const LoadICState& state) |
+ : HydrogenCodeStub(isolate) { |
+ minor_key_ = state.GetExtraICState(); |
+ } |
Code::Kind GetCodeKind() const override { return Code::KEYED_LOAD_IC; } |
InlineCacheState GetICState() const override { return GENERIC; } |
+ |
+ LanguageMode language_mode() const { |
+ return LoadICState::GetLanguageMode(MinorKey()); |
+ } |
DEFINE_CALL_INTERFACE_DESCRIPTOR(Load); |
@@ -2153,7 +2166,7 @@ |
return static_cast<ExtraICState>(minor_key_); |
} |
- private: |
+ protected: |
LoadICState state() const { |
return LoadICState(static_cast<ExtraICState>(minor_key_)); |
} |
@@ -2165,8 +2178,8 @@ |
class KeyedLoadICTrampolineStub : public LoadICTrampolineStub { |
public: |
- explicit KeyedLoadICTrampolineStub(Isolate* isolate) |
- : LoadICTrampolineStub(isolate, LoadICState(0)) {} |
+ explicit KeyedLoadICTrampolineStub(Isolate* isolate, const LoadICState& state) |
+ : LoadICTrampolineStub(isolate, state) {} |
Code::Kind GetCodeKind() const override { return Code::KEYED_LOAD_IC; } |
@@ -2272,12 +2285,18 @@ |
class KeyedLoadICStub : public PlatformCodeStub { |
public: |
- explicit KeyedLoadICStub(Isolate* isolate) : PlatformCodeStub(isolate) {} |
+ explicit KeyedLoadICStub(Isolate* isolate, const LoadICState& state) |
+ : PlatformCodeStub(isolate) { |
+ minor_key_ = state.GetExtraICState(); |
+ } |
void GenerateForTrampoline(MacroAssembler* masm); |
Code::Kind GetCodeKind() const override { return Code::KEYED_LOAD_IC; } |
InlineCacheState GetICState() const final { return DEFAULT; } |
+ ExtraICState GetExtraICState() const final { |
+ return static_cast<ExtraICState>(minor_key_); |
+ } |
DEFINE_CALL_INTERFACE_DESCRIPTOR(LoadWithVector); |
DEFINE_PLATFORM_CODE_STUB(KeyedLoadIC, PlatformCodeStub); |
@@ -2321,6 +2340,9 @@ |
Code::Kind GetCodeKind() const final { return Code::KEYED_STORE_IC; } |
InlineCacheState GetICState() const final { return DEFAULT; } |
+ virtual ExtraICState GetExtraICState() const final { |
+ return static_cast<ExtraICState>(minor_key_); |
+ } |
DEFINE_CALL_INTERFACE_DESCRIPTOR(VectorStoreIC); |
DEFINE_PLATFORM_CODE_STUB(VectorKeyedStoreIC, PlatformCodeStub); |