[llvm] [Offload] Erase entries from JIT cache when program is destroyed (PR #148847)
Ross Brunton via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 15 07:24:56 PDT 2025
================
@@ -285,8 +285,8 @@ JITEngine::compile(const __tgt_device_image &Image,
// Check if we JITed this image for the given compute unit kind before.
ComputeUnitInfo &CUI = ComputeUnitMap[ComputeUnitKind];
- if (__tgt_device_image *JITedImage = CUI.TgtImageMap.lookup(&Image))
----------------
RossBrunton wrote:
The data Image points to happens to be inside `ol_program_impl_t`, but something similar to this:
```c++
Image *MyImage = new Image();
delete MyImage;
Image *MyImage2 = new Image();
// MyImage may equal MyImage2
```
https://github.com/llvm/llvm-project/pull/148847
More information about the llvm-commits
mailing list