summaryrefslogtreecommitdiff
path: root/deps/v8/src/compiler/instruction.cc
diff options
context:
space:
mode:
Diffstat (limited to 'deps/v8/src/compiler/instruction.cc')
-rw-r--r--deps/v8/src/compiler/instruction.cc49
1 files changed, 13 insertions, 36 deletions
diff --git a/deps/v8/src/compiler/instruction.cc b/deps/v8/src/compiler/instruction.cc
index 1067d2030a..8096c5b048 100644
--- a/deps/v8/src/compiler/instruction.cc
+++ b/deps/v8/src/compiler/instruction.cc
@@ -64,7 +64,6 @@ FlagsCondition CommuteFlagsCondition(FlagsCondition condition) {
return condition;
}
UNREACHABLE();
- return condition;
}
bool InstructionOperand::InterferesWith(const InstructionOperand& other) const {
@@ -210,15 +209,6 @@ std::ostream& operator<<(std::ostream& os,
case MachineRepresentation::kSimd128:
os << "|s128";
break;
- case MachineRepresentation::kSimd1x4:
- os << "|s1x4";
- break;
- case MachineRepresentation::kSimd1x8:
- os << "|s1x8";
- break;
- case MachineRepresentation::kSimd1x16:
- os << "|s1x16";
- break;
case MachineRepresentation::kTaggedSigned:
os << "|ts";
break;
@@ -235,7 +225,6 @@ std::ostream& operator<<(std::ostream& os,
return os << "(x)";
}
UNREACHABLE();
- return os;
}
void MoveOperands::Print(const RegisterConfiguration* config) const {
@@ -415,7 +404,6 @@ std::ostream& operator<<(std::ostream& os, const ArchOpcode& ao) {
#undef CASE
}
UNREACHABLE();
- return os;
}
@@ -430,7 +418,6 @@ std::ostream& operator<<(std::ostream& os, const AddressingMode& am) {
#undef CASE
}
UNREACHABLE();
- return os;
}
@@ -448,7 +435,6 @@ std::ostream& operator<<(std::ostream& os, const FlagsMode& fm) {
return os << "trap";
}
UNREACHABLE();
- return os;
}
@@ -504,7 +490,6 @@ std::ostream& operator<<(std::ostream& os, const FlagsCondition& fc) {
return os << "negative";
}
UNREACHABLE();
- return os;
}
@@ -576,6 +561,12 @@ Handle<HeapObject> Constant::ToHeapObject() const {
return value;
}
+Handle<Code> Constant::ToCode() const {
+ DCHECK_EQ(kHeapObject, type());
+ Handle<Code> value(bit_cast<Code**>(static_cast<intptr_t>(value_)));
+ return value;
+}
+
std::ostream& operator<<(std::ostream& os, const Constant& constant) {
switch (constant.type()) {
case Constant::kInt32:
@@ -585,7 +576,7 @@ std::ostream& operator<<(std::ostream& os, const Constant& constant) {
case Constant::kFloat32:
return os << constant.ToFloat32() << "f";
case Constant::kFloat64:
- return os << constant.ToFloat64();
+ return os << constant.ToFloat64().value();
case Constant::kExternalReference:
return os << static_cast<const void*>(
constant.ToExternalReference().address());
@@ -595,7 +586,6 @@ std::ostream& operator<<(std::ostream& os, const Constant& constant) {
return os << "RPO" << constant.ToRpoNumber().ToInt();
}
UNREACHABLE();
- return os;
}
@@ -896,21 +886,17 @@ static MachineRepresentation FilterRepresentation(MachineRepresentation rep) {
return InstructionSequence::DefaultRepresentation();
case MachineRepresentation::kWord32:
case MachineRepresentation::kWord64:
- case MachineRepresentation::kFloat32:
- case MachineRepresentation::kFloat64:
- case MachineRepresentation::kSimd128:
- case MachineRepresentation::kSimd1x4:
- case MachineRepresentation::kSimd1x8:
- case MachineRepresentation::kSimd1x16:
case MachineRepresentation::kTaggedSigned:
case MachineRepresentation::kTaggedPointer:
case MachineRepresentation::kTagged:
+ case MachineRepresentation::kFloat32:
+ case MachineRepresentation::kFloat64:
+ case MachineRepresentation::kSimd128:
return rep;
case MachineRepresentation::kNone:
break;
}
UNREACHABLE();
- return MachineRepresentation::kNone;
}
@@ -1033,18 +1019,9 @@ FrameStateDescriptor::FrameStateDescriptor(
shared_info_(shared_info),
outer_state_(outer_state) {}
-
-size_t FrameStateDescriptor::GetSize(OutputFrameStateCombine combine) const {
- size_t size = 1 + parameters_count() + locals_count() + stack_count() +
- (HasContext() ? 1 : 0);
- switch (combine.kind()) {
- case OutputFrameStateCombine::kPushOutput:
- size += combine.GetPushCount();
- break;
- case OutputFrameStateCombine::kPokeAt:
- break;
- }
- return size;
+size_t FrameStateDescriptor::GetSize() const {
+ return 1 + parameters_count() + locals_count() + stack_count() +
+ (HasContext() ? 1 : 0);
}