Provides -C as alias to -demangle. Motivation: https://bugs.llvm.org/show_bug.cgi?id=40069.
I cannot have DIA SDK on my computer. As I see @jhenderson you have a Windows computer. Could you please write if tests are correct and in the right place. If there is a way to test it without DIA SDK any advice would be helpful.
Could you add an ELF test for this too, please, to show the route through the Itanium demangler (and when it doesn't go through it for -C=false)?
Unfortunately, it looks like I don't have a pre-requisite either, so the pdb test is unsupported for me too. The test change looks safe, but adding the ELF test as well would give the extra reassurance.
How do i call itanium demangler? AFAIK llvm-symbolizer only accepts bool value of -demangle flag.
The Itanium demangler is used typically for ELF C++ symbols. If you take a look at test/tools/llvm-objdump/X86/demangle.s, you can see how the (de-)mangling happens. test/DebugInfo/llvm-symbolizer.test also uses the --demangle switch, and you could extend it to add -C alongside the demangle=false case or similar, if you want.
This is not a new test because we have a test that exercises -demangle=false, but what is the "false" format style? addr2line reports an error if an argument given to --demangle or -C is not known.
You don't need a new check-prefix. You can reuse the existing one. You also don't need to recreate %t.input7.
Interesting catch. That wasn't something I noticed. llvm-symbolizer treats --demangle (and therefore -C) as a boolean switch, rather than one that takes a style, i.e. --demangle=false disables demangling.
It's worth noting that unlike addr2line, demangling is on by default too, so this switch only needs to exist for a) compatibility, and b) so that demangling can be disabled, unless we change the default (which could break people's workflows...).
LGTM. I'm happy with this, but I'd like @ruiu to give a final thumbs up with relation to his comment.