------- Comment #14 from dave at hiauly1 dot hia dot nrc dot ca  2007-06-19 
19:56 -------
Subject: Re:  [4.3 Regression] Bootstrap failure in stage1 on hppa*-*-*

> > We need to know that the return pointer (r2) is not used and that
> > the function is a leaf function (i.e., that the incoming value in
> > r2 is unchanged).  Calls clobber r2.
> > 
> > Dave
> 
> Sounds like the following patch would work:
> 
> diff -r 149399c845b5 gcc/config/pa/pa.c
> --- a/gcc/config/pa/pa.c        Tue Jun 12 15:49:27 2007 -0700
> +++ b/gcc/config/pa/pa.c        Wed Jun 13 18:37:17 2007 -0700
> @@ -4415,7 +4415,7 @@ hppa_can_use_return_insn_p (void)
>  {
>    return (reload_completed
>           && (compute_frame_size (get_frame_size (), 0) ? 0 : 1)
> -         && df_hard_reg_used_count (2) == 1
> +         && DF_REG_DEF_COUNT (2) == 0
>           && ! frame_pointer_needed);
>  }
> 
> 
> This essentially checks if r2 is ever written within the function
> (including the calls since r2 is included in the CALL_USED_REGS).

This is an update.  Since the dataflow merge I've been unable to
find a way to handle generation of the prologue/epilogue/return insns
that works on all hppa targets.  However, debugging time has been
limited.

I had one successful build on hppa2.0w-hp-hpux11.11.  However,
I haven't had a successful build on hppa64-hp-hpux11.11 or
hppa-unknown-linux-gnu.  The hppa64 problem is PR 32398.

The linux problem is wierd.  In stage2, I get the following
failure:

/bin/sh: line 1:  4487 Segmentation fault      (core dumped) ./xsinfo
../../sinf
o.h
make[3]: *** [ada/sinfo.h] Error 139

The above fault is a stack overflow.  The problem is wierd in the sense
that the error doesn't occur when I run "./xsinfo ../../sinfo.h" from
an interactive shell.  It only occurs when the command is run by make.
Increasing the stack limit didn't help.  This suggests a problem with
the environment passed to xsinfo.

Dave


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32296

Reply via email to