diff options
author | Ken Sharp <ken.sharp@artifex.com> | 2010-08-10 09:15:50 +0000 |
---|---|---|
committer | Ken Sharp <ken.sharp@artifex.com> | 2010-08-10 09:15:50 +0000 |
commit | 7594f0669e31dc308e21aae1731c36048c5175f1 (patch) | |
tree | 73d2e2d54e3e4b7d3fce6318d574ccd7d2151bba /xps/xpsgradient.c | |
parent | bbf706f769b87428abbd2c62e10dbb3b4ebe8b6a (diff) | |
download | ghostpdl-7594f0669e31dc308e21aae1731c36048c5175f1.tar.gz |
Enhancement : pdfwrite
performance enhancement for pdfwrite when handling files with large amounts of text.
Bug #689859 "Performance comparison versions 7.07 and 8.62 on HP-UX ia64" Alex's
analysis shows that pdfwrite was spending a lot of time trying to to see if two type 1
fonts were the same before deciding whether a glyph could be added to a font, or was
already present in a font copy.
Most of the time was spent extracting and comparing /Subrs. The new code creates a hash
(MD5) of both the local and global Subrs (if present) and stores that in the type 1
'data' field in the font (16 bytes). The hashes are created by pdfwrite only as they
are required, so there is no performance penalty for rendering. The hash comparison is
considerably quicker than the long winded Subrs comparison.
For many files the performance difference is minimal but for file containing lots of
pages, mostly composed of text, there is a considerable saving. The text files run in
about 60% of the time they did before this change.
Expected Differences
files 16-01.ps and 16-05.ps exhibit differences, I'm not sure why. However these are of
the 'wrong before, slightly differently wrong now' category, so I don't intend to
worry about these two files.
git-svn-id: http://svn.ghostscript.com/ghostscript/trunk@11618 a1074d23-0009-0410-80fe-cf8c14f379e6
Diffstat (limited to 'xps/xpsgradient.c')
0 files changed, 0 insertions, 0 deletions