Category talk:ARM Assembly: Difference between revisions

no edit summary
imported>BlueWren
No edit summary
imported>BlueWren
No edit summary
 
Line 21:
 
Consistent is that the programmer can see 16 registers numbered R0 to R15. R15 is the PC (Program Counter). There is not a RTS (Return from Subroutine) instruction, instead typically a MOVS PC, R14 (Acorn often used an ORRS PC, R14 etc instruction) is used to return to the calling point. NB R14 is the return address not R13 as stated in the text. R13 was usually assigned the meaning of a SP (Stack Pointer) but that was a convention recommended by Acorn rather than being a fundamental design of the microprocessor.
 
Along the way I have written a Mandelbrot program mostly in ANSI-C but with the calculation in ARM code using fixed point and a choice of 32 bits or 64 bits or 256 bits precision. It can use the MUL instruction or the UMULL if it detects that it is running on a suitable ARM microprocessor.
 
I also wrote an interrupt code fragment when my Caps Lock stopped working.
 
--[[User:BlueWren|BlueWren]] ([[User talk:BlueWren|talk]]) 17:27, 29 September 2023 (UTC)
Anonymous user