From da1889834a036a63ead2b0ca5c9ed8967712568c Mon Sep 17 00:00:00 2001 From: slaren Date: Tue, 25 Jul 2023 14:32:20 +0200 Subject: ggml : improve graph build time via hash table lookup (#2329) * improve graph build time * ggml_tensor : use 1 bit per flag * use a hash table instead --- llama.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'llama.cpp') diff --git a/llama.cpp b/llama.cpp index 2d737bb..febefba 100644 --- a/llama.cpp +++ b/llama.cpp @@ -1714,6 +1714,8 @@ static bool llama_eval_internal( // run the computation ggml_build_forward_expand(&gf, cur); + // fprintf(stderr, "graph build time: %.3f ms (%d nodes, %d leafs)\n", (ggml_time_us() - t_start_us)/1000.0, gf.n_nodes, gf.n_leafs); + #if GGML_USE_MPI ggml_mpi_graph_compute_pre(lctx.ctx_mpi, &gf, n_layer); #endif -- cgit v1.2.3