]> gcc.gnu.org Git - gcc.git/commitdiff
Fix minor length computation on stormy16
authorJeff Law <jlaw@ventanamicro>
Mon, 8 May 2023 14:28:26 +0000 (08:28 -0600)
committerJeff Law <jlaw@ventanamicro>
Mon, 8 May 2023 14:30:09 +0000 (08:30 -0600)
Today's build of xstormy16-elf failed due to a branch to an out of range
target.  Manual inspection of the assembly code for the affected function
(divdi3) showed that the zero-extension patterns were claiming a length
of 2, but clearly assembled into 4 bytes.

This patch adds an explicit length to the zero extension pattern and
appears to resolve the issue in my test builds.

gcc/

* config/stormy16/stormy16.md (zero_extendhisi2): Fix length.

gcc/config/stormy16/stormy16.md

index 91e4bb1cff7fdc94edb3941348a66d20ffecfc23..430ec297e5a45fdf0b1cef84af8aa436b5b4ae5b 100644 (file)
        (zero_extend:SI (match_operand:HI 1 "register_operand" "0")))]
   ""
   "mov %h0,#0"
-  [(set_attr "psw_operand" "clobber")])
+  [(set_attr "length" "4")
+   (set_attr "psw_operand" "clobber")])
 \f
 ;; ::::::::::::::::::::
 ;; ::
This page took 0.063693 seconds and 5 git commands to generate.