diff options
author | Robin Watts <robin.watts@artifex.com> | 2015-01-05 11:36:35 +0000 |
---|---|---|
committer | Robin Watts <robin.watts@artifex.com> | 2015-01-05 13:52:08 +0000 |
commit | e460246943441078ff28dd413a19ee6f186c3764 (patch) | |
tree | 031c30e248e0c438af35be6bbfc74f4e2f5aaf80 /platform/windows/gsview/MainWindow.xaml.cs | |
parent | 15d7a79f92e3799d3db0b2b1c733635701da04d9 (diff) | |
download | mupdf-e460246943441078ff28dd413a19ee6f186c3764.tar.xz |
Another PDF Xref speedup from Malc.
Following the recent change to hold pdf xrefs in their native 'sparse'
representation, searching the xref takes longer.
Malc has investigated this slowdown and found that it can be largely
avoided by not searching the xref lists first. A modified version of
his first patch has gone in already (getting us from 10x slower to
just 5x slower).
This commit is a modified version of a second patch from him. Again
it works by avoiding searching the xref list twice. The original
version of this patch 1) appears broken to me, as it could return the
wrong xref entry when object streams have more than one object in them,
and 2) supposedly gets the speed back to the original 'pre-sparse change'
speed.
I have updated the patch to fix 1), and I hope this should not affect 2).
I am slightly suspicious that removing a search can get us a 5x speed
increase, but certainly this is an improvemnet.
There is scope for us further reducing the search times, by us using a
new table to map object number -> xref number, but unless we find a case
where we are noticably slower than before, I think we can ignore this.
Diffstat (limited to 'platform/windows/gsview/MainWindow.xaml.cs')
0 files changed, 0 insertions, 0 deletions