EmbDev.net

Forum: ARM programming with GCC/GNU tools asm instruction question


von Dustin S. (dbrazeau)


Rate this post
useful
not useful
I am trying to debug my source through the disassembly and I can't find
any documentation on asm instruction streqt.  Could someone exsplain
this instruction to me.

streqt  fp, [r9], #543

Thanks,
DB

von Clifford S. (clifford)


Rate this post
useful
not useful
Dustin Sr wrote:
> I am trying to debug my source through the disassembly and I can't find
> any documentation on asm instruction streqt.  Could someone exsplain
> this instruction to me.
>
> streqt  fp, [r9], #543
>
> Thanks,
> DB

It is "Store Register With Translation" with a condition code of EQ (i.e
equal). The ARM instruction set has a clever feature of conditional
instructions. So this instruction is executed only if the Z flag is set
(for example from the result of a preceding compare).

It is listed in the ARM Architecture Reference Manual (you do have that
right!?) under the STRT instruction - the default condition code is AL
(always), so this is equivalent to STRALT.

The condition code reduces instruction count considerably because short
conditional sequences of one or two instructions can be encoded without
a separate conditional branch instruction.

The ARM Architecture Reference Manual can be downloaded from
http://www.altera.com/literature/third-party/ddi0100e_arm_arm.pdf. This
is not the latest edition but unless you are using a recent ARM
architecture part it should be fine - it covers ARM architecture v3, 4,
and 5 (which includes ARM7 and 9 parts - ARM's numbering is designed to
confuse it seems!).

Clifford

Please log in before posting. Registration is free and takes only a minute.
Existing account
Do you have a Google/GoogleMail account? No registration required!
Log in with Google account
No account? Register here.