aboutsummaryrefslogtreecommitdiff
path: root/zlib
diff options
context:
space:
mode:
authorMartin Jambor <mjambor@suse.cz>2021-05-13 23:26:32 +0200
committerMartin Jambor <mjambor@suse.cz>2021-05-13 23:26:32 +0200
commitca9bb74a5f856ccdceb4797f18b0a4ac8f49d069 (patch)
treeb4f2915ca953d9e308274df905e08181d646ba1c /zlib
parent1f6fc2826d19136bb5ab97a4bdac07e6736b6869 (diff)
downloadgcc-ca9bb74a5f856ccdceb4797f18b0a4ac8f49d069.zip
gcc-ca9bb74a5f856ccdceb4797f18b0a4ac8f49d069.tar.gz
gcc-ca9bb74a5f856ccdceb4797f18b0a4ac8f49d069.tar.bz2
tree-sra: Avoid refreshing into const base decls (PR 100453)
When SRA transforms an assignment where the RHS is an aggregate decl that it creates replacements for, the (least efficient) fallback method of dealing with them is to store all the replacements back into the original decl and then let the original assignment takes itc sourse. That of course should not need to be done for TREE_READONLY bases which cannot change contents. The SRA code handled this situation in one of two necessary places but only for DECL_IN_CONSTANT_POOL const decls, this patch modifies both to check TREE_READONLY. gcc/ChangeLog: 2021-05-12 Martin Jambor <mjambor@suse.cz> PR tree-optimization/100453 * tree-sra.c (sra_modify_assign): All const base accesses do not need refreshing, not just those from decl_pool. (sra_modify_assign): Do not refresh into a const base decl. gcc/testsuite/ChangeLog: 2021-05-12 Martin Jambor <mjambor@suse.cz> PR tree-optimization/100453 * gcc.dg/tree-ssa/pr100453.c: New test.
Diffstat (limited to 'zlib')
0 files changed, 0 insertions, 0 deletions