[NFC] Remove unnecessary "#include"s from header files

This commit is contained in:
Bill Wendling 2022-02-23 01:20:48 -08:00
parent a10789d6cd
commit a5bbc6ef99
30 changed files with 38 additions and 30 deletions

View File

@ -15,6 +15,7 @@
#define LLVM_ANALYSIS_SPARSEPROPAGATION_H #define LLVM_ANALYSIS_SPARSEPROPAGATION_H
#include "llvm/ADT/SmallPtrSet.h" #include "llvm/ADT/SmallPtrSet.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/Instructions.h" #include "llvm/IR/Instructions.h"
#include "llvm/Support/Debug.h" #include "llvm/Support/Debug.h"
#include <set> #include <set>

View File

@ -20,6 +20,7 @@
#include "llvm/ADT/ArrayRef.h" #include "llvm/ADT/ArrayRef.h"
#include "llvm/Analysis/ConstantFolding.h" #include "llvm/Analysis/ConstantFolding.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/IRBuilderFolder.h" #include "llvm/IR/IRBuilderFolder.h"
namespace llvm { namespace llvm {

View File

@ -9,9 +9,10 @@
#ifndef LLVM_ANALYSIS_VALUELATTICE_H #ifndef LLVM_ANALYSIS_VALUELATTICE_H
#define LLVM_ANALYSIS_VALUELATTICE_H #define LLVM_ANALYSIS_VALUELATTICE_H
#include "llvm/IR/Constants.h"
#include "llvm/IR/ConstantRange.h" #include "llvm/IR/ConstantRange.h"
#include "llvm/IR/Instructions.h" #include "llvm/IR/Instructions.h"
//
//===----------------------------------------------------------------------===// //===----------------------------------------------------------------------===//
// ValueLatticeElement // ValueLatticeElement
//===----------------------------------------------------------------------===// //===----------------------------------------------------------------------===//

View File

@ -14,17 +14,17 @@
#ifndef LLVM_IR_ABSTRACTCALLSITE_H #ifndef LLVM_IR_ABSTRACTCALLSITE_H
#define LLVM_IR_ABSTRACTCALLSITE_H #define LLVM_IR_ABSTRACTCALLSITE_H
#include "llvm/IR/Argument.h"
#include "llvm/IR/Constants.h" #include "llvm/IR/Constants.h"
#include "llvm/IR/Function.h" #include "llvm/IR/Function.h"
#include "llvm/IR/InstrTypes.h" #include "llvm/IR/InstrTypes.h"
#include "llvm/IR/Use.h"
#include "llvm/IR/Value.h" #include "llvm/IR/Value.h"
#include "llvm/Support/Casting.h"
#include <cassert> #include <cassert>
namespace llvm { namespace llvm {
class Argument;
class Use;
/// AbstractCallSite /// AbstractCallSite
/// ///
/// An abstract call site is a wrapper that allows to treat direct, /// An abstract call site is a wrapper that allows to treat direct,

View File

@ -14,7 +14,6 @@
#define LLVM_IR_ARGUMENT_H #define LLVM_IR_ARGUMENT_H
#include "llvm/ADT/Twine.h" #include "llvm/ADT/Twine.h"
#include "llvm/ADT/ilist_node.h"
#include "llvm/IR/Attributes.h" #include "llvm/IR/Attributes.h"
#include "llvm/IR/Value.h" #include "llvm/IR/Value.h"

View File

@ -21,9 +21,10 @@ namespace llvm {
class Constant; class Constant;
class Function; class Function;
class Instruction; class Instruction;
class GlobalVariable;
class MDNode; class MDNode;
class Module; class Module;
class GlobalVariable; class StringRef;
class Type; class Type;
class Value; class Value;

View File

@ -22,9 +22,6 @@
#include "llvm/IR/Instruction.h" #include "llvm/IR/Instruction.h"
#include "llvm/IR/SymbolTableListTraits.h" #include "llvm/IR/SymbolTableListTraits.h"
#include "llvm/IR/Value.h" #include "llvm/IR/Value.h"
#include "llvm/Support/CBindingWrapping.h"
#include "llvm/Support/Casting.h"
#include "llvm/Support/Compiler.h"
#include <cassert> #include <cassert>
#include <cstddef> #include <cstddef>
#include <iterator> #include <iterator>

View File

@ -25,7 +25,6 @@
#include "llvm/IR/BasicBlock.h" #include "llvm/IR/BasicBlock.h"
#include "llvm/IR/Function.h" #include "llvm/IR/Function.h"
#include "llvm/IR/Value.h" #include "llvm/IR/Value.h"
#include "llvm/Support/Casting.h"
#include <cassert> #include <cassert>
#include <cstddef> #include <cstddef>
#include <iterator> #include <iterator>

View File

@ -20,7 +20,6 @@
#include "llvm/ADT/STLExtras.h" #include "llvm/ADT/STLExtras.h"
#include "llvm/IR/Constants.h" #include "llvm/IR/Constants.h"
#include "llvm/IR/IRBuilderFolder.h" #include "llvm/IR/IRBuilderFolder.h"
#include "llvm/IR/InstrTypes.h"
#include "llvm/IR/Instruction.h" #include "llvm/IR/Instruction.h"
namespace llvm { namespace llvm {

View File

@ -32,8 +32,6 @@
#include "llvm/IR/OperandTraits.h" #include "llvm/IR/OperandTraits.h"
#include "llvm/IR/SymbolTableListTraits.h" #include "llvm/IR/SymbolTableListTraits.h"
#include "llvm/IR/Value.h" #include "llvm/IR/Value.h"
#include "llvm/Support/Casting.h"
#include "llvm/Support/Compiler.h"
#include <cassert> #include <cassert>
#include <cstddef> #include <cstddef>
#include <cstdint> #include <cstdint>

View File

@ -15,7 +15,6 @@
#include "llvm/IR/IntrinsicInst.h" #include "llvm/IR/IntrinsicInst.h"
#include "llvm/IR/Intrinsics.h" #include "llvm/IR/Intrinsics.h"
#include "llvm/IR/Module.h" #include "llvm/IR/Module.h"
#include "llvm/Support/ErrorHandling.h"
namespace llvm { namespace llvm {

View File

@ -21,22 +21,16 @@
#include "llvm/ADT/STLExtras.h" #include "llvm/ADT/STLExtras.h"
#include "llvm/ADT/Sequence.h" #include "llvm/ADT/Sequence.h"
#include "llvm/ADT/StringMap.h" #include "llvm/ADT/StringMap.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/ADT/Twine.h" #include "llvm/ADT/Twine.h"
#include "llvm/ADT/iterator_range.h" #include "llvm/ADT/iterator_range.h"
#include "llvm/IR/Attributes.h" #include "llvm/IR/Attributes.h"
#include "llvm/IR/CallingConv.h" #include "llvm/IR/CallingConv.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/DerivedTypes.h" #include "llvm/IR/DerivedTypes.h"
#include "llvm/IR/Function.h" #include "llvm/IR/Function.h"
#include "llvm/IR/Instruction.h" #include "llvm/IR/Instruction.h"
#include "llvm/IR/LLVMContext.h" #include "llvm/IR/LLVMContext.h"
#include "llvm/IR/OperandTraits.h" #include "llvm/IR/OperandTraits.h"
#include "llvm/IR/Type.h"
#include "llvm/IR/User.h" #include "llvm/IR/User.h"
#include "llvm/IR/Value.h"
#include "llvm/Support/Casting.h"
#include "llvm/Support/ErrorHandling.h"
#include <algorithm> #include <algorithm>
#include <cassert> #include <cassert>
#include <cstddef> #include <cstddef>
@ -47,6 +41,10 @@
namespace llvm { namespace llvm {
class StringRef;
class Type;
class Value;
namespace Intrinsic { namespace Intrinsic {
typedef unsigned ID; typedef unsigned ID;
} }

View File

@ -24,7 +24,6 @@
#include "llvm/IR/User.h" #include "llvm/IR/User.h"
#include "llvm/IR/Value.h" #include "llvm/IR/Value.h"
#include "llvm/Support/AtomicOrdering.h" #include "llvm/Support/AtomicOrdering.h"
#include "llvm/Support/Casting.h"
#include <cstdint> #include <cstdint>
#include <utility> #include <utility>

View File

@ -21,24 +21,18 @@
#include "llvm/ADT/None.h" #include "llvm/ADT/None.h"
#include "llvm/ADT/STLExtras.h" #include "llvm/ADT/STLExtras.h"
#include "llvm/ADT/SmallVector.h" #include "llvm/ADT/SmallVector.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/ADT/Twine.h" #include "llvm/ADT/Twine.h"
#include "llvm/ADT/iterator.h" #include "llvm/ADT/iterator.h"
#include "llvm/ADT/iterator_range.h" #include "llvm/ADT/iterator_range.h"
#include "llvm/IR/Attributes.h"
#include "llvm/IR/BasicBlock.h"
#include "llvm/IR/CFG.h" #include "llvm/IR/CFG.h"
#include "llvm/IR/Constant.h" #include "llvm/IR/Constant.h"
#include "llvm/IR/DerivedTypes.h" #include "llvm/IR/DerivedTypes.h"
#include "llvm/IR/InstrTypes.h" #include "llvm/IR/InstrTypes.h"
#include "llvm/IR/Instruction.h" #include "llvm/IR/Instruction.h"
#include "llvm/IR/OperandTraits.h" #include "llvm/IR/OperandTraits.h"
#include "llvm/IR/Type.h"
#include "llvm/IR/Use.h" #include "llvm/IR/Use.h"
#include "llvm/IR/User.h" #include "llvm/IR/User.h"
#include "llvm/IR/Value.h"
#include "llvm/Support/AtomicOrdering.h" #include "llvm/Support/AtomicOrdering.h"
#include "llvm/Support/Casting.h"
#include "llvm/Support/ErrorHandling.h" #include "llvm/Support/ErrorHandling.h"
#include <cassert> #include <cassert>
#include <cstddef> #include <cstddef>
@ -47,9 +41,14 @@
namespace llvm { namespace llvm {
class APFloat;
class APInt; class APInt;
class BasicBlock;
class ConstantInt; class ConstantInt;
class DataLayout; class DataLayout;
class StringRef;
class Type;
class Value;
//===----------------------------------------------------------------------===// //===----------------------------------------------------------------------===//
// AllocaInst Class // AllocaInst Class

View File

@ -31,7 +31,6 @@
#include "llvm/IR/GlobalVariable.h" #include "llvm/IR/GlobalVariable.h"
#include "llvm/IR/Instructions.h" #include "llvm/IR/Instructions.h"
#include "llvm/IR/Intrinsics.h" #include "llvm/IR/Intrinsics.h"
#include "llvm/IR/Metadata.h"
#include "llvm/IR/Value.h" #include "llvm/IR/Value.h"
#include "llvm/Support/Casting.h" #include "llvm/Support/Casting.h"
#include <cassert> #include <cassert>
@ -39,6 +38,8 @@
namespace llvm { namespace llvm {
class Metadata;
/// A wrapper class for inspecting calls to intrinsic functions. /// A wrapper class for inspecting calls to intrinsic functions.
/// This allows the standard isa/dyncast/cast functionality to work with calls /// This allows the standard isa/dyncast/cast functionality to work with calls
/// to intrinsic functions. /// to intrinsic functions.

View File

@ -14,6 +14,7 @@
#include "llvm/Analysis/DomTreeUpdater.h" #include "llvm/Analysis/DomTreeUpdater.h"
#include "llvm/ADT/SmallSet.h" #include "llvm/ADT/SmallSet.h"
#include "llvm/Analysis/PostDominators.h" #include "llvm/Analysis/PostDominators.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/Instructions.h" #include "llvm/IR/Instructions.h"
#include "llvm/Support/GenericDomTree.h" #include "llvm/Support/GenericDomTree.h"
#include <algorithm> #include <algorithm>

View File

@ -15,6 +15,7 @@
#include "llvm/CodeGen/MachineFunction.h" #include "llvm/CodeGen/MachineFunction.h"
#include "llvm/CodeGen/Passes.h" #include "llvm/CodeGen/Passes.h"
#include "llvm/IR/BasicBlock.h" #include "llvm/IR/BasicBlock.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/DerivedTypes.h" #include "llvm/IR/DerivedTypes.h"
#include "llvm/IR/DiagnosticInfo.h" #include "llvm/IR/DiagnosticInfo.h"
#include "llvm/IR/Instructions.h" #include "llvm/IR/Instructions.h"

View File

@ -55,6 +55,7 @@
#include "llvm/CodeGen/TargetRegisterInfo.h" #include "llvm/CodeGen/TargetRegisterInfo.h"
#include "llvm/CodeGen/TargetSubtargetInfo.h" #include "llvm/CodeGen/TargetSubtargetInfo.h"
#include "llvm/IR/BasicBlock.h" #include "llvm/IR/BasicBlock.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/Function.h" #include "llvm/IR/Function.h"
#include "llvm/IR/InlineAsm.h" #include "llvm/IR/InlineAsm.h"
#include "llvm/IR/Instructions.h" #include "llvm/IR/Instructions.h"

View File

@ -13,6 +13,7 @@
#include "llvm/IR/ReplaceConstant.h" #include "llvm/IR/ReplaceConstant.h"
#include "llvm/ADT/SmallPtrSet.h" #include "llvm/ADT/SmallPtrSet.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/Instructions.h" #include "llvm/IR/Instructions.h"
#include "llvm/IR/ValueMap.h" #include "llvm/IR/ValueMap.h"

View File

@ -19,6 +19,7 @@
#include "llvm/Analysis/CallGraphSCCPass.h" #include "llvm/Analysis/CallGraphSCCPass.h"
#include "llvm/Analysis/LazyCallGraph.h" #include "llvm/Analysis/LazyCallGraph.h"
#include "llvm/Analysis/LoopInfo.h" #include "llvm/Analysis/LoopInfo.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/Function.h" #include "llvm/IR/Function.h"
#include "llvm/IR/LegacyPassManager.h" #include "llvm/IR/LegacyPassManager.h"
#include "llvm/IR/Module.h" #include "llvm/IR/Module.h"

View File

@ -15,8 +15,9 @@
#include "AArch64MachineFunctionInfo.h" #include "AArch64MachineFunctionInfo.h"
#include "AArch64InstrInfo.h" #include "AArch64InstrInfo.h"
#include <llvm/IR/Metadata.h> #include "llvm/IR/Constants.h"
#include <llvm/IR/Module.h> #include "llvm/IR/Metadata.h"
#include "llvm/IR/Module.h"
using namespace llvm; using namespace llvm;

View File

@ -34,6 +34,7 @@
#include "AMDGPU.h" #include "AMDGPU.h"
#include "llvm/ADT/DenseSet.h" #include "llvm/ADT/DenseSet.h"
#include "llvm/ADT/SmallString.h" #include "llvm/ADT/SmallString.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/Instructions.h" #include "llvm/IR/Instructions.h"
#include "llvm/IR/Mangler.h" #include "llvm/IR/Mangler.h"
#include "llvm/IR/Module.h" #include "llvm/IR/Module.h"

View File

@ -19,11 +19,13 @@
#include "llvm/Transforms/IPO/CalledValuePropagation.h" #include "llvm/Transforms/IPO/CalledValuePropagation.h"
#include "llvm/Analysis/SparsePropagation.h" #include "llvm/Analysis/SparsePropagation.h"
#include "llvm/Analysis/ValueLatticeUtils.h" #include "llvm/Analysis/ValueLatticeUtils.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/MDBuilder.h" #include "llvm/IR/MDBuilder.h"
#include "llvm/InitializePasses.h" #include "llvm/InitializePasses.h"
#include "llvm/Pass.h" #include "llvm/Pass.h"
#include "llvm/Support/CommandLine.h" #include "llvm/Support/CommandLine.h"
#include "llvm/Transforms/IPO.h" #include "llvm/Transforms/IPO.h"
using namespace llvm; using namespace llvm;
#define DEBUG_TYPE "called-value-propagation" #define DEBUG_TYPE "called-value-propagation"

View File

@ -14,6 +14,7 @@
#include "llvm/Transforms/Utils/CallGraphUpdater.h" #include "llvm/Transforms/Utils/CallGraphUpdater.h"
#include "llvm/ADT/STLExtras.h" #include "llvm/ADT/STLExtras.h"
#include "llvm/IR/Constants.h"
#include "llvm/Transforms/Utils/ModuleUtils.h" #include "llvm/Transforms/Utils/ModuleUtils.h"
using namespace llvm; using namespace llvm;

View File

@ -19,6 +19,7 @@
#include "llvm/Transforms/Utils/UnifyLoopExits.h" #include "llvm/Transforms/Utils/UnifyLoopExits.h"
#include "llvm/ADT/MapVector.h" #include "llvm/ADT/MapVector.h"
#include "llvm/Analysis/LoopInfo.h" #include "llvm/Analysis/LoopInfo.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/Dominators.h" #include "llvm/IR/Dominators.h"
#include "llvm/InitializePasses.h" #include "llvm/InitializePasses.h"
#include "llvm/Transforms/Utils.h" #include "llvm/Transforms/Utils.h"

View File

@ -14,6 +14,7 @@
#include "ReduceArguments.h" #include "ReduceArguments.h"
#include "Delta.h" #include "Delta.h"
#include "llvm/ADT/SmallVector.h" #include "llvm/ADT/SmallVector.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/Intrinsics.h" #include "llvm/IR/Intrinsics.h"
#include <set> #include <set>
#include <vector> #include <vector>

View File

@ -14,6 +14,7 @@
#include "ReduceBasicBlocks.h" #include "ReduceBasicBlocks.h"
#include "llvm/ADT/DenseSet.h" #include "llvm/ADT/DenseSet.h"
#include "llvm/IR/BasicBlock.h" #include "llvm/IR/BasicBlock.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/Instruction.h" #include "llvm/IR/Instruction.h"
#include "llvm/IR/Instructions.h" #include "llvm/IR/Instructions.h"
#include "llvm/IR/LLVMContext.h" #include "llvm/IR/LLVMContext.h"

View File

@ -15,6 +15,7 @@
#include "ReduceFunctions.h" #include "ReduceFunctions.h"
#include "Delta.h" #include "Delta.h"
#include "llvm/ADT/STLExtras.h" #include "llvm/ADT/STLExtras.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/Instructions.h" #include "llvm/IR/Instructions.h"
#include <iterator> #include <iterator>
#include <vector> #include <vector>

View File

@ -12,6 +12,7 @@
//===----------------------------------------------------------------------===// //===----------------------------------------------------------------------===//
#include "ReduceInstructions.h" #include "ReduceInstructions.h"
#include "llvm/IR/Constants.h"
using namespace llvm; using namespace llvm;

View File

@ -9,6 +9,7 @@
#include "ReduceOperandsToArgs.h" #include "ReduceOperandsToArgs.h"
#include "Delta.h" #include "Delta.h"
#include "llvm/ADT/Sequence.h" #include "llvm/ADT/Sequence.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/InstIterator.h" #include "llvm/IR/InstIterator.h"
#include "llvm/IR/InstrTypes.h" #include "llvm/IR/InstrTypes.h"
#include "llvm/IR/Instructions.h" #include "llvm/IR/Instructions.h"