[PATCH] D57449: GlobalISel: Add alignment to LegalityQuery MMOs

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 30 08:05:10 PST 2019


arsenm added a comment.

In D57449#1377155 <https://reviews.llvm.org/D57449#1377155>, @Petar.Avramovic wrote:

> Hi, this rule will be very useful for mips32r5 that only supports naturally aligned loads and stores. 
>  However, could we have additional structure named TypeMemAndAlignDesc (or something more appropriate) and rule that uses this structure named legalForTypesWithMemSizeAndAlign instead of changing already existing ones.
>  This would leave TypePairAndMemSize and typePairAndMemSizeInSet to be used as is, since alignment is not considered on some targets/subtargets (like mips32r6). There are rules that do not take memsize into account (like LegalFor or legalForCartesianProduct).


I would think having fewer versions with all the necessary information would be better. The memory instructions are already special since they care about something besides the operand types. Also, this isn't the only addition I want to make here. I'll probably want to add the MMO flags here at some point, and wouldn't want to introduce a 3rd set of these


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

https://reviews.llvm.org/D57449





More information about the llvm-commits mailing list