From ed5eb933840f85fd3db135cc6f8d7a847c7921e4 Mon Sep 17 00:00:00 2001 From: Serge Pavlov Date: Sun, 15 Jan 2017 10:23:18 +0000 Subject: Reverted: Track validity of pass results Commits r291882 and related r291887. llvm-svn: 292062 --- llvm/lib/IR/Pass.cpp | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'llvm/lib/IR/Pass.cpp') diff --git a/llvm/lib/IR/Pass.cpp b/llvm/lib/IR/Pass.cpp index 6e22c1d4641..a42945ef3ff 100644 --- a/llvm/lib/IR/Pass.cpp +++ b/llvm/lib/IR/Pass.cpp @@ -146,16 +146,13 @@ PassManagerType FunctionPass::getPotentialPassManagerType() const { return PMT_FunctionPassManager; } -bool FunctionPass::skipFunction(const Function &F) { - if (!F.getContext().getOptBisect().shouldRunPass(this, F)) { - setExecuted(false); +bool FunctionPass::skipFunction(const Function &F) const { + if (!F.getContext().getOptBisect().shouldRunPass(this, F)) return true; - } if (F.hasFnAttribute(Attribute::OptimizeNone)) { DEBUG(dbgs() << "Skipping pass '" << getPassName() << "' on function " << F.getName() << "\n"); - setExecuted(false); return true; } return false; -- cgit v1.2.3