[llvm-commits] [llvm] r91614 - in /llvm/trunk: include/llvm/CodeGen/ValueTypes.h lib/CodeGen/SelectionDAG/LegalizeDAG.cpp

Duncan Sands baldrick at free.fr
Wed Jan 6 08:04:23 PST 2010


Hi Ken,

>> Perhaps I'm misunderstanding, but with this approach, wouldn't a store
>> of i64 with an alignment of 2 expand to two i24 stores and one i16 store
>> since the largest legal type of alignment 2 is i24? (Presumably the one
>> unaligned i24 store would need to be further expanded to an i16 and an
>> i8 store).
> 
> yes, but that's correct!  Remember I'm talking about *legal* types here,
> not simple types.  If the processor supports i24 stores and i16 stores,
> then storing two lots of i24 and one lot of i16 seems like a good thing
> to do.  Maybe it's best to check not that the type is legal, but that
> stores of the type are legal (since there might be i24 registers but
> no store operation for them).

I just realized that the second i24 store wouldn't be aligned, so indeed
something more sophisticated is needed here.

Ciao,

Duncan.



More information about the llvm-commits mailing list