aboutsummaryrefslogtreecommitdiff
path: root/llvm/tools/llvm-objdump
diff options
context:
space:
mode:
authorYury Plyakhin <yury.plyakhin@intel.com>2026-02-11 10:21:22 -0800
committerGitHub <noreply@github.com>2026-02-11 10:21:22 -0800
commit81f445b7df94de485240b21034682f22432729c4 (patch)
tree8888877defebbabcc936e0977deeae5bc747bdae /llvm/tools/llvm-objdump
parent8c93fb0c05fc12b7f6bfa2b55b969d567aeb0537 (diff)
downloadllvm-81f445b7df94de485240b21034682f22432729c4.tar.gz
llvm-81f445b7df94de485240b21034682f22432729c4.tar.bz2
llvm-81f445b7df94de485240b21034682f22432729c4.zip
[clang-sycl-linker][offload] Set TheImageKind based on IsAOTCompileNeeded flag (#180269)
Previously, TheImageKind was set to IMG_None and relied on a runtime heuristic to determine the correct image type. This commit sets it explicitly to IMG_Object for AOT-compiled images and IMG_SPIRV for SPIR-V images based on the IsAOTCompileNeeded flag. Also it adds test for this change, which required minor changes in OffloadBinary and OffloadDump.
Diffstat (limited to 'llvm/tools/llvm-objdump')
-rw-r--r--llvm/tools/llvm-objdump/OffloadDump.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/llvm/tools/llvm-objdump/OffloadDump.cpp b/llvm/tools/llvm-objdump/OffloadDump.cpp
index a77537dd90ee..cd2727069c2e 100644
--- a/llvm/tools/llvm-objdump/OffloadDump.cpp
+++ b/llvm/tools/llvm-objdump/OffloadDump.cpp
@@ -36,6 +36,8 @@ static StringRef getImageName(const OffloadBinary &OB) {
return "fatbinary";
case IMG_PTX:
return "ptx";
+ case IMG_SPIRV:
+ return "spir-v";
default:
return "<none>";
}