]> git.ipfire.org Git - thirdparty/gcc.git/commit
ipa/119973 - IPA PTA issue with global initializers
authorRichard Biener <rguenther@suse.de>
Mon, 28 Apr 2025 09:15:53 +0000 (11:15 +0200)
committerRichard Biener <rguenth@gcc.gnu.org>
Mon, 28 Apr 2025 13:19:50 +0000 (15:19 +0200)
commit7a16ef443b13fff9537baa533597836c57131262
tree5743385982532213bc238a1edc7f687796d07dea
parent83d7dcfc0e447daf93d3df824a37181a7964c2f0
ipa/119973 - IPA PTA issue with global initializers

For global initializers with IPA PTA we initialize them from the
IPA reference data but that lacks references to the constant pool.
The following conservatively considers the whole initializer.

PR ipa/119973
* tree-ssa-structalias.cc (create_variable_info_for):
Build constraints from DECL_INITIAL directly rather than
the IPA reference list which is incomplete.

* gcc.dg/torture/pr119973.c: New testcase.
gcc/testsuite/gcc.dg/torture/pr119973.c [new file with mode: 0644]
gcc/tree-ssa-structalias.cc