[llvm-bugs] [Bug 37463] New: Failure to scalarize comparison of unform-op(broadcast) vs broadcast

via llvm-bugs llvm-bugs at lists.llvm.org
Mon May 14 15:22:28 PDT 2018


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

            Bug ID: 37463
           Summary: Failure to scalarize comparison of
                    unform-op(broadcast) vs broadcast
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Scalar Optimizations
          Assignee: unassignedbugs at nondot.org
          Reporter: listmail at philipreames.com
                CC: llvm-bugs at lists.llvm.org

In the example below, we should be able to replace the sequence with a
broadcast of a scalar comparison:
  %52 = insertelement <4 x i64*> undef, i64* %51, i32 0                         
  %53 = shufflevector <4 x i64*> %52, <4 x i64*> undef, <4 x i32>
zeroinitializer                                                                 
  %54 = lshr <4 x i64> %33, <i64 21, i64 21, i64 21, i64 21>                    
  %55 = insertelement <4 x i64> undef, i64 %35, i32 0                           
  %56 = shufflevector <4 x i64> %55, <4 x i64> undef, <4 x i32> zeroinitializer 
  %57 = icmp eq <4 x i64> %56, %54

Even if we don't get to the scalar form, we definitely should be sinking the
lsr to be a scalar computation before the broadcast given both arguments are
broadcasts of scalars.

-- 
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/20180514/8c4c63ac/attachment-0001.html>


More information about the llvm-bugs mailing list