[PATCH] D61263: [X86][SSE] Fold scalar horizontal add/sub for non-0/1 element extractions

Simon Pilgrim via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 29 07:33:56 PDT 2019


RKSimon created this revision.
RKSimon added reviewers: spatel, andreadb, craig.topper.
Herald added a project: LLVM.

We already perform horizontal add/sub if we extract from elements 0 and 1, this patch extends it to non-0/1 element extraction indices (as long as they are from the lowest 128-bit vector).


Repository:
  rL LLVM

https://reviews.llvm.org/D61263

Files:
  lib/Target/X86/X86ISelLowering.cpp
  test/CodeGen/X86/haddsub.ll
  test/CodeGen/X86/phaddsub-extract.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D61263.197108.patch
Type: text/x-patch
Size: 34956 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190429/51d1f405/attachment.bin>


More information about the llvm-commits mailing list