[llvm-bugs] [Bug 43246] New: [InstSimplify] Failure to drop check-for-zero after uadd_with_overflow

via llvm-bugs llvm-bugs at lists.llvm.org
Fri Sep 6 15:01:08 PDT 2019


            Bug ID: 43246
           Summary: [InstSimplify] Failure to drop check-for-zero after
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Scalar Optimizations
          Assignee: unassignedbugs at nondot.org
          Reporter: lebedev.ri at gmail.com
                CC: llvm-bugs at lists.llvm.org


Name: zz
Pre: C != 0
  %1 = add i64 C, %offset
  %2 = icmp ne i64 %1, 0
  %3 = icmp uge i64 %1, C
  %r = and i1 %2, %3
  %r = icmp uge i64 %1, C

This comes up in https://reviews.llvm.org/D67122

for the code like

char* test(char& base, unsigned long offset) {
  return &base + offset;

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/20190906/c6e4fd78/attachment.html>

More information about the llvm-bugs mailing list