Qwen3.8-Flash-Next on any consumer hardware: one-click install for Windows / Linux. Strata inference engine, OpenAI/Anthropic API on localhost, optional image input.
C++
fix: list the pool's own worker cores for the start-up line and --aux-cpus under the NUMA split
Baptiste Rajaut2614b82c9a87
diff --git a/include/strata/kernels/cpu/pool.hpp b/include/strata/kernels/cpu/pool.hppindex 9dcb349bd..98320a925 100644--- a/include/strata/kernels/cpu/pool.hpp+++ b/include/strata/kernels/cpu/pool.hpp@@ -209,6 +209,8 @@ public:bool host_works() const { return host_works_; }bool is_hybrid() const { return topo_.is_hybrid; }+ /// The CPUs worker i is pinned to, in worker order (STRATA_NUMA_SPLIT reorders them: interleave_packages).+ const std::vector<int>& worker_cores() const { return topo_.worker_cores; }int p_cores() const { return topo_.p_cores; }int p_threads() const { return topo_.p_threads; }int e_cores() const { return topo_.e_cores; }diff --git a/src/program/generate.cpp b/src/program/generate.cppindex 427957b9d..7366427a0 100644--- a/src/program/generate.cpp+++ b/src/program/generate.cpp@@ -5835,9 +5835,11 @@ int main(int argc, char** argv) {}{ // where the threads run (--host-core)const strata::kernels::cpu::CpuTopology ht = strata::kernels::cpu::detect_cpu_topology(true, o.pool_affinity);+ // the pool's own order, not a fresh detection's: STRATA_NUMA_SPLIT interleaves the sockets+ const std::vector<int>& wc = pool.worker_cores();std::string on;- for (int i = 0; i < pool.workers() && i < (int) ht.worker_cores.size(); ++i)- on += (i > 0 ? "," : "") + std::to_string(ht.worker_cores[(size_t) i]);+ for (int i = 0; i < pool.workers() && i < (int) wc.size(); ++i)+ on += (i > 0 ? "," : "") + std::to_string(wc[(size_t) i]);std::fprintf(stderr, "strata generate: %d pool workers on logical processors %s, the host thread on %d%s ""(--host-core %s)\n", pool.workers(), on.c_str(), ht.host_core,pool.host_works() ? " (draining too)" : "",@@ -5846,10 +5848,9 @@ int main(int argc, char** argv) {: "first");// --aux-cpus: the plan, now the workers' CPUs are known; the threads that exist already (the CUDA driver's) move// now when it is on, the ones created later pin themselves (strata/platform/aux_cpus.hpp)- const size_t nw = std::min<size_t>((size_t) pool.workers(), ht.worker_cores.size());+ const size_t nw = std::min<size_t>((size_t) pool.workers(), wc.size());std::fprintf(stderr, "%s\n",- strata::aux_cpus::set_topology(ht.host_core, std::vector<int>(ht.worker_cores.begin(),- ht.worker_cores.begin() + (long) nw)).c_str());+ strata::aux_cpus::set_topology(ht.host_core, std::vector<int>(wc.begin(), wc.begin() + (long) nw)).c_str());}if (o.no_ple_prefetch) strata::kernels::ple_prefetch_enable(false);// ---- R4's slot storage. Allocated AFTER the weights and the session, so `cudaMemGetInfo` inside `open`