PATCH: Make pr16660-1.c generic
H.J. Lu
hjl.tools@gmail.com
Thu Jul 31 06:27:00 GMT 2008
On Wed, Jul 30, 2008 at 06:09:17PM -0700, Andrew Pinski wrote:
> On Wed, Jul 30, 2008 at 6:06 PM, H.J. Lu <hongjiu.lu@intel.com> wrote:
> > Hi,
> >
> > gcc.dg/torture/stackalign/pr16660-1.c is an ia32 specific test since
> > it uses inline asm. This patch moves it to gcc.target/i386. OK for
> > trunk?
>
> Why not make the test a generic test, testing the alignment of the
> memory instead of just testing that movaps works?
>
Good idea. Here is the updated patch. OK for trunk?
H.J.
---
2008-07-30 H.J. Lu <hongjiu.lu@intel.com>
* gcc.dg/torture/stackalign/pr16660-1.c: Include "check.h".
(f): Align to 64 byte. Use check instead of asm statement.
--- gcc/testsuite/gcc.dg/torture/stackalign/pr16660-1.c.align 2008-07-30 12:28:52.000000000 -0700
+++ gcc/testsuite/gcc.dg/torture/stackalign/pr16660-1.c 2008-07-30 18:19:34.000000000 -0700
@@ -1,10 +1,12 @@
/* { dg-do run } */
+#include "check.h"
+
void
f ()
{
- unsigned long tmp[4] __attribute__((aligned(16)));
- asm("movaps %%xmm0, (%0)" : : "r" (tmp) : "memory");
+ unsigned long tmp[4] __attribute__((aligned(64)));
+ check (&tmp, 64);
}
int
More information about the Gcc-patches
mailing list