| Index: src/code-stubs.h
|
| diff --git a/src/code-stubs.h b/src/code-stubs.h
|
| index 3a756585e574ead45594e3c18e662ce1b8441694..486790e6b74d694cc9179758f32b87c2fe6a11ca 100644
|
| --- a/src/code-stubs.h
|
| +++ b/src/code-stubs.h
|
| @@ -70,10 +70,8 @@ namespace internal {
|
| V(NumberToString) \
|
| V(CEntry) \
|
| V(JSEntry) \
|
| - V(KeyedLoadFastElement) \
|
| - V(KeyedStoreFastElement) \
|
| - V(KeyedLoadExternalArray) \
|
| - V(KeyedStoreExternalArray) \
|
| + V(KeyedLoadElement) \
|
| + V(KeyedStoreElement) \
|
| V(DebuggerStatement) \
|
| V(StringDictionaryNegativeLookup)
|
|
|
| @@ -928,76 +926,51 @@ class AllowStubCallsScope {
|
| #endif
|
|
|
|
|
| -class KeyedLoadFastElementStub : public CodeStub {
|
| +class KeyedLoadElementStub : public CodeStub {
|
| public:
|
| - explicit KeyedLoadFastElementStub() {
|
| - }
|
| -
|
| - Major MajorKey() { return KeyedLoadFastElement; }
|
| - int MinorKey() { return 0; }
|
| -
|
| - void Generate(MacroAssembler* masm);
|
| -
|
| - const char* GetName() { return "KeyedLoadFastElementStub"; }
|
| -
|
| - DECLARE_ARRAY_STUB_PRINT(KeyedLoadFastElementStub)
|
| -};
|
| -
|
| + explicit KeyedLoadElementStub(JSObject::ElementsKind elements_kind)
|
| + : elements_kind_(elements_kind)
|
| + { }
|
|
|
| -class KeyedStoreFastElementStub : public CodeStub {
|
| - public:
|
| - explicit KeyedStoreFastElementStub(bool is_js_array)
|
| - : is_js_array_(is_js_array) { }
|
| -
|
| - Major MajorKey() { return KeyedStoreFastElement; }
|
| - int MinorKey() { return is_js_array_ ? 1 : 0; }
|
| -
|
| - void Generate(MacroAssembler* masm);
|
| -
|
| - const char* GetName() { return "KeyedStoreFastElementStub"; }
|
| -
|
| - DECLARE_ARRAY_STUB_PRINT(KeyedStoreFastElementStub)
|
| -
|
| - private:
|
| - bool is_js_array_;
|
| -};
|
| -
|
| -
|
| -class KeyedLoadExternalArrayStub : public CodeStub {
|
| - public:
|
| - explicit KeyedLoadExternalArrayStub(JSObject::ElementsKind elements_kind)
|
| - : elements_kind_(elements_kind) { }
|
| -
|
| - Major MajorKey() { return KeyedLoadExternalArray; }
|
| + Major MajorKey() { return KeyedLoadElement; }
|
| int MinorKey() { return elements_kind_; }
|
|
|
| void Generate(MacroAssembler* masm);
|
|
|
| - const char* GetName() { return "KeyedLoadExternalArrayStub"; }
|
| + const char* GetName() { return "KeyedLoadElementStub"; }
|
|
|
| - DECLARE_ARRAY_STUB_PRINT(KeyedLoadExternalArrayStub)
|
| + DECLARE_ARRAY_STUB_PRINT(KeyedLoadElementStub)
|
|
|
| - protected:
|
| + private:
|
| JSObject::ElementsKind elements_kind_;
|
| +
|
| + DISALLOW_COPY_AND_ASSIGN(KeyedLoadElementStub);
|
| };
|
|
|
|
|
| -class KeyedStoreExternalArrayStub : public CodeStub {
|
| +class KeyedStoreElementStub : public CodeStub {
|
| public:
|
| - explicit KeyedStoreExternalArrayStub(JSObject::ElementsKind elements_kind)
|
| - : elements_kind_(elements_kind) { }
|
| + KeyedStoreElementStub(bool is_js_array,
|
| + JSObject::ElementsKind elements_kind)
|
| + : is_js_array_(is_js_array),
|
| + elements_kind_(elements_kind) { }
|
|
|
| - Major MajorKey() { return KeyedStoreExternalArray; }
|
| - int MinorKey() { return elements_kind_; }
|
| + Major MajorKey() { return KeyedStoreElement; }
|
| + int MinorKey() {
|
| + return (is_js_array_ ? 0 : JSObject::kElementsKindCount) + elements_kind_;
|
| + }
|
|
|
| void Generate(MacroAssembler* masm);
|
|
|
| - const char* GetName() { return "KeyedStoreExternalArrayStub"; }
|
| + const char* GetName() { return "KeyedStoreElementStub"; }
|
|
|
| - DECLARE_ARRAY_STUB_PRINT(KeyedStoreExternalArrayStub)
|
| + DECLARE_ARRAY_STUB_PRINT(KeyedStoreElementStub)
|
|
|
| - protected:
|
| + private:
|
| + bool is_js_array_;
|
| JSObject::ElementsKind elements_kind_;
|
| +
|
| + DISALLOW_COPY_AND_ASSIGN(KeyedStoreElementStub);
|
| };
|
|
|
|
|
|
|