From a808b70a5133ddeca5a9d1d4a4fb19d7314f1ba9 Mon Sep 17 00:00:00 2001 From: talubik Date: Thu, 19 Mar 2026 15:54:21 +0300 Subject: [PATCH] fix: local args --- lib/CL/devices/vortex/vortex_utils.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/CL/devices/vortex/vortex_utils.cc b/lib/CL/devices/vortex/vortex_utils.cc index 1877d2242..326ff3293 100644 --- a/lib/CL/devices/vortex/vortex_utils.cc +++ b/lib/CL/devices/vortex/vortex_utils.cc @@ -146,11 +146,12 @@ static bool createArgumentsBuffer(llvm::Function *function, llvm::Module *module allocated_local_mem = Builder.CreateCall(vx_local_alloc_func, {local_size}, "__local_mem"); } // Load argument __offset + auto ArgOffset = llvm::ConstantInt::get(I32Ty, arg_offset); auto offset_ptr = Builder.CreateGEP(I8Ty, ArgBuffer, ArgOffset, OldArg.getName() + "_offset_ptr"); auto offset = Builder.CreateLoad(I32Ty, offset_ptr, OldArg.getName() + "_offset"); arg_offset = ALIGN_OFFSET(arg_offset + 4, BaseAlignment); // Apply pointer offset - Arg = Builder.CreateGEP(I8PtrTy, allocated_local_mem, offset, OldArg.getName() + "_byte_ptr"); + Arg = Builder.CreateGEP(I8Ty, allocated_local_mem, offset, OldArg.getName() + "_byte_ptr"); } else { auto offset_ptr = Builder.CreateGEP(I8Ty, ArgBuffer, ArgOffset, OldArg.getName() + "_offset_ptr"); Arg = Builder.CreateLoad(ArgType, offset_ptr, OldArg.getName() + "_loaded");