You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Even when the result of the muls instruction is 0, the CPSR's Z flag does not become 1.
When r0=r1=65536,
muls r0, r1, r0
is executed, the Z flag does not become 1.
The likely cause is within ARMv7_CPU.prototype.mul = function(inst, addr){}
in arm-js/js/armv7-cpu.js, where the comparison (ret === 0) is made while ret includes the upper 32 bits, causing the issue.
When modified to something like this.cpsr.z = (ret.low === 0) ? 1 : 0;
it behaves as expected.
The text was updated successfully, but these errors were encountered:
Even when the result of the muls instruction is 0, the CPSR's Z flag does not become 1.
When r0=r1=65536,
muls r0, r1, r0
is executed, the Z flag does not become 1.
The likely cause is within
ARMv7_CPU.prototype.mul = function(inst, addr){}
in arm-js/js/armv7-cpu.js, where the comparison (ret === 0) is made while ret includes the upper 32 bits, causing the issue.
When modified to something like
this.cpsr.z = (ret.low === 0) ? 1 : 0;
it behaves as expected.
The text was updated successfully, but these errors were encountered: