| Index: src/code-stubs.h
|
| diff --git a/src/code-stubs.h b/src/code-stubs.h
|
| index 3ac51e7358e133b89e14b14b1b9df41c973ceb6f..a7283ba642ef4ea2742cbba7ed77e9783faf39a1 100644
|
| --- a/src/code-stubs.h
|
| +++ b/src/code-stubs.h
|
| @@ -101,7 +101,7 @@ namespace internal {
|
| V(KeyedLoadField)
|
|
|
| // List of code stubs only used on ARM platforms.
|
| -#if defined(V8_TARGET_ARCH_ARM) || defined(V8_TARGET_ARCH_A64)
|
| +#if V8_TARGET_ARCH_ARM
|
| #define CODE_STUB_LIST_ARM(V) \
|
| V(GetProperty) \
|
| V(SetProperty) \
|
| @@ -188,6 +188,9 @@ class CodeStub BASE_EMBEDDED {
|
| virtual Code::StubType GetStubType() {
|
| return Code::NORMAL;
|
| }
|
| + virtual int GetStubFlags() {
|
| + return -1;
|
| + }
|
|
|
| virtual void PrintName(StringStream* stream);
|
|
|
| @@ -439,8 +442,6 @@ class RuntimeCallHelper {
|
| #include "ia32/code-stubs-ia32.h"
|
| #elif V8_TARGET_ARCH_X64
|
| #include "x64/code-stubs-x64.h"
|
| -#elif V8_TARGET_ARCH_A64
|
| -#include "a64/code-stubs-a64.h"
|
| #elif V8_TARGET_ARCH_ARM
|
| #include "arm/code-stubs-arm.h"
|
| #elif V8_TARGET_ARCH_MIPS
|
| @@ -486,13 +487,6 @@ class ToNumberStub: public HydrogenCodeStub {
|
| Isolate* isolate,
|
| CodeStubInterfaceDescriptor* descriptor);
|
|
|
| - static void InstallDescriptors(Isolate* isolate) {
|
| - ToNumberStub stub;
|
| - stub.InitializeInterfaceDescriptor(
|
| - isolate,
|
| - isolate->code_stub_interface_descriptor(CodeStub::ToNumber));
|
| - }
|
| -
|
| private:
|
| Major MajorKey() { return ToNumber; }
|
| int NotMissMinorKey() { return 0; }
|
| @@ -631,8 +625,6 @@ class FastCloneShallowArrayStub : public HydrogenCodeStub {
|
| Isolate* isolate,
|
| CodeStubInterfaceDescriptor* descriptor);
|
|
|
| - static void InstallDescriptors(Isolate* isolate);
|
| -
|
| private:
|
| Mode mode_;
|
| AllocationSiteMode allocation_site_mode_;
|
| @@ -891,7 +883,7 @@ class HICStub: public HydrogenCodeStub {
|
| class HandlerStub: public HICStub {
|
| public:
|
| virtual Code::Kind GetCodeKind() const { return Code::HANDLER; }
|
| - virtual ExtraICState GetExtraICState() { return kind(); }
|
| + virtual int GetStubFlags() { return kind(); }
|
|
|
| protected:
|
| HandlerStub() : HICStub() { }
|
| @@ -987,6 +979,8 @@ class StoreGlobalStub : public HandlerStub {
|
| Isolate* isolate,
|
| CodeStubInterfaceDescriptor* descriptor);
|
|
|
| + virtual ExtraICState GetExtraICState() { return bit_field_; }
|
| +
|
| bool is_constant() {
|
| return IsConstantBits::decode(bit_field_);
|
| }
|
| @@ -1002,25 +996,27 @@ class StoreGlobalStub : public HandlerStub {
|
| }
|
|
|
| private:
|
| + virtual int NotMissMinorKey() { return GetExtraICState(); }
|
| Major MajorKey() { return StoreGlobal; }
|
|
|
| class IsConstantBits: public BitField<bool, 0, 1> {};
|
| class RepresentationBits: public BitField<Representation::Kind, 1, 8> {};
|
|
|
| + int bit_field_;
|
| +
|
| DISALLOW_COPY_AND_ASSIGN(StoreGlobalStub);
|
| };
|
|
|
|
|
| class CallApiFunctionStub : public PlatformCodeStub {
|
| public:
|
| - CallApiFunctionStub(bool is_store,
|
| + CallApiFunctionStub(bool restore_context,
|
| bool call_data_undefined,
|
| int argc) {
|
| bit_field_ =
|
| - IsStoreBits::encode(is_store) |
|
| + RestoreContextBits::encode(restore_context) |
|
| CallDataUndefinedBits::encode(call_data_undefined) |
|
| ArgumentBits::encode(argc);
|
| - ASSERT(!is_store || argc == 1);
|
| }
|
|
|
| private:
|
| @@ -1028,7 +1024,7 @@ class CallApiFunctionStub : public PlatformCodeStub {
|
| virtual Major MajorKey() V8_OVERRIDE { return CallApiFunction; }
|
| virtual int MinorKey() V8_OVERRIDE { return bit_field_; }
|
|
|
| - class IsStoreBits: public BitField<bool, 0, 1> {};
|
| + class RestoreContextBits: public BitField<bool, 0, 1> {};
|
| class CallDataUndefinedBits: public BitField<bool, 1, 1> {};
|
| class ArgumentBits: public BitField<int, 2, Code::kArgumentsBits> {};
|
|
|
| @@ -1372,7 +1368,7 @@ class CompareNilICStub : public HydrogenCodeStub {
|
| Isolate* isolate,
|
| CodeStubInterfaceDescriptor* descriptor);
|
|
|
| - static void InstallDescriptors(Isolate* isolate) {
|
| + static void InitializeForIsolate(Isolate* isolate) {
|
| CompareNilICStub compare_stub(kNullValue, UNINITIALIZED);
|
| compare_stub.InitializeInterfaceDescriptor(
|
| isolate,
|
| @@ -1870,21 +1866,23 @@ class DoubleToIStub : public PlatformCodeStub {
|
| int offset,
|
| bool is_truncating,
|
| bool skip_fastpath = false) : bit_field_(0) {
|
| - bit_field_ = SourceRegisterBits::encode(source.code()) |
|
| - DestinationRegisterBits::encode(destination.code()) |
|
| + bit_field_ = SourceRegisterBits::encode(source.code_) |
|
| + DestinationRegisterBits::encode(destination.code_) |
|
| OffsetBits::encode(offset) |
|
| IsTruncatingBits::encode(is_truncating) |
|
| SkipFastPathBits::encode(skip_fastpath) |
|
| SSEBits::encode(CpuFeatures::IsSafeForSnapshot(SSE2) ?
|
| - CpuFeatures::IsSafeForSnapshot(SSE3) ? 2 : 1 : 0);
|
| + CpuFeatures::IsSafeForSnapshot(SSE3) ? 2 : 1 : 0);
|
| }
|
|
|
| Register source() {
|
| - return Register::from_code(SourceRegisterBits::decode(bit_field_));
|
| + Register result = { SourceRegisterBits::decode(bit_field_) };
|
| + return result;
|
| }
|
|
|
| Register destination() {
|
| - return Register::from_code(DestinationRegisterBits::decode(bit_field_));
|
| + Register result = { DestinationRegisterBits::decode(bit_field_) };
|
| + return result;
|
| }
|
|
|
| bool is_truncating() {
|
| @@ -2329,7 +2327,7 @@ class ToBooleanStub: public HydrogenCodeStub {
|
|
|
| virtual bool SometimesSetsUpAFrame() { return false; }
|
|
|
| - static void InstallDescriptors(Isolate* isolate) {
|
| + static void InitializeForIsolate(Isolate* isolate) {
|
| ToBooleanStub stub;
|
| stub.InitializeInterfaceDescriptor(
|
| isolate,
|
|
|