bug in new ia32 backend
Mike Stump
mrs@wrs.com
Thu Jun 24 16:14:00 GMT 1999
I have completed a full (gcc/g++/g77/objc/libio/libstdc++) testsuite
run (linux native), and only found one problem...
Merge droppage:
FAIL: gcc.dg/990424-1.c (test for excess errors)
caused by (i386.h):
! { "preferred-stack-boundary=", &i386_preferred_stack_boundary_string, "Attem
pt to keep stack aligned to this power of 2" }, \
! { "branch-cost=", &i386_branch_cost_string, "Branches are this expensive (
1-5, arbitrary units)" }, \
in pass0. This wasn't in any of the raw patches, so this was a
clobber of new work, bad. I'll see about auditing the raw files with
the pass0 file, and see what else I can come up with. I was using the
first set of patches, and a very recent snapshot with fixes previously
described and an older loop.c with one seemingly related bug fix.
I see the branch is done, so I will switch over to it.
For completeness, below you will find what I tested with.
Doing diffs in .:
*** ./gcc/reg-stack.c.~1~ Fri Jun 18 15:03:49 1999
--- ./gcc/reg-stack.c Fri Jun 18 16:38:40 1999
*************** stack_regs_mentioned (pat)
*** 374,379 ****
--- 374,382 ----
register char *fmt;
register int i;
+ if (pat == 0)
+ return 0;
+
if (STACK_REG_P (pat))
return 1;
*** ./gcc/unroll.c.~1~ Fri Jun 18 15:03:49 1999
--- ./gcc/unroll.c Tue Jun 22 18:51:14 1999
*************** loop_iterations (loop_start, loop_end, l
*** 3669,3675 ****
/* If there is a more than a single jump to the top of the loop
we cannot (easily) determine the iteration count. */
! if (LABEL_NUSES (JUMP_LABEL (last_loop_insn)) > 1)
{
if (loop_dump_stream)
fprintf (loop_dump_stream,
--- 3669,3676 ----
/* If there is a more than a single jump to the top of the loop
we cannot (easily) determine the iteration count. */
! if (JUMP_LABEL (last_loop_insn) == 0
! || LABEL_NUSES (JUMP_LABEL (last_loop_insn)) > 1)
{
if (loop_dump_stream)
fprintf (loop_dump_stream,
*** ./gcc/resource.c.~1~ Fri Jun 18 15:03:49 1999
--- ./gcc/resource.c Tue Jun 22 14:28:14 1999
*************** find_free_register (current_insn, class_
*** 1263,1276 ****
for (i = 0; i < FIRST_PSEUDO_REGISTER; i++)
{
! int success = 1;
! if (! TEST_HARD_REG_BIT (reg_class_contents[class], i))
! continue;
! for (j = HARD_REGNO_NREGS (i, mode) - 1; j >= 0; j--)
{
! if (TEST_HARD_REG_BIT (*reg_set, i + j)
! || TEST_HARD_REG_BIT (used.regs, i + j))
{
success = 0;
break;
--- 1263,1295 ----
for (i = 0; i < FIRST_PSEUDO_REGISTER; i++)
{
! int regno;
! int success;
! #ifdef REG_ALLOC_ORDER
! regno = reg_alloc_order [i];
! #else
! regno = i;
! #endif
!
! /* Don't allocate fixed registers. */
! if (fixed_regs[regno])
! continue;
! /* Make sure the register is of the right class. */
! if (! TEST_HARD_REG_BIT (reg_class_contents[class], regno))
! continue;
! /* And can support the mode we need. */
! if (! HARD_REGNO_MODE_OK (regno, mode))
! continue;
! /* And that we don't create an extra save/restore. */
! if (! call_used_regs[regno] && ! regs_ever_live[regno])
! continue;
!
! success = 1;
! for (j = HARD_REGNO_NREGS (regno, mode) - 1; j >= 0; j--)
{
! if (TEST_HARD_REG_BIT (*reg_set, regno + j)
! || TEST_HARD_REG_BIT (used.regs, regno + j))
{
success = 0;
break;
*************** find_free_register (current_insn, class_
*** 1278,1288 ****
}
if (success)
{
! for (j = HARD_REGNO_NREGS (i, mode) - 1; j >= 0; j--)
{
! SET_HARD_REG_BIT (*reg_set, i + j);
}
! return gen_rtx_REG (mode, i);
}
}
return NULL_RTX;
--- 1297,1307 ----
}
if (success)
{
! for (j = HARD_REGNO_NREGS (regno, mode) - 1; j >= 0; j--)
{
! SET_HARD_REG_BIT (*reg_set, regno + j);
}
! return gen_rtx_REG (mode, regno);
}
}
return NULL_RTX;
*** ./gcc/loop.c.~1~ Fri Jun 18 15:03:47 1999
--- ./gcc/loop.c Wed Jun 23 18:49:35 1999
*************** combine_givs_p (g1, g2)
*** 6976,6982 ****
return NULL_RTX;
ret = comb = express_from (g1, g2);
! if (g1->mode != g2->mode)
ret = gen_lowpart (g2->mode, comb);
/* If these givs are identical, they can be combined. We use the results
--- 6976,6982 ----
return NULL_RTX;
ret = comb = express_from (g1, g2);
! if (ret && g1->mode != g2->mode)
ret = gen_lowpart (g2->mode, comb);
/* If these givs are identical, they can be combined. We use the results
--------------
More information about the Gcc-bugs
mailing list