This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: latent bug in unreachable code removal?


On Tue, Jul 17, 2001 at 06:48:37PM +0200, Jan Hubicka wrote:
> the problem is in redirect_edge, that got edge from abnormal call
> and called redirect_jump on it.  Redirection of jump has suceeded
> so the real receiver label got failed.

This isn't the problem.  Both try_redirect_by_replacing_jump,
and later on in redirect_edge_and_branch we'll see that the
last instruction isn't a JUMP_INSN and return false as well.

(It is a good change to make but that's besiide beside the point.)

The problem is that 

zz.c.21.greg
(insn 67 4 42 (set (reg/f:DI 2 $2 [72])
        (label_ref:DI 43)) 212 {*movdi_fix} (nil)
    (insn_list:REG_LABEL 43 (expr_list:REG_EQUIV (label_ref:DI 43)
            (nil))))

gets replaced by

zz.c.22.postreload
(insn 67 4 42 (set (reg/f:DI 2 $2 [72])
        (label_ref:DI 52)) 212 {*movdi_fix} (nil)
    (insn_list:REG_LABEL 52 (expr_list:REG_EQUIV (label_ref:DI 43)
            (nil))))

but label 52 is not on nonlocal_goto_handler_labels, so
the flow2 CFG is constructed incorrectly.  I havn't found
out why yet.


r~


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]