https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102767
--- Comment #13 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Kewen Lin <li...@gcc.gnu.org>: https://gcc.gnu.org/g:b343a29dbcbfc5eaca11243ac603a1e5b48630f3 commit r12-4762-gb343a29dbcbfc5eaca11243ac603a1e5b48630f3 Author: Kewen Lin <li...@linux.ibm.com> Date: Thu Oct 28 01:11:56 2021 -0500 rs6000: Fix ICE of vect cost related to V1TI [PR102767] As PR102767 shows, the commit r12-3482 exposed one ICE in function rs6000_builtin_vectorization_cost. We claims V1TI supports movmisalign on rs6000 (See define_expand "movmisalign<mode>"), so it return true in rs6000_builtin_support_vector_misalignment for misalign 8. Later in the cost querying function rs6000_builtin_vectorization_cost, we don't have the arms to handle the V1TI input under (TARGET_VSX && TARGET_ALLOW_MOVMISALIGN). The proposed fix is to add the consideration for V1TI, simply make it as the cost for doubleword which is apparently bigger than the cost of scalar, won't have the vectorization to happen, just to keep consistency and avoid ICE. Another thought is to not support movmisalign for V1TI, but it sounds like a bad idea since it doesn't match the reality. Note that this patch also fixes up the wrong indentations around. gcc/ChangeLog: PR target/102767 * config/rs6000/rs6000.c (rs6000_builtin_vectorization_cost): Consider V1T1 mode for unaligned load and store. gcc/testsuite/ChangeLog: PR target/102767 * gcc.target/powerpc/ppc-fortran/pr102767.f90: New file.