[PATCH] D57247: Simply operands of masked stores and scatters based on demanded elements

Simon Pilgrim via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Jan 26 03:01:27 PST 2019


RKSimon added a comment.

In D57247#1371663 <https://reviews.llvm.org/D57247#1371663>, @reames wrote:

> In D57247#1371550 <https://reviews.llvm.org/D57247#1371550>, @RKSimon wrote:
>
> > Would it be better to put this inside InstCombiner::SimplifyDemandedVectorElts so we can also simplify the mask based on the demanded elts from its user(s)?
>
>
> Is that idiomatic for a void result instruction?  I thought SimplifyDemandedVectorElts expected to be given a value of vector type?


*facepalm* sorry, my brain was in Friday mode and I was thinking gathers/masked-loads.....

I agree some kind of helper function that can extract vector values from various Constant vector forms would be useful - they do keep turning up in code in various guises (and if you do gathers/maskedloads you'll be duplicating the code yet again!).


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D57247/new/

https://reviews.llvm.org/D57247





More information about the llvm-commits mailing list