Using Visual Studio 2010/2012, one can compile a c++ source file with the /FAs
switch to generate the assembly output of the resulting code. But the generated asm file contains all symbols in their mangled form.
Is there a switch or other smart way to make Visual Studio generate unmangled symbols instead? I know that one could manually feed the asm file through undname.exe
but a switch would be much more convenient than a custom post-build event.
It is not possible to do so, because of the nature of /FA's output. FA outputs valid assembly code. The symbols one needs to express a C++ function unmangled are simply not valid label names in microsoft's x86 assembly. There is also no good notation for anonymous namespaces.
Any output which handled those cases would not be compilable using an assembler. If you made an assembler which did handle such names, it would need to know whose name mangling rules to apply to assemble it. This defeats the main purpose of outputting assembly (to see EXACTLY what is going on).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With