alpha.md setjmp patch

Andrew Macleod amacleod@cygnus.com
Mon Apr 26 07:51:00 GMT 1999


I've checked in the following patch to alpha.md. The pattern for
builtin_setjmp_receiver was using a CODE_LABEL instead of a LABEL_REF.
This mean that flow didn't recognize it when it was counting 
label references, and sometimes we'd eliminate or rename the
label and we'd end up with an undeclared label being used.

rth has approved this for checkin.

Andrew




	* config/alpha/alpha.md (builtin_setjmp_receiver): Use a label_ref.


Index: gcc/config/alpha/alpha.md
===================================================================
RCS file: /egcs/carton/cvsfiles/egcs/gcc/config/alpha/alpha.md,v
retrieving revision 1.76
diff -c -p -r1.76 alpha.md
*** alpha.md	1999/04/17 23:31:34	1.76
--- alpha.md	1999/04/22 13:53:46
***************
*** 5187,5200 ****
  }")
  
  (define_insn "builtin_setjmp_receiver"
!   [(unspec_volatile [(match_operand 0 "" "")] 2)]
    "! TARGET_OPEN_VMS && ! TARGET_WINDOWS_NT && TARGET_AS_CAN_SUBTRACT_LABELS"
    "\\n$LSJ%=:\;ldgp $29,$LSJ%=-%l0($27)"
    [(set_attr "length" "8")
     (set_attr "type" "multi")])
  
  (define_insn ""
!   [(unspec_volatile [(match_operand 0 "" "")] 2)]
    "! TARGET_OPEN_VMS && ! TARGET_WINDOWS_NT"
    "br $29,$LSJ%=\\n$LSJ%=:\;ldgp $29,0($29)"
    [(set_attr "length" "12")
--- 5187,5200 ----
  }")
  
  (define_insn "builtin_setjmp_receiver"
!   [(unspec_volatile [(label_ref (match_operand 0 "" ""))] 2)]
    "! TARGET_OPEN_VMS && ! TARGET_WINDOWS_NT && TARGET_AS_CAN_SUBTRACT_LABELS"
    "\\n$LSJ%=:\;ldgp $29,$LSJ%=-%l0($27)"
    [(set_attr "length" "8")
     (set_attr "type" "multi")])
  
  (define_insn ""
!   [(unspec_volatile [(label_ref (match_operand 0 "" ""))] 2)]
    "! TARGET_OPEN_VMS && ! TARGET_WINDOWS_NT"
    "br $29,$LSJ%=\\n$LSJ%=:\;ldgp $29,0($29)"
    [(set_attr "length" "12")


More information about the Gcc-patches mailing list