Skip to content
Snippets Groups Projects
  1. Oct 21, 2018
  2. Oct 19, 2018
    • Christian Persch's avatar
      glib: Only export symbols in the public API · 4ef2020d
      Christian Persch authored
      poppler-glib exported lots of internal C++ symbols
      that are not in the public API, nor have any ABI
      guarantees.
      
      Mark all public functions with POPPLER_PUBLIC, and
      use symbol visibility to hide everything else.
      4ef2020d
    • Christian Persch's avatar
      pdf-inspector: Link to the right libraries · 1d8df8e3
      Christian Persch authored
      pdf-inspector doesn't use libpoppler-glib, but linked to it.
      Changing it to link only to libpoppler revealed that it
      used lots of symbols from poppler-glib that poppler-glib
      should not export. Fix that by adding the necessary sources
      to the pdf-inspector sources and linking to the libraries
      needed by these sources (freetype, pthreads).
      1d8df8e3
    • Evangelos Rigas's avatar
      Add support for PDF subtype property (glib backend) · 20dfaa9e
      Evangelos Rigas authored
      Export PDFSubtype, PDFSubtypePart, and PDFSubtypeConformance
      to GLib as enums and add function to get the GTS string based
      on the PDF Subtype.
      
      Add PDF Subtype documentation reference in glib.
      20dfaa9e
  3. Oct 17, 2018
  4. Oct 16, 2018
  5. Oct 15, 2018
  6. Oct 12, 2018
    • StefanBruens's avatar
      SplashXPathScanner: Force inlining of addIntersection · a32fb958
      StefanBruens authored and Albert Astals Cid's avatar Albert Astals Cid committed
      The majority of the code in addIntersection can be optimized away for
      vertical (x0 == x1) and horizontal (count == 0) segments, thus the inlined
      code is less than the function call setup alone.
      This leaves diagonal segments as the only remaining call site, i.e.
      inlining here is a net win as well.
      
      Reduces runtime for #57 (fdo#96728, runsforever-poppler.pdf) from 1442 seconds
      to 1239 seconds (86%), and #24 (fdo#78728, surf-types.pdf) from ~ 5.0 seconds
      to 4.7 seconds.
      a32fb958
    • StefanBruens's avatar
      SplashXPathScanner: Move more invariant code out of the loop · 97f310b1
      StefanBruens authored and Albert Astals Cid's avatar Albert Astals Cid committed
      "seg->x0 - seg->y0 * seg->dxdy" is constant and can be moved out of the
      loop.
      The next start point is the old end point. Thus, only the new x coordinate
      has to clamped (segXMin <= xx1 <= segXMax), also do the 'floor' operation
      just once per loop.
      
      According to valgrind/callgrind, this reduces instruction count in
      computeIntersections() for #24 (fdo#78728) by 6%. No change for fdo#96728.
      97f310b1
    • StefanBruens's avatar
      SplashXPathScanner: Move invariant checks out of addIntersection loop · d8ba50c6
      StefanBruens authored and Albert Astals Cid's avatar Albert Astals Cid committed
      For horizontal segments, count is always 0. For vertical/diagonal segments,
      the count depends on the winding rule (EvenOdd/NonZero) and the direction,
      but is constant for each segment.
      
      Reduces runtime for #57 (fdo#96728) from 1773 seconds to 1442 seconds (81%).
      d8ba50c6
    • Tobias Deiminger's avatar
      Skip XRef reconstruction for new-style XRef streams · 5f817cb2
      Tobias Deiminger authored and Albert Astals Cid's avatar Albert Astals Cid committed
      XRef::constructXRef was invented to support old style XRef tables.
      Sadly it won't work for XRef streams. If applied anyway, it corrupts our
      existing XRef::entries array. Better skip reconstruction for the XRef-stream-case
      in XRef::readXRefUntil (just like XRef::fetch already does).
      
      Fixes #139.
      5f817cb2
  7. Oct 10, 2018
    • Adam Reichold's avatar
      Remove usage of pragmas interface and implementation · 7f20ace4
      Adam Reichold authored
      GCC recommends not using them for a long time and its documentation says:
      > These #pragmas have been superceded as of GCC 2.7.2 by COMDAT support
      > and the “key method” heuristic mentioned in Vague Linkage.
      > Using them can actually cause your program to grow due to
      > unnecessary out-of-line copies of inline functions.
      
      Also nobody seems to set USE_GCC_PRAGMAS and sometimes they were
      guarded by just __GNUC__ which upsets Clang.
      7f20ace4
  8. Oct 09, 2018
  9. Oct 08, 2018
  10. Oct 07, 2018
  11. Oct 06, 2018
  12. Oct 05, 2018
    • StefanBruens's avatar
      SplashXPathScanner: Reduce complexity of sorting spans · 0118e221
      StefanBruens authored and Albert Astals Cid's avatar Albert Astals Cid committed
      For complex paths, a significant amount of time is spent in
      SplashXPathScanner::computeIntersections, more specifically with
      sorting the spans in y/x order.
      
      Instead of using one large array for all spans, use a 2-dimensional
      structure.  As the number of y positions is known upfront, it is
      possible to create an array for the y dimension and insert the spans
      directly at the appropriate position.
      
      For Y rows with X spans per row, this reduces the complexity for sorting
      from O( Y*X log Y*X) to O( Y * X log X), i.e. a reduction by log Y.
      
      For the documents from #57 (fdo#96728) and #24 (fdo#78728), the
      runtime/memory is significantly reduced (according to /usr/bin/time -v):
      (1) $> pdftoppm -r 18 -aa no runsforever-poppler.pdf
      (2) $> pdftoppm surf-types.pdf
      
      Before/After
                                        runsforever-poppler |    surf-types
      User time (seconds):                2979.80 / 2348.08 |  9.45 /  7.76
      Maximum resident set size (kbytes):   51208 /   46288 | 18084 / 14076
      0118e221
    • StefanBruens's avatar
      SplashXPathScanner: Clamp y range to yMin/yMax outside the loop · 7ef04b56
      StefanBruens authored and Albert Astals Cid's avatar Albert Astals Cid committed
      Instead of implicitly clamping by setting interIdx == interEnd, calculate
      the first and last y position outside the loop, and use these as loop
      bounds.
      7ef04b56
    • StefanBruens's avatar
      SplashXPathScanner: Move state out of SplashXPathScanner for iterating spans · 68fdbfd0
      StefanBruens authored and Albert Astals Cid's avatar Albert Astals Cid committed
      Iterating through spans is independent of the spans itself. Moving the
      iteration to a seperate class allows to keep the iteration state out
      of SplashXPathScanner, and also allows to move invariant code out of
      getNextSpan(...).
      68fdbfd0
    • Albert Astals Cid's avatar
      GooList: Be a class again · 29bf8086
      Albert Astals Cid authored
      All the forward declarations we have are saying class and both MSVC and
      clang are unhappy about it
      29bf8086
    • Albert Astals Cid's avatar
      Fix Windows build · f3916132
      Albert Astals Cid authored
      f3916132
Loading