[PATCH] D97751: [Polly] Refabricating IsOutermostParallel() from Integer Set Libarary(ISL) to take the C++ wrapper
Prateek Pardeshi via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Mar 1 17:59:41 PST 2021
prateekpardeshi created this revision.
prateekpardeshi added a reviewer: Meinersbur.
prateekpardeshi added a project: Polly.
Herald added a reviewer: bollu.
prateekpardeshi requested review of this revision.
Herald added a project: Sanitizers.
Herald added a subscriber: Sanitizers.
Polly use algorithms from the Integer Set Library (isl), which is a library written in C and which is incompatible with the rest of the LLVM as it is written in C++.
Changes made:
- Refabricating IsOutermostParallel() to take C++ bindings instead of reference-counting in C isl lib.
- Addition of manage_copy() to be used as reference for C objects instead of IsOutermostParallel()
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D97751
Files:
compiler-rt/lib/hwasan/hwasan_flags.inc
polly/include/polly/CodeGen/IslAst.h
polly/lib/CodeGen/IslAst.cpp
Index: polly/lib/CodeGen/IslAst.cpp
===================================================================
--- polly/lib/CodeGen/IslAst.cpp
+++ polly/lib/CodeGen/IslAst.cpp
@@ -186,7 +186,7 @@
if (IslAstInfo::isExecutedInParallel(Node))
Printer = printLine(Printer, OmpPragmaStr);
- else if (IslAstInfo::isOutermostParallel(Node))
+ else if (IslAstInfo::isOutermostParallel(isl::manage_copy(Node)))
Printer = printLine(Printer, KnownParallelStr + BrokenReductionsStr);
isl_pw_aff_free(DD);
@@ -483,7 +483,7 @@
NumParallel++;
if (IslAstInfo::isInnermostParallel(isl::manage_copy(Node)))
NumInnermostParallel++;
- if (IslAstInfo::isOutermostParallel(Node))
+ if (IslAstInfo::isOutermostParallel(isl::manage_copy(Node)))
NumOutermostParallel++;
if (IslAstInfo::isReductionParallel(Node))
NumReductionParallel++;
@@ -602,7 +602,7 @@
bool IslAstInfo::isParallel(__isl_keep isl_ast_node *Node) {
return IslAstInfo::isInnermostParallel(isl::manage_copy(Node)) ||
- IslAstInfo::isOutermostParallel(Node);
+ IslAstInfo::isOutermostParallel(isl::manage_copy(Node));
}
bool IslAstInfo::isInnermostParallel(const isl::ast_node &Node) {
@@ -610,8 +610,8 @@
return Payload && Payload->IsInnermostParallel;
}
-bool IslAstInfo::isOutermostParallel(__isl_keep isl_ast_node *Node) {
- IslAstUserPayload *Payload = getNodePayload(isl::manage_copy(Node));
+bool IslAstInfo::isOutermostParallel(const isl::ast_node &Node) {
+ IslAstUserPayload *Payload = getNodePayload(Node);
return Payload && Payload->IsOutermostParallel;
}
@@ -636,7 +636,7 @@
if (!PollyParallelForce && isInnermost(Node))
return false;
- return isOutermostParallel(Node) && !isReductionParallel(Node);
+ return isOutermostParallel(isl::manage_copy(Node)) && !isReductionParallel(Node);
}
__isl_give isl_union_map *
Index: polly/include/polly/CodeGen/IslAst.h
===================================================================
--- polly/include/polly/CodeGen/IslAst.h
+++ polly/include/polly/CodeGen/IslAst.h
@@ -145,7 +145,7 @@
static bool isParallel(__isl_keep isl_ast_node *Node);
/// Is this loop an outermost parallel loop?
- static bool isOutermostParallel(__isl_keep isl_ast_node *Node);
+ static bool isOutermostParallel(const isl::ast_node &Node);
/// Is this loop an innermost parallel loop?
static bool isInnermostParallel(const isl::ast_node &Node);
Index: compiler-rt/lib/hwasan/hwasan_flags.inc
===================================================================
--- compiler-rt/lib/hwasan/hwasan_flags.inc
+++ compiler-rt/lib/hwasan/hwasan_flags.inc
@@ -80,4 +80,4 @@
// testsuite can run since we manually ensure any pointer arguments to syscalls
// are untagged before the call.
HWASAN_FLAG(bool, fail_without_syscall_abi, true,
- "Exit if fail to request relaxed syscall ABI.")
+ "Exit if fail to request relaxed syscall ABI.")
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D97751.327334.patch
Type: text/x-patch
Size: 2998 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210302/8de82d6e/attachment.bin>
More information about the llvm-commits
mailing list