summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/Utils/LowerSwitch.cpp
diff options
context:
space:
mode:
authorAhmed Bougacha <ahmed.bougacha@gmail.com>2014-12-02 18:09:51 +0000
committerAhmed Bougacha <ahmed.bougacha@gmail.com>2014-12-02 18:09:51 +0000
commit54b7d334c7d1c5e0a28f91852fdbeae2da464565 (patch)
tree54bb62a6c350224ae0cd93c01f9212b01efa39eb /llvm/lib/Transforms/Utils/LowerSwitch.cpp
parentf7a104254aa1d9cb26136accce3dbf5aca2233b2 (diff)
downloadbcm5719-llvm-54b7d334c7d1c5e0a28f91852fdbeae2da464565.tar.gz
bcm5719-llvm-54b7d334c7d1c5e0a28f91852fdbeae2da464565.zip
[MachineCSE] Clear kill-flag on registers imp-def'd by the CSE'd instruction.
Go through implicit defs of CSMI and MI, and clear the kill flags on their uses in all the instructions between CSMI and MI. We might have made some of the kill flags redundant, consider: subs ... %NZCV<imp-def> <- CSMI csinc ... %NZCV<imp-use,kill> <- this kill flag isn't valid anymore subs ... %NZCV<imp-def> <- MI, to be eliminated csinc ... %NZCV<imp-use,kill> Since we eliminated MI, and reused a register imp-def'd by CSMI (here %NZCV), that register, if it was killed before MI, should have that kill flag removed, because it's lifetime was extended. Also, add an exhaustive testcase for the motivating example. Reviewed by: Juergen Ributzka <juergen@apple.com> llvm-svn: 223133
Diffstat (limited to 'llvm/lib/Transforms/Utils/LowerSwitch.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud