[PATCH] D81083: [Clang] Allow "vector_size" applied to Booleans
Simon Moll via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Jun 3 04:53:59 PDT 2020
simoll created this revision.
simoll added reviewers: hfinkel, erichkeane, craig.topper, rsandifo-arm, kaz7, k-ishizaka.
simoll added a project: clang.
Herald added subscribers: cfe-commits, kristof.beyls.
Herald added a reviewer: rengolin.
simoll updated this revision to Diff 268140.
simoll added a comment.
NFC. Undid stray change.
This patch extends Clang to allow 'bool' as a valid vector element type (attribute `vector_size`).
This is the natural type for SIMD masks and facilitates clean vector intrinsic declarations.
Vectors of i1 are supported on IR level and below down to many SIMD ISAs, such as AVX512, ARM SVE (fixed vector length) and the VE target (NEC SX-Aurora TSUBASA).
The RFC on cfe-dev: https://lists.llvm.org/pipermail/cfe-dev/2020-May/065434.html
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D81083
Files:
clang/docs/LanguageExtensions.rst
clang/include/clang/AST/ASTContext.h
clang/include/clang/Sema/Sema.h
clang/lib/AST/ASTContext.cpp
clang/lib/AST/TypePrinter.cpp
clang/lib/CodeGen/CGExpr.cpp
clang/lib/CodeGen/CGExprScalar.cpp
clang/lib/CodeGen/CGRecordLayoutBuilder.cpp
clang/lib/CodeGen/CodeGenFunction.cpp
clang/lib/CodeGen/CodeGenFunction.h
clang/lib/CodeGen/CodeGenTypes.cpp
clang/lib/Sema/SemaExpr.cpp
clang/lib/Sema/SemaExprCXX.cpp
clang/lib/Sema/SemaType.cpp
clang/test/SemaCXX/vector.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D81083.268140.patch
Type: text/x-patch
Size: 35099 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20200603/692a1b60/attachment-0001.bin>
More information about the cfe-commits
mailing list