]> git.ipfire.org Git - thirdparty/gcc.git/commit
MATCH: Look through VIEW_CONVERT when folding VEC_PERM_EXPRs.
authorManolis Tsamis <manolis.tsamis@vrull.eu>
Wed, 1 Nov 2023 11:27:28 +0000 (12:27 +0100)
committerPhilipp Tomsich <philipp.tomsich@vrull.eu>
Fri, 24 May 2024 12:11:51 +0000 (14:11 +0200)
commit6d6f324bda1ccb51cd43ff9d4d017eb71bb2d690
tree20558f0a6c4aaa12601d55fb4832eb99e3d7e35c
parent7acd5d71547f74a2af35bab1b17a518197d25d23
MATCH: Look through VIEW_CONVERT when folding VEC_PERM_EXPRs.

The match.pd patterns to merge two vector permutes into one fail when a
potentially no-op view convert expressions is between the two permutes.
This change lifts this restriction.

gcc/ChangeLog:

* match.pd: Allow no-op view_convert between permutes.

gcc/testsuite/ChangeLog:

* gcc.dg/fold-perm-2.c: New test.
gcc/match.pd
gcc/testsuite/gcc.dg/fold-perm-2.c [new file with mode: 0644]