[llvm] [AMDGPU] Support i8/i16 GEP indices when promoting allocas to vectors (PR #175489)

Matt Arsenault via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 20 09:36:28 PST 2026


================
@@ -489,6 +490,9 @@ static Value *calculateVectorIndex(Value *Ptr, AllocaAnalysis &AA) {
       Result = I->second.VarIndex;
       Result = B.CreateSExtOrTrunc(Result, B.getInt32Ty());
 
+      if (I->second.VarShift)
+        Result = B.CreateAShr(Result, I->second.VarShift);
----------------
arsenm wrote:

You should know this is exact 

https://github.com/llvm/llvm-project/pull/175489


More information about the llvm-commits mailing list