This is the mail archive of the 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]

Re: [tree-ssa]: PRE updates

On Wednesday, June 11, 2003, at 03:49 PM, Andrew MacLeod wrote:

On Tue, 2003-06-10 at 19:08, Daniel Berlin wrote:
Updates for PRE make it do the right thing in more cases, and faster.
Also added a bit more dump info.
Eventually, we should be able to get the temporary without ever needing to
call get_reaching_def.
It'll mean i have to look more at open64's injury/repair stuff for
strength reduction, in order to get the temporary right for those cases.

I now get stopped in the bootstrap here:
c-parse.c: In function `yyparse':
c-parse.c:5421: internal compiler error: in coalesce_ssa_name, at
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:> for instructions.

Andrew, this is *with* your phi updating patch. Without it, we get the phi
node abort we discussed before the weekend. I'll note that this
file/function is the first file that requires splitting an edge to do an
insertion where it has to update the phi's, and the location of the abort
gives me the feeling something else needs to be updated (maybe dominator
children or something? I haven't looked).

SO when you split an edge, the current routines will take care of adjusting existing PHI's. What they dont do is take care of any new PHI's you are adding.

The failure here is because you inserted a stmt on the edge from the IF
to the next stmt. There was no else caluse, so the insert routines
placed your stmt in the else clause of the IF stmt:


# BLOCK 1730. PRED: 748. SUCC: 754.
pretmp.1473_8344 = yyvsp_27 + -4B <<-- Inserted stmt

# BLOCK 754 (pre.i:18276). PRED: 1730 753 749. SUCC: 1681.
# pretmp.1473_8320 = PHI <pretmp.1473_8344(748), pretmp.1473_8360(749), pretmp.1473_8360(753)>;

But the PHI you created still uses the original basic block of the IF (Ie, the PRED of the else block.).

My fault, i forgot to update the euse to the newly created block, (and update the EPHI edge) so it thinks it's on the old edge (where it would have been had the block not been split).

So the PHI node says it gets pretmp.1473_8344 from BB 748, and the live
reange routines find no def on that path, so they make it live on entry.
The same situation existed for pretmp.1473_8343, so it was marked as
live on entry. Since they were both live on entry, both need to
coalesce to the same memory location, but they also interfere over the
range they are live, so its an impossible situation, and hence the

So, are you inserting a stmt at a time, or inserting them all and then

Inserting one at a time and committing at the same time.

If edges are split, and a new basic block is going to be created, you are going to need to know that to create your PHI node properly.


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