[PATCH] D33732: Catch invalid bitwise operation on vector of floats

Serge Pavlov via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Sun Jun 4 11:32:15 PDT 2017


sepavloff added inline comments.


================
Comment at: test/Sema/types.c:92
+
+typedef float __attribute__((ext_vector_type(4)))  float4;
+float4 test3(float4 x) {
----------------
bruno wrote:
> Can you also add a test for the `vector_type` variant? It might be more appropriate to put this at test/Sema/ext_vector* and test/Sema/vector*
The test for the `vector_type` variant already exists in `test/Sema/vector-ops.c`. I tried to made similar test file for `ext_vector_type` by copying vector-ops.c and replacing vector types accordingly, but there are many differences in diagnostic, so only the part that checks the complement operation was copied.


https://reviews.llvm.org/D33732





More information about the cfe-commits mailing list