[PATCH] D101944: [X86][Codegen] Shift amount mod: sh? i64 x, (32-y) --> sh? i64 x, -(y+32)
Roman Lebedev via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed May 5 13:56:32 PDT 2021
lebedev.ri created this revision.
lebedev.ri added reviewers: craig.topper, RKSimon, spatel.
lebedev.ri added a project: LLVM.
Herald added subscribers: pengfei, hiraditya.
lebedev.ri requested review of this revision.
I've seen this in the wild when looking into a +5% runtime regression.
I was hoping that this would fix it, but it doesn't.
I'm not certain whether this is always beneficial?
But i'm actually mainly interested in the case where we already compute `(y+32)` (see last test),
so if we aren't okay with this in general, i can try restricting it to `getNodeIfExists()`.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D101944
Files:
llvm/lib/Target/X86/X86ISelDAGToDAG.cpp
llvm/test/CodeGen/X86/64-bit-shift-by-32-minus-y.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D101944.343178.patch
Type: text/x-patch
Size: 4756 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210505/9a6a671b/attachment.bin>
More information about the llvm-commits
mailing list