aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
diff options
context:
space:
mode:
authorNikita Popov <nikita.ppv@gmail.com>2021-07-07 22:29:43 +0200
committerNikita Popov <nikita.ppv@gmail.com>2021-07-15 18:04:26 +0200
commitc191035f421b5dc69873cba8885fee41e984cc5d (patch)
treea005ea28a289f84bc40a272c5001a8cfae98e4d5 /llvm/lib/Bitcode/Reader/BitcodeReader.cpp
parent1fd23a065bf729836dd52ef1ad3c84c449735a56 (diff)
downloadllvm-c191035f421b5dc69873cba8885fee41e984cc5d.zip
llvm-c191035f421b5dc69873cba8885fee41e984cc5d.tar.gz
llvm-c191035f421b5dc69873cba8885fee41e984cc5d.tar.bz2
[IR] Add elementtype attribute
This implements the elementtype attribute specified in D105407. It just adds the attribute and the specified verifier rules, but doesn't yet make use of it anywhere. Differential Revision: https://reviews.llvm.org/D106008
Diffstat (limited to 'llvm/lib/Bitcode/Reader/BitcodeReader.cpp')
-rw-r--r--llvm/lib/Bitcode/Reader/BitcodeReader.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/llvm/lib/Bitcode/Reader/BitcodeReader.cpp b/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
index c9c1cef3..07db3c0 100644
--- a/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
+++ b/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
@@ -1385,6 +1385,8 @@ static Attribute::AttrKind getAttrFromCode(uint64_t Code) {
return Attribute::Cold;
case bitc::ATTR_KIND_CONVERGENT:
return Attribute::Convergent;
+ case bitc::ATTR_KIND_ELEMENTTYPE:
+ return Attribute::ElementType;
case bitc::ATTR_KIND_INACCESSIBLEMEM_ONLY:
return Attribute::InaccessibleMemOnly;
case bitc::ATTR_KIND_INACCESSIBLEMEM_OR_ARGMEMONLY: