tree-optimization/101555 - avoid redundant alias queries in PRE
authorRichard Biener <rguenther@suse.de>
Tue, 7 Sep 2021 08:35:42 +0000 (10:35 +0200)
committerRichard Biener <rguenther@suse.de>
Tue, 7 Sep 2021 09:14:17 +0000 (11:14 +0200)
commitf387ff788f63c1974479644edae728047f843ec4
tree4b83403ef0c883508e7d554fb39a3d1bba4c7ba9
parentcff72ef4e2ff8d5775470a8a01a6d9760d2c70be
tree-optimization/101555 - avoid redundant alias queries in PRE

This avoids doing redundant work during PHI translation to invalidate
mems when translating their corresponding VUSE through the blocks
virtual PHI node.  All the invalidation work is already done by
prune_clobbered_mems.

This speeds up the compile of the testcase from 275s with PRE
taking 91% of the compile-time down to 43s with PRE taking 16%
of the compile-time.

2021-09-07  Richard Biener  <rguenther@suse.de>

PR tree-optimization/101555
* tree-ssa-pre.c (translate_vuse_through_block): Do not
perform an alias walk to determine the validity of the
mem at the start of the block which is already guaranteed
by means of prune_clobbered_mems.
(phi_translate_1): Pass edge to translate_vuse_through_block.
gcc/tree-ssa-pre.c