diff --git a/include/llvm/Transforms/Utils/BuildLibCalls.h b/include/llvm/Transforms/Utils/BuildLibCalls.h index 0f39ada566e..7660312056d 100644 --- a/include/llvm/Transforms/Utils/BuildLibCalls.h +++ b/include/llvm/Transforms/Utils/BuildLibCalls.h @@ -21,7 +21,7 @@ namespace llvm { class Value; class DataLayout; class TargetLibraryInfo; - + /// CastToCStr - Return V if it is an i8*, otherwise cast it to i8*. Value *CastToCStr(Value *V, IRBuilder<> &B); diff --git a/include/llvm/Transforms/Utils/Cloning.h b/include/llvm/Transforms/Utils/Cloning.h index 03e156ed4be..99b31f0777c 100644 --- a/include/llvm/Transforms/Utils/Cloning.h +++ b/include/llvm/Transforms/Utils/Cloning.h @@ -55,13 +55,13 @@ struct ClonedCodeInfo { /// ContainsCalls - This is set to true if the cloned code contains a normal /// call instruction. bool ContainsCalls; - + /// ContainsDynamicAllocas - This is set to true if the cloned code contains /// a 'dynamic' alloca. Dynamic allocas are allocas that are either not in /// the entry block or they are in the entry block but are not a constant /// size. bool ContainsDynamicAllocas; - + ClonedCodeInfo() : ContainsCalls(false), ContainsDynamicAllocas(false) {} }; @@ -129,7 +129,7 @@ void CloneFunctionInto(Function *NewFunc, const Function *OldFunc, ValueToValueMapTy &VMap, bool ModuleLevelChanges, SmallVectorImpl &Returns, - const char *NameSuffix = "", + const char *NameSuffix = "", ClonedCodeInfo *CodeInfo = nullptr, ValueMapTypeRemapper *TypeMapper = nullptr, ValueMaterializer *Materializer = nullptr); @@ -149,19 +149,19 @@ void CloneAndPruneFunctionInto(Function *NewFunc, const Function *OldFunc, ValueToValueMapTy &VMap, bool ModuleLevelChanges, SmallVectorImpl &Returns, - const char *NameSuffix = "", + const char *NameSuffix = "", ClonedCodeInfo *CodeInfo = nullptr, const DataLayout *DL = nullptr, Instruction *TheCall = nullptr); - + /// InlineFunctionInfo - This class captures the data input to the -/// InlineFunction call, and records the auxiliary results produced by it. +/// InlineFunction call, and records the auxiliary results produced by it. class InlineFunctionInfo { public: explicit InlineFunctionInfo(CallGraph *cg = nullptr, const DataLayout *DL = nullptr) : CG(cg), DL(DL) {} - + /// CG - If non-null, InlineFunction will update the callgraph to reflect the /// changes it makes. CallGraph *CG; @@ -174,13 +174,13 @@ public: /// InlinedCalls - InlineFunction fills this in with callsites that were /// inlined from the callee. This is only filled in if CG is non-null. SmallVector InlinedCalls; - + void reset() { StaticAllocas.clear(); InlinedCalls.clear(); } }; - + /// InlineFunction - This function inlines the called function into the basic /// block of the caller. This returns false if it is not possible to inline /// this call. The program is still in a well defined state if this occurs diff --git a/include/llvm/Transforms/Utils/CmpInstAnalysis.h b/include/llvm/Transforms/Utils/CmpInstAnalysis.h index 22469e0593f..73c15e42c35 100644 --- a/include/llvm/Transforms/Utils/CmpInstAnalysis.h +++ b/include/llvm/Transforms/Utils/CmpInstAnalysis.h @@ -63,4 +63,3 @@ namespace llvm { } // end namespace llvm #endif - diff --git a/include/llvm/Transforms/Utils/IntegerDivision.h b/include/llvm/Transforms/Utils/IntegerDivision.h index 55e8b66e19e..0ec3321b9cf 100644 --- a/include/llvm/Transforms/Utils/IntegerDivision.h +++ b/include/llvm/Transforms/Utils/IntegerDivision.h @@ -55,16 +55,16 @@ namespace llvm { /// @brief Replace Rem with generated code. bool expandRemainderUpTo64Bits(BinaryOperator *Rem); - /// Generate code to divide two integers, replacing Div with the generated + /// Generate code to divide two integers, replacing Div with the generated /// code. Uses ExpandDivision with a 32bit Div which makes it useful for /// targets with little or no support for less than 32 bit arithmetic. - /// + /// /// @brief Replace Rem with generated code. bool expandDivisionUpTo32Bits(BinaryOperator *Div); - /// Generate code to divide two integers, replacing Div with the generated + /// Generate code to divide two integers, replacing Div with the generated /// code. Uses ExpandDivision with a 64bit Div. - /// + /// /// @brief Replace Rem with generated code. bool expandDivisionUpTo64Bits(BinaryOperator *Div); diff --git a/include/llvm/Transforms/Utils/SSAUpdater.h b/include/llvm/Transforms/Utils/SSAUpdater.h index 72ba6582414..86658bfb7f3 100644 --- a/include/llvm/Transforms/Utils/SSAUpdater.h +++ b/include/llvm/Transforms/Utils/SSAUpdater.h @@ -137,27 +137,27 @@ public: LoadAndStorePromoter(const SmallVectorImpl &Insts, SSAUpdater &S, StringRef Name = StringRef()); virtual ~LoadAndStorePromoter() {} - + /// \brief This does the promotion. /// /// Insts is a list of loads and stores to promote, and Name is the basename /// for the PHIs to insert. After this is complete, the loads and stores are /// removed from the code. void run(const SmallVectorImpl &Insts) const; - - + + /// \brief Return true if the specified instruction is in the Inst list. /// /// The Insts list is the one passed into the constructor. Clients should /// implement this with a more efficient version if possible. virtual bool isInstInList(Instruction *I, const SmallVectorImpl &Insts) const; - + /// \brief This hook is invoked after all the stores are found and inserted as /// available values. virtual void doExtraRewritesBeforeFinalDeletion() const { } - + /// \brief Clients can choose to implement this to get notified right before /// a load is RAUW'd another value. virtual void replaceLoadWithValue(LoadInst *LI, Value *V) const { diff --git a/include/llvm/Transforms/Utils/ValueMapper.h b/include/llvm/Transforms/Utils/ValueMapper.h index 33578bbcf22..c108dcf2770 100644 --- a/include/llvm/Transforms/Utils/ValueMapper.h +++ b/include/llvm/Transforms/Utils/ValueMapper.h @@ -28,7 +28,7 @@ namespace llvm { virtual void anchor(); // Out of line method. public: virtual ~ValueMapTypeRemapper() {} - + /// remapType - The client should implement this method if they want to /// remap types while mapping values. virtual Type *remapType(Type *SrcTy) = 0; @@ -46,26 +46,26 @@ namespace llvm { /// lazily. virtual Value *materializeValueFor(Value *V) = 0; }; - + /// RemapFlags - These are flags that the value mapping APIs allow. enum RemapFlags { RF_None = 0, - + /// RF_NoModuleLevelChanges - If this flag is set, the remapper knows that /// only local values within a function (such as an instruction or argument) /// are mapped, not global values like functions and global metadata. RF_NoModuleLevelChanges = 1, - + /// RF_IgnoreMissingEntries - If this flag is set, the remapper ignores /// entries that are not in the value map. If it is unset, it aborts if an /// operand is asked to be remapped which doesn't exist in the mapping. RF_IgnoreMissingEntries = 2 }; - + static inline RemapFlags operator|(RemapFlags LHS, RemapFlags RHS) { return RemapFlags(unsigned(LHS)|unsigned(RHS)); } - + Value *MapValue(const Value *V, ValueToValueMapTy &VM, RemapFlags Flags = RF_None, ValueMapTypeRemapper *TypeMapper = nullptr, @@ -75,7 +75,7 @@ namespace llvm { RemapFlags Flags = RF_None, ValueMapTypeRemapper *TypeMapper = nullptr, ValueMaterializer *Materializer = nullptr); - + /// MapValue - provide versions that preserve type safety for MDNode and /// Constants. inline MDNode *MapValue(const MDNode *V, ValueToValueMapTy &VM, @@ -92,7 +92,7 @@ namespace llvm { return cast(MapValue((const Value*)V, VM, Flags, TypeMapper, Materializer)); } - + } // End llvm namespace