Update prebuilt Clang to r416183b from Android.
https://android.googlesource.com/platform/prebuilts/clang/host/
linux-x86/+/06a71ddac05c22edb2d10b590e1769b3f8619bef
clang 12.0.5 (based on r416183b) from build 7284624.
Change-Id: I277a316abcf47307562d8b748b84870f31a72866
Signed-off-by: Olivier Deprez <olivier.deprez@arm.com>
diff --git a/linux-x64/clang/include/llvm/Analysis/LazyValueInfo.h b/linux-x64/clang/include/llvm/Analysis/LazyValueInfo.h
index 570a504..363cb49 100644
--- a/linux-x64/clang/include/llvm/Analysis/LazyValueInfo.h
+++ b/linux-x64/clang/include/llvm/Analysis/LazyValueInfo.h
@@ -33,18 +33,17 @@
AssumptionCache *AC = nullptr;
const DataLayout *DL = nullptr;
class TargetLibraryInfo *TLI = nullptr;
- DominatorTree *DT = nullptr;
void *PImpl = nullptr;
LazyValueInfo(const LazyValueInfo&) = delete;
void operator=(const LazyValueInfo&) = delete;
public:
~LazyValueInfo();
LazyValueInfo() {}
- LazyValueInfo(AssumptionCache *AC_, const DataLayout *DL_, TargetLibraryInfo *TLI_,
- DominatorTree *DT_)
- : AC(AC_), DL(DL_), TLI(TLI_), DT(DT_) {}
+ LazyValueInfo(AssumptionCache *AC_, const DataLayout *DL_,
+ TargetLibraryInfo *TLI_)
+ : AC(AC_), DL(DL_), TLI(TLI_) {}
LazyValueInfo(LazyValueInfo &&Arg)
- : AC(Arg.AC), DL(Arg.DL), TLI(Arg.TLI), DT(Arg.DT), PImpl(Arg.PImpl) {
+ : AC(Arg.AC), DL(Arg.DL), TLI(Arg.TLI), PImpl(Arg.PImpl) {
Arg.PImpl = nullptr;
}
LazyValueInfo &operator=(LazyValueInfo &&Arg) {
@@ -52,7 +51,6 @@
AC = Arg.AC;
DL = Arg.DL;
TLI = Arg.TLI;
- DT = Arg.DT;
PImpl = Arg.PImpl;
Arg.PImpl = nullptr;
return *this;
@@ -73,19 +71,21 @@
Instruction *CxtI = nullptr);
/// Determine whether the specified value comparison with a constant is known
- /// to be true or false at the specified instruction
- /// (from an assume intrinsic). Pred is a CmpInst predicate.
+ /// to be true or false at the specified instruction.
+ /// \p Pred is a CmpInst predicate. If \p UseBlockValue is true, the block
+ /// value is also taken into account.
Tristate getPredicateAt(unsigned Pred, Value *V, Constant *C,
- Instruction *CxtI);
+ Instruction *CxtI, bool UseBlockValue = false);
- /// Determine whether the specified value is known to be a
- /// constant at the end of the specified block. Return null if not.
- Constant *getConstant(Value *V, BasicBlock *BB, Instruction *CxtI = nullptr);
+ /// Determine whether the specified value is known to be a constant at the
+ /// specified instruction. Return null if not.
+ Constant *getConstant(Value *V, Instruction *CxtI);
/// Return the ConstantRange constraint that is known to hold for the
- /// specified value at the end of the specified block. This may only be called
+ /// specified value at the specified instruction. This may only be called
/// on integer-typed Values.
- ConstantRange getConstantRange(Value *V, BasicBlock *BB, Instruction *CxtI = nullptr);
+ ConstantRange getConstantRange(Value *V, Instruction *CxtI,
+ bool UndefAllowed = true);
/// Determine whether the specified value is known to be a
/// constant on the specified edge. Return null if not.
@@ -108,17 +108,9 @@
/// Print the \LazyValueInfo Analysis.
/// We pass in the DTree that is required for identifying which basic blocks
- /// we can solve/print for, in the LVIPrinter. The DT is optional
- /// in LVI, so we need to pass it here as an argument.
+ /// we can solve/print for, in the LVIPrinter.
void printLVI(Function &F, DominatorTree &DTree, raw_ostream &OS);
- /// Disables use of the DominatorTree within LVI.
- void disableDT();
-
- /// Enables use of the DominatorTree within LVI. Does nothing if the class
- /// instance was initialized without a DT pointer.
- void enableDT();
-
// For old PM pass. Delete once LazyValueInfoWrapperPass is gone.
void releaseMemory();
@@ -144,9 +136,7 @@
void operator=(const LazyValueInfoWrapperPass&) = delete;
public:
static char ID;
- LazyValueInfoWrapperPass() : FunctionPass(ID) {
- initializeLazyValueInfoWrapperPassPass(*PassRegistry::getPassRegistry());
- }
+ LazyValueInfoWrapperPass();
~LazyValueInfoWrapperPass() override {
assert(!Info.PImpl && "releaseMemory not called");
}