summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/AArch64/AArch64InstrInfo.cpp
diff options
context:
space:
mode:
authorJessica Paquette <jpaquette@apple.com>2018-03-16 22:53:34 +0000
committerJessica Paquette <jpaquette@apple.com>2018-03-16 22:53:34 +0000
commitb3e7dc9144eee605a6456e6aef94a8e0a77c6cdb (patch)
tree400c87cd2943db7f7577e8d6745f1bc59463fcad /llvm/lib/Target/AArch64/AArch64InstrInfo.cpp
parent961235d3352963cbe9efac946ec2f6ae9c14276c (diff)
downloadbcm5719-llvm-b3e7dc9144eee605a6456e6aef94a8e0a77c6cdb.tar.gz
bcm5719-llvm-b3e7dc9144eee605a6456e6aef94a8e0a77c6cdb.zip
[MachineOutliner] Make KILLs invisible
At the point the outliner runs, KILLs don't impact anything, but they're still considered unique instructions. This commit makes them invisible like DebugValues so that they can still be outlined without impacting outlining decisions. llvm-svn: 327760
Diffstat (limited to 'llvm/lib/Target/AArch64/AArch64InstrInfo.cpp')
-rw-r--r--llvm/lib/Target/AArch64/AArch64InstrInfo.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/lib/Target/AArch64/AArch64InstrInfo.cpp b/llvm/lib/Target/AArch64/AArch64InstrInfo.cpp
index b4231d6ff05..0164905a3e0 100644
--- a/llvm/lib/Target/AArch64/AArch64InstrInfo.cpp
+++ b/llvm/lib/Target/AArch64/AArch64InstrInfo.cpp
@@ -5036,6 +5036,11 @@ AArch64InstrInfo::getOutliningType(MachineBasicBlock::iterator &MIT,
// Don't allow debug values to impact outlining type.
if (MI.isDebugValue() || MI.isIndirectDebugValue())
return MachineOutlinerInstrType::Invisible;
+
+ // At this point, KILL instructions don't really tell us much so we can go
+ // ahead and skip over them.
+ if (MI.isKill())
+ return MachineOutlinerInstrType::Invisible;
// Is this a terminator for a basic block?
if (MI.isTerminator()) {
OpenPOWER on IntegriCloud