[llvm-bugs] [Bug 28730] New: trunk/llvm/lib/Transforms/Scalar/GVNHoist.cpp:77: suspicious assert ?

via llvm-bugs llvm-bugs at lists.llvm.org
Tue Jul 26 23:25:17 PDT 2016


https://llvm.org/bugs/show_bug.cgi?id=28730

            Bug ID: 28730
           Summary: trunk/llvm/lib/Transforms/Scalar/GVNHoist.cpp:77:
                    suspicious assert ?
           Product: new-bugs
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: new bugs
          Assignee: unassignedbugs at nondot.org
          Reporter: dcb314 at hotmail.com
                CC: llvm-bugs at lists.llvm.org
    Classification: Unclassified

trunk/llvm/lib/Transforms/Scalar/GVNHoist.cpp:77]: (style) Same expression on
both sides of '&&'.

Source code is

    unsigned ADFS = DFSNumber.lookup(A);
    unsigned BDFS = DFSNumber.lookup(B);
    assert (ADFS && ADFS);

Maybe better code

    unsigned ADFS = DFSNumber.lookup(A);
    unsigned BDFS = DFSNumber.lookup(B);
    assert (ADFS && BDFS);

According to svn blame, account spop wrote this code.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20160727/2ff3f79c/attachment.html>


More information about the llvm-bugs mailing list