[llvm] [BasicAA] MemCpyOpt fix on tail stackrestore (PR #101352)

Nikita Popov via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 1 00:15:41 PDT 2024


https://github.com/nikic commented:

> The alternative here is that we declare the tailcallelim transform on llvm.stackrestore illegal. Which I think is a better idea in case anything else looks at the "tail" marker.

Agree. LangRef says this:

> Both markers imply that the callee does not access allocas from the caller.

Where "both markers" are tail/musttail here. This requirement is not satisfied for stackrestore, so it should not get a tail marker.

https://github.com/llvm/llvm-project/pull/101352


More information about the llvm-commits mailing list