Author: Kazu Hirata Date: 2021-01-24T12:18:54-08:00 New Revision: d44ca0cf2f64dab1da309f70f841ce3d2ffb527c
URL: https://github.com/llvm/llvm-project/commit/d44ca0cf2f64dab1da309f70f841ce3d2ffb527c DIFF: https://github.com/llvm/llvm-project/commit/d44ca0cf2f64dab1da309f70f841ce3d2ffb527c.diff LOG: [CodeGen] Forward-declare TargetMachine (NFC) InstrEmitter.h needs TargetMachine but relies on a forward declaration of TargetMachine in MachineOperand.h. This patch adds a forward declaration right in InstrEmitter.h. While we are at it, this patch removes the one in MachineOperand.h, where it is unnecessary. Added: Modified: llvm/include/llvm/CodeGen/MachineOperand.h llvm/lib/CodeGen/SelectionDAG/InstrEmitter.h Removed: ################################################################################ diff --git a/llvm/include/llvm/CodeGen/MachineOperand.h b/llvm/include/llvm/CodeGen/MachineOperand.h index b7e89cf4b133..b12351b8a702 100644 --- a/llvm/include/llvm/CodeGen/MachineOperand.h +++ b/llvm/include/llvm/CodeGen/MachineOperand.h @@ -33,7 +33,6 @@ class MachineRegisterInfo; class MCCFIInstruction; class MDNode; class ModuleSlotTracker; -class TargetMachine; class TargetIntrinsicInfo; class TargetRegisterInfo; class hash_code; diff --git a/llvm/lib/CodeGen/SelectionDAG/InstrEmitter.h b/llvm/lib/CodeGen/SelectionDAG/InstrEmitter.h index d969cb65c5b6..09658b8143fe 100644 --- a/llvm/lib/CodeGen/SelectionDAG/InstrEmitter.h +++ b/llvm/lib/CodeGen/SelectionDAG/InstrEmitter.h @@ -26,6 +26,7 @@ class MCInstrDesc; class SDDbgLabel; class SDDbgValue; class TargetLowering; +class TargetMachine; class LLVM_LIBRARY_VISIBILITY InstrEmitter { MachineFunction *MF; _______________________________________________ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits