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



--- Comment #5 from gnugcc at emblocks dot org 2013-02-25 13:14:46 UTC ---

Could it be that in the file arm.md concerning the following snippet:



(define_insn "*arm_jump"

  [(set (pc)

    (label_ref (match_operand 0 "" "")))]

  "TARGET_32BIT"

  "*

  {

    if (arm_ccfsm_state == 1 || arm_ccfsm_state == 2)

      {

        arm_ccfsm_state += 2;

        return \"\";

      }

    return \"b%?\\t%l0\";

  }

  "

  [(set_attr "predicable" "yes")

   (set (attr "length")

    (if_then_else

       (and (match_test "TARGET_THUMB2")

        (and (ge (minus (match_dup 0) (pc)) (const_int -2044))

             (le (minus (match_dup 0) (pc)) (const_int 2048))))

       (const_int 2)

       (const_int 4)))]

)





the (match_test "TARGET_THUMB2")  must be replaced by



(and (not(match_test "TARGET_THUMB2"))





same for

- "*arm_cond_branch"

- "*arm_cond_branch_reversed"





the assembler always uses b.w even if the branch is only 10 bytes away.



Regards

Reply via email to