[llvm-bugs] [Bug 49244] New: Suboptimal lowering of `mul x, 0b111....` when using SelectionDAG
via llvm-bugs
llvm-bugs at lists.llvm.org
Wed Feb 17 23:55:41 PST 2021
https://bugs.llvm.org/show_bug.cgi?id=49244
Bug ID: 49244
Summary: Suboptimal lowering of `mul x, 0b111....` when using
SelectionDAG
Product: libraries
Version: trunk
Hardware: PC
OS: All
Status: NEW
Severity: normal
Priority: P
Component: Backend: M68k
Assignee: unassignedbugs at nondot.org
Reporter: minyihh at uci.edu
CC: glaubitz at physik.fu-berlin.de,
llvm-bugs at lists.llvm.org, minyihh at uci.edu
As described in test/CodeGen/M68k/ASM/Arith/imul-neg.ll, when multiplying value
`x` with 2^n - 1 integer, the result will be `-x`, which is preferred to be
lowered to `neg x` instruction. However, SelectionDAG ISel will generate `sub
0, x` (FastISel doesn't have this problem though).
--
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/20210218/d8432c73/attachment.html>
More information about the llvm-bugs
mailing list