llvm-project/polly/test/ScheduleOptimizer
Michael Kruse 7860c5fe4e [IslAst] Fix InParallelFor nesting.
IslAst could mark two nested outer loops as "OutermostParallel". It
caused that the code generator tried to OpenMP-parallelize both loops,
which it is not prepared loop.

It was because the recursive AST build algorithm managed a flag
"InParallelFor" to ensure that no nested loop is also marked as
"OutermostParallel". Unfortunatetly the same flag was used by nodes
marked as SIMD, and reset to false after the SIMD node. Since loops can
be marked as SIMD inside "OutermostParallel" loops, the recursive
algorithm again tried to mark loops as "OutermostParellel" although
still nested inside another "OutermostParallel" loop.

The fix exposed another bug: The function "astScheduleDimIsParallel" was
only called when a loop was potentially "OutermostParallel" or
"InnermostParallel", but as a side-effect also determines the minimum
dependence distance. Hence, changing when we need to know whether a loop
is "OutermostParallel" also changed which loop was annotated with
"#pragma minimal dependence distance".

Moreover, some complex condition linked with "InParallelFor" determined
whether a loop should be an "InnermostParallel" loop. It missed some
situations where it would not use mark as such although being inside an
SIMD mark node, and therefore not be annotated using "#pragma simd".

The changes in particular:

1. Split the "InParallelFor" flag into an "InParallelFor" and an
   "InSIMD" flag.

2. Unconditionally call "astScheduleDimIsParallel" for its side-effects
   and store the result in "InParallel" for later use.

3. Simplify the condition when a loop is "InnermostParallel".

Fixes llvm.org/PR33153 and llvm.org/PR38073.

llvm-svn: 343212
2018-09-27 13:39:37 +00:00
..
2012-03-16-Empty-Domain.ll
2012-04-16-Trivially-vectorizable-loops.ll
2013-04-11-Empty-Domain-two.ll
SIMDInParallelFor.ll [IslAst] Fix InParallelFor nesting. 2018-09-27 13:39:37 +00:00
computeout.ll
ensure-correct-tile-sizes.ll Fix missing .git/indexloadPolly in ensure-correct-tile-sizes testcase 2017-04-07 12:55:26 +00:00
full_partial_tile_separation.ll [IslAst] Fix InParallelFor nesting. 2018-09-27 13:39:37 +00:00
kernel_gemm___%for.body---%for.end24.jscop Use SCEV information for the second level aliasing 2017-08-08 16:50:28 +00:00
kernel_gemm___%for.body---%for.end24.jscop.transformed Use SCEV information for the second level aliasing 2017-08-08 16:50:28 +00:00
kernel_gemm___%for.cond1.preheader---%for.end18.jscop.transformed Make the pattern matching work with modified memory accesses 2017-07-19 16:59:06 +00:00
line-tiling-2.ll
line-tiling.ll
mat_mul_pattern_data_layout.ll Update isl to isl-0.18-1047-g4a20ef8 2018-02-20 07:26:42 +00:00
mat_mul_pattern_data_layout_2.ll Disable the Loop Vectorizer in case of GEMM 2017-08-22 17:38:46 +00:00
one-dimensional-band.ll
outer_coincidence.ll Bump isl to isl-0.18-768-g033b61ae 2017-07-04 15:54:11 +00:00
pattern-matching-based-opts-after-delicm.ll [ScheduleOptimizer] Make matmul pattern detection work with delicm output 2017-08-08 06:15:15 +00:00
pattern-matching-based-opts.ll [ScheduleOptimizer] Fix and test schedule tree statistics. 2017-09-20 11:53:05 +00:00
pattern-matching-based-opts_2.ll A new algorithm for identification of a SCoP statement that implement a matrix 2017-02-02 14:23:14 +00:00
pattern-matching-based-opts_3.ll Disable the Loop Vectorizer in case of GEMM 2017-08-22 17:38:46 +00:00
pattern-matching-based-opts_4.ll Disable the Loop Vectorizer in case of GEMM 2017-08-22 17:38:46 +00:00
pattern-matching-based-opts_5.ll Unroll and separate the remaining parts of isolation 2017-09-11 17:46:47 +00:00
pattern-matching-based-opts_6.ll Unroll and separate the remaining parts of isolation 2017-09-11 17:46:47 +00:00
pattern-matching-based-opts_7.ll Disable the Loop Vectorizer in case of GEMM 2017-08-22 17:38:46 +00:00
pattern-matching-based-opts_8.ll Disable the Loop Vectorizer in case of GEMM 2017-08-22 17:38:46 +00:00
pattern-matching-based-opts_9.ll Disable the Loop Vectorizer in case of GEMM 2017-08-22 17:38:46 +00:00
pattern-matching-based-opts_10.ll [IRBuilder] Only emit alias scop metadata for arrays, but not scalars 2017-08-22 21:58:48 +00:00
pattern-matching-based-opts_11.ll [FIX] Update test/ScheduleOptimizer/pattern-matching-based-opts_11.ll. 2017-07-19 18:01:51 +00:00
pattern-matching-based-opts_12.ll Unroll and separate the remaining parts of isolation 2017-09-11 17:46:47 +00:00
pattern-matching-based-opts_13.ll Unroll and separate the remaining parts of isolation 2017-09-11 17:46:47 +00:00
pattern-matching-based-opts_14.ll Disable the Loop Vectorizer in case of GEMM 2017-08-22 17:38:46 +00:00
pattern_matching_based_opts_splitmap.ll [MatMul] Make MatMul detection independent of internal isl representations. 2017-08-20 21:31:11 +00:00
pattern_matching_based_opts_splitmap___%for.body---%for.end23.jscop [MatMul] Make MatMul detection independent of internal isl representations. 2017-08-20 21:31:11 +00:00
pattern_matching_based_opts_splitmap___%for.body---%for.end23.jscop.transformed [MatMul] Make MatMul detection independent of internal isl representations. 2017-08-20 21:31:11 +00:00
prevectorization-without-tiling.ll Make optimizations based on pattern matching be enabled by default 2017-02-23 11:44:12 +00:00
prevectorization.ll Make optimizations based on pattern matching be enabled by default 2017-02-23 11:44:12 +00:00
rectangular-tiling.ll
statistics.ll [ScheduleOptimizer] Fix and test schedule tree statistics. 2017-09-20 11:53:05 +00:00
tile_after_fusion.ll [ScheduleOptimizer] Allow tiling after fusion 2017-03-12 19:02:31 +00:00