cleanup alter_subreg; fix simplify_subreg

Jan Hubicka jh@suse.cz
Tue Nov 13 15:03:00 GMT 2001


> The change
> 
>   Wed Nov 14 14:17:05 CET 2001  Jan Hubicka  <jh@suse.cz>
> 
>         * dbxout.c (dbxout_symbol_location): Update call of alter_subreg.
>         * final.c (walk_alter_subreg): Take pointer; update call of alter_subreg.
>         (final_scan_insn): Update call of alter_subreg.
>         (cleanup_subreg_operands): Likewise.
>         (alter_subreg): Rewrite using simplify_subreg.
>         (output_address, output_operand): Update call of alter_subreg.
>         * output.h (alter_subreg): Update prototype.
>         * sdbout.c (sdbout_symbol): Update call of alter_subreg.
>         * simplify-rtx.c (simplify_subreg): Copy ORIGINAL_REGNO.
>         * Makefile.in (final.o): Add depdendancy on expr.h
> 
> causes a segmentation fault during bootstrap for arm-unknown-netbsd1.5Y.
Thanks,
I will try to debug this at monday (I can't do much work till then).
The problem appears to be that some ports construct subregs they claim
to be invalid and thus simplify_subreg returns NULL.
I plan to solve it by adding simplify_subreg_force that will do the
simplification even when the results does not validate.

Honza
> 
> I have attached a small .i file that triggers this bug, compiled as
> 
>   > ./xgcc -B./ -O2 -c bug.c --save-temps
>   bug.c: In function `__register_frame_info_bases':
>   bug.c:35: Internal error: Segmentation fault
>   Please submit a full bug report,
>   with preprocessed source if appropriate.
>   See <URL:http://www.gnu.org/software/gcc/bugs.html> for instructions.
> 
>    /Krister
> 




More information about the Gcc-patches mailing list