This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Fix gcc.dg/smod-1.c on x86-64


On Tue, Oct 19, 2004 at 03:51:18PM -0700, Janis Johnson wrote:
> > You could also do -m32 -mtune=i486 for x86_64 like the other testcases
> > do.
> 
> Some of us at IBM have been wondering how to handle tests for
> powerpc64-unknown-linux-gnu that either are relevant for only 32-bit or
> 64-bit code generation, or that need xfail for one but not the other.
> The problem is complicated by the fact that we normally test a biarch
> compiler by running the entire test suite with -m32 and again with -m64,
> and there's no way to known whether GCC for target powerpc64-*-linux*
> generates only 64-bit code, defaults to 64-bit code, or defaults to
> 32-bit code.  I suspect that the same is true for x86_64-*-*.
> 
> It doesn't seem like a good idea to explicitly add '-m32' to a test
> that might already be run with both -m32 and -m64.

One possibility would be to tweak the target triplet depending on
the CFLAGS used (and the multilib default) inside of the testsuite,
another would be to introduce effective-target (or something similar)
while preserving current target meaning.
So, if CFLAGS include -m64 on powerpc64-redhat-linux (or -m64 is the
default), { dg-do compile { effective-target powerpc64-redhat-linux } }
would be run, if CFLAGS include -m32 on powerpc64-redhat-linux, -m32
is the default or on powerpc-redhat-linux,
{ dg-do compile { effective-target powerpc-redhat-linux } } would be run.

	Jakub


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]