Archived
- every model serves without a GPU: libavx covers every op, so `--kernels libavx` alone serves every shipped container - Qwen3-ASR (zivius): speech to text on /v1/audio/transcriptions and live over /v1/realtime - /v1/messages works with Claude Code as it ships (gearwave00001) - a long agent conversation keeps its cached history when the client rewrites its last turn (manueloverride) - a stream's first event goes out with the first token, so llama-benchy measures prefill right - opt-in --prefill-interleave (Smellyyyy, baKon) and --prefill-span (keptn42) - four-rank TP releases the link early; four-rank selftests and docs/TP4.md (goodman-b) - NVFP4 and FP8 compressed-tensors imports (devmilan); tools/rad-export for finetunes and LoRA adapters (baKon) - many fixes, among them lost tokens on stop strings under concurrency, keep-alive, MiniCPM5 tool arguments and the CPU's vision and audio encoders - plugin ABI 17 and changed op schemas: out-of-tree plugins must be rebuilt
34 lines
846 B
C++
34 lines
846 B
C++
/* rank_barrier.cpp -- see rank_barrier.h for why this is a condvar and not an IPC handshake. */
|
|
#include "rank_barrier.h"
|
|
|
|
namespace rad {
|
|
|
|
void RankBarrier::arrive_and_wait() {
|
|
std::unique_lock<std::mutex> lk(m_);
|
|
if (aborted_) return;
|
|
|
|
const uint64_t my_gen = gen_;
|
|
if (++waiting_ == n_) {
|
|
/* Last one in resets the counter and flips the generation, so a rank that re-enters at
|
|
* once waits on the new generation instead of racing through. */
|
|
waiting_ = 0;
|
|
++gen_;
|
|
lk.unlock();
|
|
cv_.notify_all();
|
|
return;
|
|
}
|
|
cv_.wait(lk, [&] { return aborted_ || gen_ != my_gen; });
|
|
}
|
|
|
|
void RankBarrier::abort() {
|
|
{
|
|
std::lock_guard<std::mutex> lk(m_);
|
|
aborted_ = true;
|
|
waiting_ = 0;
|
|
++gen_;
|
|
}
|
|
cv_.notify_all();
|
|
}
|
|
|
|
} /* namespace rad */
|