Skip to content
This repository was archived by the owner on Jul 4, 2025. It is now read-only.

Commit 3c5c307

Browse files
authored
Merge pull request #312 from janhq/hotfix-high-cpu-usage
fix high cpu usage
2 parents e89a646 + 4bf641c commit 3c5c307

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

controllers/llamaCPP.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1537,6 +1537,7 @@ struct llama_server_context {
15371537
"cache\n");
15381538
kv_cache_clear();
15391539
}
1540+
std::this_thread::sleep_for(std::chrono::milliseconds(5));
15401541
// TODO: Need to implement queueing using CV for better performance
15411542
// std::unique_lock<std::mutex> lock(mutex_tasks);
15421543
// condition_tasks.wait(lock, [&] { return !queue_tasks.empty(); });

0 commit comments

Comments
 (0)