summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoman Gareev <gareevroman@gmail.com>2017-02-27 08:03:11 +0000
committerRoman Gareev <gareevroman@gmail.com>2017-02-27 08:03:11 +0000
commitbc3fbe49c56801b861c3d69a145f13f970372ad1 (patch)
tree8b9848765587b10fa805108fa713a77c99bec6ee
parent972948b36eecc591cff85391bf11635750c1c88e (diff)
downloadbcm5719-llvm-bc3fbe49c56801b861c3d69a145f13f970372ad1.tar.gz
bcm5719-llvm-bc3fbe49c56801b861c3d69a145f13f970372ad1.zip
Disable the parallel code generation in case of extension nodes
We can not perform the dependence analysis and, consequently, the parallel code generation in case the schedule tree contains extension nodes. Reviewed-by: Tobias Grosser <tobias@grosser.es> Differential Revision: https://reviews.llvm.org/D30394 llvm-svn: 296325
-rw-r--r--polly/lib/CodeGen/IslAst.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/polly/lib/CodeGen/IslAst.cpp b/polly/lib/CodeGen/IslAst.cpp
index c60cd68e547..e8ce6b4dc0b 100644
--- a/polly/lib/CodeGen/IslAst.cpp
+++ b/polly/lib/CodeGen/IslAst.cpp
@@ -400,6 +400,14 @@ void IslAst::init(const Dependences &D) {
bool PerformParallelTest = PollyParallel || DetectParallel ||
PollyVectorizerChoice != VECTORIZER_NONE;
+ // We can not perform the dependence analysis and, consequently,
+ // the parallel code generation in case the schedule tree contains
+ // extension nodes.
+ auto *ScheduleTree = S->getScheduleTree();
+ PerformParallelTest =
+ PerformParallelTest && !S->containsExtensionNode(ScheduleTree);
+ isl_schedule_free(ScheduleTree);
+
// Skip AST and code generation if there was no benefit achieved.
if (!benefitsFromPolly(S, PerformParallelTest))
return;
OpenPOWER on IntegriCloud