< is less than and > is greater than
In arm if you want to check r1 > r2
the code is
Shouldn't the name actually be glt? Or am I confused?Code:cmp r1, r2 blt label1
< is less than and > is greater than
In arm if you want to check r1 > r2
the code is
Shouldn't the name actually be glt? Or am I confused?Code:cmp r1, r2 blt label1
You're assuming that because r1 is on the left in the assembly instruction that it corresponds with the left hand side of the express "r1 > r2". That assumption is completely baseless.
Code://try //{ if (a) do { f( b); } while(1); else do { f(!b); } while(1); //}
We would need to see the the high-level code and the rest of the assembly code to determine if it's correct. It really depends on whether the branch is taking you to the "if" part, or some "else" part, or the loop condition this belongs to.