mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-07-21 08:01:31 +00:00
rocmPackages.rocm-comgr: fix failure to find code object when xnack any variant should match
Fixes No compatible code objects found for: gfx90a:sramecc+:xnack- in /nix/store/klazf7j7i5642cyjwi125fx4fdwx82f3-python3.13-torch-2.10.0-lib/lib/libtorch_hip.so, value of HIP_FORCE_SPIRV_CODEOBJECT: 0. Available code objects: [amdgcn-amd-amdhsa--gfx90a] Failed to load fat binary for function '_ZN2at6native29vectorized_elementwise_kernelILi4ENS0_11FillFunctorIiEESt5arrayIPcLm1EEEEviT0_T1_' (error 200)
This commit is contained in:
@@ -40,6 +40,9 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
url = "https://github.com/GZGavinZhao/rocm-llvm-project/commit/2c1e44fc3eacadcafdd4ada3e3184a092b6f26c5.patch";
|
||||
relative = "amd/comgr";
|
||||
})
|
||||
# Fix: CCOB compat patch used coerced (featureless) name for output filename,
|
||||
# causing CLR's code_obj_map key to miss when looking up device ISA with features
|
||||
./fix-ccob-compat-output-filename.patch
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
--- a/src/comgr-compiler.cpp
|
||||
+++ b/src/comgr-compiler.cpp
|
||||
@@ -1425,7 +1425,7 @@
|
||||
// Add an output file for each target
|
||||
SmallString<128> OutputFilePath = OutputDir;
|
||||
sys::path::append(OutputFilePath,
|
||||
- OutputPrefix + "-" + CompatEntry + "." + FileExtension);
|
||||
+ OutputPrefix + "-" + Entry + "." + FileExtension);
|
||||
|
||||
BundlerConfig.TargetNames.emplace_back(CompatEntry);
|
||||
BundlerConfig.OutputFileNames.emplace_back(OutputFilePath);
|
||||
Reference in New Issue
Block a user