Poor performance with Cairo/Pixman master when zooming out

Bug #1288838 reported by Guillermo Espertino (Gez) on 2014-03-06
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Inkscape
Medium
Krzysztof Kosinski

Bug Description

I've just compiled cairo and pixman from git expecting to solve the bitmap downscaling issues with current cairo. It works great, but I noticed an important performance hit, specially when zooming out.
The problem doesn't seem to be related to zooming itself, but to redrawing. Zooming in and out in outline mode is fast.
It's not related to bitmap resampling either, since the lag is also noticeable with pure vectors, without any filter.

The performance hit when zooming out a relatively complex artwork is really important, measurable in seconds. With simpler stuff it's still noticeable.

Inkscape 0.48+devel r13018
Debian Testing 64 bit
Phenom X4 - 8 GB - nVidia graphics (non-free driver).

su_v (suv-lp) wrote :

Reproduced with current trunk >= r12599 on OS X 10.7.5, if using a patched stable cairo version, or cairo git master.

tags: added: cairo performance renderer-cairo
Changed in inkscape:
importance: Undecided → Medium
milestone: none → 0.91
status: New → Confirmed
tags: added: regression
description: updated

Revision 12599 reverted the workaround for bug #804162 (added to trunk in r12227):
<http://bazaar.launchpad.net/~inkscape.dev/inkscape/trunk/revision/12599>

summary: - Poor performance with Cairo/Pixman master
+ Poor performance with Cairo/Pixman master (inkscape rev >= 12599)

Correction: not directly related to the changes in r12599 - older archived builds seem to expose the same delays when zooming out, if using cairo master or stable cairo 1.12.16 with downscale patch.

summary: - Poor performance with Cairo/Pixman master (inkscape rev >= 12599)
+ Poor performance with Cairo/Pixman master
su_v (suv-lp) wrote :

Attaching sample file (pure vector, no gradients, no swatches, no filter effects, no bitmaps) which exposes the lag on zooming out:

1) launch trunk with default prefs
2) open attached file
3) select a rectangle
4) zoom to selection ('3')
5) zoom to 1:1 ('1')

Step 5 is very fast to redraw after zooming out with unpatched cairo 1.12.16, but shows a noticeable delay when using cairo 1.12.16 + original downscale patch [1] or current cairo git master [2]. The more complex the drawing the longer such delays (this can be very disruptive for workflows which often toggle between two zoom states).

Tested and reproduced with
- Inkscape r13125, cairo git master [2] on Ubuntu 13.10
- Inkscape r13127, patched cairo 1.12.16 [1], cairo git master [2] on OS X 10.7.5.

[1] <http://cgit.freedesktop.org/cairo/commit/?id=fb57ea13e04d82866cbc8e86c83261148bb3e231>
[2] @ ed175b2a2bebb6def85133257bc11a875d13b0dd

Note that rev 13124 did have no effect on this performance regression:
<http://bazaar.launchpad.net/~inkscape.dev/inkscape/trunk/revision/13124>

su_v (suv-lp) wrote :

On 2014-03-08 07:07 +0100, ~suv wrote:
> Tested and reproduced with
> - Inkscape r13125, cairo git master [2] on Ubuntu 13.10

Tests had been run based on these earlier instructions by Adrian Johnson:
<https://bugs.launchpad.net/inkscape/+bug/375323/comments/47>

Krzysztof Kosinski (tweenk) wrote :

This is probably related to render caching. The caches are being downscaled when zoomed out, but for fairly simple drawings this might be too slow to

~suv, does the regression happen when Cairo is run with the environment variable _INKSCAPE_DISABLE_CACHE=1 ?

su_v (suv-lp) wrote :

On 2014-03-11 14:20 +0100, Krzysztof Kosinski wrote:
> does the regression happen when Cairo is run with the environment
> variable _INKSCAPE_DISABLE_CACHE=1 ?

No, the regression does not happen if caching is disabled - tested with use case described in comment #4 on Ubuntu 13.10 (VM, 64bit) and OS X 10.7.5.

summary: - Poor performance with Cairo/Pixman master
+ Poor performance with Cairo/Pixman master when zooming out
Krzysztof Kosinski (tweenk) wrote :

Should be fixed in r13137.

Changed in inkscape:
assignee: nobody → Krzysztof Kosinski (tweenk)
status: Confirmed → Fix Committed
Changed in inkscape:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers