A quick elementary assembly question I'm puzzling over:
When the compare results are equal, does the N-flag remain 0 and thus the branch is taken?
Now, a similar question with a two's complement twist:
Am I correct that the result of the CPY ($80) is -128 in two's complement and the branch will be skipped?
Finally, a slightly related question on absolute indexed addressing:
Is Y treated as a positive or negative index? In other words, does indexing ignore two's complement?
Code:
LDY #$04
CPY #$04
BPL label
CPY #$04
BPL label
When the compare results are equal, does the N-flag remain 0 and thus the branch is taken?
Now, a similar question with a two's complement twist:
Code:
LDY #$84
CPY #$04
BPL label
CPY #$04
BPL label
Am I correct that the result of the CPY ($80) is -128 in two's complement and the branch will be skipped?
Finally, a slightly related question on absolute indexed addressing:
Code:
LDY #$80
LDA DATA, Y
LDA DATA, Y
Is Y treated as a positive or negative index? In other words, does indexing ignore two's complement?