You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When ghidra analyzed the file of MIPS:BE:32 architecture, the function recognized the error and expected FUN_00402120 to be changed to system.
Like the files for the MIPS:LE:32 architecture
The text was updated successfully, but these errors were encountered:
There is something weird in the first screenshot with the delay slots.
The second one looks correct: addiu is located after jr, so it will be executed in the delay slot of jr.
However it the first example, addiu is before jr. So the lui instruction of the next function will be executed in the delay slot of jr. This could explain why the function is not "thunked" ; it is not just a call to "system". Also, it seems to mess up the function analysis a lot, since it adds a "call return override" on the lui instruction.
I guess it's a "bug" in the compiler for the plt/got generation, since the rest of the functions looks normal.
It does appear to be a bug in the compiler generating the .plt code.
The code might actually execute, however as @Tim--- mentions the function below the jr to system has it's first instruction as part of the delayslot of the previous functions final jr instruction.
Ghidra doesn't currently support branching into the delay-slot, so it messes with analysis a bit, including turning the first instruction of the following function into a call/return. Which it is, but as the first instruction of the next function it isn't.
The shared return analyzer might be able to put the flow override on the jr, but the API might actually force it on the delay-slotted instruction.
When ghidra analyzed the file of MIPS:BE:32 architecture, the function recognized the error and expected FUN_00402120 to be changed to system.
Like the files for the MIPS:LE:32 architecture
The text was updated successfully, but these errors were encountered: