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

Akira Hatanaka ahatanak at gmail.com
Tue Feb 11 12:15:41 PST 2014


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


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/6e636c8d/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: taildup-branch-weight2.patch
Type: application/octet-stream
Size: 4237 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140211/6e636c8d/attachment.obj>


More information about the llvm-commits mailing list