diff options
author | Tay Ray Chuan <rctay89@gmail.com> | 2011-08-17 09:53:57 +0800 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2011-08-17 17:15:05 -0700 |
commit | 27af01d552331eacf1ed2671b2b4b6ad4c268106 (patch) | |
tree | f74cdcae565bca29ad0ee78fb539d4e4df50738d /t/t5100/rfc2047-info-0009 | |
parent | Sync with "maint" (diff) | |
download | tgif-27af01d552331eacf1ed2671b2b4b6ad4c268106.tar.xz |
xdiff/xprepare: improve O(n*m) performance in xdl_cleanup_records()
In xdl_cleanup_records(), we see O(n*m) performance, where n is the
number of records from xdf->dstart to xdf->dend, and m is the size of a
bucket in xdf->rhash (<= by mlim).
Here, we improve this to O(n) by pre-computing nm (in rcrec->len(1|2))
in xdl_classify_record().
Reported-by: Marat Radchenko <marat@slonopotamus.org>
Signed-off-by: Tay Ray Chuan <rctay89@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t5100/rfc2047-info-0009')
0 files changed, 0 insertions, 0 deletions