renderdoc
renderdoc copied to clipboard
Handle preloaders in GetExecutableFilename
Description
Uses /proc/self/cmdline
instead of /proc/self/exe
for GetExecutableFilename
to correctly handle preloaders, such as the Wine preloader.
Additionally handles removing leading directories with Windows style \
s if it detects this is the Wine preloader.
This is intended to make things cleaner for developers using the new RenderDoc functionality in the SteamOS Devkit Client.
For the FEX-Emu comment here, behaviour changes depending on how something is getting captured.
-
Capturing using x86-64/x86 Renderdoc This is used for capturing applications without using native AArch64 Vulkan/GL thunks. This means
/proc/self/exe
and/proc/self/cmdline
get captured by our emulation code andFEXInterpreter
gets hidden from these files. -
Capture using AArch64 Renderdoc This is ussed for capturing applications that use native AArch64 Vulkan/GL thunks. In this case, renderdoc wouldn't hit FEX's emulation of these files so
FEXInterpreter
would be visible in the files.
In the future we would like to resolve this binfmt_misc oversight in the kernel with a new option there. This way if a binfmt_misc option opts it, it would be more similar to how the Linux kernel resolves this situation with PT_INTERP, hiding the interpreter from these options. Sadly this would require someone to deal with kernel so it is unlikely to get fixed anytime soon.
Closing this due to lack of activity.
We still need to solve this. I can come back to it this week if you are still open to it.
Yes if you want to resume work on it you can reopen the PR. I closed it because I'd asked questions/given review feedback and it hadn't been addressed or replied to.
I am not able to re open it because you closed it.
Ah OK. Yeh then open a new PR when you're ready to work on it again, not much in this one anyway.