MCPcopy Create free account
hub / github.com/Tiiny-AI/PowerInfer / sched_backend_prio

Function sched_backend_prio

ggml-backend.c:467–474  ·  view source on GitHub ↗

returns the priority of the backend, lower is better

Source from the content-addressed store, hash-verified

465
466// returns the priority of the backend, lower is better
467static int sched_backend_prio(ggml_backend_sched_t sched, ggml_backend_t backend) {
468 for (int i = 0; i < sched->n_backends; i++) {
469 if (sched->backends[i] == backend) {
470 return i;
471 }
472 }
473 return INT_MAX;
474}
475
476static int sched_allocr_prio(ggml_backend_sched_t sched, ggml_tallocr_t allocr) {
477 for (int i = 0; i < sched->n_backends; i++) {

Calls

no outgoing calls

Tested by

no test coverage detected