subtree: add build targets 'man' and 'html'
[gitweb.git] / preload-index.c
index 71cd2437a3b33b343696bf96067603e8dc9e4464..f7365761f4725d6f7ddbb6d8c9c8fe92488de6ce 100644 (file)
@@ -78,7 +78,6 @@ static void preload_index(struct index_state *index,
 {
        int threads, i, work, offset;
        struct thread_data data[MAX_PARALLEL];
-       uint64_t start = getnanotime();
 
        if (!core_preload_index)
                return;
@@ -88,6 +87,7 @@ static void preload_index(struct index_state *index,
                threads = 2;
        if (threads < 2)
                return;
+       trace_performance_enter();
        if (threads > MAX_PARALLEL)
                threads = MAX_PARALLEL;
        offset = 0;
@@ -109,7 +109,7 @@ static void preload_index(struct index_state *index,
                if (pthread_join(p->pthread, NULL))
                        die("unable to join threaded lstat");
        }
-       trace_performance_since(start, "preload index");
+       trace_performance_leave("preload index");
 }
 #endif