[Bug target/125636] QI extends to HImode causes partial-register write stalls

cvs-commit at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Tue Jun 9 17:20:48 GMT 2026


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=125636

--- Comment #13 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Uros Bizjak <uros@gcc.gnu.org>:

https://gcc.gnu.org/g:093ffc54f4e5a8e1355e5d17fc6ee596983dbd65

commit r17-1454-g093ffc54f4e5a8e1355e5d17fc6ee596983dbd65
Author: Uros Bizjak <ubizjak@gmail.com>
Date:   Tue Jun 9 16:48:56 2026 +0200

    i386: Always emit MOVSBL instead of MOVSBW [PR125636]

    Use MOVSBL instead of MOVSBW for QImode-to-HImode sign extension to avoid
    a 16-bit partial register write and to eliminate 0x66 operand size prefix.

            PR target/125636

    gcc/ChangeLog:

            * config/i386/i386.md (extendqihi2): Use movsbl instead of movsbw.
            Adjust the destination operand to use %k0 and update the mode
            attribute accordingly.

    gcc/testsuite/ChangeLog:

            * gcc.target/i386/pr89954.c: Update assembler scan
            directives to expect movsbl instead of movsbw.


More information about the Gcc-bugs mailing list