Summary: | pdftoppm: out of memory; tries to allocate huge bitmap | ||
---|---|---|---|
Product: | poppler | Reporter: | Jakub Wilk <jwilk> |
Component: | splash backend | Assignee: | poppler-bugs <poppler-bugs> |
Status: | RESOLVED FIXED | QA Contact: | |
Severity: | normal | ||
Priority: | medium | ||
Version: | unspecified | ||
Hardware: | Other | ||
OS: | All | ||
Whiteboard: | |||
i915 platform: | i915 features: | ||
Bug Depends on: | 94053 | ||
Bug Blocks: | |||
Attachments: | Fall back to Gfx implementation of tiling pattern if repetition rate is small |
Description
Jakub Wilk
2015-05-22 15:35:31 UTC
The huge bitmap is a tiling pattern including its repititions before it is scaled to the resulting bitmap. This algorithm was introduced in poppler 0.17.0 and dramatically increased the speed for rendering when there is a high repitition rate. But in this case the tiling pattern itself is so huge, but the repitition count in x and y direction is nearly always small, between 1 x 1 amd 2 x 2 in nearly every of quite a lot tiling patterns. So I give it a try to fall back to the old algorithm, where the tiling pattern is rendered for every repitition again but directly to the resulting bitmap and measured the time: a) Without my changes: time ./utils/pdftoppm -png -cropbox -r 300 90596.open/Page156.pdf output/90596 real 0m29.039s user 0m28.395s sys 0m0.275s b) Use the fallback time ./utils/pdftoppm -png -cropbox -r 300 90596.open/Page156.pdf output/90596-new real 0m25.754s user 0m25.592s sys 0m0.170s So it's even faster to use the fallback here. So I create a patch where it falls back to the old algorithm if repeatX * repeatY <= 4 and measure the time of my regression test: a) Without changes: Refs created in 44 minutes and 32 seconds b) With limit and fallback: Refs created in 41 minutes and 4 seconds So I will upload a patch when a solution for bug 94053 will be committed. Created attachment 121780 [details] [review] Fall back to Gfx implementation of tiling pattern if repetition rate is small Here the announced patch Patch commited |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.