This is the mail archive of the gcc-bugs@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]
Other format: [Raw text]

[Bug tree-optimization/18270] [4.0 Regression] internal compiler error: in tree_redirect_edge_and_branch, at tree-cfg.c:4146


------- Additional Comments From rakdver at atrey dot karlin dot mff dot cuni dot cz  2004-11-02 21:23 -------
Subject: Re:  [4.0 Regression] internal compiler error: in tree_redirect_edge_and_branch, at tree-cfg.c:4146

Hello,

> Is there a rule for make_forwarder_block that says it cannot forward a block
> which has *any* abnormal edges?

no.  Just that all the abnormal edges must go to the created forwarder
block.

> Is there a reason it doesnt leave all the old labels in the old block, add a new
> label to the top of the new block, and redirect all the requested edges to this
> new label?.

Yes.  Since we cannot redirect abnormal edges, I had to choose one of
the two possible behaviors -- either having all abnormal edges to point
to the forwarder block, or having all abnormal edges to point to the
other basic block.  I chose the former, since it was easier to write
(it just calls split_block, then redirects the edge(s)).  Also it is
more sane choice for the original purpose of the function (to create
preheaders for loops) -- you then have to redirect only one edge (latch)
instead of possibly multiple entry edges.

But in fact I do not really care; if you need to rewrite the function
so that it works in the other way, I think no code of mine should have
a problem with this.  The other alternative is adding a flag to
make_forwarder_block that would let you choose which way you prefer.

Zdenek


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18270


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