[PATCH] D69604: [WebAssembly] Expand setcc of v2i64

Thomas Lively via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 29 22:40:30 PDT 2019


tlively created this revision.
tlively added a reviewer: aheejin.
Herald added subscribers: llvm-commits, sunfish, hiraditya, jgravelle-google, sbc100, dschuff.
Herald added a project: LLVM.

The SIMD spec does not include i64x2 comparisons, so they need to be
expanded. Using setOperationAction to expand them also causes f64x2
comparisons to be expanded, so setCondCodeAction needs to be used
instead. But since there are no legal condition codes, the legalizer
does not know how to expand the comparisons. We therefore manually
unroll the operation, taking care to fill each lane with -1 or 0
rather than 1 or 0 for consistency with the other vector comparisons.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D69604

Files:
  llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
  llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.h
  llvm/test/CodeGen/WebAssembly/simd-comparisons.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D69604.227029.patch
Type: text/x-patch
Size: 8823 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20191030/8fee5d7b/attachment.bin>


More information about the llvm-commits mailing list