[llvm-bugs] [Bug 50949] New: VectorCombine index optimization isn't poison-safe

via llvm-bugs llvm-bugs at lists.llvm.org
Wed Jun 30 10:46:41 PDT 2021


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

            Bug ID: 50949
           Summary: VectorCombine index optimization isn't poison-safe
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Scalar Optimizations
          Assignee: florian_hahn at apple.com
          Reporter: efriedma at quicinc.com
                CC: llvm-bugs at lists.llvm.org

https://reviews.llvm.org/D102476#inline-996311 .  For reference, IR that is
mis-optimized:

define void @insert_store_nonconst_index_known_valid_by_and(<16 x i8>* %q, i8
zeroext %s, i32 %idx) {
entry:
  %0 = load <16 x i8>, <16 x i8>* %q
  %idx.clamped = and i32 %idx, 7
  %vecins = insertelement <16 x i8> %0, i8 %s, i32 %idx.clamped
  store <16 x i8> %vecins, <16 x i8>* %q
  ret void
}

-- 
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/20210630/6d50dddc/attachment.html>


More information about the llvm-bugs mailing list