This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[PATCH] Move testcase for pr45017.c
- From: Richard Guenther <rguenther at suse dot de>
- To: gcc-patches at gcc dot gnu dot org
- Date: Mon, 26 Jul 2010 11:14:22 +0200 (CEST)
- Subject: [PATCH] Move testcase for pr45017.c
No idea how to portably test bitfield endianess/order.
Committed.
Richard.
2010-07-26 Richard Guenther <rguenther@suse.de>
* gcc.c-torture/execute/pr45017.c: Move ...
* gcc.dg/torture/pr45017.c: ... here. Restrict to i?86 and x86_64.
Index: gcc/testsuite/gcc.c-torture/execute/pr45017.c
===================================================================
--- gcc/testsuite/gcc.c-torture/execute/pr45017.c (revision 162526)
+++ gcc/testsuite/gcc.c-torture/execute/pr45017.c (working copy)
@@ -1,22 +0,0 @@
-int tester(char *bytes)
-{
- union {
- struct {
- unsigned int r1:4;
- unsigned int r2:4;
- } fmt;
- char value[1];
- } ovl;
-
- ovl.value[0] = bytes[0];
- return ovl.fmt.r1;
-}
-extern void abort (void);
-int main()
-{
- char buff = 0x2f;
- if (tester(&buff) != 0x0f)
- abort ();
- return 0;
-}
-