[llvm] [libsycl] Introduce Kernel name based cache (PR #225865)
via llvm-commits
llvm-commits at lists.llvm.org
Thu Oct 1 05:26:43 PDT 2026
================
@@ -185,8 +202,10 @@ ol_symbol_handle_t ProgramAndKernelManager::getOrCreateKernel(
trackContext(Context);
// Lock order is MDataCollectionMutex -> ContextImpl::MProgramCacheMutex.
- return Context->getOrCreateKernel(DeviceImage, Device.getOLHandle(),
- KernelInfo.getName());
+ ol_symbol_handle_t Kernel = Context->getOrCreateKernel(
----------------
Robertkq wrote:
Yes, this would be reached whenever two kernels from the same device image are submitted to the same `(context, device)`. Say `KernelA` and `KernelB` are from the same Image, submitting `KernelA` builds the program for and caches `KernelA`'s symbol, submitting `KernelB` is a miss for it's cache, so it still needs to find built program and lookup the symbol, once that is found, it is also cached. The cache only skips repeat lookups of the same kernel, it does not change the "get" branch fires for two different kernels from the same image.
Hope that I understood the question and responded well, any follow up is welcome if needed
https://github.com/llvm/llvm-project/pull/225865
More information about the llvm-commits
mailing list