Re: Simple ARM code generation

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> To make things a bit easier when talking about stacks you can also talk 
> about the stack layout in the instructions, you can then write your ldm 
> and stm instructions using the stack mnemonics, the most common of which 
> is a 'full-descending' stack (the stack grows by moving to a lower address 
> and the bottom, addresed, word contains data -- it's full).  So
> 
> 	stmdb sp!, {r4, r5, r6}
> 	ldmdb sp!, {r4, r5, r6}
> 
> will push r4-r6 onto the stack and then pop them off again.

Bah! I've just noticed a critical typo in the above.  The stack variants 
of the instructions are

	stmFD sp!, {r4, r5, r6}
	ldmFD sp!, {r4, r5, r6}

FD describes the stack here (F-ull D-escending).

Sorry about that, hope you weren't too confused.

R.



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux