summaryrefslogtreecommitdiffstats
path: root/llvm/tools/llvm-bcanalyzer
diff options
context:
space:
mode:
authorDuncan P. N. Exon Smith <dexonsmith@apple.com>2014-12-11 23:02:24 +0000
committerDuncan P. N. Exon Smith <dexonsmith@apple.com>2014-12-11 23:02:24 +0000
commit5c7006e06283a61b26783a8141936466ad3dd3c7 (patch)
tree53ee96f7df23bd560147b7b6c3ab955d20c54b6a /llvm/tools/llvm-bcanalyzer
parentc9e266b8cf4abd43167b70609df6039da3ecd9b4 (diff)
downloadbcm5719-llvm-5c7006e06283a61b26783a8141936466ad3dd3c7.tar.gz
bcm5719-llvm-5c7006e06283a61b26783a8141936466ad3dd3c7.zip
Bitcode: Add METADATA_NODE and METADATA_VALUE
This reflects the typelessness of `Metadata` in the bitcode format, removing types from all metadata operands. `METADATA_VALUE` represents a `ValueAsMetadata`, and always has two fields: the type and the value. `METADATA_NODE` represents an `MDNode`, and unlike `METADATA_OLD_NODE`, doesn't store types. It stores operands at their ID+1 so that `0` can reference `nullptr` operands. Part of PR21532. llvm-svn: 224073
Diffstat (limited to 'llvm/tools/llvm-bcanalyzer')
-rw-r--r--llvm/tools/llvm-bcanalyzer/llvm-bcanalyzer.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/llvm/tools/llvm-bcanalyzer/llvm-bcanalyzer.cpp b/llvm/tools/llvm-bcanalyzer/llvm-bcanalyzer.cpp
index a18665964bc..69880a425a1 100644
--- a/llvm/tools/llvm-bcanalyzer/llvm-bcanalyzer.cpp
+++ b/llvm/tools/llvm-bcanalyzer/llvm-bcanalyzer.cpp
@@ -266,6 +266,8 @@ static const char *GetCodeName(unsigned CodeID, unsigned BlockID,
case bitc::METADATA_STRING: return "METADATA_STRING";
case bitc::METADATA_NAME: return "METADATA_NAME";
case bitc::METADATA_KIND: return "METADATA_KIND";
+ case bitc::METADATA_NODE: return "METADATA_NODE";
+ case bitc::METADATA_VALUE: return "METADATA_VALUE";
case bitc::METADATA_OLD_NODE: return "METADATA_OLD_NODE";
case bitc::METADATA_OLD_FN_NODE: return "METADATA_OLD_FN_NODE";
case bitc::METADATA_NAMED_NODE: return "METADATA_NAMED_NODE";
OpenPOWER on IntegriCloud