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



Jorn Wolfgang Rennecke <amylaar at gcc dot gnu.org> changed:



           What    |Removed                     |Added

----------------------------------------------------------------------------

                 CC|                            |law at redhat dot com

          Component|middle-end                  |target



--- Comment #4 from Jorn Wolfgang Rennecke <amylaar at gcc dot gnu.org> 
2012-11-04 17:31:52 UTC ---

(In reply to comment #3)

In the ccA1Vjgkjx.234r.shorten dump file,

between L19464 and L19463, there is but one call instruction, a basic block

start, a barrier, and some 600 NOTE_INSN_VAR_LOCATION:



(code_label 4141 28778 2472 19464 "" [1 uses])

(note 2472 4141 3318 [bb 311] NOTE_INSN_BASIC_BLOCK)

(call_insn:TI 3318 2472 3319 (parallel [

            (call (mem:SI (symbol_ref/v:SI ("@_Jv_ThrowBadArrayIndex") [flags

0x241]  <function_decl 0xb73b8700 _Jv_ThrowBadArrayIndex>) [0 S4 A32])

                (const_int 16 [0x10]))

            (clobber (reg:SI 1 %r1))

            (clobber (reg:SI 2 %r2))

            (use (reg:SI 19 %r19))

            (use (const_int 0 [0]))

        ])

/ssd/synopsys/arc_gnu_4.8-r192641/gcc-4.8/libjava/classpath/gnu/java/nio/charset/MacSymbol.java:73

198 {*call_symref_pic_post_reload}

     (expr_list:REG_DEAD (reg:SI 26 %r26)

        (expr_list:REG_DEAD (reg:SI 19 %r19)

            (expr_list:REG_NORETURN (const_int 0 [0])

                (nil))))

    (expr_list:REG_CC_SETTER (use (reg:SI 26 %r26))

        (nil)))

(barrier 3319 3318 28981)

(note 28981 3319 28980 (nil) NOTE_INSN_CALL_ARG_LOCATION)

...



(note 29183 29182 4140 (var_location D.16611 (nil)) NOTE_INSN_VAR_LOCATION)

(code_label 4140 29183 2459 19463 "" [1 uses])



The instruction call_symref_pic_post_reload has the following length

attribute setting:



(set (attr "length") (symbol_ref "pa_attr_length_call (insn, 0)"))



Such a length attribute is not considered variable by shorten_branches.



You need to include a clause that is directly in the attribute, e.g.

(and (match_test "0") (eq (match_dup 0) (pc)))

Reply via email to