Clarification on branch instruction when Register value is 0
Posted: Fri Mar 03, 2017 3:32 am
Hello Experts,
SLL R9,1
LTR R9,R9
BZ NXTMEET
BP NXTSEM
Suppose R9 has a value of 8. i.e. 10000000 00000000 00000000 00000000
When the first SLL R9,1 is executed,then both the above branch statements will be skipped since sign bit is negative.
Now for the second SLL R9,1 Can someone please tell me which Branch Instruction will be executed,since R9 now contains a value of 0 and also the bit 0 is 0 so positive.
SLL R9,1
LTR R9,R9
BZ NXTMEET
BP NXTSEM
Suppose R9 has a value of 8. i.e. 10000000 00000000 00000000 00000000
When the first SLL R9,1 is executed,then both the above branch statements will be skipped since sign bit is negative.
Now for the second SLL R9,1 Can someone please tell me which Branch Instruction will be executed,since R9 now contains a value of 0 and also the bit 0 is 0 so positive.