summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Analysis
diff options
context:
space:
mode:
authorAdam Nemet <anemet@apple.com>2016-11-10 17:47:03 +0000
committerAdam Nemet <anemet@apple.com>2016-11-10 17:47:03 +0000
commit7da20c39ee1b80838e036fc1c586e3806c9fe9b9 (patch)
treec32fea13e2b32b4080fc237b9689a331d7fb9a07 /llvm/lib/Analysis
parentd67af68f06383c1fe2bab980f47768f39e77f03b (diff)
downloadbcm5719-llvm-7da20c39ee1b80838e036fc1c586e3806c9fe9b9.tar.gz
bcm5719-llvm-7da20c39ee1b80838e036fc1c586e3806c9fe9b9.zip
[OptDiag] Remove non-printable chars from function name
The r283656 did this in the remark arguments. We also need to do this in the main function attribute as that is written to YAML as well. llvm-svn: 286482
Diffstat (limited to 'llvm/lib/Analysis')
-rw-r--r--llvm/lib/Analysis/OptimizationDiagnosticInfo.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/Analysis/OptimizationDiagnosticInfo.cpp b/llvm/lib/Analysis/OptimizationDiagnosticInfo.cpp
index 0a5ef1b9b23..da1173b283f 100644
--- a/llvm/lib/Analysis/OptimizationDiagnosticInfo.cpp
+++ b/llvm/lib/Analysis/OptimizationDiagnosticInfo.cpp
@@ -80,7 +80,8 @@ template <> struct MappingTraits<DiagnosticInfoOptimizationBase *> {
// These are read-only for now.
DebugLoc DL = OptDiag->getDebugLoc();
- StringRef FN = OptDiag->getFunction().getName();
+ StringRef FN = GlobalValue::getRealLinkageName(
+ OptDiag->getFunction().getName());
StringRef PassName(OptDiag->PassName);
io.mapRequired("Pass", PassName);
OpenPOWER on IntegriCloud