i m looking for a way to move any 32 bit constant in arch64 register X1.
Is there a way to perform the equivalent operation of
MOV X1, #imm32
imm32 can be any random 32 bit value like 0xaf41d32c
I know how it can be done in A32 using MOVW and MOVT. I do not want to use LDR X1, =0xaf41d32c, because i am not writing assembly code directly, but instead storing instructions in cache by writing their 32 bit ARM encodings in memory. So i basically cannot form an encoding for LDR X1, =0xaf41d32c.
For eg => According ARMv7 ref manual encoding for a instruction ADD R1, R1, #1 is 0xe2811001. So i store this in I Cache at a location and then start executing from that location.
Do A64 equivalents of MOVW and MOVT exist ? Can you suggest a solution ?