OSDN Git Service

* gcc.dg/20030218-1.c: New.
authoraldyh <aldyh@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 19 Feb 2003 04:30:10 +0000 (04:30 +0000)
committeraldyh <aldyh@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 19 Feb 2003 04:30:10 +0000 (04:30 +0000)
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@63089 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/20030218-1.c [new file with mode: 0644]

index 4c7b8b3..d38552d 100644 (file)
@@ -1,3 +1,7 @@
+2003-02-18  Aldy Hernandez  <aldyh@redhat.com>
+
+        * gcc.dg/20030218-1.c: New.
+
 2003-02-18  Richard Henderson  <rth@redhat.com>
 
        * gcc.dg/attr-invalid.c: Allow __used__ on static data.
diff --git a/gcc/testsuite/gcc.dg/20030218-1.c b/gcc/testsuite/gcc.dg/20030218-1.c
new file mode 100644 (file)
index 0000000..d584461
--- /dev/null
@@ -0,0 +1,16 @@
+/* { dg-do compile { target powerpc-*-eabi* } } */
+/* { dg-options "-mcpu=8540" } */
+
+/* Test vectors that can interconvert without a cast.  */
+
+int vint __attribute__((mode(V2SI)));
+int vshort __attribute__((mode(V4HI)));
+int vfloat __attribute__((mode(V2SF)));
+
+int
+main (void)
+{
+  vint = vfloat;
+  vshort = vint;
+  vfloat = vshort; /* { dg-error "incompatible types in assignment" } */
+}