[llvm-dev] accessing subwords in memory

Tom Stellard via llvm-dev llvm-dev at lists.llvm.org
Tue Jun 26 22:24:06 PDT 2018

On 06/26/2018 12:06 PM, Preston Briggs via llvm-dev wrote:
> I'm targeting a machine that can only load and store aligned 64-bit words,
> but I'd like to be able to pack 8-, 16-, and 32-bit values into these words.
> Loads will require various shifts and masks; stores are more complicated.
> Does LLVM provide any support for such things?
> Is there an example target I can look at for ideas?

The R600 subtarget in the AMDGPU backend does this with loads/stores for some
address spaces.  See R600TargetLowering::lowerPrivateExtLoad()
and R600TargetLowering::lowerPrivateTruncStore().


> Thanks,
> Preston
> _______________________________________________
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev

More information about the llvm-dev mailing list