diff options
Diffstat (limited to 'llvm/lib/Transforms/Utils/SimplifyInstructions.cpp')
-rw-r--r-- | llvm/lib/Transforms/Utils/SimplifyInstructions.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/llvm/lib/Transforms/Utils/SimplifyInstructions.cpp b/llvm/lib/Transforms/Utils/SimplifyInstructions.cpp index d5377f9a4c1..edba5d2656e 100644 --- a/llvm/lib/Transforms/Utils/SimplifyInstructions.cpp +++ b/llvm/lib/Transforms/Utils/SimplifyInstructions.cpp @@ -48,6 +48,9 @@ namespace { /// runOnFunction - Remove instructions that simplify. bool runOnFunction(Function &F) override { + if (skipFunction(F)) + return false; + const DominatorTreeWrapperPass *DTWP = getAnalysisIfAvailable<DominatorTreeWrapperPass>(); const DominatorTree *DT = DTWP ? &DTWP->getDomTree() : nullptr; |