diff options
author | Kerry McLaughlin <kerry.mclaughlin@arm.com> | 2019-10-02 09:25:02 +0000 |
---|---|---|
committer | Kerry McLaughlin <kerry.mclaughlin@arm.com> | 2019-10-02 09:25:02 +0000 |
commit | 76365b3b24dce0ab3c6a4bce3f84f632b6f825e0 (patch) | |
tree | 6ab27e002af5353b3d43a021fbfd606cdb8d89c5 /llvm/utils/TableGen | |
parent | 442be727773408581f59041c77e5441ca021dedd (diff) | |
download | bcm5719-llvm-76365b3b24dce0ab3c6a4bce3f84f632b6f825e0.tar.gz bcm5719-llvm-76365b3b24dce0ab3c6a4bce3f84f632b6f825e0.zip |
[IntrinsicEmitter] Add overloaded type VecOfBitcastsToInt for SVE intrinsics
Summary:
This allows intrinsics such as the following to be defined:
- declare <n x 4 x i32> @llvm.something.nxv4f32(<n x 4 x i32>, <n x 4 x i1>, <n x 4 x float>)
...where <n x 4 x i32> is derived from <n x 4 x float>, but
the element needs bitcasting to int.
Reviewers: c-rhodes, sdesmalen, rovka
Reviewed By: c-rhodes
Subscribers: tschuett, hiraditya, jdoerfert, llvm-commits, cfe-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D68021
llvm-svn: 373437
Diffstat (limited to 'llvm/utils/TableGen')
-rw-r--r-- | llvm/utils/TableGen/IntrinsicEmitter.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/llvm/utils/TableGen/IntrinsicEmitter.cpp b/llvm/utils/TableGen/IntrinsicEmitter.cpp index 71ed579386c..e01f91c2045 100644 --- a/llvm/utils/TableGen/IntrinsicEmitter.cpp +++ b/llvm/utils/TableGen/IntrinsicEmitter.cpp @@ -223,7 +223,8 @@ enum IIT_Info { IIT_VEC_ELEMENT = 42, IIT_SCALABLE_VEC = 43, IIT_SUBDIVIDE2_ARG = 44, - IIT_SUBDIVIDE4_ARG = 45 + IIT_SUBDIVIDE4_ARG = 45, + IIT_VEC_OF_BITCASTS_TO_INT = 46 }; static void EncodeFixedValueType(MVT::SimpleValueType VT, @@ -299,6 +300,8 @@ static void EncodeFixedType(Record *R, std::vector<unsigned char> &ArgCodes, Sig.push_back(IIT_SUBDIVIDE2_ARG); else if (R->isSubClassOf("LLVMSubdivide4VectorType")) Sig.push_back(IIT_SUBDIVIDE4_ARG); + else if (R->isSubClassOf("LLVMVectorOfBitcastsToInt")) + Sig.push_back(IIT_VEC_OF_BITCASTS_TO_INT); else Sig.push_back(IIT_ARG); return Sig.push_back((Number << 3) | 7 /*IITDescriptor::AK_MatchType*/); |