Skip to content

Commit

Permalink
Backed out 2 changesets (bug 1609138, bug 1608791) for Assembler-vixl…
Browse files Browse the repository at this point in the history
….h related bustage CLOSED TREE

Backed out changeset 7d2c3216d225 (bug 1608791)
Backed out changeset d2b7ff305b35 (bug 1609138)
  • Loading branch information
bogdant-old committed Jan 20, 2020
1 parent c210152 commit 4dbee21
Show file tree
Hide file tree
Showing 12 changed files with 165 additions and 220 deletions.
10 changes: 4 additions & 6 deletions js/src/jit/JitFrames.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2170,12 +2170,10 @@ MachineState MachineState::FromBailout(RegisterDump::GPRArray& regs,
}
#elif defined(JS_CODEGEN_ARM64)
for (unsigned i = 0; i < FloatRegisters::TotalPhys; i++) {
machine.setRegisterLocation(
FloatRegister(FloatRegisters::Encoding(i), FloatRegisters::Single),
&fpregs[i]);
machine.setRegisterLocation(
FloatRegister(FloatRegisters::Encoding(i), FloatRegisters::Double),
&fpregs[i]);
machine.setRegisterLocation(FloatRegister(i, FloatRegisters::Single),
&fpregs[i]);
machine.setRegisterLocation(FloatRegister(i, FloatRegisters::Double),
&fpregs[i]);
}

#elif defined(JS_CODEGEN_NONE)
Expand Down
7 changes: 2 additions & 5 deletions js/src/jit/arm/Architecture-arm.h
Original file line number Diff line number Diff line change
Expand Up @@ -386,11 +386,8 @@ class VFPRegister {
bool isUInt() const { return kind == UInt; }
bool equiv(const VFPRegister& other) const { return other.kind == kind; }
size_t size() const { return (kind == Double) ? 8 : 4; }
bool isInvalid() const { return _isInvalid; }
bool isMissing() const {
MOZ_ASSERT(!_isInvalid);
return _isMissing;
}
bool isInvalid() const;
bool isMissing() const;

VFPRegister doubleOverlay(unsigned int which = 0) const;
VFPRegister singleOverlay(unsigned int which = 0) const;
Expand Down
7 changes: 7 additions & 0 deletions js/src/jit/arm/Assembler-arm.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1114,6 +1114,13 @@ VFPRegister VFPRegister::uintOverlay(unsigned int which) const {
return VFPRegister(code_, UInt);
}

bool VFPRegister::isInvalid() const { return _isInvalid; }

bool VFPRegister::isMissing() const {
MOZ_ASSERT(!_isInvalid);
return _isMissing;
}

bool Assembler::oom() const {
return AssemblerShared::oom() || m_buffer.oom() || jumpRelocations_.oom() ||
dataRelocations_.oom();
Expand Down
2 changes: 1 addition & 1 deletion js/src/jit/arm/Simulator-arm.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -526,7 +526,7 @@ bool ArmDebugger::getValue(const char* desc, int32_t* value) {

bool ArmDebugger::getVFPDoubleValue(const char* desc, double* value) {
FloatRegister reg = FloatRegister::FromCode(FloatRegister::FromName(desc));
if (reg.isInvalid()) {
if (reg == InvalidFloatReg) {
return false;
}

Expand Down
12 changes: 8 additions & 4 deletions js/src/jit/arm64/Architecture-arm64.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,22 +28,22 @@ Registers::Code Registers::FromName(const char* name) {
}

for (uint32_t i = 0; i < Total; i++) {
if (strcmp(GetName(i), name) == 0) {
if (strcmp(GetName(Code(i)), name) == 0) {
return Code(i);
}
}

return Invalid;
return invalid_reg;
}

FloatRegisters::Code FloatRegisters::FromName(const char* name) {
for (size_t i = 0; i < Total; i++) {
if (strcmp(GetName(i), name) == 0) {
if (strcmp(GetName(Code(i)), name) == 0) {
return Code(i);
}
}

return Invalid;
return invalid_fpreg;
}

FloatRegisterSet FloatRegister::ReduceSetForPush(const FloatRegisterSet& s) {
Expand All @@ -54,6 +54,10 @@ FloatRegisterSet FloatRegister::ReduceSetForPush(const FloatRegisterSet& s) {
return ret.set();
}

uint32_t FloatRegister::GetSizeInBytes(const FloatRegisterSet& s) {
return s.size() * sizeof(double);
}

uint32_t FloatRegister::GetPushSizeInBytes(const FloatRegisterSet& s) {
return s.size() * sizeof(double);
}
Expand Down
Loading

0 comments on commit 4dbee21

Please sign in to comment.