[PATCH] D86900: [BitCodeAnalyzer] Add a few missing TYPE_CODES and MODULE_CODE_COMDAT to GetCodeName
Craig Topper via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 31 17:08:47 PDT 2020
craig.topper created this revision.
craig.topper added reviewers: thegameg, tejohnson, jfb, arsenm.
Herald added subscribers: ASDenysPetrov, dkrupp, donat.nagy, Szelethus, dexonsmith, a.sidorin, baloghadamsoftware, hiraditya.
Herald added a project: LLVM.
craig.topper requested review of this revision.
Herald added a subscriber: wdng.
Happened to notice some of these printing as UnknownCode while running llvm-bcanalyzer on a bc file I had.
Not sure how we usually test these.
https://reviews.llvm.org/D86900
Files:
llvm/lib/Bitcode/Reader/BitcodeAnalyzer.cpp
Index: llvm/lib/Bitcode/Reader/BitcodeAnalyzer.cpp
===================================================================
--- llvm/lib/Bitcode/Reader/BitcodeAnalyzer.cpp
+++ llvm/lib/Bitcode/Reader/BitcodeAnalyzer.cpp
@@ -135,6 +135,7 @@
STRINGIFY_CODE(MODULE_CODE, FUNCTION)
STRINGIFY_CODE(MODULE_CODE, ALIAS)
STRINGIFY_CODE(MODULE_CODE, GCNAME)
+ STRINGIFY_CODE(MODULE_CODE, COMDAT)
STRINGIFY_CODE(MODULE_CODE, VSTOFFSET)
STRINGIFY_CODE(MODULE_CODE, METADATA_VALUES_UNUSED)
STRINGIFY_CODE(MODULE_CODE, SOURCE_FILENAME)
@@ -176,16 +177,20 @@
STRINGIFY_CODE(TYPE_CODE, OPAQUE)
STRINGIFY_CODE(TYPE_CODE, INTEGER)
STRINGIFY_CODE(TYPE_CODE, POINTER)
+ STRINGIFY_CODE(TYPE_CODE, HALF)
STRINGIFY_CODE(TYPE_CODE, ARRAY)
STRINGIFY_CODE(TYPE_CODE, VECTOR)
STRINGIFY_CODE(TYPE_CODE, X86_FP80)
STRINGIFY_CODE(TYPE_CODE, FP128)
STRINGIFY_CODE(TYPE_CODE, PPC_FP128)
STRINGIFY_CODE(TYPE_CODE, METADATA)
+ STRINGIFY_CODE(TYPE_CODE, X86_MMX)
STRINGIFY_CODE(TYPE_CODE, STRUCT_ANON)
STRINGIFY_CODE(TYPE_CODE, STRUCT_NAME)
STRINGIFY_CODE(TYPE_CODE, STRUCT_NAMED)
STRINGIFY_CODE(TYPE_CODE, FUNCTION)
+ STRINGIFY_CODE(TYPE_CODE, TOKEN)
+ STRINGIFY_CODE(TYPE_CODE, BFLOAT)
}
case bitc::CONSTANTS_BLOCK_ID:
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D86900.289048.patch
Type: text/x-patch
Size: 1350 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200901/96ebcf2c/attachment.bin>
More information about the llvm-commits
mailing list