aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/llvm/Target/TargetInstrInfo.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/llvm/Target/TargetInstrInfo.h b/include/llvm/Target/TargetInstrInfo.h
index 2d73dbf83c..c73fdfb46c 100644
--- a/include/llvm/Target/TargetInstrInfo.h
+++ b/include/llvm/Target/TargetInstrInfo.h
@@ -415,6 +415,13 @@ public:
return false;
}
+ /// CanBeDuplicated - Returns true if the instruction can be duplicated
+ /// without causing unforseenable side-effect (e.g. instructions with unique
+ /// labels attached).
+ virtual bool CanBeDuplicated(const MachineInstr *MI) const {
+ return false;
+ }
+
/// isUnpredicatedTerminator - Returns true if the instruction is a
/// terminator instruction that has not been predicated.
virtual bool isUnpredicatedTerminator(const MachineInstr *MI) const;