Re: Clear basic block flags before using BB_VISITED for OpenACC loops processing (was: basic_block flags, BB_VISITED)

2016-10-17 Thread Richard Biener
On Mon, Oct 17, 2016 at 11:38 AM, Thomas Schwinge wrote: > Hi! > > On Fri, 14 Oct 2016 13:06:59 +0200, Richard Biener > wrote: >> On Fri, Oct 14, 2016 at 1:00 PM, Nathan Sidwell wrote: >> > On 10/14/16 05:28, Richard Biener wrote: >> > >> >> The BB_VISITED flag has indetermined state at the beg

Clear basic block flags before using BB_VISITED for OpenACC loops processing (was: basic_block flags, BB_VISITED)

2016-10-17 Thread Thomas Schwinge
Hi! On Fri, 14 Oct 2016 13:06:59 +0200, Richard Biener wrote: > On Fri, Oct 14, 2016 at 1:00 PM, Nathan Sidwell wrote: > > On 10/14/16 05:28, Richard Biener wrote: > > > >> The BB_VISITED flag has indetermined state at the beginning of a pass. > >> You have to ensure it is cleared yourself. > >

Re: basic_block flags, BB_VISITED

2016-10-14 Thread Richard Biener
On Fri, Oct 14, 2016 at 12:57 PM, Bernd Schmidt wrote: > On 10/14/2016 11:26 AM, Richard Biener wrote: >> >> On Fri, Oct 14, 2016 at 11:15 AM, Bernd Schmidt >> wrote: >>> >>> So maybe it should just call clear_bb_flags instead of doing the loop >>> itself? Ok if that works. >> >> >> That doesn't

Re: basic_block flags, BB_VISITED

2016-10-14 Thread Richard Biener
On Fri, Oct 14, 2016 at 1:00 PM, Nathan Sidwell wrote: > On 10/14/16 05:28, Richard Biener wrote: > >> The BB_VISITED flag has indetermined state at the beginning of a pass. >> You have to ensure it is cleared yourself. > > > In that case the openacc (&nvptx?) passes should be modified to clear th

Re: basic_block flags, BB_VISITED

2016-10-14 Thread Nathan Sidwell
On 10/14/16 05:28, Richard Biener wrote: The BB_VISITED flag has indetermined state at the beginning of a pass. You have to ensure it is cleared yourself. In that case the openacc (&nvptx?) passes should be modified to clear the flags at their start, rather than at their end. nathan

Re: basic_block flags, BB_VISITED

2016-10-14 Thread Bernd Schmidt
On 10/14/2016 11:26 AM, Richard Biener wrote: On Fri, Oct 14, 2016 at 11:15 AM, Bernd Schmidt wrote: So maybe it should just call clear_bb_flags instead of doing the loop itself? Ok if that works. That doesn't generally work, it clears too many flags (it was appearantly designed for RTL). O

Re: basic_block flags, BB_VISITED

2016-10-14 Thread Richard Biener
On Fri, Oct 14, 2016 at 10:01 AM, Thomas Schwinge wrote: > Hi! > > After the "Add Early VRP" GCC trunk commit r240291 (Kugan CC for your > information), I've been observing all kinds of OpenACC offloading > failures. I now figured out what's going on. > > The "evrp" pass uses basic_block's BB_VIS

Re: basic_block flags, BB_VISITED

2016-10-14 Thread Richard Biener
On Fri, Oct 14, 2016 at 11:15 AM, Bernd Schmidt wrote: > On 10/14/2016 10:01 AM, Thomas Schwinge wrote: >> >> After the "Add Early VRP" GCC trunk commit r240291 (Kugan CC for your >> information), I've been observing all kinds of OpenACC offloading >> failures. I now figured out what's going on.

Re: basic_block flags, BB_VISITED

2016-10-14 Thread Bernd Schmidt
On 10/14/2016 10:01 AM, Thomas Schwinge wrote: After the "Add Early VRP" GCC trunk commit r240291 (Kugan CC for your information), I've been observing all kinds of OpenACC offloading failures. I now figured out what's going on. The "evrp" pass uses basic_block's BB_VISITED flag. It first clear

basic_block flags, BB_VISITED

2016-10-14 Thread Thomas Schwinge
Hi! After the "Add Early VRP" GCC trunk commit r240291 (Kugan CC for your information), I've been observing all kinds of OpenACC offloading failures. I now figured out what's going on. The "evrp" pass uses basic_block's BB_VISITED flag. It first clears these all, gcc/tree-vrp.c:execute_early_vr