diff options
author | Eugene Zelenko <eugene.zelenko@gmail.com> | 2016-08-25 00:45:04 +0000 |
---|---|---|
committer | Eugene Zelenko <eugene.zelenko@gmail.com> | 2016-08-25 00:45:04 +0000 |
commit | 1804a77b2a70dea81cc21b171febcc9df9cc1274 (patch) | |
tree | bd77aac1e417fcc9de1b8fac75c76a837278ed00 /llvm/lib/Analysis/ConstantFolding.cpp | |
parent | 0bae624934ccee9434893025fc80cfd4bbd8eec8 (diff) | |
download | bcm5719-llvm-1804a77b2a70dea81cc21b171febcc9df9cc1274.tar.gz bcm5719-llvm-1804a77b2a70dea81cc21b171febcc9df9cc1274.zip |
Fix some Clang-tidy modernize-use-using and Include What You Use warnings; other minor fixes.
Differential revision: https://reviews.llvm.org/D23861
llvm-svn: 279695
Diffstat (limited to 'llvm/lib/Analysis/ConstantFolding.cpp')
-rw-r--r-- | llvm/lib/Analysis/ConstantFolding.cpp | 21 |
1 files changed, 15 insertions, 6 deletions
diff --git a/llvm/lib/Analysis/ConstantFolding.cpp b/llvm/lib/Analysis/ConstantFolding.cpp index a7fb10b2d2b..73cf336f5eb 100644 --- a/llvm/lib/Analysis/ConstantFolding.cpp +++ b/llvm/lib/Analysis/ConstantFolding.cpp @@ -17,29 +17,38 @@ //===----------------------------------------------------------------------===// #include "llvm/Analysis/ConstantFolding.h" +#include "llvm/ADT/APFloat.h" +#include "llvm/ADT/APInt.h" +#include "llvm/ADT/ArrayRef.h" +#include "llvm/ADT/DenseMap.h" #include "llvm/ADT/STLExtras.h" -#include "llvm/ADT/SmallPtrSet.h" +#include "llvm/ADT/StringRef.h" #include "llvm/ADT/SmallVector.h" -#include "llvm/ADT/StringMap.h" #include "llvm/Analysis/TargetLibraryInfo.h" #include "llvm/Analysis/ValueTracking.h" #include "llvm/Config/config.h" +#include "llvm/IR/Constant.h" #include "llvm/IR/Constants.h" #include "llvm/IR/DataLayout.h" #include "llvm/IR/DerivedTypes.h" #include "llvm/IR/Function.h" -#include "llvm/IR/GetElementPtrTypeIterator.h" +#include "llvm/IR/GlobalValue.h" #include "llvm/IR/GlobalVariable.h" +#include "llvm/IR/InstrTypes.h" +#include "llvm/IR/Instruction.h" #include "llvm/IR/Instructions.h" -#include "llvm/IR/Intrinsics.h" #include "llvm/IR/Operator.h" +#include "llvm/IR/Type.h" +#include "llvm/IR/Value.h" +#include "llvm/Support/Casting.h" #include "llvm/Support/ErrorHandling.h" #include "llvm/Support/MathExtras.h" #include <cassert> #include <cerrno> #include <cfenv> #include <cmath> -#include <limits> +#include <cstddef> +#include <cstdint> using namespace llvm; @@ -342,7 +351,7 @@ bool ReadDataFromGlobal(Constant *C, uint64_t ByteOffset, unsigned char *CurPtr, uint64_t CurEltOffset = SL->getElementOffset(Index); ByteOffset -= CurEltOffset; - while (1) { + while (true) { // If the element access is to the element itself and not to tail padding, // read the bytes from the element. uint64_t EltSize = DL.getTypeAllocSize(CS->getOperand(Index)->getType()); |