On 02/12/2014 11:51 AM, Roman Gareev wrote:
Hi Roman,
thanks for the quick feedback!
I've found out that this bug appeared in revision 189156
(svn://gcc.gnu.org/svn/gcc/trunk)
and similar error message appeared in revision 191757
(svn://gcc.gnu.org/svn/gcc/trunk)
(maybe it's because of changes in diagnostic.c). If
subtract_commutative_associative_deps, a function located in
gcc/graphite-dependences.c, is commented out, the error will disappear . I
am trying to find a bug in this function now. *Could you *please answer a
few questions about it?
1) Where can I find the algorithm for finding associative commutative
reduction, which was used in subtract_commutative_associative_deps?
It seems as if there is no such description available. This is a problem
by itself and we should probably add documentation about what is going
on. Unfortunately, I did not write the code and I also don't really get
what it is doing. The intuition seems to be that the dependences between
a set of reduction statements are computed and those dependences are
then removed from the overall set of dependences.
This is in general a good idea, but the code could need some
improvements and fixes. Several things look shady here. Here one example
1) We only remove dependences, but we should also add new ones
Let 'a->a' be reduction dependences, then dependences between 'a'
can only be removed in case we add new dependences between 'b1' and all
'a' and all 'a' and 'b2.
b1
|
a -> a -> a
|
b2
This should probably be fixed, but I don't think this is the problem of
the current bug report. In fact, to fix the bug report, I don't even
think we need to understand the full algorithm. The first question to
ask is:
Why are we segfaulting? Which statement is causing the segfault?
2) What is the number returned by isl_union_map_compute_flow? (I haven't
found its description in “Integer Set Library: Manual”)
3) I've found the following terms in subtract_commutative_associative_deps:
“may accesses”, “must access”. “Integer Set Library: Manual” gives the
following definition: «If any of the source accesses are marked as being
may accesses, then there will be a dependence to the last must access and
to any may access that follows this last must access». *Could you *please
describe
their meaning? Are they related to transitively-covered dependences?
Thanks Sven for answering those.
Tobias