[PATCH] D52912: [SelectionDAG] allow FP binops in SimplifyDemandedVectorElts

Sanjay Patel via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Oct 5 14:43:33 PDT 2018


spatel added inline comments.


================
Comment at: test/CodeGen/X86/avx512-hadd-hsub.ll:183
+; KNL-NEXT:    vunpckhpd {{.*#+}} ymm0 = ymm0[1],ymm1[1],ymm0[3],ymm1[3]
 ; KNL-NEXT:    vaddpd %zmm0, %zmm2, %zmm0
 ; KNL-NEXT:    # kill: def $ymm0 killed $ymm0 killed $zmm0
----------------
spatel wrote:
> craig.topper wrote:
> > Do you have a plan to narrow the add here too?
> That's the goal, but I'm still not sure how many steps this is going to take. I'm imagining there are 5 groups of patches needed before we get there:
> 1. Allow undefs with splat matching.
> 2. Propagate more undefs with SimplifyDemandedVectorElts.
> 3. Call SimplifyDemandedVectorElts starting from more opcodes.
> 4. Add per-element demanded logic for more ops (example: add X, undef --> undef).
> 5. Add narrowing transforms.
This particular case (extract_subvector) should be easy. I thought I already had that 1 in IR...but it's not there either.


https://reviews.llvm.org/D52912





More information about the llvm-commits mailing list