Question about CASE_DROPS_THROUGH
Zack Weinberg
zack@codesourcery.com
Mon Jun 21 05:32:00 GMT 2004
Roger Sayle <roger@eyesopen.com> writes:
> I'll admit that this looks like a major improvement over what we
> have now, and is closer to the semantics of our new SWITCH_EXPR.
> The only difficulty I see is that the addr_vec is not easily
> accessible for the the jump_insn, so building an accurate CFG is
> made harder. For example, there's nothing to prevent insn 13
> above being hoisted out of a loop, or even CSE'd such that
> two switches/indirect jumps share the same jump table [both of
> which I consider to be good things]. And not just CFG building,
> redirect_edge and friends would need to locate the addr_vec.
>
> One way to keep the association between between the actual control
> flow instruction (jump_insn) and the addr_vec-containing instruction
> is to perhaps attach a NOTE to the jump_insn referencing the "load".
> The VAX that keeps the addr_vec and the jump_insn together doesn't
> need such a note. Or perhaps some form of RTL sharing.
Good point. The NOTE is definitely what I would try first.
zw
More information about the Gcc
mailing list