Using ARM assembly, I want to load R0 with predefined bytes A, B, C, D. In the .data section I have them defined as:
A: .byte 0xFF
B: .byte 0xAA
C: .byte 0x88
D: .byte 0x77
I want R0 to be FFAA8877 when all is said and done. Not sure I should be using .byte or .word or even something else for A, B, C, D.
EDIT: Here is what I'm trying to do with R0:
@on entry: R0 holds the word to be swapped
@on exit: R0 holds the swapped word, R1 is destroyed
@R0 = A, B, C, D
byteswap:
EOR R1, R0, R0, ROR #16
BIC R1, R1, #0xFF0000
MOV R0, R0, ROR #8
EOR R0, R0, R1, LSR #8