This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Fix IA-64 failure


Hi,
the attached patch fixes the IA-64 crashes caused by my verify_flow_info
checks.  Bootstrap is still in progress, but I hope it will pass.  THe
patch is almost definitly correct and makes the bootstrap to get past
early stages is crashed previously.

Wed Mar 13 12:45:40 CET 2002  Jan Hubicka  <jh@suse.cz>
	* cfgrtl.c (verify_flow_info): Be permisive about non-any_condjump
	instructions to have branch prediction notes.
	* ia64reorg.c (ia64_reorg): Do not rebuild CFG.

Index: gcc/cfgrtl.c
===================================================================
RCS file: /cvs/gcc/egcs/gcc/cfgrtl.c,v
retrieving revision 1.35
diff -c -3 -p -r1.35 cfgrtl.c
*** cfgrtl.c	2002/03/08 20:32:14	1.35
--- cfgrtl.c	2002/03/13 11:44:20
*************** verify_flow_info ()
*** 1745,1758 ****
        rtx note;
  
        if (INSN_P (bb->end)
! 	  && (note = find_reg_note (bb->end, REG_BR_PROB, NULL_RTX)))
  	{
- 	  if (!any_condjump_p (bb->end))
- 	    {
- 	      error ("verify_flow_info: REG_BR_PROB on non-condjump",
- 		     bb->index);
- 	      err = 1;
- 	    }
  	  if (INTVAL (XEXP (note, 0)) != BRANCH_EDGE (bb)->probability)
  	    {
  	      error ("verify_flow_info: REG_BR_PROB does not match cfg %i %i",
--- 1745,1753 ----
        rtx note;
  
        if (INSN_P (bb->end)
! 	  && (note = find_reg_note (bb->end, REG_BR_PROB, NULL_RTX))
! 	  && any_condjump_p (bb->end))
  	{
  	  if (INTVAL (XEXP (note, 0)) != BRANCH_EDGE (bb)->probability)
  	    {
  	      error ("verify_flow_info: REG_BR_PROB does not match cfg %i %i",
Index: gcc/config/ia64/ia64.c
===================================================================
RCS file: /cvs/gcc/egcs/gcc/config/ia64/ia64.c,v
retrieving revision 1.146
diff -c -3 -p -r1.146 ia64.c
*** ia64.c	2002/03/13 07:49:22	1.146
--- ia64.c	2002/03/13 11:44:25
*************** ia64_reorg (insns)
*** 6733,6741 ****
    if (optimize == 0)
      split_all_insns_noflow ();
  
!   /* Make sure the CFG and global_live_at_start are correct
!      for emit_predicate_relation_info.  */
!   find_basic_blocks (insns, max_reg_num (), NULL);
    life_analysis (insns, NULL, PROP_DEATH_NOTES);
  
    if (ia64_flag_schedule_insns2)
--- 6733,6742 ----
    if (optimize == 0)
      split_all_insns_noflow ();
  
!   /* We are freeing block_for_insn in the toplev to keep compatibility
!      with old MDEP_REORGS that are not CFG based.  Recompute it now.  */
!   compute_bb_for_insn (get_max_uid ());
!   /* update_life_info_in_dirty_blocks should be enought here.  */
    life_analysis (insns, NULL, PROP_DEATH_NOTES);
  
    if (ia64_flag_schedule_insns2)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]