Replies: 1 comment 3 replies
-
If its relevant, param_1 is a class, that I am representing as a struct due to ghidra's current inability to represent classes. TrashTStringInstancePlus**? seems to only ever be called on Classes. |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Okay, so there's this function, and a couple others like this, which definitely don't seem to be using standard calling conventions, but I'm not sure what to change it to, to get things decompiling correctly.


This seems to be for some sort of memory thing? It pops up to reset variables inside of classes in vtable functions and the like, however it's "output" is just... wrong. "iVar2" is just.. also param1 at an offset of 0x3c. So for example, the second call of the "trash" function takes param1->0x34, and the third call takes param1->0x30. I can get the correct behavior here, by manually creating pointer offsets at every time this function is called, but that... really sucks for both readability, and because I have to keep doing it every single time. Since it should just be spitting out a pointer offset of "whatever it takes in", what do I even define it as? Marking it as no-return just breaks things, making it return a different register doesn't fix the problem either, etc.
here's the bytecode of where the function is being called as well, for reference.
What do I do to this function to get things decompiling correctly?
Beta Was this translation helpful? Give feedback.
All reactions