annotate clang/test/Sema/big-endian-neon-initializers.c @ 222:81f6424ef0e3 llvm-original

LLVM original branch
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Sun, 18 Jul 2021 22:10:01 +0900 (2021-07-18)
parents 1d019706d866
children c4bab56944e8
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
150
anatofuz
parents:
diff changeset
1 // RUN: %clang_cc1 %s -triple aarch64_be -target-feature +neon -verify -fsyntax-only -ffreestanding
anatofuz
parents:
diff changeset
2 // RUN: %clang_cc1 %s -triple armebv7 -target-cpu cortex-a8 -verify -fsyntax-only -ffreestanding
anatofuz
parents:
diff changeset
3
anatofuz
parents:
diff changeset
4 #include <arm_neon.h>
anatofuz
parents:
diff changeset
5
anatofuz
parents:
diff changeset
6 int32x4_t x = {1, 2, 3, 4}; // expected-warning{{vector initializers are not compatible with NEON intrinsics}} expected-note{{consider using vld1q_s32() to initialize a vector from memory, or vcombine_s32(vcreate_s32(), vcreate_s32()) to initialize from integer constants}}
anatofuz
parents:
diff changeset
7 int16x4_t y = {1, 2, 3, 4}; // expected-warning{{vector initializers are not compatible with NEON intrinsics}} expected-note{{consider using vld1_s16() to initialize a vector from memory, or vcreate_s16() to initialize from an integer constant}}
anatofuz
parents:
diff changeset
8 int64x2_t z = {1, 2}; // expected-warning{{vector initializers are not compatible with NEON intrinsics}} expected-note{{consider using vld1q_s64() to initialize a vector from memory, or vcombine_s64(vcreate_s64(), vcreate_s64()) to initialize from integer constants}}
anatofuz
parents:
diff changeset
9 float32x2_t b = {1, 2}; // expected-warning{{vector initializers are not compatible with NEON intrinsics}} expected-note{{consider using vld1_f32() to initialize a vector from memory, or vcreate_f32() to initialize from an integer constant}}
anatofuz
parents:
diff changeset
10
anatofuz
parents:
diff changeset
11 // No warning expected here.
anatofuz
parents:
diff changeset
12 typedef int v4si __attribute__ ((vector_size (16)));
anatofuz
parents:
diff changeset
13 v4si c = {1, 2, 3, 4};