[llvm] [offload] Fix build with debug libomptarget (PR #159144)

via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 16 11:23:54 PDT 2025


llvmbot wrote:


<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-offload

Author: Nick Sarnie (sarnex)

<details>
<summary>Changes</summary>

Currently get this error
```
offload/plugins-nextgen/common/src/PluginInterface.cpp:859:63: error: member reference type 'StringRef' is not a pointer; did you mean to use '.'?
```

We pass the full image binary now so we can't really print anything useful here.

Seems introduced in https://github.com/llvm/llvm-project/pull/158748.

---
Full diff: https://github.com/llvm/llvm-project/pull/159144.diff


1 Files Affected:

- (modified) offload/plugins-nextgen/common/src/PluginInterface.cpp (+1-1) 


``````````diff
diff --git a/offload/plugins-nextgen/common/src/PluginInterface.cpp b/offload/plugins-nextgen/common/src/PluginInterface.cpp
index 4f83caf7a1187..684deb19b4eda 100644
--- a/offload/plugins-nextgen/common/src/PluginInterface.cpp
+++ b/offload/plugins-nextgen/common/src/PluginInterface.cpp
@@ -856,7 +856,7 @@ Error GenericDeviceTy::deinit(GenericPluginTy &Plugin) {
 }
 Expected<DeviceImageTy *> GenericDeviceTy::loadBinary(GenericPluginTy &Plugin,
                                                       StringRef InputTgtImage) {
-  DP("Load data from image " DPxMOD "\n", DPxPTR(InputTgtImage->ImageStart));
+  DP("Load data from image\n");
 
   std::unique_ptr<MemoryBuffer> Buffer;
   if (identify_magic(InputTgtImage) == file_magic::bitcode) {

``````````

</details>


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


More information about the llvm-commits mailing list