I can reproduce the problem now. After some investigation, this error should be a bug exposed by this patch.
The root cause is, in expand_omp_taskreg, it calls move_sese_region_to_fn with gimple_block(entry_stmt) as the root of the block tree. However, there is an edge inside the region that has the root's sibling as its goto_block. As a result, the block get escaped when numbering the blocks. This bug does not expose before because he goto_block was set NULL. The block_location patch reserved the value for the goto_block, thus exposed he problem. I'll try to fix it in the next couple of days. Thanks, Dehao On Fri, Sep 21, 2012 at 6:07 AM, Dominique Dhumieres <domi...@lps.ens.fr> wrote: >> This problem will be fixed by >> http://gcc.gnu.org/ml/gcc-patches/2012-09/msg01491.html > > Sorry, but its not (see pr54645 c#3). > > Dominique