On Fri, Jun 12, 2015 at 10:52:56AM +0200, Andreas Krebbel wrote: > Yes that's better. I've adjusted the testcase as you proposed and > have tested it on x86_64, ppc, and s390x with -m32(-m31) and -m64.
As I said earlier, talking just about the testcase, leaving review to Jason. > --- /dev/null > +++ b/gcc/testsuite/g++.dg/pr33661.C > @@ -0,0 +1,31 @@ > +/* PR c++/33661 */ > + > +/* { dg-do compile } */ > +/* { dg-options "-O1" } */ > +/* { dg-final { scan-assembler "reg: %r8" { target { { x86_64*-*-* i?86-*-* > } && lp64 } } } } */ > +/* { dg-final { scan-assembler "reg: %ecx" { target { { x86_64*-*-* i?86-*-* > } && ia32 } } } } */ > +/* { dg-final { scan-assembler "reg: 8" { target { powerpc*-*-* } } } } */ Looks mostly good, just wonder about the powerpc scan-assembler. Shouldn't that be "reg: (%r)?8" instead? I think powerpc has -mregnames option, dunno if some target doesn't even use it by default. Jakub