Question about cfgrtl.c:flow_delete_block_noexpunge

law@redhat.com law@redhat.com
Wed Jun 11 03:51:00 GMT 2003


In message <20030611011455.GA29565@redhat.com>, Richard Henderson writes:
 >On Tue, Jun 10, 2003 at 06:59:01PM -0400, Richard Kenner wrote:
 >> Why is the jump table right after the basic block?  Isn't it in a basic
 >> block of its own?
 >
 >No, it's between blocks.  It's not a basic block of its own because
 >it's not code that you can execute on its own.  Indeed, on some
 >platforms (vax, m68k) you cannot even separate it from the tablejump insn.
 >
 >> I see this failing in GCC 3.2 in a very large Ada testcase where what
 >> happens is that CSE converts a tablejump into an unconditional jump.
 >> It leaves the tablejump for later passes to clean up and that's when
 >> this blows up.
 >
 >There have been several fixes for this in 3.3 and mainline since 3.2.
 >We had to iterate several times to prevent the air bubble from popping
 >up somewhere else.  So there's no simple answer to give you; search
 >the archives from late April, early May and you should find some info
 >on this topic.
And several times in 1999, 2000, 2001.  The whole notion of separating
jump tables from their associated jump insn has caused us more problems
than I care to recall.  Every change related to them has caused some
unexpected downstream effect.  It's been a nightmare.

Kenner -- if you really want to fix this problem, attach the jump table
to the tablejump/switch insn itself.  Doing that would enable cleanups
in several places within the compiler.

Jeff



More information about the Gcc mailing list