This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Thumb and Thumb2

Hello evreybody,

I have met a confusiong issue while working with the RVMDK assembly:
when I have written this statement:

ADD r1, r1, r2


It has been coded in Thumb2. But when I have changed the ADD instruction to ADDS, it become a Thumb instruction!
Could any one explain to me why the add of the S, which indicates if the stauts register has to be modified or not, changes the mode in wich the instruction is coded.

Thanks to all

Parents
  • Hi Robert,

    Thank you for the response.
    Could you please tell me where I can found this kind of information?
    In fact, to write a speed optimized assembly code, it is more efficient to use Thumb instructions instead of Thumb2. Unless, the Thumb2 are used to reduce the number of the instructions. So, the user who intends to write an assembly program must know in which mode their instructions will be coded.

    Thank you again

    Thank You again

Reply
  • Hi Robert,

    Thank you for the response.
    Could you please tell me where I can found this kind of information?
    In fact, to write a speed optimized assembly code, it is more efficient to use Thumb instructions instead of Thumb2. Unless, the Thumb2 are used to reduce the number of the instructions. So, the user who intends to write an assembly program must know in which mode their instructions will be coded.

    Thank you again

    Thank You again

Children