[Poppler-bugs] [Bug 7808] Speedup PDF loading by ~19%

bugzilla-daemon at annarchy.freedesktop.org bugzilla-daemon at annarchy.freedesktop.org
Sun Aug 13 20:03:16 PDT 2006


Please do not reply to this email: if you want to comment on the bug, go to    
       
the URL shown below and enter yourcomments there.     
   
https://bugs.freedesktop.org/show_bug.cgi?id=7808          
     

kkowalczyk at gmail.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|Speedup PDF loading by ~20% |Speedup PDF loading by ~19%




------- Additional Comments From kkowalczyk at gmail.com  2006-08-13 20:03 -------
I've created two new patches that, when combined, provide ~19% speed improvement
when loading PDFReference16.pdf document (PDF reference from Adobe website).

It cleans up previous patch and adds additional improvements.

Brief overview of changes:
* make GooString use internal buffer for short strings; re-factor GooString to
remove code duplication
* gfree() doesn't have to check for NULL pointer (C library does it anyway, it's
in the C ISO standard). gfree() is called so often that removing that check
improves the speed by 1%
* make UGooString use internal buffer as well; refactor the code to make it more
like GooString
* Parser::getObj(): make 'key' to be UGooString to avoid creating temporary
objects since dictAdd() uses UGooString as the argument
* Lexer::lookChar() and Lexer::getChar() - getChar() is often called right after
lookChar() (for about 30% of all getChar()s). Currently it has to re-do all the
work that lookChar() did. A very simple optimization is to cache the last value
of lookChar() and return it in getChar() if available.
* PageLabelInfo.cc: #include <config.h> since it's needed for compilation on Windows

Most of those changes reduce the number of malloc()/free() calls. There are
still ways to go.
          
     
     
--           
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email         
     
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.


More information about the Poppler-bugs mailing list