mirror of
https://github.com/wownero/RandomX.git
synced 2026-10-25 10:18:39 +01:00
Fixed IMUL_RCP if divisor is a power of 2
This commit is contained in:
@@ -435,8 +435,8 @@ namespace randomx {
|
||||
} break;
|
||||
|
||||
CASE_REP(IMUL_RCP) {
|
||||
uint32_t divisor = instr.getImm32();
|
||||
if (divisor != 0) {
|
||||
uint64_t divisor = instr.getImm32();
|
||||
if (!isPowerOf2(divisor)) {
|
||||
auto dst = instr.dst % RegistersCount;
|
||||
ibc.type = InstructionType::IMUL_R;
|
||||
ibc.idst = &r[dst];
|
||||
|
||||
Reference in New Issue
Block a user