[llvm-bugs] [Bug 43191] New: [AArch64] failed to form 'ubfiz'

via llvm-bugs llvm-bugs at lists.llvm.org
Sun Sep 1 12:08:34 PDT 2019


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

            Bug ID: 43191
           Summary: [AArch64] failed to form 'ubfiz'
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Backend: AArch64
          Assignee: unassignedbugs at nondot.org
          Reporter: spatel+llvm at rotateright.com
                CC: arnaud.degrandmaison at arm.com,
                    llvm-bugs at lists.llvm.org, peter.smith at linaro.org,
                    Ties.Stuij at arm.com

As discussed in:
https://reviews.llvm.org/D67021
...there seems to be something missing in the transforms/recognition between
TLI.isDesirableToCommuteWithShift() and
AArch64DAGToDAGISel::tryBitfieldInsertInZeroOp() with this example:

define i32 @ubfiz(i8 %x) {
  %conv = zext i8 %x to i32
  %r = shl nuw nsw i32 %conv, 3
  ret i32 %r
}

$ llc -o - ubfiz.ll
  and   w8, w0, #0xff
  lsl   w0, w8, #3

But this could be:
  ubfiz w0, w0, #3, #8

-- 
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/20190901/837862d9/attachment.html>


More information about the llvm-bugs mailing list