Revert "Revert "Upgrade to 5.0.71.48"" DO NOT MERGE
This reverts commit f2e3994fa5148cc3d9946666f0b0596290192b0e,
and updates the x64 makefile properly so it doesn't break that
build.
FPIIM-449
Change-Id: Ib83e35bfbae6af627451c926a9650ec57c045605
(cherry picked from commit 109988c7ccb6f3fd1a58574fa3dfb88beaef6632)
diff --git a/src/compiler/instruction.h b/src/compiler/instruction.h
index 8a6a0ae..9c978ce 100644
--- a/src/compiler/instruction.h
+++ b/src/compiler/instruction.h
@@ -67,8 +67,10 @@
inline bool IsAnyRegister() const;
inline bool IsRegister() const;
inline bool IsDoubleRegister() const;
+ inline bool IsSimd128Register() const;
inline bool IsStackSlot() const;
inline bool IsDoubleStackSlot() const;
+ inline bool IsSimd128StackSlot() const;
template <typename SubKindOperand>
static SubKindOperand* New(Zone* zone, const SubKindOperand& op) {
@@ -411,7 +413,7 @@
}
int index() const {
- DCHECK(IsStackSlot() || IsDoubleStackSlot());
+ DCHECK(IsStackSlot() || IsDoubleStackSlot() || IsSimd128StackSlot());
return static_cast<int64_t>(value_) >> IndexField::kShift;
}
@@ -427,6 +429,12 @@
IndexField::kShift);
}
+ Simd128Register GetSimd128Register() const {
+ DCHECK(IsSimd128Register());
+ return Simd128Register::from_code(static_cast<int64_t>(value_) >>
+ IndexField::kShift);
+ }
+
LocationKind location_kind() const {
return LocationKindField::decode(value_);
}
@@ -441,6 +449,7 @@
case MachineRepresentation::kWord64:
case MachineRepresentation::kFloat32:
case MachineRepresentation::kFloat64:
+ case MachineRepresentation::kSimd128:
case MachineRepresentation::kTagged:
return true;
case MachineRepresentation::kBit:
@@ -522,6 +531,12 @@
IsFloatingPoint(LocationOperand::cast(this)->representation());
}
+bool InstructionOperand::IsSimd128Register() const {
+ return IsAnyRegister() &&
+ LocationOperand::cast(this)->representation() ==
+ MachineRepresentation::kSimd128;
+}
+
bool InstructionOperand::IsStackSlot() const {
return (IsAllocated() || IsExplicit()) &&
LocationOperand::cast(this)->location_kind() ==
@@ -536,6 +551,14 @@
IsFloatingPoint(LocationOperand::cast(this)->representation());
}
+bool InstructionOperand::IsSimd128StackSlot() const {
+ return (IsAllocated() || IsExplicit()) &&
+ LocationOperand::cast(this)->location_kind() ==
+ LocationOperand::STACK_SLOT &&
+ LocationOperand::cast(this)->representation() ==
+ MachineRepresentation::kSimd128;
+}
+
uint64_t InstructionOperand::GetCanonicalizedValue() const {
if (IsAllocated() || IsExplicit()) {
// TODO(dcarney): put machine type last and mask.
@@ -633,8 +656,14 @@
MoveOperands* AddMove(const InstructionOperand& from,
const InstructionOperand& to) {
- auto zone = get_allocator().zone();
- auto move = new (zone) MoveOperands(from, to);
+ Zone* zone = get_allocator().zone();
+ return AddMove(from, to, zone);
+ }
+
+ MoveOperands* AddMove(const InstructionOperand& from,
+ const InstructionOperand& to,
+ Zone* operand_allocation_zone) {
+ MoveOperands* move = new (operand_allocation_zone) MoveOperands(from, to);
push_back(move);
return move;
}
@@ -732,7 +761,6 @@
return FlagsConditionField::decode(opcode());
}
- // TODO(titzer): make call into a flags.
static Instruction* New(Zone* zone, InstructionCode opcode) {
return New(zone, opcode, 0, nullptr, 0, nullptr, 0, nullptr);
}
@@ -1323,6 +1351,11 @@
void Print(const RegisterConfiguration* config) const;
void Print() const;
+ void PrintBlock(const RegisterConfiguration* config, int block_id) const;
+ void PrintBlock(int block_id) const;
+
+ void Validate();
+
private:
friend std::ostream& operator<<(std::ostream& os,
const PrintableInstructionSequence& code);