]> git.ipfire.org Git - thirdparty/gcc.git/commit
Always use TYPE_MODE instead of DECL_MODE for vector field
authorH.J. Lu <hjl.tools@gmail.com>
Wed, 19 Oct 2022 19:53:35 +0000 (12:53 -0700)
committerH.J. Lu <hjl.tools@gmail.com>
Tue, 8 Nov 2022 22:24:30 +0000 (14:24 -0800)
commitbb08940b30bd50c6e860bb8ac72d6f2ce7c1b25d
tree39f830114c46c901e74c110be1d569c6935d7735
parent15dfc5f929e838eefc435a47ef8e72eb51790c67
Always use TYPE_MODE instead of DECL_MODE for vector field

e034c5c8957 re PR target/78643 (ICE in convert_move, at expr.c:230)

fixed the case where DECL_MODE of a vector field is BLKmode and its
TYPE_MODE is a vector mode because of target attribute.  Remove the
BLKmode check for the case where DECL_MODE of a vector field is a vector
mode and its TYPE_MODE isn't a vector mode because of target attribute.

gcc/

PR target/107304
* expr.c (get_inner_reference): Always use TYPE_MODE for vector
field with vector raw mode.

gcc/testsuite/

PR target/107304
* gcc.target/i386/pr107304.c: New test.

(cherry picked from commit 1c64aba8cdf6509533f554ad86640f274cdbe37f)
gcc/expr.c
gcc/testsuite/gcc.target/i386/pr107304.c [new file with mode: 0644]