[llvm] [DSE] Fold small malloc + zero-store into calloc (PR #106069)
Nikita Popov via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 26 06:44:56 PDT 2024
nikic wrote:
Also worth noting that this transform is unlikely to be profitable, unless maybe for optsize/minsize. Calloc will be more expensive than a malloc plus a single store. Even ignoring the umulo for the size calculation, there's substantial logic in glibc deciding whether and how exactly the zeroing of the memory needs to happen.
https://github.com/llvm/llvm-project/pull/106069
More information about the llvm-commits
mailing list