This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: (known?) Issue with bitmap iterators
- From: Dave Korn <dave dot korn dot cygwin at googlemail dot com>
- To: Jeff Law <law at redhat dot com>
- Cc: Alexander Monakov <amonakov at ispras dot ru>, Joe Buck <Joe dot Buck at synopsys dot COM>, Richard Guenther <richard dot guenther at gmail dot com>, GCC <gcc at gcc dot gnu dot org>
- Date: Wed, 01 Jul 2009 08:00:28 +0100
- Subject: Re: (known?) Issue with bitmap iterators
- References: <4A3CF81C.7050406@redhat.com> <84fc9c000906200801v28f814cj3fa5327c5f3df35e@mail.gmail.com> <4A3FBA1E.6040502@redhat.com> <20090622174623.GA6603@synopsys.com> <4A43C0F3.30503@redhat.com> <alpine.LNX.2.00.0906261424050.27723@endeed2.ispras.ru> <20090626163559.GM14794@synopsys.com> <alpine.LNX.2.00.0906262309570.27723@endeed2.ispras.ru> <4A4AC845.7080709@redhat.com>
Jeff Law wrote:
> (*) Imagine something like this (and related variants)
>
> EXECUTE_IF_SET_IN_BITMAP (bitmap, 0, i, bi)
> {
> blah blah blah
>
> if (bitmap_empty_p (bitmap))
> {
> modify bitmap
> break;
> }
> more blah blah
> }
>
> We exit without iterating BI and thus miss your check.
That's OK; there's no problem if you don't use the iterator again after you
modify the bitmap.
cheers,
DaveK