now that Apple's platforms finally made a decision about architectures, I am starting to learn arm64 assembly on Darwin, and I don't find any information how to load addresses in the .data section.
On Linux, this works:
ldr X1, =symbol
.data
symbol: .ascii "foo"
Apple has an article why this does not work for Mach-O binaries, and how it is done on x86 with @GOTPCREL
, but that does not tell me how the Clang assembler handles this on Apple Silicon.
(Putting the data into the .text section does not help, because I need it to be writable)
Any information is appreciated!