* [lra] patch to fix listdc++ build failure on ppc64
@ 2011-08-04 22:00 Vladimir Makarov
0 siblings, 0 replies; only message in thread
From: Vladimir Makarov @ 2011-08-04 22:00 UTC (permalink / raw)
To: gcc-patches
[-- Attachment #1: Type: text/plain, Size: 271 bytes --]
The following patch fixes a bug introduced by a recent LRA patch.
The patch was successfully bootstrapped on x86-64 and ppc64.
2011-08-04 Vladimir Makarov <vmakarov@redhat.com>
* lra-constraints.c (uses_hard_regs_p): Use hard register
elimination.
[-- Attachment #2: ppc.patch --]
[-- Type: text/plain, Size: 994 bytes --]
Index: lra-constraints.c
===================================================================
--- lra-constraints.c (revision 176950)
+++ lra-constraints.c (working copy)
@@ -1249,7 +1303,7 @@ get_final_hard_regno (int hard_regno, in
static bool
uses_hard_regs_p (rtx *loc, HARD_REG_SET set)
{
- int i, j, x_hard_regno;
+ int i, j, x_hard_regno, offset;
enum machine_mode mode;
rtx x;
const char *fmt;
@@ -1271,9 +1325,10 @@ uses_hard_regs_p (rtx *loc, HARD_REG_SET
if (REG_P (x))
{
- x_hard_regno = REGNO (x);
- if (x_hard_regno >= FIRST_PSEUDO_REGISTER)
- x_hard_regno = reg_renumber[x_hard_regno];
+ lra_get_hard_regno_and_offset (x, &x_hard_regno, &offset);
+ /* The real hard regno of the operand after the allocation. It
+ can be negative only for registers. */
+ x_hard_regno = get_final_hard_regno (x_hard_regno, offset);
return (x_hard_regno >= 0
&& lra_hard_reg_set_intersection_p (x_hard_regno, mode, set));
}
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2011-08-04 22:00 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-08-04 22:00 [lra] patch to fix listdc++ build failure on ppc64 Vladimir Makarov
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).