llama : fix invalid assert in recurrent memory (#29799)

This commit is contained in:
Georgi Gerganov
2026-10-01 14:49:03 +03:00
committed by GitHub
parent b56f34ab13
commit 869034b4bb
+3 -2
View File
@@ -731,8 +731,9 @@ bool llama_memory_recurrent::get_can_shift() const {
}
bool llama_memory_recurrent::is_empty() const {
assert(total_size() == 0);
return ctxs_bufs.empty();
const bool res = ctxs_bufs.empty();
assert(!res || total_size() == 0);
return res;
}
size_t llama_memory_recurrent::total_size() const {