[Bug middle-end/106075] Wrong DSE with -fnon-call-exceptions

2023-05-08 Thread ebotcazou at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106075 --- Comment #15 from Eric Botcazou --- > Maybe just setting insn_info->non_frame_wild_read to true will work? Possibly.

[Bug middle-end/106075] Wrong DSE with -fnon-call-exceptions

2023-05-08 Thread ebotcazou at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106075 --- Comment #14 from Eric Botcazou --- > Ah - interesting. I wonder how the CALL handling is correct in > using add_non_frame_wild_read then for the case we pass the address > of a frame variable to it. See kill_on_calls. > So I suppose add_w

[Bug middle-end/106075] Wrong DSE with -fnon-call-exceptions

2023-05-08 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106075 --- Comment #13 from Richard Biener --- Maybe just setting insn_info->non_frame_wild_read to true will work? add_non_frame_wild_read is odd in that it removes _all_ read records, not only non-frame related ones, same as add_wild_read (but we do

[Bug middle-end/106075] Wrong DSE with -fnon-call-exceptions

2023-05-08 Thread rguenther at suse dot de via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106075 --- Comment #12 from rguenther at suse dot de --- On Mon, 8 May 2023, ebotcazou at gcc dot gnu.org wrote: > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106075 > > --- Comment #11 from Eric Botcazou --- > > Eric, maybe you can help with RTL D

[Bug middle-end/106075] Wrong DSE with -fnon-call-exceptions

2023-05-08 Thread ebotcazou at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106075 --- Comment #11 from Eric Botcazou --- > Eric, maybe you can help with RTL DSE here? The problem is that add_non_frame_wild_read is exclusive, i.e. the read is turned into a read from *only* non-frame memory, but can_throw_external is conservat

[Bug middle-end/106075] Wrong DSE with -fnon-call-exceptions

2023-05-08 Thread ebotcazou at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106075 --- Comment #10 from Eric Botcazou --- > Eric, maybe you can help with RTL DSE here? Sure, let me have a look.

[Bug middle-end/106075] Wrong DSE with -fnon-call-exceptions

2023-05-03 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106075 Richard Biener changed: What|Removed |Added CC||ebotcazou at gcc dot gnu.org --- Comme

[Bug middle-end/106075] Wrong DSE with -fnon-call-exceptions

2023-05-03 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106075 --- Comment #8 from Richard Biener --- Created attachment 54979 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=54979&action=edit patch This patch fixes the testcase but it causes Ada and Go failures. I've isolated the Ada FAILs to the ds

[Bug middle-end/106075] Wrong DSE with -fnon-call-exceptions

2023-01-17 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106075 Richard Biener changed: What|Removed |Added Status|NEW |ASSIGNED Assignee|unassigned

[Bug middle-end/106075] Wrong DSE with -fnon-call-exceptions

2023-01-16 Thread hubicka at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106075 --- Comment #6 from Jan Hubicka --- The SRA issue is fixed now, but I am not quite sure what is desrable solution here... This blocks modref from understanding side effects of functions doing EH.

[Bug middle-end/106075] Wrong DSE with -fnon-call-exceptions

2022-06-24 Thread hubicka at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106075 --- Comment #5 from Jan Hubicka --- Also note that the longjmp testcase will not get misoptimized since we consider longjmp as using all global memory.

[Bug middle-end/106075] Wrong DSE with -fnon-call-exceptions

2022-06-24 Thread hubicka at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106075 --- Comment #4 from Jan Hubicka --- PR106077 demonstrates related problem where ipa-sra concludes it is safe to move dereference earlier in the code. It uses dominator test for that.

[Bug middle-end/106075] Wrong DSE with -fnon-call-exceptions

2022-06-24 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106075 Richard Biener changed: What|Removed |Added Status|UNCONFIRMED |NEW Ever confirmed|0

[Bug middle-end/106075] Wrong DSE with -fnon-call-exceptions

2022-06-24 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106075 --- Comment #2 from Andrew Pinski --- Oh wait -fdelete-dead-exceptions won't change that here or will ir.

[Bug middle-end/106075] Wrong DSE with -fnon-call-exceptions

2022-06-24 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106075 --- Comment #1 from Andrew Pinski --- There is another option to not to remove stores for non call exceptions.