summaryrefslogtreecommitdiffstats
path: root/llvm/lib/DebugInfo/CodeView/CodeViewRecordIO.cpp
diff options
context:
space:
mode:
authorNilanjana Basu <nilanjana.basu87@gmail.com>2019-08-01 22:05:14 +0000
committerNilanjana Basu <nilanjana.basu87@gmail.com>2019-08-01 22:05:14 +0000
commitac7e5788ca03dac225fd92ac937593454bd36d21 (patch)
tree700c62b68f7e9274e3ac622635b2c5809088e941 /llvm/lib/DebugInfo/CodeView/CodeViewRecordIO.cpp
parente86fffcd4489f4862a514a0fd85276b968313739 (diff)
downloadbcm5719-llvm-ac7e5788ca03dac225fd92ac937593454bd36d21.tar.gz
bcm5719-llvm-ac7e5788ca03dac225fd92ac937593454bd36d21.zip
Changes to improve CodeView debug info type record inline comments
Signed-off-by: Nilanjana Basu <nilanjana.basu87@gmail.com> llvm-svn: 367623
Diffstat (limited to 'llvm/lib/DebugInfo/CodeView/CodeViewRecordIO.cpp')
-rw-r--r--llvm/lib/DebugInfo/CodeView/CodeViewRecordIO.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/llvm/lib/DebugInfo/CodeView/CodeViewRecordIO.cpp b/llvm/lib/DebugInfo/CodeView/CodeViewRecordIO.cpp
index 092099bb0a1..73ff57b9bbd 100644
--- a/llvm/lib/DebugInfo/CodeView/CodeViewRecordIO.cpp
+++ b/llvm/lib/DebugInfo/CodeView/CodeViewRecordIO.cpp
@@ -126,7 +126,11 @@ Error CodeViewRecordIO::mapByteVectorTail(std::vector<uint8_t> &Bytes,
Error CodeViewRecordIO::mapInteger(TypeIndex &TypeInd, const Twine &Comment) {
if (isStreaming()) {
- emitComment(Comment);
+ StringRef TypeNameStr = Streamer->getTypeName(TypeInd);
+ if (!TypeNameStr.empty())
+ emitComment(Comment + ": " + TypeNameStr);
+ else
+ emitComment(Comment);
Streamer->EmitIntValue(TypeInd.getIndex(), sizeof(TypeInd.getIndex()));
incrStreamedLen(sizeof(TypeInd.getIndex()));
} else if (isWriting()) {
OpenPOWER on IntegriCloud