Remove unnecessary options from HTailCallThroughMegamorphicCache
authormvstanton <mvstanton@chromium.org>
Mon, 13 Apr 2015 16:23:24 +0000 (09:23 -0700)
committerCommit bot <commit-bot@chromium.org>
Mon, 13 Apr 2015 16:23:23 +0000 (16:23 +0000)
These options were added for a hydrogen code stub version of
the VectorIC dispatcher, which was discontinued.

R=verwaest@chromium.org
BUG=

Review URL: https://codereview.chromium.org/1081883002

Cr-Commit-Position: refs/heads/master@{#27793}

20 files changed:
src/arm/lithium-arm.cc
src/arm/lithium-arm.h
src/arm/lithium-codegen-arm.cc
src/arm64/lithium-arm64.cc
src/arm64/lithium-arm64.h
src/arm64/lithium-codegen-arm64.cc
src/code-stubs-hydrogen.cc
src/hydrogen-instructions.h
src/ia32/lithium-codegen-ia32.cc
src/ia32/lithium-ia32.cc
src/ia32/lithium-ia32.h
src/mips/lithium-codegen-mips.cc
src/mips/lithium-mips.cc
src/mips/lithium-mips.h
src/mips64/lithium-codegen-mips64.cc
src/mips64/lithium-mips64.cc
src/mips64/lithium-mips64.h
src/x64/lithium-codegen-x64.cc
src/x64/lithium-x64.cc
src/x64/lithium-x64.h

index b45e1c5226c7c4b80b75d1e85b6a150027a409ac..30301f9f324ad3c03b3d8970896bd8da7a10a384 100644 (file)
@@ -1112,17 +1112,10 @@ LInstruction* LChunkBuilder::DoTailCallThroughMegamorphicCache(
       UseFixed(instr->receiver(), LoadDescriptor::ReceiverRegister());
   LOperand* name_register =
       UseFixed(instr->name(), LoadDescriptor::NameRegister());
-  LOperand* slot = NULL;
-  LOperand* vector = NULL;
-  if (FLAG_vector_ics) {
-    slot = UseFixed(instr->slot(), VectorLoadICDescriptor::SlotRegister());
-    vector =
-        UseFixed(instr->vector(), VectorLoadICDescriptor::VectorRegister());
-  }
 
   // Not marked as call. It can't deoptimize, and it never returns.
   return new (zone()) LTailCallThroughMegamorphicCache(
-      context, receiver_register, name_register, slot, vector);
+      context, receiver_register, name_register);
 }
 
 
index fbf648f0e4669dac56eb44e908127c407a63b177..fc42f084fe0aa445c85ea9dd2feeaff3f31ff9b6 100644 (file)
@@ -474,23 +474,18 @@ class LCallStub FINAL : public LTemplateInstruction<1, 1, 0> {
 
 
 class LTailCallThroughMegamorphicCache FINAL
-    : public LTemplateInstruction<0, 5, 0> {
+    : public LTemplateInstruction<0, 3, 0> {
  public:
   LTailCallThroughMegamorphicCache(LOperand* context, LOperand* receiver,
-                                   LOperand* name, LOperand* slot,
-                                   LOperand* vector) {
+                                   LOperand* name) {
     inputs_[0] = context;
     inputs_[1] = receiver;
     inputs_[2] = name;
-    inputs_[3] = slot;
-    inputs_[4] = vector;
   }
 
   LOperand* context() { return inputs_[0]; }
   LOperand* receiver() { return inputs_[1]; }
   LOperand* name() { return inputs_[2]; }
-  LOperand* slot() { return inputs_[3]; }
-  LOperand* vector() { return inputs_[4]; }
 
   DECLARE_CONCRETE_INSTRUCTION(TailCallThroughMegamorphicCache,
                                "tail-call-through-megamorphic-cache")
index 8a647d880b3bce58b893eed0dcb380d9a70db919..2453509c2dd67a28153da83fbba148c335cc0bba 100644 (file)
@@ -3957,32 +3957,13 @@ void LCodeGen::DoTailCallThroughMegamorphicCache(
   Register extra2 = r6;
   Register extra3 = r9;
 
-#ifdef DEBUG
-  Register slot = FLAG_vector_ics ? ToRegister(instr->slot()) : no_reg;
-  Register vector = FLAG_vector_ics ? ToRegister(instr->vector()) : no_reg;
-  DCHECK(!FLAG_vector_ics ||
-         !AreAliased(slot, vector, scratch, extra, extra2, extra3));
-#endif
-
-  // Important for the tail-call.
-  bool must_teardown_frame = NeedsEagerFrame();
-
-  if (!instr->hydrogen()->is_just_miss()) {
-    DCHECK(!instr->hydrogen()->is_keyed_load());
-
-    // The probe will tail call to a handler if found.
-    isolate()->stub_cache()->GenerateProbe(
-        masm(), Code::LOAD_IC, instr->hydrogen()->flags(), must_teardown_frame,
-        receiver, name, scratch, extra, extra2, extra3);
-  }
+  // The probe will tail call to a handler if found.
+  isolate()->stub_cache()->GenerateProbe(
+      masm(), Code::LOAD_IC, instr->hydrogen()->flags(), false, receiver, name,
+      scratch, extra, extra2, extra3);
 
   // Tail call to miss if we ended up here.
-  if (must_teardown_frame) __ LeaveFrame(StackFrame::INTERNAL);
-  if (instr->hydrogen()->is_keyed_load()) {
-    KeyedLoadIC::GenerateMiss(masm());
-  } else {
-    LoadIC::GenerateMiss(masm());
-  }
+  LoadIC::GenerateMiss(masm());
 }
 
 
index 4a89fc43449dd52c38b238250db4db3943dd85dd..c57cb689a042cf8ea9e717bbeb26a3d08db7c9c4 100644 (file)
@@ -1586,17 +1586,10 @@ LInstruction* LChunkBuilder::DoTailCallThroughMegamorphicCache(
       UseFixed(instr->receiver(), LoadDescriptor::ReceiverRegister());
   LOperand* name_register =
       UseFixed(instr->name(), LoadDescriptor::NameRegister());
-  LOperand* slot = NULL;
-  LOperand* vector = NULL;
-  if (FLAG_vector_ics) {
-    slot = UseFixed(instr->slot(), VectorLoadICDescriptor::SlotRegister());
-    vector =
-        UseFixed(instr->vector(), VectorLoadICDescriptor::VectorRegister());
-  }
 
   // Not marked as call. It can't deoptimize, and it never returns.
   return new (zone()) LTailCallThroughMegamorphicCache(
-      context, receiver_register, name_register, slot, vector);
+      context, receiver_register, name_register);
 }
 
 
index 0549689e796cadc575356c590ad62c3b4e12808e..1afed1a6074e9cb39f545caf044e74e9b166a980 100644 (file)
@@ -318,23 +318,18 @@ class LTemplateInstruction : public LTemplateResultInstruction<R> {
 
 
 class LTailCallThroughMegamorphicCache FINAL
-    : public LTemplateInstruction<0, 5, 0> {
+    : public LTemplateInstruction<0, 3, 0> {
  public:
   LTailCallThroughMegamorphicCache(LOperand* context, LOperand* receiver,
-                                   LOperand* name, LOperand* slot,
-                                   LOperand* vector) {
+                                   LOperand* name) {
     inputs_[0] = context;
     inputs_[1] = receiver;
     inputs_[2] = name;
-    inputs_[3] = slot;
-    inputs_[4] = vector;
   }
 
   LOperand* context() { return inputs_[0]; }
   LOperand* receiver() { return inputs_[1]; }
   LOperand* name() { return inputs_[2]; }
-  LOperand* slot() { return inputs_[3]; }
-  LOperand* vector() { return inputs_[4]; }
 
   DECLARE_CONCRETE_INSTRUCTION(TailCallThroughMegamorphicCache,
                                "tail-call-through-megamorphic-cache")
index 8f32bdd678dd5f4a279dfe72c454dfa0ecad68c8..0cc1dfc5bcb36b8cacdcd79cc7b6934040f87dda 100644 (file)
@@ -2024,29 +2024,14 @@ void LCodeGen::DoTailCallThroughMegamorphicCache(
   Register extra = x5;
   Register extra2 = x6;
   Register extra3 = x7;
-  DCHECK(!FLAG_vector_ics ||
-         !AreAliased(ToRegister(instr->slot()), ToRegister(instr->vector()),
-                     scratch, extra, extra2, extra3));
 
-  // Important for the tail-call.
-  bool must_teardown_frame = NeedsEagerFrame();
-
-  if (!instr->hydrogen()->is_just_miss()) {
-    DCHECK(!instr->hydrogen()->is_keyed_load());
-
-    // The probe will tail call to a handler if found.
-    isolate()->stub_cache()->GenerateProbe(
-        masm(), Code::LOAD_IC, instr->hydrogen()->flags(), must_teardown_frame,
-        receiver, name, scratch, extra, extra2, extra3);
-  }
+  // The probe will tail call to a handler if found.
+  isolate()->stub_cache()->GenerateProbe(
+      masm(), Code::LOAD_IC, instr->hydrogen()->flags(), false, receiver, name,
+      scratch, extra, extra2, extra3);
 
   // Tail call to miss if we ended up here.
-  if (must_teardown_frame) __ LeaveFrame(StackFrame::INTERNAL);
-  if (instr->hydrogen()->is_keyed_load()) {
-    KeyedLoadIC::GenerateMiss(masm());
-  } else {
-    LoadIC::GenerateMiss(masm());
-  }
+  LoadIC::GenerateMiss(masm());
 }
 
 
index 8168aac4b861f804be40bd3857c066b380d6a851..3ca301ca6c3a6c215097d6f0afbfa575e5df08e7 100644 (file)
@@ -2029,6 +2029,10 @@ HValue* CodeStubGraphBuilder<MegamorphicLoadStub>::BuildCodeStub() {
   // megamorphic case is handled as part of the default stub.
   DCHECK(!FLAG_vector_ics);
 
+  // This stub tail calls, and an erected frame presents complications we don't
+  // need.
+  info()->MarkMustNotHaveEagerFrame();
+
   // Probe the stub cache.
   Add<HTailCallThroughMegamorphicCache>(receiver, name);
 
index 64a05167218c7d4f2cd599e2ea07cec495f1d83b..8c42e021c663ccae9851729bcea3a6c8f592c45e 100644 (file)
@@ -5291,28 +5291,6 @@ class HCallStub FINAL : public HUnaryCall {
 
 class HTailCallThroughMegamorphicCache FINAL : public HInstruction {
  public:
-  enum Flags {
-    NONE = 0,
-    CALLED_FROM_KEYED_LOAD = 1 << 0,
-    PERFORM_MISS_ONLY = 1 << 1
-  };
-
-  static Flags ComputeFlags(bool called_from_keyed_load,
-                            bool perform_miss_only) {
-    Flags flags = NONE;
-    if (called_from_keyed_load) {
-      flags = static_cast<Flags>(flags | CALLED_FROM_KEYED_LOAD);
-    }
-    if (perform_miss_only) {
-      flags = static_cast<Flags>(flags | PERFORM_MISS_ONLY);
-    }
-    return flags;
-  }
-
-  DECLARE_INSTRUCTION_WITH_CONTEXT_FACTORY_P5(
-      HTailCallThroughMegamorphicCache, HValue*, HValue*, HValue*, HValue*,
-      HTailCallThroughMegamorphicCache::Flags);
-
   DECLARE_INSTRUCTION_WITH_CONTEXT_FACTORY_P2(HTailCallThroughMegamorphicCache,
                                               HValue*, HValue*);
 
@@ -5320,27 +5298,14 @@ class HTailCallThroughMegamorphicCache FINAL : public HInstruction {
     return Representation::Tagged();
   }
 
-  virtual int OperandCount() const FINAL OVERRIDE {
-    return FLAG_vector_ics ? 5 : 3;
-  }
+  virtual int OperandCount() const FINAL OVERRIDE { return 3; }
   virtual HValue* OperandAt(int i) const FINAL OVERRIDE { return inputs_[i]; }
 
   HValue* context() const { return OperandAt(0); }
   HValue* receiver() const { return OperandAt(1); }
   HValue* name() const { return OperandAt(2); }
-  HValue* slot() const {
-    DCHECK(FLAG_vector_ics);
-    return OperandAt(3);
-  }
-  HValue* vector() const {
-    DCHECK(FLAG_vector_ics);
-    return OperandAt(4);
-  }
   Code::Flags flags() const;
 
-  bool is_keyed_load() const { return flags_ & CALLED_FROM_KEYED_LOAD; }
-  bool is_just_miss() const { return flags_ & PERFORM_MISS_ONLY; }
-
   std::ostream& PrintDataTo(std::ostream& os) const OVERRIDE;  // NOLINT
 
   DECLARE_CONCRETE_INSTRUCTION(TailCallThroughMegamorphicCache)
@@ -5352,27 +5317,13 @@ class HTailCallThroughMegamorphicCache FINAL : public HInstruction {
 
  private:
   HTailCallThroughMegamorphicCache(HValue* context, HValue* receiver,
-                                   HValue* name, HValue* slot, HValue* vector,
-                                   Flags flags)
-      : flags_(flags) {
-    DCHECK(FLAG_vector_ics);
+                                   HValue* name) {
     SetOperandAt(0, context);
     SetOperandAt(1, receiver);
     SetOperandAt(2, name);
-    SetOperandAt(3, slot);
-    SetOperandAt(4, vector);
   }
 
-  HTailCallThroughMegamorphicCache(HValue* context, HValue* receiver,
-                                   HValue* name)
-      : flags_(NONE) {
-    SetOperandAt(0, context);
-    SetOperandAt(1, receiver);
-    SetOperandAt(2, name);
-  }
-
-  EmbeddedContainer<HValue*, 5> inputs_;
-  Flags flags_;
+  EmbeddedContainer<HValue*, 3> inputs_;
 };
 
 
index 72bb270e7a6fcfe384da3579b12a989e721b9cd2..6d26fde2708e584ef4aa9f81e0a6fec084316964 100644 (file)
@@ -3473,44 +3473,18 @@ void LCodeGen::DoTailCallThroughMegamorphicCache(
   Register name = ToRegister(instr->name());
   DCHECK(receiver.is(LoadDescriptor::ReceiverRegister()));
   DCHECK(name.is(LoadDescriptor::NameRegister()));
-  Register slot = FLAG_vector_ics ? ToRegister(instr->slot()) : no_reg;
-  Register vector = FLAG_vector_ics ? ToRegister(instr->vector()) : no_reg;
-
   Register scratch = ebx;
   Register extra = edi;
-  DCHECK(!extra.is(slot) && !extra.is(vector));
   DCHECK(!scratch.is(receiver) && !scratch.is(name));
   DCHECK(!extra.is(receiver) && !extra.is(name));
 
-  // Important for the tail-call.
-  bool must_teardown_frame = NeedsEagerFrame();
-
-  if (!instr->hydrogen()->is_just_miss()) {
-    if (FLAG_vector_ics) {
-      __ push(slot);
-      __ push(vector);
-    }
+  // The probe will tail call to a handler if found.
+  // If --vector-ics is on, then it knows to pop the two args first.
+  isolate()->stub_cache()->GenerateProbe(masm(), Code::LOAD_IC,
+                                         instr->hydrogen()->flags(), false,
+                                         receiver, name, scratch, extra);
 
-    // The probe will tail call to a handler if found.
-    // If --vector-ics is on, then it knows to pop the two args first.
-    DCHECK(!instr->hydrogen()->is_keyed_load());
-    isolate()->stub_cache()->GenerateProbe(
-        masm(), Code::LOAD_IC, instr->hydrogen()->flags(), must_teardown_frame,
-        receiver, name, scratch, extra);
-
-    if (FLAG_vector_ics) {
-      __ pop(vector);
-      __ pop(slot);
-    }
-  }
-
-  // Tail call to miss if we ended up here.
-  if (must_teardown_frame) __ leave();
-  if (instr->hydrogen()->is_keyed_load()) {
-    KeyedLoadIC::GenerateMiss(masm());
-  } else {
-    LoadIC::GenerateMiss(masm());
-  }
+  LoadIC::GenerateMiss(masm());
 }
 
 
index 0bda914f6d06593139dbed038d357922eacbba1f..d0ca2a847c2a40ba6e309662fcf936f33afe5816 100644 (file)
@@ -1153,17 +1153,10 @@ LInstruction* LChunkBuilder::DoTailCallThroughMegamorphicCache(
       UseFixed(instr->receiver(), LoadDescriptor::ReceiverRegister());
   LOperand* name_register =
       UseFixed(instr->name(), LoadDescriptor::NameRegister());
-  LOperand* slot = NULL;
-  LOperand* vector = NULL;
-  if (FLAG_vector_ics) {
-    slot = UseFixed(instr->slot(), VectorLoadICDescriptor::SlotRegister());
-    vector =
-        UseFixed(instr->vector(), VectorLoadICDescriptor::VectorRegister());
-  }
 
   // Not marked as call. It can't deoptimize, and it never returns.
   return new (zone()) LTailCallThroughMegamorphicCache(
-      context, receiver_register, name_register, slot, vector);
+      context, receiver_register, name_register);
 }
 
 
index 4ea444a665432faa2f6ad6592bb2a8b00d809c78..6d9e3b31eee87434f9aeaaa94c46e609042f89ad 100644 (file)
@@ -469,23 +469,18 @@ class LCallStub FINAL : public LTemplateInstruction<1, 1, 0> {
 
 
 class LTailCallThroughMegamorphicCache FINAL
-    : public LTemplateInstruction<0, 5, 0> {
+    : public LTemplateInstruction<0, 3, 0> {
  public:
   LTailCallThroughMegamorphicCache(LOperand* context, LOperand* receiver,
-                                   LOperand* name, LOperand* slot,
-                                   LOperand* vector) {
+                                   LOperand* name) {
     inputs_[0] = context;
     inputs_[1] = receiver;
     inputs_[2] = name;
-    inputs_[3] = slot;
-    inputs_[4] = vector;
   }
 
   LOperand* context() { return inputs_[0]; }
   LOperand* receiver() { return inputs_[1]; }
   LOperand* name() { return inputs_[2]; }
-  LOperand* slot() { return inputs_[3]; }
-  LOperand* vector() { return inputs_[4]; }
 
   DECLARE_CONCRETE_INSTRUCTION(TailCallThroughMegamorphicCache,
                                "tail-call-through-megamorphic-cache")
index 6293b2cb108a435f45516ecf7d3cda584ee46e41..6431100e5ff2303cca7dedea66389838e373e370 100644 (file)
@@ -3948,32 +3948,14 @@ void LCodeGen::DoTailCallThroughMegamorphicCache(
   Register extra = t1;
   Register extra2 = t2;
   Register extra3 = t5;
-#ifdef DEBUG
-  Register slot = FLAG_vector_ics ? ToRegister(instr->slot()) : no_reg;
-  Register vector = FLAG_vector_ics ? ToRegister(instr->vector()) : no_reg;
-  DCHECK(!FLAG_vector_ics ||
-         !AreAliased(slot, vector, scratch, extra, extra2, extra3));
-#endif
 
-  // Important for the tail-call.
-  bool must_teardown_frame = NeedsEagerFrame();
-
-  if (!instr->hydrogen()->is_just_miss()) {
-    DCHECK(!instr->hydrogen()->is_keyed_load());
-
-    // The probe will tail call to a handler if found.
-    isolate()->stub_cache()->GenerateProbe(
-        masm(), Code::LOAD_IC, instr->hydrogen()->flags(), must_teardown_frame,
-        receiver, name, scratch, extra, extra2, extra3);
-  }
+  // The probe will tail call to a handler if found.
+  isolate()->stub_cache()->GenerateProbe(
+      masm(), Code::LOAD_IC, instr->hydrogen()->flags(), false, receiver, name,
+      scratch, extra, extra2, extra3);
 
   // Tail call to miss if we ended up here.
-  if (must_teardown_frame) __ LeaveFrame(StackFrame::INTERNAL);
-  if (instr->hydrogen()->is_keyed_load()) {
-    KeyedLoadIC::GenerateMiss(masm());
-  } else {
-    LoadIC::GenerateMiss(masm());
-  }
+  LoadIC::GenerateMiss(masm());
 }
 
 
index b710ef9fdeb3b48fca01c33af1d899efb8c4923c..330262f3916491385023b7a58ae2ca3fe00165a4 100644 (file)
@@ -1117,17 +1117,10 @@ LInstruction* LChunkBuilder::DoTailCallThroughMegamorphicCache(
       UseFixed(instr->receiver(), LoadDescriptor::ReceiverRegister());
   LOperand* name_register =
       UseFixed(instr->name(), LoadDescriptor::NameRegister());
-  LOperand* slot = NULL;
-  LOperand* vector = NULL;
-  if (FLAG_vector_ics) {
-    slot = UseFixed(instr->slot(), VectorLoadICDescriptor::SlotRegister());
-    vector =
-        UseFixed(instr->vector(), VectorLoadICDescriptor::VectorRegister());
-  }
 
   // Not marked as call. It can't deoptimize, and it never returns.
   return new (zone()) LTailCallThroughMegamorphicCache(
-      context, receiver_register, name_register, slot, vector);
+      context, receiver_register, name_register);
 }
 
 
index ede4cbed91bc3c35c930c95393c69bbf95239425..46ed444e5b87bd9db9ecd9b5a2270f4d9eeb9897 100644 (file)
@@ -471,23 +471,18 @@ class LCallStub FINAL : public LTemplateInstruction<1, 1, 0> {
 
 
 class LTailCallThroughMegamorphicCache FINAL
-    : public LTemplateInstruction<0, 5, 0> {
+    : public LTemplateInstruction<0, 3, 0> {
  public:
   LTailCallThroughMegamorphicCache(LOperand* context, LOperand* receiver,
-                                   LOperand* name, LOperand* slot,
-                                   LOperand* vector) {
+                                   LOperand* name) {
     inputs_[0] = context;
     inputs_[1] = receiver;
     inputs_[2] = name;
-    inputs_[3] = slot;
-    inputs_[4] = vector;
   }
 
   LOperand* context() { return inputs_[0]; }
   LOperand* receiver() { return inputs_[1]; }
   LOperand* name() { return inputs_[2]; }
-  LOperand* slot() { return inputs_[3]; }
-  LOperand* vector() { return inputs_[4]; }
 
   DECLARE_CONCRETE_INSTRUCTION(TailCallThroughMegamorphicCache,
                                "tail-call-through-megamorphic-cache")
index fb3bda8df54b538701e1adb75e64a94e9070e369..d1e9d217aaafa4006f620b21e904a54ad8c769c4 100644 (file)
@@ -4010,32 +4010,14 @@ void LCodeGen::DoTailCallThroughMegamorphicCache(
   Register extra = a5;
   Register extra2 = a6;
   Register extra3 = t1;
-#ifdef DEBUG
-  Register slot = FLAG_vector_ics ? ToRegister(instr->slot()) : no_reg;
-  Register vector = FLAG_vector_ics ? ToRegister(instr->vector()) : no_reg;
-  DCHECK(!FLAG_vector_ics ||
-         !AreAliased(slot, vector, scratch, extra, extra2, extra3));
-#endif
 
-  // Important for the tail-call.
-  bool must_teardown_frame = NeedsEagerFrame();
-
-  if (!instr->hydrogen()->is_just_miss()) {
-    DCHECK(!instr->hydrogen()->is_keyed_load());
-
-    // The probe will tail call to a handler if found.
-    isolate()->stub_cache()->GenerateProbe(
-        masm(), Code::LOAD_IC, instr->hydrogen()->flags(), must_teardown_frame,
-        receiver, name, scratch, extra, extra2, extra3);
-  }
+  // The probe will tail call to a handler if found.
+  isolate()->stub_cache()->GenerateProbe(
+      masm(), Code::LOAD_IC, instr->hydrogen()->flags(), false, receiver, name,
+      scratch, extra, extra2, extra3);
 
   // Tail call to miss if we ended up here.
-  if (must_teardown_frame) __ LeaveFrame(StackFrame::INTERNAL);
-  if (instr->hydrogen()->is_keyed_load()) {
-    KeyedLoadIC::GenerateMiss(masm());
-  } else {
-    LoadIC::GenerateMiss(masm());
-  }
+  LoadIC::GenerateMiss(masm());
 }
 
 
index 60a837e7c5eff0dfa82938f2ac30edc46719a108..0c01128d579c4f38f9f0667e7160574eb3b2769d 100644 (file)
@@ -1117,17 +1117,10 @@ LInstruction* LChunkBuilder::DoTailCallThroughMegamorphicCache(
       UseFixed(instr->receiver(), LoadDescriptor::ReceiverRegister());
   LOperand* name_register =
       UseFixed(instr->name(), LoadDescriptor::NameRegister());
-  LOperand* slot = NULL;
-  LOperand* vector = NULL;
-  if (FLAG_vector_ics) {
-    slot = UseFixed(instr->slot(), VectorLoadICDescriptor::SlotRegister());
-    vector =
-        UseFixed(instr->vector(), VectorLoadICDescriptor::VectorRegister());
-  }
 
   // Not marked as call. It can't deoptimize, and it never returns.
   return new (zone()) LTailCallThroughMegamorphicCache(
-      context, receiver_register, name_register, slot, vector);
+      context, receiver_register, name_register);
 }
 
 
index 6eed2c2391e942d0b07ca4286991dd69bf34b4f1..e859f7e5ffcf134a728ecc665333be4cf4767156 100644 (file)
@@ -470,23 +470,18 @@ class LCallStub FINAL : public LTemplateInstruction<1, 1, 0> {
 
 
 class LTailCallThroughMegamorphicCache FINAL
-    : public LTemplateInstruction<0, 5, 0> {
+    : public LTemplateInstruction<0, 3, 0> {
  public:
   LTailCallThroughMegamorphicCache(LOperand* context, LOperand* receiver,
-                                   LOperand* name, LOperand* slot,
-                                   LOperand* vector) {
+                                   LOperand* name) {
     inputs_[0] = context;
     inputs_[1] = receiver;
     inputs_[2] = name;
-    inputs_[3] = slot;
-    inputs_[4] = vector;
   }
 
   LOperand* context() { return inputs_[0]; }
   LOperand* receiver() { return inputs_[1]; }
   LOperand* name() { return inputs_[2]; }
-  LOperand* slot() { return inputs_[3]; }
-  LOperand* vector() { return inputs_[4]; }
 
   DECLARE_CONCRETE_INSTRUCTION(TailCallThroughMegamorphicCache,
                                "tail-call-through-megamorphic-cache")
index 3b72d690fe514c17d17d939b3ad3b13d24748b86..245ca5ce96c1ac382f8098e645560dae9e306d0f 100644 (file)
@@ -3553,28 +3553,13 @@ void LCodeGen::DoTailCallThroughMegamorphicCache(
   DCHECK(name.is(LoadDescriptor::NameRegister()));
   Register scratch = rdi;
   DCHECK(!scratch.is(receiver) && !scratch.is(name));
-  DCHECK(!FLAG_vector_ics ||
-         !AreAliased(ToRegister(instr->slot()), ToRegister(instr->vector()),
-                     scratch));
 
-  // Important for the tail-call.
-  bool must_teardown_frame = NeedsEagerFrame();
+  // The probe will tail call to a handler if found.
+  isolate()->stub_cache()->GenerateProbe(masm(), Code::LOAD_IC,
+                                         instr->hydrogen()->flags(), false,
+                                         receiver, name, scratch, no_reg);
 
-  if (!instr->hydrogen()->is_just_miss()) {
-    // The probe will tail call to a handler if found.
-    DCHECK(!instr->hydrogen()->is_keyed_load());
-    isolate()->stub_cache()->GenerateProbe(
-        masm(), Code::LOAD_IC, instr->hydrogen()->flags(), must_teardown_frame,
-        receiver, name, scratch, no_reg);
-  }
-
-  // Tail call to miss if we ended up here.
-  if (must_teardown_frame) __ leave();
-  if (instr->hydrogen()->is_keyed_load()) {
-    KeyedLoadIC::GenerateMiss(masm());
-  } else {
-    LoadIC::GenerateMiss(masm());
-  }
+  LoadIC::GenerateMiss(masm());
 }
 
 
index 9e6a65526b8056d94d0ac4fb2b634fc33c340f1f..87c4a64bbb0c5d4b3566cf6295e91c9a66c3e79c 100644 (file)
@@ -1133,17 +1133,10 @@ LInstruction* LChunkBuilder::DoTailCallThroughMegamorphicCache(
       UseFixed(instr->receiver(), LoadDescriptor::ReceiverRegister());
   LOperand* name_register =
       UseFixed(instr->name(), LoadDescriptor::NameRegister());
-  LOperand* slot = NULL;
-  LOperand* vector = NULL;
-  if (FLAG_vector_ics) {
-    slot = UseFixed(instr->slot(), VectorLoadICDescriptor::SlotRegister());
-    vector =
-        UseFixed(instr->vector(), VectorLoadICDescriptor::VectorRegister());
-  }
 
   // Not marked as call. It can't deoptimize, and it never returns.
   return new (zone()) LTailCallThroughMegamorphicCache(
-      context, receiver_register, name_register, slot, vector);
+      context, receiver_register, name_register);
 }
 
 
index a7a1fe87963a8a503b42ad26f9e39394fa93ed78..fa307cfd3ec9af730a03f7e1b8ab118ff4c49638 100644 (file)
@@ -478,23 +478,19 @@ class LCallStub FINAL : public LTemplateInstruction<1, 1, 0> {
 
 
 class LTailCallThroughMegamorphicCache FINAL
-    : public LTemplateInstruction<0, 5, 0> {
+    : public LTemplateInstruction<0, 3, 0> {
  public:
   explicit LTailCallThroughMegamorphicCache(LOperand* context,
-                                            LOperand* receiver, LOperand* name,
-                                            LOperand* slot, LOperand* vector) {
+                                            LOperand* receiver,
+                                            LOperand* name) {
     inputs_[0] = context;
     inputs_[1] = receiver;
     inputs_[2] = name;
-    inputs_[3] = slot;
-    inputs_[4] = vector;
   }
 
   LOperand* context() { return inputs_[0]; }
   LOperand* receiver() { return inputs_[1]; }
   LOperand* name() { return inputs_[2]; }
-  LOperand* slot() { return inputs_[3]; }
-  LOperand* vector() { return inputs_[4]; }
 
   DECLARE_CONCRETE_INSTRUCTION(TailCallThroughMegamorphicCache,
                                "tail-call-through-megamorphic-cache")