I'm interested in writing and understanding assembly. I'm currently trying on a M2 Apple chip. And I just want to translate x86-64 assembly code to ARM64 one. Is it possible ? And how?
To do so i started to write some code in nasm (i found the most documentation on it but feel free to give me advice if you have a better understanding of the subject), and when i want to execute the .o file that the command : nasm -f elf64 -l hello.lst hello.asm gave me I have an error.
Of course it is because my processor is an M2 chip from Apple, but I couldn't figure out how I can (if I can) change those x86-64 executable files to files my computer can understand.
After some research I could not find gcc or nasm commands to make those files. I am also aware of Apple's Rosetta but I couldn't put it in use also.
Also, should I keep trying writing in nasm assembly, or may I start to learn ARM64 assembly?
Thanks for your help !