Public bug reported:
"ghostscript -sDEVICE=bbox" is used to compute the "BoundingBox" of an
input file. On focal with ghostscript 9.50~dfsg-5ubuntu3 this is
extremely slow for PostScript files (~factor 6 compared to bionic). This
may affect printing as e.g. foomatic-rip is using this approach when
rendering such a file.
Example with a simple (one page) PostScript test page:
ghostscript 9.50 on focal:
> time gs -q -dNOPAUSE -dBATCH -sDEVICE=bbox testprint.ps
real 0m16,493s
> time gs -q -dNOPAUSE -dBATCH -sDEVICE=bbox -r4000 testprint.ps
real 0m17,071s
> time gs -q -dNOPAUSE -dBATCH -sDEVICE=bbox -r1200 testprint.ps
real 0m0,980s
ghostscript 9.26~dfsg+0-0ubuntu0.18.04.12 on bionic:
> time gs -q -dNOPAUSE -dBATCH -sDEVICE=bbox testprint.ps
real 0m2,697s
> time gs -q -dNOPAUSE -dBATCH -sDEVICE=bbox -r4000 testprint.ps
real 0m2,604s
> time gs -q -dNOPAUSE -dBATCH -sDEVICE=bbox -r1200 testprint.ps
real 0m1,029s
As one can see, the default resolution for computing the BoundingBox is
4000dpi. While on bionic the time is basically linear, on focal this takes much
longer. Surprisingly for PDF this is no problem at all.
I'm not an expert for ghostscript internals, but by strace-ing the beast
it seems that 9.26 mallocs a 300MB memory area while 9.50 only allocates
at max ~30MB. Maybe this is a problem with internal memory management
when the rendered page doesn't fit in the allocated area at high
resolutions?
Obviously I don't know if this is an upstream bug or a problem with the
Ubuntu build.
** Affects: ghostscript (Ubuntu)
Importance: Undecided
Status: New
** Tags: focal
** Tags added: focal
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1869902
Title:
foomatic-rip extremely slow on focal for PostScript input files - may
affect printing
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/ghostscript/+bug/1869902/+subscriptions
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs