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: [RFA][PATCH][PR middle-end/59743] Fix ree improvement when defining insn is after use insn


On Fri, Jan 10, 2014 at 02:58:59PM -0700, Jeff Law wrote:
> +2014-01-10  Jeff Law  <law@redhat.com>
> +
> +	PR middle-end/59743
> +	* ree.c (combine_reaching_defs): Ensure the defining statement
> +	occurs before the extension when optimizing extensions with
> +	different source and destination hard registers.

> --- /dev/null
> +++ b/gcc/testsuite/gcc.c-torture/compile/pr59743.c
> @@ -0,0 +1,22 @@

Please add a

/* PR middle-end/59743 */

comment here.

Ok with that change, thanks.
> +
> +typedef union {
> +  long all;
> +  struct {
> +    int low;
> +    int high;
> +  } s;
> +} udwords;
> +int a, b, c, d;
> +void __udivmoddi4() {
> +  udwords r;
> +  d = __builtin_clz(0);
> +  r.s.low = 0;
> +  for (; d; --d) {
> +    r.s.high = r.s.high << 1 | r.s.low >> a;
> +    r.s.low = r.s.low << b >> 1;
> +    int s = -r.all;
> +    c = s;
> +    r.all--;
> +  }
> +}
> +

	Jakub


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