[PATCH] Make sure branch edge weights are not dropped in TailDuplicatePass

Manman Ren manman.ren at gmail.com
Tue Feb 11 12:20:55 PST 2014


On Tue, Feb 11, 2014 at 12:15 PM, Akira Hatanaka <ahatanak at gmail.com> wrote:

> Updated patch attached. I added FileCheck to the command line and changed
> the weight to something that looks more normal.
>

Are the weights fixed with the testing case? I don't get why you can just
change the weights to something.
LGTM otherwise,

Manman


>
>
> Please review. Thank you.
>
>
> On Tue, Feb 11, 2014 at 11:20 AM, Manman Ren <manman.ren at gmail.com> wrote:
>
>>
>> The testing case seems to miss FileCheck.
>> +; RUN: llc -march=arm -print-machineinstrs=tailduplication
>> -tail-dup-size=100 -enable-tail-merge=false -disable-cgp < %s
>>
>> +; CHECK: Successors according to CFG: BB#1(1234) BB#2(5678)
>> +; CHECK: Successors according to CFG: BB#1(4321) BB#2(8765)
>>
>> The above numbers look weird 1234 5678 :]
>>
>> Thanks for working on this.
>> Manman
>>
>>
>>
>> On Tue, Feb 11, 2014 at 10:36 AM, Akira Hatanaka <ahatanak at gmail.com>wrote:
>>
>>> There are two lines in TailDuplication.cpp where edge weights are not
>>> passed to MachineBasicBlock::addSuccessor, which results in the weights
>>> being dropped from MachineBasicBlock. The attached patch fixes this bug.
>>>
>>> _______________________________________________
>>> llvm-commits mailing list
>>> llvm-commits at cs.uiuc.edu
>>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>>>
>>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140211/f9a60d93/attachment.html>


More information about the llvm-commits mailing list