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
According to the CS:APP book 3rd edition, section 3.6.1, it is stated "For the logical operations, such as XOR, the carry and overflow flags are set to zero". To my understanding, other than not having the carry flag, y86 should have the same behavior on condition codes as x86.
Currently, if you do something like an addq that sets the overflow flag, the xorq instruction does not clear it. This is an easy fix in the instr.js file, line 81, where you can first set OF to zero before going into the switch statement.
Here is an example of a .ys code that reflects the discrepancy with the book stated above:
According to the CS:APP book 3rd edition, section 3.6.1, it is stated "For the logical operations, such as XOR, the carry and overflow flags are set to zero". To my understanding, other than not having the carry flag, y86 should have the same behavior on condition codes as x86.
Currently, if you do something like an
addq
that sets the overflow flag, thexorq
instruction does not clear it. This is an easy fix in the instr.js file, line 81, where you can first set OF to zero before going into the switch statement.Here is an example of a .ys code that reflects the discrepancy with the book stated above:
The text was updated successfully, but these errors were encountered: