------- Comment #6 from spark at gcc dot gnu dot org 2007-06-12 23:07 ------- (In reply to comment #5) > Subject: Re: [4.3 Regression] Bootstrap failure in stage1 on hppa*-*-* > > > @@ -4384,7 +4385,7 @@ hppa_can_use_return_insn_p (void) > > { > > return (reload_completed > > && (compute_frame_size (get_frame_size (), 0) ? 0 : 1) > > - && ! df_regs_ever_live_p (2) > > + && df_hard_reg_used_count (2) == 1 > > && ! frame_pointer_needed); > > } > > Don't understand difference between df_regs_ever_live_p and > f->hard_regs_live_count, and why you are checking for a count of 1.
hppa_can_use_return_insn_p() is called from "return" insn pattern in pa.md. The pattern looks: (define_insn "return" [(return) (use (reg:SI 2)) (const_int 0)] "hppa_can_use_return_insn_p ()" "* i.e. there's a use of reg 2. Before dataflow branch got merged, regs_ever_live(2) was not true for reg 2, even though it is used at the return (hence it's live throughout the function body) - unless there's some other use within the function. Now, with df, we always have the correct and precise regs_ever_live. Since the condition hppa_can_use_return_p() is checking is really that there are no other insn that uses reg 2 AND since we know the pattern has a use of reg 2, checking the number of use count to be 1 checks effectively the same assertion. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32296