From e75cd5305afa90606dae98bd3f53ac26facbcddf Mon Sep 17 00:00:00 2001 From: Michael Kruse Date: Thu, 20 Jul 2017 12:47:09 +0000 Subject: [PATCH] [ScopBuilder] Avoid use of getStmtFor(BB). NFC. Since there will be no more a 1:1 correspondence between statements and basic blocks, we would like to get rid of the method getStmtFor(BB) and its uses. Here we remove one of its uses in ScopBuilder by fetching the statement in which the instruction lies. Contributed-by: Nandini Singhal Differential Revision: https://reviews.llvm.org/D35610 git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@308610 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Analysis/ScopBuilder.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/Analysis/ScopBuilder.cpp b/lib/Analysis/ScopBuilder.cpp index 4ec4c980..2d2918f4 100644 --- a/lib/Analysis/ScopBuilder.cpp +++ b/lib/Analysis/ScopBuilder.cpp @@ -880,11 +880,11 @@ static void verifyUse(Scop *S, Use &Op, LoopInfo &LI) { /// happened yet, such that virtual and physical uses are equivalent. static void verifyUses(Scop *S, LoopInfo &LI, DominatorTree &DT) { for (auto *BB : S->getRegion().blocks()) { - auto *Stmt = S->getStmtFor(BB); - if (!Stmt) - continue; - for (auto &Inst : *BB) { + auto *Stmt = S->getStmtFor(&Inst); + if (!Stmt) + continue; + if (isIgnoredIntrinsic(&Inst)) continue; -- 2.11.4.GIT