René Scharfe
66e2adb8f6
describe: use prio_queue
...
Replace the use a list-based priority queue whose order is maintained by
commit_list_insert_by_date() with a prio_queue. This avoids quadratic
worst-case complexity. And in the somewhat contrived example of
describing the 4751 commits from v2.41.0 to v2.47.0 in one go (to get a
sizable chunk of describe work with minimal ref loading overhead) it's
significantly faster:
Benchmark 1: ./git_2.50.1 describe $(git rev-list v2.41.0..v2.47.0)
Time (mean ± σ): 1.558 s ± 0.002 s [User: 1.492 s, System: 0.051 s]
Range (min … max): 1.557 s … 1.562 s 10 runs
Benchmark 2: ./git describe $(git rev-list v2.41.0..v2.47.0)
Time (mean ± σ): 1.209 s ± 0.006 s [User: 1.143 s, System: 0.051 s]
Range (min … max): 1.201 s … 1.219 s 10 runs
Summary
./git describe $(git rev-list v2.41.0..v2.47.0) ran
1.29 ± 0.01 times faster than ./git_2.50.1 describe $(git rev-list v2.41.0..v2.47.0)
Signed-off-by: René Scharfe <l.s.r@web.de >
Signed-off-by: Junio C Hamano <gitster@pobox.com >
2025-08-03 09:13:27 -07:00
..
2025-05-27 13:59:09 -07:00
2025-07-16 09:42:28 -07:00
2024-10-25 14:02:36 -04:00
2025-07-01 14:58:24 -07:00
2024-10-11 09:37:18 -07:00
2025-07-01 14:46:38 -07:00
2024-12-06 20:20:02 +09:00
2025-07-01 14:46:37 -07:00
2025-01-29 14:05:09 -08:00
2025-04-15 08:24:35 -07:00
2024-12-13 07:33:36 -08:00
2025-07-15 15:18:18 -07:00
2024-09-13 14:32:24 -07:00
2024-09-13 14:32:24 -07:00
2025-02-21 18:27:16 -08:00
2025-01-17 13:30:03 -08:00
2025-01-17 13:30:03 -08:00
2025-03-07 16:52:02 -08:00
2025-07-15 15:18:18 -07:00
2024-12-06 20:20:02 +09:00
2025-07-01 14:46:38 -07:00
2025-04-17 08:15:16 -07:00
2025-07-15 15:18:18 -07:00
2025-07-01 14:46:35 -07:00
2025-07-16 08:25:17 -07:00
2025-07-01 10:28:48 -07:00
2025-07-01 14:46:36 -07:00
2025-04-15 08:24:35 -07:00
2024-11-01 12:53:19 -04:00
2024-09-13 14:32:24 -07:00
2025-01-28 13:02:22 -08:00
2025-08-03 09:13:27 -07:00
2025-04-15 08:24:35 -07:00
2025-01-17 13:30:03 -08:00
2025-01-17 13:30:03 -08:00
2025-03-03 08:17:47 -08:00
2025-01-17 13:30:03 -08:00
2025-07-21 09:14:25 -07:00
2025-07-01 14:46:38 -07:00
2025-07-23 15:45:16 -07:00
2025-07-23 15:45:16 -07:00
2025-06-04 08:52:25 -07:00
2025-07-16 09:42:27 -07:00
2025-04-17 08:15:15 -07:00
2025-03-07 16:52:02 -08:00
2024-12-06 20:20:04 +09:00
2025-07-01 14:46:38 -07:00
2025-01-17 13:30:03 -08:00
2025-08-01 11:27:11 -07:00
2025-01-17 13:30:03 -08:00
2025-07-01 14:46:39 -07:00
2025-07-21 09:14:25 -07:00
2024-12-18 10:44:30 -08:00
2024-11-26 10:36:08 +09:00
2025-07-21 09:14:25 -07:00
2025-04-24 17:25:34 -07:00
2024-10-14 12:33:02 -04:00
2025-08-01 11:27:11 -07:00
2025-07-01 14:46:37 -07:00
2025-07-01 14:58:24 -07:00
2025-07-01 14:46:37 -07:00
2024-12-18 10:44:31 -08:00
2025-01-17 13:30:03 -08:00
2024-12-27 08:12:40 -08:00
2025-07-01 14:46:34 -07:00
2025-01-17 13:30:03 -08:00
2025-01-17 13:30:03 -08:00
2025-04-08 13:59:11 -07:00
2025-07-01 14:46:38 -07:00
2025-06-13 11:54:14 -07:00
2025-07-15 15:18:18 -07:00
2025-07-01 14:46:37 -07:00
2025-07-01 14:46:34 -07:00
2025-05-08 12:36:32 -07:00
2025-04-15 13:50:15 -07:00
2025-07-01 14:46:38 -07:00
2025-07-21 09:14:26 -07:00
2025-07-15 15:18:18 -07:00
2025-03-07 16:52:01 -08:00
2025-07-01 14:58:24 -07:00
2024-09-13 14:33:30 -07:00
2025-07-15 15:18:18 -07:00
2025-08-01 11:27:14 -07:00
2025-02-04 09:51:41 -08:00
2024-12-23 09:32:17 -08:00
2025-04-17 08:15:15 -07:00
2025-07-09 08:39:46 -07:00
2025-07-21 09:14:25 -07:00
2025-07-22 16:34:11 -07:00
2025-03-26 16:26:10 +09:00
2025-01-17 13:30:03 -08:00
2025-01-17 13:30:03 -08:00
2025-07-21 09:14:26 -07:00
2025-07-21 09:14:26 -07:00
2025-07-01 14:46:37 -07:00
2025-06-05 08:35:22 -07:00
2025-02-28 13:54:11 -08:00
2025-05-16 12:02:47 -07:00
2025-08-01 11:27:11 -07:00
2025-02-28 13:54:11 -08:00
2025-04-24 17:25:34 -07:00
2025-03-29 01:04:40 -07:00
2025-07-07 14:12:57 -07:00
2025-07-21 09:14:25 -07:00
2025-04-29 14:21:28 -07:00
2025-07-01 14:58:24 -07:00
2025-07-01 14:46:38 -07:00
2025-04-15 08:24:35 -07:00
2025-06-30 14:30:31 -07:00
2024-09-13 14:32:24 -07:00
2025-07-15 15:18:18 -07:00
2024-09-13 14:32:24 -07:00
2025-07-01 14:46:38 -07:00
2025-07-01 14:46:38 -07:00
2025-07-01 14:46:38 -07:00
2025-07-09 08:39:26 -07:00
2025-05-19 11:06:31 -07:00
2025-04-08 14:47:37 -07:00
2025-01-17 13:30:03 -08:00
2024-12-18 10:44:30 -08:00
2025-01-28 13:02:22 -08:00
2025-03-07 16:52:01 -08:00
2024-09-13 14:32:24 -07:00
2025-03-07 16:52:01 -08:00
2025-06-17 10:44:40 -07:00
2025-07-09 08:39:28 -07:00