[PATCH] D55768: [TargetLowering] Add DemandedElts mask to SimplifyDemandedBits (PR40000)
Andrea Di Biagio via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Dec 17 10:00:23 PST 2018
andreadb accepted this revision.
andreadb added a comment.
This revision is now accepted and ready to land.
LGTM. Thanks!
================
Comment at: test/CodeGen/X86/combine-sdiv.ll:3052-3057
; AVX1-NEXT: vpsrlw $8, %xmm1, %xmm1
; AVX1-NEXT: vpunpcklbw {{.*#+}} xmm2 = xmm0[0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7]
; AVX1-NEXT: vpsraw $8, %xmm2, %xmm2
; AVX1-NEXT: vpsllw $8, %xmm2, %xmm2
; AVX1-NEXT: vpsrlw $8, %xmm2, %xmm2
; AVX1-NEXT: vpackuswb %xmm1, %xmm2, %xmm1
----------------
Unrelated to your patch.
This could be simplified to:
```
vpsrlw $8, %xmm1, %xmm1
vpxor %xmm2, %xmm2, %xmm2
vpunpcklbw %xmm2, %xmm0, %xmm2
vpackuswb %xmm1, %xmm2, %xmm0
```
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D55768/new/
https://reviews.llvm.org/D55768
More information about the llvm-commits
mailing list