diff options
author | Florian Hahn <flo@fhahn.com> | 2022-04-11 16:45:18 +0200 |
---|---|---|
committer | Florian Hahn <flo@fhahn.com> | 2022-04-11 16:45:18 +0200 |
commit | 42229b96bf94ec896d5c62fa643d83ba96e86eea (patch) | |
tree | ff151254881449dd84e531289f9e5b7a1695b7dd /llvm/lib/ToolDrivers/llvm-lib/LibDriver.cpp | |
parent | 2c6217f252f74d2b98ad5130af20a7da94b83030 (diff) | |
download | llvm-42229b96bf94ec896d5c62fa643d83ba96e86eea.zip llvm-42229b96bf94ec896d5c62fa643d83ba96e86eea.tar.gz llvm-42229b96bf94ec896d5c62fa643d83ba96e86eea.tar.bz2 |
[LICM] Only create load in pre-header when promoting load.
When only a store is sunk, there is no need to create a load in the
pre-header, as the result of the load will never get used.
The dead load can can introduce UB, if the function is marked as
writeonly.
Fixes #51248.
Reviewed By: nikic
Differential Revision: https://reviews.llvm.org/D123473
Diffstat (limited to 'llvm/lib/ToolDrivers/llvm-lib/LibDriver.cpp')
0 files changed, 0 insertions, 0 deletions