Patch to fix powerpc-ibm-aix4.3.3.0 bootstrap
John Wehle
john@feith.com
Sat Oct 6 07:07:00 GMT 2001
hash_rtx assumes that identical symbols have the same hash
which is unfortunately not true on the rs6000 due to the
backend's use of ggc_strdup. This results in reload_cse_regs_1
producing varying results depending on how the toc label symbol
reference hash (which depends on its address) works out.
This patch fixes the make bootstrap comparison errors on
powerpc-ibm-aix4.3.3.0.
ChangeLog:
Sat Oct 6 09:36:55 EDT 2001 John Wehle (john@feith.com)
* rs6000.c (rs6000_emit_load_toc_table): Don't
strdup the toc label.
(create_TOC_reference): Likewise.
Enjoy!
-- John Wehle
------------------8<------------------------8<------------------------
*** gcc/config/rs6000/rs6000.c.ORIGINAL Tue Oct 2 18:28:59 2001
--- gcc/config/rs6000/rs6000.c Sat Oct 6 01:53:29 2001
*************** rs6000_emit_load_toc_table (fromprolog)
*** 5795,5801 ****
rtx tocsym;
static int reload_toc_labelno = 0;
! tocsym = gen_rtx_SYMBOL_REF (Pmode, ggc_strdup (toc_label_name));
ASM_GENERATE_INTERNAL_LABEL (buf, "LCG", reload_toc_labelno++);
symF = gen_rtx_SYMBOL_REF (Pmode, ggc_strdup (buf));
--- 5795,5801 ----
rtx tocsym;
static int reload_toc_labelno = 0;
! tocsym = gen_rtx_SYMBOL_REF (Pmode, toc_label_name);
ASM_GENERATE_INTERNAL_LABEL (buf, "LCG", reload_toc_labelno++);
symF = gen_rtx_SYMBOL_REF (Pmode, ggc_strdup (buf));
*************** create_TOC_reference(symbol)
*** 5872,5878 ****
gen_rtx_REG (Pmode, TOC_REGISTER),
gen_rtx_CONST (Pmode,
gen_rtx_MINUS (Pmode, symbol,
! gen_rtx_SYMBOL_REF (Pmode, ggc_strdup (toc_label_name)))));
}
#if TARGET_AIX
--- 5872,5878 ----
gen_rtx_REG (Pmode, TOC_REGISTER),
gen_rtx_CONST (Pmode,
gen_rtx_MINUS (Pmode, symbol,
! gen_rtx_SYMBOL_REF (Pmode, toc_label_name))));
}
#if TARGET_AIX
-------------------------------------------------------------------------
| Feith Systems | Voice: 1-215-646-8000 | Email: john@feith.com |
| John Wehle | Fax: 1-215-540-5495 | |
-------------------------------------------------------------------------
More information about the Gcc-patches
mailing list