@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ @ @ @ Assembly file for "read" @ @ @ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ @ Author: Yu-Fang Wu @ Date: 28th September, 2003 @---------------------------------------------------------------------- @ Assembly language preamble for the main module .text @ Executable code follows .global read @ Declare function read @---------------------------------------------------------------------- .equ spartan_VSData, 0x4000000A read: mov ip, sp @ Save the callers Stack pointer into ip stmfd sp!, {fp, ip, lr, pc, r0} @ Store things that need to be preserved sub fp, ip, #4 @ Set up frame pointer ldr r0, =spartan_VSData @ Load the address of VS data ldrb r0, [r0] read_done: ldmea fp, {fp, sp, pc}