mirror of
https://github.com/wownero/RandomX.git
synced 2026-10-19 16:28:47 +02:00
Fixed non-portable deserialization
This commit is contained in:
+14
-14
@@ -37,7 +37,7 @@ namespace RandomX {
|
||||
}
|
||||
|
||||
void Instruction::genAddressImm(std::ostream& os) const {
|
||||
os << "L3" << "[" << (imm32 & ScratchpadL3Mask) << "]";
|
||||
os << "L3" << "[" << (getImm32() & ScratchpadL3Mask) << "]";
|
||||
}
|
||||
|
||||
void Instruction::h_IADD_R(std::ostream& os) const {
|
||||
@@ -45,7 +45,7 @@ namespace RandomX {
|
||||
os << "r" << (int)dst << ", r" << (int)src << std::endl;
|
||||
}
|
||||
else {
|
||||
os << "r" << (int)dst << ", " << (int32_t)imm32 << std::endl;
|
||||
os << "r" << (int)dst << ", " << (int32_t)getImm32() << std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -63,7 +63,7 @@ namespace RandomX {
|
||||
}
|
||||
|
||||
void Instruction::h_IADD_RC(std::ostream& os) const {
|
||||
os << "r" << (int)dst << ", r" << (int)src << ", " << (int32_t)imm32 << std::endl;
|
||||
os << "r" << (int)dst << ", r" << (int)src << ", " << (int32_t)getImm32() << std::endl;
|
||||
}
|
||||
|
||||
//1 uOP
|
||||
@@ -72,7 +72,7 @@ namespace RandomX {
|
||||
os << "r" << (int)dst << ", r" << (int)src << std::endl;
|
||||
}
|
||||
else {
|
||||
os << "r" << (int)dst << ", " << (int32_t)imm32 << std::endl;
|
||||
os << "r" << (int)dst << ", " << (int32_t)getImm32() << std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -90,7 +90,7 @@ namespace RandomX {
|
||||
}
|
||||
|
||||
void Instruction::h_IMUL_9C(std::ostream& os) const {
|
||||
os << "r" << (int)dst << ", " << (int32_t)imm32 << std::endl;
|
||||
os << "r" << (int)dst << ", " << (int32_t)getImm32() << std::endl;
|
||||
}
|
||||
|
||||
void Instruction::h_IMUL_R(std::ostream& os) const {
|
||||
@@ -98,7 +98,7 @@ namespace RandomX {
|
||||
os << "r" << (int)dst << ", r" << (int)src << std::endl;
|
||||
}
|
||||
else {
|
||||
os << "r" << (int)dst << ", " << (int32_t)imm32 << std::endl;
|
||||
os << "r" << (int)dst << ", " << (int32_t)getImm32() << std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -158,7 +158,7 @@ namespace RandomX {
|
||||
os << "r" << (int)dst << ", r" << (int)src << std::endl;
|
||||
}
|
||||
else {
|
||||
os << "r" << (int)dst << ", " << (int32_t)imm32 << std::endl;
|
||||
os << "r" << (int)dst << ", " << (int32_t)getImm32() << std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -180,7 +180,7 @@ namespace RandomX {
|
||||
os << "r" << (int)dst << ", r" << (int)src << std::endl;
|
||||
}
|
||||
else {
|
||||
os << "r" << (int)dst << ", " << (imm32 & 63) << std::endl;
|
||||
os << "r" << (int)dst << ", " << (getImm32() & 63) << std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -189,16 +189,16 @@ namespace RandomX {
|
||||
os << "r" << (int)dst << ", r" << (int)src << std::endl;
|
||||
}
|
||||
else {
|
||||
os << "r" << (int)dst << ", " << (imm32 & 63) << std::endl;
|
||||
os << "r" << (int)dst << ", " << (getImm32() & 63) << std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
void Instruction::h_IMUL_RCP(std::ostream& os) const {
|
||||
os << "r" << (int)dst << ", " << imm32 << std::endl;
|
||||
os << "r" << (int)dst << ", " << getImm32() << std::endl;
|
||||
}
|
||||
|
||||
void Instruction::h_ISDIV_C(std::ostream& os) const {
|
||||
os << "r" << (int)dst << ", " << (int32_t)imm32 << std::endl;
|
||||
os << "r" << (int)dst << ", " << (int32_t)getImm32() << std::endl;
|
||||
}
|
||||
|
||||
void Instruction::h_ISWAP_R(std::ostream& os) const {
|
||||
@@ -274,7 +274,7 @@ namespace RandomX {
|
||||
}
|
||||
|
||||
void Instruction::h_CFROUND(std::ostream& os) const {
|
||||
os << "r" << (int)src << ", " << (imm32 & 63) << std::endl;
|
||||
os << "r" << (int)src << ", " << (getImm32() & 63) << std::endl;
|
||||
}
|
||||
|
||||
static inline const char* condition(int index) {
|
||||
@@ -302,13 +302,13 @@ namespace RandomX {
|
||||
}
|
||||
|
||||
void Instruction::h_COND_R(std::ostream& os) const {
|
||||
os << "r" << (int)dst << ", " << condition((mod >> 2) & 7) << "(r" << (int)src << ", " << (int32_t)imm32 << ")" << std::endl;
|
||||
os << "r" << (int)dst << ", " << condition((mod >> 2) & 7) << "(r" << (int)src << ", " << (int32_t)getImm32() << ")" << std::endl;
|
||||
}
|
||||
|
||||
void Instruction::h_COND_M(std::ostream& os) const {
|
||||
os << "r" << (int)dst << ", " << condition((mod >> 2) & 7) << "(";
|
||||
genAddressReg(os);
|
||||
os << ", " << (int32_t)imm32 << ")" << std::endl;
|
||||
os << ", " << (int32_t)getImm32() << ")" << std::endl;
|
||||
}
|
||||
|
||||
void Instruction::h_ISTORE(std::ostream& os) const {
|
||||
|
||||
Reference in New Issue
Block a user