The flag "-coverage-function-names-in-data" is actually backwards -- we do
emit function names in .gcda files by default, and the flag turns that off!
Rename the flag to make it match what it actually does. This keeps the default
format compatible with gcc 4.2.
Also add a test for this flag.
llvm-svn: 177475
diff --git a/clang/lib/CodeGen/BackendUtil.cpp b/clang/lib/CodeGen/BackendUtil.cpp
index 23d8b97..952d1fb 100644
--- a/clang/lib/CodeGen/BackendUtil.cpp
+++ b/clang/lib/CodeGen/BackendUtil.cpp
@@ -312,9 +312,8 @@
memcpy(Options.Version, CodeGenOpts.CoverageVersion, 4);
Options.UseCfgChecksum = CodeGenOpts.CoverageExtraChecksum;
Options.NoRedZone = CodeGenOpts.DisableRedZone;
- // FIXME: the clang flag name is backwards.
Options.FunctionNamesInData =
- !CodeGenOpts.CoverageFunctionNamesInData;
+ !CodeGenOpts.CoverageNoFunctionNamesInData;
MPM->add(createGCOVProfilerPass(Options));
if (CodeGenOpts.getDebugInfo() == CodeGenOptions::NoDebugInfo)
MPM->add(createStripSymbolsPass(true));