[trans-mem] RFC Fix missing REG_TM notes

Patrick Marlier patrick.marlier@gmail.com
Tue Jan 10 08:18:00 GMT 2012


On 01/09/2012 04:19 PM, Patrick Marlier wrote:
> On 01/09/2012 04:04 PM, Torvald Riegel wrote:
>> On Mon, 2012-01-09 at 15:55 -0500, Patrick Marlier wrote:
>>> On my side, I was able to fix the problem with genome but the patch is
>>> not clean at all and I need to find exactly where and why the problem
>>> was fixed.
>>
>> What do you mean? Do you still see issues with Genome, even with the
>> returns-twice patch? If so, just on i686 or x86_64 too? With libitm?
> Sorry for confusion. Of course, I disabled your returns-twice patch. I
> patched at different places and I hope to figure out where is the
> problem and that it is not a side effect...
> I am currently testing on x86_64 with libitm.
>
> Patrick.
>

Continuation...
In genome, the problem is that in ira-lives.c the bb has lost its 
abnormal edge and thus this 'if' is never satisfied for TM back edge.
       /* Allocnos can't go in stack regs at the start of a basic block
          that is reached by an abnormal edge. Likewise for call
          clobbered regs, because caller-save, fixup_abnormal_edges and
          possibly the table driven EH machinery are not quite ready to
          handle such allocnos live across such edges.  */
       if (bb_has_abnormal_pred (bb))


The bb has lost its abnormal edge here in cfgbuild.c:gimple_expand_cfg

           /* At the moment not all abnormal edges match the RTL
              representation.  It is safe to remove them here as
              find_many_sub_basic_blocks will rediscover them.
              In the future we should get this fixed properly.  */
           if ((e->flags & EDGE_ABNORMAL)
               && !(e->flags & EDGE_SIBCALL))
             remove_edge (e);

So if I apply the modification from the previous post and if I don't 
remove_edge here, genome seems to work correctly.
Actually, I don't really know what to do with this remove_edge...

I hope this may help you guys!
and thanks in advance for any comment on this (I will be happy to learn!).
--
Patrick Marlier.



More information about the Gcc mailing list