[PATCH] D50392: [TargetLowering] Add support for non-uniform vectors to BuildExactSDIV

Simon Pilgrim via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 7 09:13:03 PDT 2018


RKSimon created this revision.
RKSimon added reviewers: spatel, efriedma, craig.topper, andreadb.

This patch refactors the existing BuildExactSDIV implementation to support non-uniform constant vector denominators.

I've ended up duplicating much of the scalar/vector code pattern that I did for TargetLowering::BuildUDIV (https://reviews.llvm.org/D49248) - calling a 'BuildSDIVPattern' helper - does anyone have any suggestions how I could reduce this further? I'm going to end up doing the same again for TargetLowering::BuildSDIV as well when I get around to it.


Repository:
  rL LLVM

https://reviews.llvm.org/D50392

Files:
  lib/CodeGen/SelectionDAG/TargetLowering.cpp
  test/CodeGen/X86/sdiv-exact.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D50392.159522.patch
Type: text/x-patch
Size: 12488 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180807/a6ee941a/attachment.bin>


More information about the llvm-commits mailing list