Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
lochsh
· 6y ago · 0 comments
This is true! If I was writing something to be optimal speed- and size-wise, I'd do that. I think I just liked the consistency with the other parts of the code where using both was necessary :)
Comments
[–]
lochsh
OP
6y ago
Oh actually I was being sleepy and hadn't understood what you'd said! I hadn't realised you could do that actually, neat, thanks!
So you could do `mov r1, #0x01000000` right? nice.
[–]
dmitrygr
6y ago
yup, some other constants are also loadable in one instr, of the form 0xXX00XX00, 0x00XX00XX, 0xXXXXXXXX where XX is any byte
[–]
saagarjha
6y ago
Do you not need the usual LSL, or does the assembler take care of that?
[–]
dmitrygr
6y ago
it does, yes