From: jakub Date: Sat, 2 Feb 2002 09:22:00 +0000 (+0000) Subject: * gcc.dg/20020201-3.c: New test. X-Git-Tag: upstream/4.9.2~88952 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=2836a99359fd5738c18fb947361e066b0aba9249;p=platform%2Fupstream%2Flinaro-gcc.git * gcc.dg/20020201-3.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@49437 138bc75d-0d04-0410-961f-82ee72b054a4 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index c58eb79..13dd94e 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -2,6 +2,8 @@ * gcc.dg/20020201-2.c: New test. + * gcc.dg/20020201-3.c: New test. + 2002-02-02 Neil Booth * gcc.dg/bitfld-1.c: Update. diff --git a/gcc/testsuite/gcc.dg/20020201-3.c b/gcc/testsuite/gcc.dg/20020201-3.c new file mode 100644 index 0000000..67e9a8a --- /dev/null +++ b/gcc/testsuite/gcc.dg/20020201-3.c @@ -0,0 +1,15 @@ +/* This testcase ICEd because a SFmode variable was given a MMX register + for which there is no movsf exists. */ +/* { dg-do compile { target i?86-*-* } } */ +/* { dg-options "-O2 -march=i686 -mmmx -fno-strict-aliasing" } */ + +struct A { unsigned int a, b; }; + +void foo (struct A *x, int y, int z) +{ + const float d = 1.0; + float e = (float) y + z; + + x->a = *(unsigned int *) &d; + x->b = *(unsigned int *) &e; +}