h8300 branch offsets

Jeff Law law@redhat.com
Sat Jul 12 05:32:00 GMT 2008


DJ Delorie wrote:
> Branch to exactly 128 bytes beyond the insn was being coded as an
> 8-bit branch, resulting in branching 128 bytes *before* the insn.
> 
> Ok to apply?
> 
> 2008-07-11  DJ Delorie  <dj@redhat.com>
> 
> 	* config/h8300/h8300.md (length): Fix branch offset limit.
> 
> Index: config/h8300/h8300.md
> ===================================================================
> --- config/h8300/h8300.md	(revision 137724)
> +++ config/h8300/h8300.md	(working copy)
> @@ -91,7 +91,7 @@
>  				(const_int -126))
>  			    (le (plus (minus (match_dup 0) (pc))
>  				      (symbol_ref "DELAY_SLOT_LENGTH (insn)"))
> -				(const_int 126)))
> +				(const_int 125)))
>  		       (const_int 2)
>  		       (if_then_else (and (eq_attr "cpu" "h8300h")
>  					  (and (ge (minus (pc) (match_dup 0))
Approved.

Jeff



More information about the Gcc-patches mailing list