Patch to fix flow2 frame pointer handling

Jeffrey A Law law@cygnus.com
Tue Aug 24 00:32:00 GMT 1999


  In message <199905152318.TAA23531@jwlab.FEITH.COM>you write:
  > In tracking down problems with getting sched2 to recreate the
  > REG_DEAD notes I encountered what appears to be a problem with
  > flow and -fomit_frame_pointer.  The symptom is that flow produces:
  > 
  > (insn 455 453 457 (set (mem:DI (pre_dec:SI (reg:SI 7 %esp)) 0)
  >         (reg:DI 241)) 76 {swapxf+1} (insn_list 449 (nil))
  >     (expr_list:REG_DEAD (reg:DI 241)
  >         (nil)))
  > 
  > and flow2 produces:
  > 
  > (insn 455 453 457 (set (mem:DI (pre_dec:SI (reg:SI 7 %esp)) 0)
  >         (reg:DI 5 %edi)) 76 {swapxf+1} (insn_list 1345 (insn_list 449 (nil)
  > ))
  >     (expr_list:REG_DEAD (reg:SI 5 %edi)
  >         (nil)))
  > 
  > when compiling gcc.c-torture/compile/930623-2.c with -O3 -fomit-frame_point
  > er
  > on x86.  Notice the mode of the REG_DEAD note.
  > 
  > The problem appears to be that flow always gives the frame pointer register
  > special treatment even when it's being used as a normal register.
  > 
  > ChangeLog:
  > 
  > Sat May 15 18:15:10 EDT 1999  John Wehle  (john@feith.com)
  > 
  > 	* flow.c (mark_regs_live_at_end, insn_dead_p,
  > 	mark_set_1, mark_used_regs): Only give FRAME_POINTER_REGNUM
  > 	and HARD_FRAME_POINTER_REGNUM special treatment if reload
  > 	hasn't run or the frame pointer is needed.
  > 	* haifa-sched.c (attach_deaths): Likewise.
  > 	* sched.c (attach_deaths): Likewise.
This is fine.  Can you please install it?

Note that the sched.c change is no longer necessary since I killed it
earlier tonight.

Thanks,
jeff



More information about the Gcc-patches mailing list