[PATCH] D24956: [SelectionDAG] Add expansion and promotion of [US]MUL_LOHI

Nicolai Hähnle via llvm-commits llvm-commits at lists.llvm.org
Thu Oct 20 07:09:22 PDT 2016


nhaehnle updated this revision to Diff 75296.
nhaehnle marked 2 inline comments as done.
nhaehnle added a comment.

Thank you all for looking into this and sorry for the delay. I think I've
addressed all your comments:

- getMulExpansion is gone
- vector scalarization is done in LegalizeVectorOps
- use getScalarSizeInBits() throughout to prepare for vector use

There's also the question of "promoting" / using half-width multiplies for
vectors. That could become useful to have more aggressive replacement of
divide-by-constant with the equivalent multiply+shift sequence also for
vector types, i.e. pushing https://reviews.llvm.org/D24822 even further.

However, there are more problems there (X86 gets unnecessarily worse looking
instruction sequences in some tests), so that should be a separate change.


https://reviews.llvm.org/D24956

Files:
  include/llvm/Target/TargetLowering.h
  lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
  lib/CodeGen/SelectionDAG/LegalizeIntegerTypes.cpp
  lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp
  lib/CodeGen/SelectionDAG/TargetLowering.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D24956.75296.patch
Type: text/x-patch
Size: 19230 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20161020/92f7b9e6/attachment.bin>


More information about the llvm-commits mailing list