Converting 2 x86 opcodes to AArch64 (Switch) - need a bit of help

Maq47

Lord of Pyro
OP
Member
Joined
Jan 7, 2012
Messages
1,248
Trophies
1
Location
Your basement
Website
idont.have.one
XP
3,306
Country
United States
So, I'm trying to port a CheatEngine cheat table code to the Switch version of the game, and found out that the 2 opcodes that revolve around the cheat need to be converted to 2 or 3 opcodes EACH for the Switch. The problem I am having is figuring out how the switch does a store instruction of an immediate value to the address pointed to by a register PLUS an immediate value, like the below:

str 0x3DA3D70A, [w1 + 0x00000330]

The above code isn't valid, presumably because I formatted it wrong, so I am trying to get the hexadecimal representation of this. I have found an article for Cortex A-series CPUs online, which mentions the possibility of placing an immediate value into an address using store opcodes, but looking at other instruction set lists, I cannot find an opcode that does it. The closest that does anything like it doesn't allow any immediate values whatsoever, only using straight registers. I for certain need at least either an immediate value to be stored or an immediate value to be added to the destination address register. Is there no way to get that? If not, making this code could very well be a pipe dream for me without using IDA Pro or Ghidra on the executable and trying to search for specific instruction patterns, because if I have to split this instruction into more than 2 opcodes, it is unlikely that they will be consecutive in the executable. @FAST6191 I saw your post regarding AArch64 ASM from 2022 in the Vita section, maybe you could weigh in? You seem to know your stuff.

P.S.: The 2 x86 opcodes that I am trying to convert are the following:

Code:
[rbx + 00000330], 3DA3D70A
[rbx + 0000034C], 00000002
Their hexadecimal representation is the following:

Code:
C7 83 30 03 00 00 0A D7 A3 3D C7 83 4C 03 00 00 02 00 00 00
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
  • SylverReZ @ SylverReZ:
    @Materia_tofu, We do learn a lot from plenty of talented individuals.
  • Materia_tofu @ Materia_tofu:
    this is true! i learned how to make soundfont remixes from a friend back in 2021
    +1
  • BakerMan @ BakerMan:
    Update on my brother: He's home now, tired and hungry, obviously, but other than that, seems to be doing fine.
    +2
  • Veho @ Veho:
    That's a relief to hear. Do you know what happened?
  • SylverReZ @ SylverReZ:
    @BakerMan, Any idea what happened? I hope that your brother's doing good.
  • BakerMan @ BakerMan:
    Well, from what I've heard from my parents, he had a seizure last night, perhaps an epileptic episode, fucking died, had a near death experience, my dad called the paramedics, they showed up, took him to the hospital, and he woke up covered in tubes, and started complaining.
  • BakerMan @ BakerMan:
    He couldn't eat until after his MRI, when he had a bomb pop.
  • BakerMan @ BakerMan:
    What matters now is that he's doing alright.
  • Veho @ Veho:
    But you still don't know what it was?
  • Veho @ Veho:
    Has he had seizures before?
  • The Real Jdbye @ The Real Jdbye:
    apparently stress can cause seizures, my brother had one during a test once
  • The Real Jdbye @ The Real Jdbye:
    never had one before that, and never had one since
  • Redleviboy123 @ Redleviboy123:
    Question about game texture chanching Do i need an own game id?
  • The Real Jdbye @ The Real Jdbye:
    @Veho for those that want to
    experience being sonic the hedgehog
  • Veho @ Veho:
    Ah, you mean
    furries.
    +1
  • The Real Jdbye @ The Real Jdbye:
    well, sonic fans are a whole separate thing from furries
  • The Real Jdbye @ The Real Jdbye:
    like bronys
  • The Real Jdbye @ The Real Jdbye:
    sonic porn is too weird even for me
  • Dumpflam @ Dumpflam:
    bruh
  • Dumpflam @ Dumpflam:
    guys how do i delete a post
  • The Real Jdbye @ The Real Jdbye:
    you don't
  • The Real Jdbye @ The Real Jdbye:
    you can report it and request deletion
  • BakerMan @ BakerMan:
    Also, no, that was his first time having a seizure, and hopefully the last
    +1
    BakerMan @ BakerMan: Also, no, that was his first time having a seizure, and hopefully the last +1