As per title. This will allow the optimizer to pick up on it.
Details
Details
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
lib/Transforms/Scalar/MemCpyOptimizer.cpp | ||
---|---|---|
537 ↗ | (On Diff #44112) | Unrelated change? Please commit separately if you want it. |
639 ↗ | (On Diff #44112) | It is not intuitive (to me at least) that it is always a good thing, especially since tryMergingIntoMemset just above has a notion of profitability. |
lib/Transforms/Scalar/MemCpyOptimizer.cpp | ||
---|---|---|
639 ↗ | (On Diff #44112) | Yes, also one element aggregate would have been unpacked away by instcombine at this stage, so only somewhat large aggregate will be memsetted here. It is done after tryMergingIntoMemset because it is indeed less profitable so we want the most profitable optimization tried first. |