Hi,

I'm trying to outline a function and move all basic-blocks in the function
to different child functions. Only left 1 newly created bb in the original
function with newly inserted statements.

But I got an ICE when gcc call remove_ssa_form for the original function.
I debugged the code, it seems that the ssa names is not removed/released
in the original function even if they are already moved to the newly created
child functions (still in the set of cfun->gimple_df->ssa_names).

And in coalesce_ssa_name, it will scan for every ssa name and do
something there which I thought probably how the ICE is caused.

By moving the basic-block to a newly created child function, I'm using
move_sese_region_to_fn (). I'm wondering how could I correctly manage
the ssa names information so that I could solve the problem properly?

Here is the back-trace information.
#0  0x081f3f2e in bitmap_find_bit (head=0x0, bit=4) at ../../gcc/bitmap.c:557
#1  0x081f415b in bitmap_set_bit (head=0x0, bit=4) at ../../gcc/bitmap.c:643
#2  0x087c5d6d in set_var_live_on_entry (ssa_name=0xb80ae6e0,
live=0xa2f2808) at ../../gcc/tree-ssa-live.c:984
#3  0x087c6448 in calculate_live_ranges (map=0xa34b4a0) at
../../gcc/tree-ssa-live.c:1098
#4  0x08798322 in coalesce_ssa_name () at ../../gcc/tree-ssa-coalesce.c:1409
#5  0x08723191 in remove_ssa_form (perform_ter=0 '\0', sa=0x8f731a8)
at ../../gcc/tree-outof-ssa.c:909
#6  0x08723eb5 in rewrite_out_of_ssa (sa=0x8f731a8) at
../../gcc/tree-outof-ssa.c:1143

Thanks,
Feng

Reply via email to