[PATCH] D20907: [IfConversion] Bugfix: don't add Undef flag on use if reg is live.
Matthias Braun via llvm-commits
llvm-commits at lists.llvm.org
Thu Jul 7 11:40:43 PDT 2016
I tried the reproducer from http://llvm.org/PR28295 <http://llvm.org/PR28295>, it does not reproduce anymore on ToT, but reverting clang and llvm back to around r273545 did indeed reproduce. With http://reviews.llvm.org/D22027 applied the problem disappears so we should try to re-apply this fix once that revision is committed.
- Matthias
> On Jul 7, 2016, at 10:41 AM, Matthias Braun via llvm-commits <llvm-commits at lists.llvm.org> wrote:
>
>>
>> On Jul 7, 2016, at 10:33 AM, Quentin Colombet via llvm-commits <llvm-commits at lists.llvm.org> wrote:
>>
>>
>>> On Jul 6, 2016, at 3:30 PM, Matthias Braun <matze at braunis.de> wrote:
>>>
>>> MatzeB added a comment.
>>>
>>> In http://reviews.llvm.org/D20907#473455, @jonpa wrote:
>>>
>>>> Matthias, from what I can see you have some experience with this part of IfConversion.cpp. Perhaps you could give some advice on or even fix this problem? In short, a bug in IfConversion was found and fixed, but when patch was applied, we ran into a problem relating to Redefs - see above.
>>>
>>>
>>> To come back to this discussion: I added the UpdatePredRedefs() code to achieve the liveness effects stated in my previous post. I have no idea why I used the undef flag, it was one of my first commits to llvm so I assume I misunderstood the semantics back then. So removing this flag is the right call.
>>
>> I believe Pete added that code, so you’re clear :P.
>>
>>>
>>> To fix calls clobbering a live register; "pseudo" live in the sense that it is only live in our "ignore the predicates" worldview. I believe we have to add a implicit def and(!) and implicit use in the presence of clobbers or dead definitions.
>>
>> The problem, as far as I understood, is that the liveness information is wrong when we call updatepredreg, which is why the add of implicit-use gets buggy.
>
> If it is really just that, then my BranchFolder patch may have fixed that by accident. I'll give it a try.
>
> - Matthias
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at lists.llvm.org <mailto:llvm-commits at lists.llvm.org>
> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits <http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160707/f58a3a7c/attachment.html>
More information about the llvm-commits
mailing list