generate: decode_defaults_arch_ok() (gfx1200/gfx1201 on HIP, always on CUDA) for the HIP decode defaults
This commit is contained in:
1 parent
6ab541f625
commit
606eb1080c
1 file changed
+14
@@ -36,6 +36,7 @@
|
||||
#include "strata/core/layout.hpp"
|
||||
#include "strata/core/session.hpp"
|
||||
#include "strata/core/weights.hpp"
|
||||
#include "strata/kernels/gfx_arch.hpp"
|
||||
#include "strata/kernels/cpu/expert.hpp"
|
||||
#include "strata/kernels/cpu/pool.hpp"
|
||||
#include "strata/platform/aux_cpus.hpp"
|
||||
@@ -1534,6 +1535,19 @@ bool load_control_vectors(const Options& o, const strata::core::ModelGeometry& g
|
||||
return true;
|
||||
}
|
||||
|
||||
// 0.1.43: the HIP defaults of the decode speed push (route tail skip, measured PCIe share) were measured on gfx1201 (Radeon AI PRO
|
||||
// R9700) and apply on gfx1200 / gfx1201 only; every other AMD part (gfx11, gfx906, ...) keeps its earlier behaviour. CUDA: always true.
|
||||
[[maybe_unused]] static bool decode_defaults_arch_ok() {
|
||||
#if defined(STRATA_USE_HIP)
|
||||
int dev = 0;
|
||||
cudaDeviceProp p{};
|
||||
return cudaGetDevice(&dev) == cudaSuccess && cudaGetDeviceProperties(&p, dev) == cudaSuccess &&
|
||||
strata::kernels::gfx_arch_is_gfx12_wmma(p.gcnArchName);
|
||||
#else
|
||||
return true;
|
||||
#endif
|
||||
}
|
||||
|
||||
// The effective host->device bandwidth of the PCIe link: copies from pinned host memory, as the expert arena's
|
||||
// reads are. The native default share (0.55) was measured on x16 links (~26-28 GB/s); a x8 card in a x8 slot
|
||||
// carries about half of that. Returns < 0 when the probe cannot run (then the caller keeps the default).
|
||||
|
||||
Reference in new issue
Block a user