[PATCH] D18049: AMDGPU/SI: Make i16 a legal type for VI subtargets

Tom Stellard via llvm-commits llvm-commits at lists.llvm.org
Thu Oct 27 13:24:48 PDT 2016


tstellarAMD added inline comments.


================
Comment at: lib/Target/AMDGPU/BUFInstructions.td:962-963
+
+defm : MUBUFLoad_Pattern <BUFFER_LOAD_SBYTE_OFFSET, i16, sextloadi8_constant>;
+defm : MUBUFLoad_Pattern <BUFFER_LOAD_UBYTE_OFFSET, i16, az_extloadi8_constant>;
+defm : MUBUFLoad_Pattern <BUFFER_LOAD_SBYTE_OFFSET, i16, mubuf_sextloadi8>;
----------------
arsenm wrote:
> Originally I was avoiding these by promoting the load return type and truncating. Is this the same or is there an advantage from known bits types of things knowing it is really a 32-bit extload?
The main problem is that extload must be legal, so it's hard to custom lower all extloads.  I attempted to do this, and I think it would require a lot of work in the backend and also the legalizer to make this work.  I'm not sure it's worth the effort at this point.


https://reviews.llvm.org/D18049





More information about the llvm-commits mailing list