llvm-project/clang/test
Cullen Rhodes 89e61e782b [Sema][AArch64] Add semantics for arm_sve_vector_bits attribute
Summary:
This patch implements semantics for the 'arm_sve_vector_bits' type
attribute, defined by the Arm C Language Extensions (ACLE) for SVE [1].
The purpose of this attribute is to define fixed-length (VLST) versions
of existing sizeless types (VLAT).

Implemented in this patch is the the behaviour described in section 3.7.3.2
and minimal parts of sections 3.7.3.3 and 3.7.3.4, this includes:

    * Defining VLST globals, structs, unions, and local variables
    * Implicit casting between VLAT <=> VLST.
    * Diagnosis of ill-formed conditional expressions of the form:

        C ?  E1 : E2

      where E1 is a VLAT type and E2 is a VLST, or vice-versa. This
      avoids any ambiguity about the nature of the result type (i.e is
      it sized or sizeless).
    * For vectors:
        * sizeof(VLST) == N/8
        * alignof(VLST) == 16
    * For predicates:
        * sizeof(VLST) == N/64
        * alignof(VLST) == 2

VLSTs have the same representation as VLATs in the AST but are wrapped
with a TypeAttribute. Scalable types are currently emitted in the IR for
uses such as globals and structs which don't support these types, this
is addressed in the next patch with codegen, where VLSTs are lowered to
sized arrays for globals, structs / unions and arrays.

Not implemented in this patch is the behaviour guarded by the feature
macros:

    * __ARM_FEATURE_SVE_VECTOR_OPERATORS
    * __ARM_FEATURE_SVE_PREDICATE_OPERATORS

As such, the GNU __attribute__((vector_size)) extension is not available
and operators such as binary '+' are not supported for VLSTs. Support
for this is intended to be addressed by later patches.

[1] https://developer.arm.com/documentation/100987/latest

This is patch 2/4 of a patch series.

Reviewers: sdesmalen, rsandifo-arm, efriedma, cameron.mcinally, ctetreau, rengolin, aaron.ballman

Reviewed By: aaron.ballman

Differential Revision: https://reviews.llvm.org/D83551
2020-07-22 16:26:23 +00:00
..
ARCMT
AST [AST][RecoveryExpr] Error-dependent expression should not be treat as a nullptr pointer constant. 2020-07-22 10:03:51 +02:00
ASTMerge
Analysis [analyzer][solver] Track symbol disequalities 2020-07-22 13:02:39 +03:00
CXX [clang][NFC] Tests showing the problems with some uses of NamedDecl::getDeclName in diagnostics, SemaOverload.cpp+SemaStmt.cpp part 2020-07-18 20:44:06 +01:00
ClangScanDeps
CodeCompletion [CodeComplete] Add code completion after function equals 2020-07-01 12:51:25 +08:00
CodeGen Fix target specific InstCombine 2020-07-22 17:00:46 +02:00
CodeGenCUDA [CUDA][HIP] Let lambda be host device by default 2020-07-08 13:10:26 -04:00
CodeGenCXX [AIX] report_fatal_error on `-fregister_global_dtors_with_atexit` for static init 2020-07-17 16:14:49 -04:00
CodeGenCoroutines [Coroutines] Ensure co_await promise.final_suspend() does not throw 2020-06-22 15:01:42 -07:00
CodeGenHIP [NFC] Fixed ignored .hip test. 2020-06-29 18:57:14 +03:00
CodeGenObjC Re-enable "[InstCombine] Simplify boolean Phis with const inputs using CFG" 2020-07-16 16:09:08 +07:00
CodeGenObjCXX Re-enable "[InstCombine] Simplify boolean Phis with const inputs using CFG" 2020-07-16 16:09:08 +07:00
CodeGenOpenCL [SimplifyCFG] Do not create unneeded PR Phi in block with convergent calls 2020-07-22 13:53:50 +07:00
CodeGenOpenCLCXX [CGCall] Annotate references with "align" attribute. 2020-05-19 20:21:30 -07:00
CodeGenSYCL
Coverage
CoverageMapping Revert abd45154b "[Coverage] Add comment to skipped regions" 2020-07-22 17:09:20 +02:00
Driver add -fpch-codegen/debuginfo mapping to -fmodules-codegen/debuginfo 2020-07-22 10:21:53 +02:00
FixIt
Format
Frontend [clang] Teach -fembed-bitcode option not to embed W_value Group 2020-07-14 14:40:43 -07:00
Headers [OpenMP][CUDA] Fix std::complex in GPU regions 2020-07-11 00:40:05 -05:00
Import [clang] Rework how and when APValues are dumped 2020-07-06 22:03:08 +01:00
Index [libclang] Fix crash when visiting a captured VLA 2020-07-08 13:10:16 -07:00
Integration
InterfaceStubs [llvm-readobj] Update tests because of changes in llvm-readobj behavior 2020-07-20 10:39:04 +01:00
Layout
Lexer [clang][slh] Add test for SLH feature checking macro 2020-05-15 12:23:31 -07:00
Misc [Driver] Add --ld-path= and deprecate -fuse-ld=/abs/path and -fuse-ld=rel/path 2020-07-20 09:34:39 -07:00
Modules make -fmodules-codegen and -fmodules-debuginfo work also with PCHs 2020-07-09 15:22:26 +02:00
OpenMP [OpenMP] Implement TR8 `present` map type modifier in Clang (1/2) 2020-07-22 10:15:32 -04:00
PCH accept 'clang++ -c a.pch -o a.o' to create PCH's object file 2020-07-22 10:21:23 +02:00
Parser [clang] Provide a more specific diagnostic for a misplaced lambda capture-default. 2020-07-18 20:35:16 +01:00
ParserSYCL
Preprocessor [Sema][AArch64] Add parsing support for arm_sve_vector_bits attribute 2020-07-17 10:06:54 +00:00
Profile Fix version of c-general.profdata.v5 test case 2020-06-10 16:20:20 +02:00
Refactor
Rewriter
Sema [Sema][AArch64] Add semantics for arm_sve_vector_bits attribute 2020-07-22 16:26:23 +00:00
SemaCUDA recommit 4fc752b30b [CUDA][HIP] Always defer diagnostics for wrong-sided reference 2020-07-17 09:14:39 -04:00
SemaCXX [AST][RecoveryExpr] Preserve the invalid "undef_var" initializer. 2020-07-21 09:38:09 +02:00
SemaObjC [clang][NFC] Tests showing the problems with some uses of NamedDecl::getDeclName in diagnostics, SemaOverload.cpp+SemaStmt.cpp part 2020-07-18 20:44:06 +01:00
SemaObjCXX Clang crashed while checking for deletion of copy and move ctors 2020-07-07 14:40:37 -04:00
SemaOpenCL [AST][RecoveryExpr] Fix a crash on opencl C++. 2020-07-20 15:15:30 +02:00
SemaOpenCLCXX [OpenCL] Defer addr space deduction for dependent type. 2020-07-13 11:44:38 +01:00
SemaSYCL [SYCL][OpenMP] Implement thread-local storage restriction 2020-06-17 14:36:00 +03:00
SemaTemplate [AST][RecoveryExpr] Preserve the AST for invalid conditions. 2020-07-20 14:58:36 +02:00
TableGen
Templight
Tooling [clang] Rework how and when APValues are dumped 2020-07-06 22:03:08 +01:00
Unit
VFS
clang-rename
utils/update_cc_test_checks [Utils][Fix] remove unnecessary ; at the end 2020-07-19 20:48:28 +02:00
.clang-format [clang] Partially revert "Disable a few formatting options for test/" 2020-07-21 14:53:37 +01:00
CMakeLists.txt Revert "[CMake] Simplify CMake handling for zlib" 2020-07-14 19:56:10 -07:00
TestRunner.sh
cxx-sections.data
lit.cfg.py Revert abd45154b "[Coverage] Add comment to skipped regions" 2020-07-22 17:09:20 +02:00
lit.site.cfg.py.in Revert "[CMake] Simplify CMake handling for zlib" 2020-07-14 19:56:10 -07:00
make_test_dirs.pl