aboutsummaryrefslogtreecommitdiff
path: root/gcc/ipa-modref.c
diff options
context:
space:
mode:
authorJan Hubicka <jh@suse.cz>2021-11-12 23:55:50 +0100
committerJan Hubicka <jh@suse.cz>2021-11-12 23:55:50 +0100
commit4d2d5565a0953eaa829d10006baf007cf33bab89 (patch)
treea6c78a8840e4805de98cab1ecd70952ac692252d /gcc/ipa-modref.c
parent264f061997c0a5349cdce6d73f0dc167ac7fc8f4 (diff)
downloadgcc-4d2d5565a0953eaa829d10006baf007cf33bab89.zip
gcc-4d2d5565a0953eaa829d10006baf007cf33bab89.tar.gz
gcc-4d2d5565a0953eaa829d10006baf007cf33bab89.tar.bz2
Fix wrong code with pure functions
I introduced bug into find_func_aliases_for_call in handling pure functions. Instead of reading global memory pure functions are believed to write global memory. This results in misoptimization of the testcase at -O1. The change to pta-callused.c updates the template for new behaviour of the constraint generation. We copy nonlocal memory to calluse which is correct but also not strictly necessary because later we take care to add nonlocal_p flag manually. gcc/ChangeLog: PR tree-optimization/103209 * tree-ssa-structalias.c (find_func_aliases_for_call): Fix use of handle_rhs_call gcc/testsuite/ChangeLog: PR tree-optimization/103209 * gcc.dg/tree-ssa/pta-callused.c: Update template. * gcc.c-torture/execute/pr103209.c: New test.
Diffstat (limited to 'gcc/ipa-modref.c')
0 files changed, 0 insertions, 0 deletions