This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Fix PR rtl-optimization/67736 in combine.c
- From: Steve Ellcey <sellcey at imgtec dot com>
- To: Segher Boessenkool <segher at kernel dot crashing dot org>
- Cc: <gcc-patches at gcc dot gnu dot org>
- Date: Thu, 22 Oct 2015 12:29:34 -0700
- Subject: Re: [PATCH] Fix PR rtl-optimization/67736 in combine.c
- Authentication-results: sourceware.org; auth=none
- References: <5bc76c2f-4488-4e0b-8f20-aaa51e1b013b at BAMAIL02 dot ba dot imgtec dot org> <20151022184623 dot GA11172 at gate dot crashing dot org>
- Reply-to: <sellcey at imgtec dot com>
On Thu, 2015-10-22 at 13:46 -0500, Segher Boessenkool wrote:
> One nit and maybe a problem:
>
> > --- a/gcc/testsuite/gcc.dg/combine-subregs.c
> > +++ b/gcc/testsuite/gcc.dg/combine-subregs.c
> > @@ -0,0 +1,36 @@
> > +/* { dg-do run } */
> > +/* { dg-options "-O2 -fexpensive-optimizations" } */
>
> -fexpensive-optimizations is default at -O2.
You are right, the original report I got mentioned this flag and then I
was comparing -fexpensive-optimization and -fno-expensive-optimization
so I didn't notice that it was on by default. I will remove it from the
test.
> > +
> > +#include <inttypes.h>
>
> Does every target have that header? Shouldn't it be <stdint.h>?
>
> > --- a/gcc/testsuite/gcc.dg/torture/pr67736.c
> > +++ b/gcc/testsuite/gcc.dg/torture/pr67736.c
> > @@ -0,0 +1,32 @@
> > +/* { dg-do run } */
> > +
> > +#include <stdlib.h>
> > +
>
> And here you don't need inttypes at all? Confused.
>
>
> Segher
Not including the include in pr67736.c was an oversight, I meant to
include it. I didn't notice that Andrew had put in his own definition
of uint64_t into this test so it didn't need any includes, that is why
it still worked. But you are right I should be using stdint.h instead
of inttypes.h. It looks like most tests have:
/* { dg-do run { target { stdint_types } } } */
#include <stdint.h>
So I will use that in both tests and remove the local definition of
uint64_t from pr67736.c.
Steve Ellcey
sellcey@imgtec.com