take into account contraction when generating OpenMP support
commitb6d6ba5945cf179d12ad0eb0eb176e738324ec78
authorSven Verdoolaege <sven.verdoolaege@gmail.com>
Thu, 22 Aug 2019 20:22:23 +0000 (22 22:22 +0200)
committerSven Verdoolaege <sven.verdoolaege@gmail.com>
Sat, 24 Aug 2019 15:28:31 +0000 (24 17:28 +0200)
tree1b6dfac792f42ed54a5503540b5f9df2bcf13315
parent933bab4070b49764cf418d1944f0da655110149c
take into account contraction when generating OpenMP support

Commit ppcg-0.05-103-gc7d7a176 (optionally group chains of statements,
Thu Mar 17 17:06:40 2016 +0100) introduced the possibility
of grouping several statements into a single statement for scheduling,
but failed to update the detection of parallel loops
in the OpenMP support accordingly.

In particular, when statements are grouped together,
the schedule tree refers to the groups rather than the individual
statements, while the dependence relations still refer
to the original statements.
The practical result is that all dependences get ignored and
every loop is considered parallel when grouping takes place.

Reformulate the partial schedule used in the detection
of parallel loops in terms of the original statements
such that the dependences do get taken into account.

Signed-off-by: Sven Verdoolaege <sven.verdoolaege@gmail.com>
cpu.c