Skip to content

Commit

Permalink
[ExtractScopStmt/PlutoOpt] supports scop.ignored
Browse files Browse the repository at this point in the history
  • Loading branch information
kumasento committed Oct 21, 2021
1 parent aa454e9 commit aaf767c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 5 additions & 1 deletion lib/Transforms/ExtractScopStmt.cc
Original file line number Diff line number Diff line change
Expand Up @@ -510,7 +510,11 @@ class ExtractScopStmtPass
OpBuilder b(m.getContext());

SmallVector<mlir::FuncOp, 4> funcs;
m.walk([&](mlir::FuncOp f) { funcs.push_back(f); });
m.walk([&](mlir::FuncOp f) {
if (f->hasAttr("scop.ignored"))
return;
funcs.push_back(f);
});

unsigned numCallees = 0;
for (mlir::FuncOp f : funcs) {
Expand Down
2 changes: 1 addition & 1 deletion lib/Transforms/PlutoTransform.cc
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ class PlutoTransformPass
llvm::DenseMap<mlir::FuncOp, mlir::FuncOp> funcMap;

m.walk([&](mlir::FuncOp f) {
if (!f->getAttr("scop.stmt"))
if (!f->getAttr("scop.stmt") && !f->hasAttr("scop.ignored"))
funcOps.push_back(f);
});

Expand Down

0 comments on commit aaf767c

Please sign in to comment.