mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[PR #4691] [Engine] fix Windows HIP long-path loading #5138
Labels
No labels
needs-format
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Niko1221/Strata#5138
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Niko1221/Strata/pull/4691
Author: @tobitege
Created: 10/30/2026
Status: 🔄 Open
Base:
main← Head:codex/fix-windows-hip-long-paths📝 Commits (1)
bf3ef25[Engine] fix Windows HIP long-path loading📊 Changes
3 files changed (+16 additions, -0 deletions)
View changed files
📝
cmake/hip_backend.cmake(+11 -0)📝
cmake/strata-utf8.manifest(+1 -0)📝
src/kernels/hc_persist_parity.cpp(+4 -0)📄 Description
Problem and result
On Windows, a HIP engine installed under a long directory can fail to load hipBLASLt's Tensile kernel files and crash in
getAlgosFromIndex. This was reproduced on Radeon 8065S / gfx1151 with ROCm 10.2.0a20260930, hipBLASLt 1.5.0 and the packaged gfx1151 tuning table. Windows long paths were already enabled.The original test executable passed from a short directory but failed when the Tensile file path reached 273 characters, using the same ROCm DLLs and tuning table. With this patch, the native test passed at the same long installed path: all four numerical checks passed, with four tuned launches and zero fallbacks.
Related discussion
None. Open and closed issues and PRs were searched for
longPathAwareand"long path" HIP; no matching discussion was found.Approach
The Windows HIP build uses clang's GNU-style driver, so the existing MSVC-only manifest handling does not apply. Embed the Windows manifest through a HIP interface target and add
longPathAwarealongside the existing UTF-8 setting. Track the manifest as a link dependency so changes trigger relinking.The regular Windows HIP test build also exposed POSIX-only
setenv/unsetenvcalls inhc_persist_parity. Use_putenv_son Windows so that test compiles. No kernel algorithm or tuning-table entries change.Validation
Local results were produced on Windows with Radeon 8065S / gfx1151, Adrenalin 26.10.1 and ROCm 10.2.0a20260930. The tested patch on base
870aedd9is committed asbf3ef258. The following CI runs use that exact commit.Passed:
tools\hip\build_windows.bat tests, withSTRATA_HIP_ARCHS=gfx1151: engine, native test executables, CPU/HIP vision readers and package built successfully.hip_prefill_hipblaslt_gemm.exeat the original long installed path with the gfx1151 table enabled: four cases passed,launches=4 fallbacks=0. Before the patch, the same installed-path replay reportedFailed to open fileand exited with0xC0000005inside the bundled Tensile/hipBLASLt libraries.hip_prefill_gemm,hip_prefill_wmma_gemm_parity,hip_prefill_hipblaslt_gemm,hc_persist_parityandhc_persist_default_off: all five passed.npm run typecheckpassed. All 29 tests intests/terminal/test_hipblaslt_tuning.pypassed as part of the full Python run below.Failed:
ctest --test-dir build-hip-win --output-on-failure --timeout 120 --output-junit <report>: 158 passed, eight failed, eight skipped. Failures:vmm_test,hip_handoff,native_grouped_parity,ple_parity,conversation_copy_streams_test,hip_prefill_mmq_parity,expert_parityandpool_test. Some require unavailable model fixtures;hip_prefill_mmq_paritycrashed. These native failures have not been compared with an unmodified upstream build, so their regression status remains unverified.python -m pytest tests/terminal tests/tuning -ra --junitxml=<report>: 2,222 passed, 18 failed, 70 skipped. Two failing cases passed after correcting the test environment. A subsequent comparison of the 18 original cases with the same Python environment produced 16 failures on unmodifiedupstream/main(870aedd9) and 15 on this patch. Every failure in the patched comparison also failed upstream; one additional upstream failure did not reproduce in the patched focused run. This is a focused comparison, not a second full-suite pass.npm test: 1,120 passed, 25 failed, 102 skipped. Hanging test workers were stopped after recording their state. No full upstream comparison was completed for these host failures.tools/test_setup_*.pyscript separately left four failing suites after an environment correction:test_setup_download.py,test_setup_dsv41.py,test_setup_golden.pyandtest_setup_unsloth.py. All four also failed in the unmodified upstream checkout. Their causes are not resolved here.Not run:
Limits
The installed-path check covers four cases using two of the tuning table's 32 rows. It does not validate every solution ID. The broader local suite is not green, and the CI workflows do not cover all host or native HIP tests.
This PR contains only the three code files for the Windows HIP fix. The benchmark report, measurements and unrelated test repairs are excluded. No performance claim is made.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.