On Wed, Jun 14, 2023 at 09:22:09AM +0000, Richard Biener wrote: > How can a clobber be validly dropped?
Same as any other set: if no code executed after it can read whatever is written. This typically means a stack frame goes away, or simply no more code is executed *at all* after this. > For the case of stack > memory if there's no stack use after it it could be elided > and I suppose the clobber itself can be moved. But then > the function return is a stack use as well. A function return does not access the stack at all on most architectures, including PowerPC. Some epilogue insns can do, of course, but we expand to separate insns during expand already. Segher