Re: [PATCH] Improve RTL DSE with -fstack-protector* (PR rtl-optimization/88796)

2019-01-14 Thread Richard Biener
On Fri, 11 Jan 2019, Jakub Jelinek wrote: > On Fri, Jan 11, 2019 at 01:53:21PM +0100, Richard Biener wrote: > > >The canary slot in the stack frame is written in the prologue using > > >MEM_VOLATILE_P store, so we never consider those to be DSEd and is only > > >read > > >in the epilogue, so it sh

Re: [PATCH] Improve RTL DSE with -fstack-protector* (PR rtl-optimization/88796)

2019-01-11 Thread Jakub Jelinek
On Fri, Jan 11, 2019 at 01:53:21PM +0100, Richard Biener wrote: > >The canary slot in the stack frame is written in the prologue using > >MEM_VOLATILE_P store, so we never consider those to be DSEd and is only > >read > >in the epilogue, so it shouldn't alias any other stores. > >Similarly, __stack

Re: [PATCH] Improve RTL DSE with -fstack-protector* (PR rtl-optimization/88796)

2019-01-11 Thread Richard Biener
On January 10, 2019 11:38:55 PM GMT+01:00, Jakub Jelinek wrote: >Hi! > >As mentioned in the PR, RTL DSE doesn't do much with >-fstack-protector*, >because the stack canary test in the epilogue of instrumented functions >is a MEM_VOLATILE_P read out of the crtl->stack_protect_guard ssp >canary >sl

[PATCH] Improve RTL DSE with -fstack-protector* (PR rtl-optimization/88796)

2019-01-10 Thread Jakub Jelinek
Hi! As mentioned in the PR, RTL DSE doesn't do much with -fstack-protector*, because the stack canary test in the epilogue of instrumented functions is a MEM_VOLATILE_P read out of the crtl->stack_protect_guard ssp canary slot in the stack frame and either a MEM_VOLATILE_P read of __stack_chk_guar