[llvm-commits] [llvm] r92883 - in /llvm/trunk: include/llvm/CodeGen/MachineFunction.h include/llvm/Target/TargetInstrInfo.h test/CodeGen/Thumb2/2010-01-06-TailDuplicateLabels.ll
Jakob Stoklund Olesen
stoklund at 2pi.dk
Wed Jan 6 16:51:05 PST 2010
Author: stoklund
Date: Wed Jan 6 18:51:04 2010
New Revision: 92883
URL: http://llvm.org/viewvc/llvm-project?rev=92883&view=rev
Log:
Add comments.
Modified:
llvm/trunk/include/llvm/CodeGen/MachineFunction.h
llvm/trunk/include/llvm/Target/TargetInstrInfo.h
llvm/trunk/test/CodeGen/Thumb2/2010-01-06-TailDuplicateLabels.ll
Modified: llvm/trunk/include/llvm/CodeGen/MachineFunction.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/CodeGen/MachineFunction.h?rev=92883&r1=92882&r2=92883&view=diff
==============================================================================
--- llvm/trunk/include/llvm/CodeGen/MachineFunction.h (original)
+++ llvm/trunk/include/llvm/CodeGen/MachineFunction.h Wed Jan 6 18:51:04 2010
@@ -315,6 +315,8 @@
/// 'Orig' instruction, identical in all ways except the the instruction
/// has no parent, prev, or next.
///
+ /// See also TargetInstrInfo::duplicate() for target-specific fixes to cloned
+ /// instructions.
MachineInstr *CloneMachineInstr(const MachineInstr *Orig);
/// DeleteMachineInstr - Delete the given MachineInstr.
Modified: llvm/trunk/include/llvm/Target/TargetInstrInfo.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Target/TargetInstrInfo.h?rev=92883&r1=92882&r2=92883&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Target/TargetInstrInfo.h (original)
+++ llvm/trunk/include/llvm/Target/TargetInstrInfo.h Wed Jan 6 18:51:04 2010
@@ -235,6 +235,8 @@
/// duplicate - Create a duplicate of the Orig instruction in MF. This is like
/// MachineFunction::CloneMachineInstr(), but the target may update operands
/// that are required to be unique.
+ ///
+ /// The instruction must be duplicable as indicated by isNotDuplicable().
virtual MachineInstr *duplicate(MachineInstr *Orig,
MachineFunction &MF) const = 0;
Modified: llvm/trunk/test/CodeGen/Thumb2/2010-01-06-TailDuplicateLabels.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/Thumb2/2010-01-06-TailDuplicateLabels.ll?rev=92883&r1=92882&r2=92883&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/Thumb2/2010-01-06-TailDuplicateLabels.ll (original)
+++ llvm/trunk/test/CodeGen/Thumb2/2010-01-06-TailDuplicateLabels.ll Wed Jan 6 18:51:04 2010
@@ -2,6 +2,8 @@
target datalayout = "e-p:32:32:32-i1:8:32-i8:8:32-i16:16:32-i32:32:32-i64:32:32-f32:32:32-f64:32:32-v64:64:64-v128:128:128-a0:0:32-n32"
target triple = "thumbv7-apple-darwin10"
+; This function produces a duplicate LPC label unless special care is taken when duplicating a t2LDRpci_pic instruction.
+
%struct.PlatformMutex = type { i32, [40 x i8] }
%struct.SpinLock = type { %struct.PlatformMutex }
%"struct.WTF::TCMalloc_ThreadCache" = type { i32, %struct._opaque_pthread_t*, i8, [68 x %"struct.WTF::TCMalloc_ThreadCache_FreeList"], i32, i32, %"struct.WTF::TCMalloc_ThreadCache"*, %"struct.WTF::TCMalloc_ThreadCache"* }
More information about the llvm-commits
mailing list