HIP: RDNA4 gfx1201 beside gfx1100; the startup check compares the card with the compiled archs; setup picks ROCm and the hipBLASLt table per arch
- CMake: CMAKE_HIP_ARCHITECTURES may list gfx1100 and gfx1201 (validated) and gfx1101 / gfx1102 / gfx1200 (build with a warning: same wave32, 64 KiB LDS and dot4, not run by us; #192, #176). The list reaches the code as STRATA_HIP_ARCHS. - Runtime: the engine (every GPU a run uses) and strata-device compare the card's gcnArchName (up to the ':' feature suffix) with the compiled archs and require wave32, with a message naming the card, its arch and the build's archs, instead of a later "invalid device function". - __dp4a uses __builtin_amdgcn_sudot4 (v_dot4_i32_iu8) on all five archs; the portable fallback stays for other compilers/targets. - setup.py: AMD_ARCHS gfx1100 + gfx1201; TheRock's wheel index per GPU family (gfx110X-dgpu, gfx120X-all; the pinned 7.10.0a20251120 is on both), only that family's libraries on the path, reinstall when the family changes; a system ROCm older than 7.0 is passed over for the wheels; the engine is rebuilt when the chosen card's arch is not in its BUILD.json. The hipBLASLt table is tools/hip/<arch>-hipblaslt-<version>.txt for the card's arch AND the installed hipBLASLt (read from hipblaslt-version.h, 1.4.1 -> 100401), else none with a message; before, the highest-named table of the arch was taken whatever the installed version, which the engine then refused.
This commit is contained in:
1 parent
ca574a27ad
commit
862c5a4767
10 files changed
+227
-47
No files matched your search
@@ -14,6 +14,7 @@
|
||||
// AND IT IS PHASE 2, so hit rate is `h = 0` and the number it prints is slow on purpose
|
||||
// (`phase-2-correct-engine.md:5-9`). What it is FOR is the honest tok/s figure and the logit dump.
|
||||
|
||||
#include "strata/core/device.hpp"
|
||||
#include "strata/core/expert_cache.hpp"
|
||||
#include "strata/core/expert_source.hpp"
|
||||
#include "strata/core/remote_experts.hpp"
|
||||
@@ -1179,6 +1180,22 @@ int main(int argc, char** argv) {
|
||||
std::fprintf(stderr, "strata generate: layer split across %zu GPUs: CUDA0, then CUDA%s (split %s)\n",
|
||||
split_devs.size() + 1, devs.c_str(), o.layer_split.c_str());
|
||||
}
|
||||
#if defined(STRATA_USE_HIP)
|
||||
{
|
||||
// every GPU this run uses must be an architecture the binary has code for (a gfx1100 build on a gfx1201
|
||||
// card would otherwise fail later with "invalid device function")
|
||||
std::vector<int> used{0};
|
||||
if (multi_gpu) used.insert(used.end(), split_devs.begin(), split_devs.end());
|
||||
for (int r = 0; r < 3; ++r)
|
||||
if (o.expert_cache_remote[(size_t) r] > 0) used.push_back(remote_dev[r]);
|
||||
for (const int d : used) {
|
||||
if (const std::string why = strata::core::gpu_arch_problem(d); !why.empty()) {
|
||||
std::fprintf(stderr, "strata generate: %s\n", why.c_str());
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
if (o.prefill_auto && (o.no_prefill_borrow || o.expert_profile.empty())) {
|
||||
o.prefill_auto = false; // nothing to lend from: the buffers are reserved for the session, so keep them small
|
||||
o.prefill_chunk = 2048;
|
||||
|
||||
Reference in new issue
Block a user