[Bug rtl-optimization/112525] fail to eliminate unused store
cvs-commit at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Tue Dec 19 05:18:55 GMT 2023
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112525
--- Comment #7 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jiu Fu Guo <guojiufu@gcc.gnu.org>:
https://gcc.gnu.org/g:4759383245ac97a5c83c0272f0a831f2a26ea5c1
commit r14-6674-g4759383245ac97a5c83c0272f0a831f2a26ea5c1
Author: Jiufu Guo <guojiufu@linux.ibm.com>
Date: Tue Dec 19 13:03:06 2023 +0800
treat argp-based mem as frame related in dse
The issue mentioned in PR112525 would be able to be handled by
updating dse.cc to treat arg_pointer_rtx similarly with frame_pointer_rtx.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=30271#c10 also mentioned
this idea.
And arpg area may be used to pass argument to callee. So, it would
be needed to check if call insns are using that mem.
PR rtl-optimization/112525
PR target/30271
gcc/ChangeLog:
* dse.cc (get_group_info): Add arg_pointer_rtx as frame_related.
(check_mem_read_rtx): Add parameter to indicate if it is checking
mem
for call insn.
(scan_insn): Add mem checking on call usage.
gcc/testsuite/ChangeLog:
* gcc.target/powerpc/pr112525.c: New test.
* gcc.target/powerpc/pr30271.c: New test.
More information about the Gcc-bugs
mailing list