1
0
mirror of https://github.com/moparisthebest/pacman synced 2025-03-03 02:41:53 -05:00
Dan McGee b221af660d Database read optimizations
Hard to believe there was still more room to improve on this, but I
found an easily correctable oversight tonight. Our databases (both sync
and local) contain many blank lines, and we were not moving onto the
next line right away in these cases; instead we would proceed through
our strcmp() conditional checks as normal.

Some local numbers follow to show the effects of this patch:

Sync `-Ss foobarbaz`:
71,709 blank lines skipped early
~1,505,889 strcmp() calls avoided (21 per line)
~15% speed improvement (.210 --> .179 sec)

Local `-Qs foobarbaz`:
6,823 blank lines skipped early
115,991 strcmp() calls avoided (17 per line)
~6% speed improvement (.080 -> .071 sec)

Signed-off-by: Dan McGee <dan@archlinux.org>
2011-08-28 23:49:27 -05:00
..
2011-08-19 11:09:57 -05:00
2011-06-28 14:04:00 +10:00
2011-07-02 02:01:39 +10:00
2011-08-28 23:41:17 -05:00
2011-08-15 06:24:49 -05:00
2011-08-15 06:24:49 -05:00
2011-08-28 23:49:27 -05:00
2011-08-28 23:49:27 -05:00
2011-08-18 10:47:41 -05:00
2011-06-28 23:28:23 +10:00
2011-06-28 14:04:00 +10:00
2011-06-28 23:28:24 +10:00
2011-06-28 23:28:24 +10:00
2011-07-18 21:06:24 -05:00
2011-07-02 02:01:39 +10:00
2011-06-28 23:28:24 +10:00
2011-08-28 23:41:17 -05:00
2011-06-28 23:28:24 +10:00
2011-06-28 23:28:24 +10:00
2011-07-05 22:36:40 -05:00
2011-07-06 09:26:09 -05:00
2011-08-28 19:52:10 -05:00
2011-06-28 14:04:00 +10:00
2011-08-15 12:13:35 -05:00