[llvm] r268512 - [SimplifyCFG] isSafeToSpeculateStore now ignores debug info

Hans Wennborg via llvm-commits llvm-commits at lists.llvm.org
Wed May 4 09:02:27 PDT 2016


+the original author; these are good comments for future patches.

On Wed, May 4, 2016 at 8:51 AM, David Blaikie via llvm-commits
<llvm-commits at lists.llvm.org> wrote:
>
>
> On Wed, May 4, 2016 at 8:40 AM, Hans Wennborg via llvm-commits
> <llvm-commits at lists.llvm.org> wrote:
>>
>> Author: hans
>> Date: Wed May  4 10:40:57 2016
>> New Revision: 268512
>>
>> URL: http://llvm.org/viewvc/llvm-project?rev=268512&view=rev
>> Log:
>> [SimplifyCFG] isSafeToSpeculateStore now ignores debug info
>>
>> This patch fixes PR27615.
>>
>> @llvm.dbg.value instructions no longer count towards the maximum number of
>> instructions to look back at in the instruction list when searching for a
>> store instruction. This should make the output consistent between debug
>> and
>> non-debug build.
>>
>> Patch by Henric Karlsson <henric.karlsson at ericsson.com>!
>>
>> Differential Revision: http://reviews.llvm.org/D19912

[..]

>> --- llvm/trunk/test/Transforms/SimplifyCFG/PR27615-simplify-cond-br.ll
>> (added)
>> +++ llvm/trunk/test/Transforms/SimplifyCFG/PR27615-simplify-cond-br.ll Wed
>> May  4 10:40:57 2016
>> @@ -0,0 +1,68 @@
>> +; RUN: opt -S -simplifycfg -strip-debug < %s | FileCheck %s
>> +; RUN: opt -S -simplifycfg < %s | FileCheck %s
>> +
>> +; Test case for BUG-27615
>
>
> I was going to say that we usually refer to bugs by PRXXXXX, but then I saw
> you did in the file name - so perhaps this comment doesn't add much?
>
> Also, I'd tend to prefer a test case that just describes what it tests (both
> in name & text) standalone, rather than needing to refer to a bug to
> understand the intent. But that's not a strong habit within the project, so
> it's hardly something I'll advocate strongly for.


More information about the llvm-commits mailing list