public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "cvs-commit at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug middle-end/113179] [11/12/13/14/15 Regression] MIPS: INS is used for long long, before SLL Date: Mon, 06 May 2024 04:10:49 +0000 [thread overview] Message-ID: <bug-113179-4-rjPB7zHnDO@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-113179-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113179 --- Comment #4 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by YunQiang Su <syq@gcc.gnu.org>: https://gcc.gnu.org/g:7d5d2b879ae7636ca118fb4f3a08b22705cdeacb commit r15-171-g7d5d2b879ae7636ca118fb4f3a08b22705cdeacb Author: YunQiang Su <syq@gcc.gnu.org> Date: Mon Apr 29 00:33:44 2024 +0800 expmed: TRUNCATE value1 if needed in store_bit_field_using_insv PR target/113179. In `store_bit_field_using_insv`, we just use SUBREG if value_mode >= op_mode, while in some ports, a sign_extend will be needed, such as MIPS64: If either GPR rs or GPR rt does not contain sign-extended 32-bit values (bits 63..31 equal), then the result of the operation is UNPREDICTABLE. The problem happens for the code like: struct xx { int a:4; int b:24; int c:3; int d:1; }; void xx (struct xx *a, long long b) { a->d = b; } In the above code, the hard register contains `b`, may be note well sign-extended. gcc/ PR target/113179 * expmed.cc(store_bit_field_using_insv): TRUNCATE value1 if needed. gcc/testsuite PR target/113179 * gcc.target/mips/pr113179.c: New tests.
next prev parent reply other threads:[~2024-05-06 4:10 UTC|newest] Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top 2023-12-30 10:36 [Bug target/113179] New: MIPS syq at gcc dot gnu.org 2023-12-31 6:42 ` [Bug rtl-optimization/113179] [11/12/13/14 Regression] MIPS: INS is used for long long, before SLL pinskia at gcc dot gnu.org 2023-12-31 6:44 ` [Bug middle-end/113179] " pinskia at gcc dot gnu.org 2024-03-04 4:20 ` law at gcc dot gnu.org 2024-04-27 9:16 ` [Bug middle-end/113179] [11/12/13/14/15 " syq at gcc dot gnu.org 2024-05-06 4:10 ` cvs-commit at gcc dot gnu.org [this message] 2024-05-06 4:13 ` syq at gcc dot gnu.org 2024-05-06 4:15 ` syq at gcc dot gnu.org 2024-05-06 4:18 ` pinskia at gcc dot gnu.org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-113179-4-rjPB7zHnDO@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).