aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Transforms/Utils/ValueMapper.cpp
diff options
context:
space:
mode:
authorMicah Weston <micahsweston@gmail.com>2022-01-17 17:17:15 +0000
committerDavid Green <david.green@arm.com>2022-01-17 17:17:15 +0000
commite6698f09929a134bf0f46d9347142b86d8f636a2 (patch)
treead5094cd5c153539a807b987fca564670c775612 /llvm/lib/Transforms/Utils/ValueMapper.cpp
parente76ecbb0f36441b2d84908f907369b6dcfc26163 (diff)
downloadllvm-e6698f09929a134bf0f46d9347142b86d8f636a2.zip
llvm-e6698f09929a134bf0f46d9347142b86d8f636a2.tar.gz
llvm-e6698f09929a134bf0f46d9347142b86d8f636a2.tar.bz2
[AArch64] Revive optimize add/sub with immediate through MIPeepholeOpt
Fixes the build issue with D111034, whose goal was to optimize add/sub with long immediates. Optimize ([add|sub] r, imm) -> ([ADD|SUB] ([ADD|SUB] r, #imm0, lsl #12), #imm1), if imm == (imm0<<12)+imm1. and both imm0 and imm1 are non-zero 12-bit unsigned integers. Optimize ([add|sub] r, imm) -> ([SUB|ADD] ([SUB|ADD] r, #imm0, lsl #12), #imm1), if imm == -(imm0<<12)-imm1, and both imm0 and imm1 are non-zero 12-bit unsigned integers. The change which fixed the build issue in D111034 was the use of new virtual registers so that SSA form is maintained until deleting MI. Differential Revision: https://reviews.llvm.org/D117429
Diffstat (limited to 'llvm/lib/Transforms/Utils/ValueMapper.cpp')
0 files changed, 0 insertions, 0 deletions