- The jz instruction is a conditional jump that follows a test.
- It jumps to the specified location if the Zero Flag (ZF) is set (1).
- jz is commonly used to explicitly test for something being equal to zero whereas je is commonly found after a cmp instruction.
test eax, eax ; test if eax=0
jz short loc_402B13 ; if condition is met, jump to loc_402B13
cmp edx, 42
je short loc_402B13 ; if edx equals 42, jum to loc_402B13
blog comments powered by