diff options
Diffstat (limited to 'gcc/testsuite')
-rw-r--r-- | gcc/testsuite/ChangeLog | 4 | ||||
-rw-r--r-- | gcc/testsuite/gnat.dg/vect7.adb | 20 | ||||
-rw-r--r-- | gcc/testsuite/gnat.dg/vect7.ads | 15 |
3 files changed, 39 insertions, 0 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 945e50795db..b16a490b58c 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,7 @@ +2012-03-28 Eric Botcazou <ebotcazou@adacore.com> + + * gnat.dg/vect7.ad[sb]: New test. + 2012-03-28 Paul Thomas <pault@gcc.gnu.org> Tobias Burnus <burnus@gcc.gnu.org> diff --git a/gcc/testsuite/gnat.dg/vect7.adb b/gcc/testsuite/gnat.dg/vect7.adb new file mode 100644 index 00000000000..7911cc812c6 --- /dev/null +++ b/gcc/testsuite/gnat.dg/vect7.adb @@ -0,0 +1,20 @@ +-- { dg-do compile } + +package body Vect7 is + + procedure Assign is + v1 : constant v4sf := (-1.0, -2.0, -3.0, -4.0); + v2 : v4sf := v1; + v3 : v4sf; + begin + v3 := vzero; + v3 := vconst; + v3 := v1; + v3 := v2; + v3 := (1.0, -2.0, 3.0, -4.0); + v3 := (1.0, -2.0, 3.0, F); + + v2 := vzero; + end; + +end Vect7; diff --git a/gcc/testsuite/gnat.dg/vect7.ads b/gcc/testsuite/gnat.dg/vect7.ads new file mode 100644 index 00000000000..faf01679e23 --- /dev/null +++ b/gcc/testsuite/gnat.dg/vect7.ads @@ -0,0 +1,15 @@ +package Vect7 is + + type v4sf is array (1 .. 4) of Float; + for v4sf'Alignment use 16; + pragma Machine_Attribute (v4sf, "vector_type"); + + vzero : constant v4sf := (0.0, 0.0, 0.0, 0.0); + vconst : constant v4sf := (1.0, 2.0, 3.0, 4.0); + vvar : v4sf := vconst; + + F : Float := 5.0; + + procedure Assign; + +end Vect7; |