Skip to content

How to know exactly what CPU dll is being loaded #147

Description

@FerLuisxd

I got paranoid as I didn't know what version was being loaded for the CPU backend

Proposed solution:

Allow for a way or function to get the selected CPU backend or print the evaluation.

What I found:

in:
transcribe.cpp\ggml\src\ggml-backend-reg.cpp

around lines ~524:

                    if (handle) {
                        auto score_fn = (ggml_backend_score_t) dl_get_sym(handle.get(), "ggml_backend_score");
                        if (score_fn) {
                            int s = score_fn();
                            if (s > 0) {
                                fprintf(stderr, "[ISA Probe] %s -> Score: %d (Supported)\n", path_str(entry.path().filename()).c_str(), s);
                            }
                            if (s > best_score) {
                                best_score = s;
                                best_path = entry.path();
                            }

Adding that print line to see the score if a debug parameter is passed.
So you can be sure that you are running the optimized one.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions