Commit graph

99 commits

Author SHA1 Message Date
Carl Worth
d5531c4f50 Add unaligned_clip perf case courtesy of Jeff Muizelaar
Conflicts:

	perf/Makefile.am
	perf/cairo-perf.c
	perf/cairo-perf.h
2007-01-09 14:31:22 -08:00
Brian Ewins
22e271d687 [perf/cairo-perf-diff] Pass CAIRO_AUTOGEN_OPTIONS to autogen.
Makes it was possible to run cairo-perf-diff with different
configurations, eg with quartz enabled.
2007-01-07 18:12:40 +00:00
Carl Worth
cc11c264ec Add long-lines perf case
This shows some very bad slowness for lines that are mostly
offscreen (like 100x slower than just drawing the visible
portion).
2007-01-05 16:50:11 -08:00
M Joonas Pihlaja
4c95e2b7bf New performance test case "mosaic" for splines. 2006-12-16 21:32:19 +02:00
M Joonas Pihlaja
4057a98f88 cairo-perf-diff-files: Don't segfault reading cooked perf reports.
Fixes cairo-perf-diff-files for non-raw cairo-perf reports.  Similar
to the patch on the mailing list, only applied to the caller of
_cairo_stats_compute():

http://lists.freedesktop.org/archives/cairo/2006-December/008720.html
2006-12-05 06:02:45 +02:00
Dan Amelang
3dbe468fd6 [perf] Provide watered-down implementations of getline and strndup for
building on non-GNU toolchains.
2006-12-01 14:12:16 -08:00
Behdad Esfahbod
72a4a98346 [test|perf|boilerplate/Makefile.am] Add -I$(top_builddir)/src to INCLUDES
needed to find cairo-features.h when building out of tree.
2006-11-27 13:23:13 -05:00
Carl Worth
1ed3811338 perf: Add box_outline test case.
This test shows that drawing a 100x100 single-pixel wide box outline is
currently 5 to 16 times slower when using the natural cairo_stroke() as
compared to a rather awkward cairo_fill() of two rectangles.

[ # ]  backend-content                    test-size min(ticks)  min(ms) median(ms) stddev. iterations
[  0]    image-rgba         box-outline-stroke-100     301321    0.218    0.219  0.39%   5
[  1]    image-rgba           box-outline-fill-100      18178    0.013    0.013  0.43%   5
[  0]     xlib-rgba         box-outline-stroke-100     379177    0.275    0.276  1.39%   6
[  1]     xlib-rgba           box-outline-fill-100      83355    0.060    0.060  0.17%   5
2006-11-17 18:00:36 -08:00
Carl Worth
a8faa0aef1 cairo-perf: When iteration count is given on command-line, never execute fewer 2006-11-17 17:48:39 -08:00
Carl Worth
0f7381b26e cairo-perf-diff: Run git-ls-tree from the correct directory
Before this change, cairo-perf-diff would work correctly only
if run from the top-level directory, (and if run from any other
directory it would not pull in the latest boilerplate and perf
files).
2006-11-14 15:13:58 -08:00
Carl Worth
74f5fe241e cairo-perf-diff: rsync only git-managed files from boilerplate/perf
Previously, we were using rsync to recursively copy all files
from boilerplate and perf when doing the performance tests. This
had the fatal flaw that pre-built binaries would be hard coded to
link against the cairo library from $CAIRO_DIR with an absolute
path, (due to libtool rpath stuff).

By only copying git-managed files, we only get source and the compiled
binaries (or libtool wrappers) will now be hard-coded to link against
the library under test.
2006-11-13 14:44:07 -08:00
Carl Worth
26b74049e7 cairo-perf-diff: Use rsync instead of cp to avoid some unnecessary rebuilding 2006-11-10 11:26:01 -08:00
Carl Worth
f1f189b81a cairo-perf-diff: Separate old and new build directories
With the fancy new, incremental cairo-perf-diff we don't want to keep
resetting the same working tree back and forth between the old and new
versions and rebuilding everything all over again. So use two different
build directories instead of one.

This fixes the rebuild of the library itself, but the perf stuff is still
being rebuilt, (since it's being re-copied each time).
2006-11-10 10:34:37 -08:00
Carl Worth
d9b697c46c cairo-perf-diff: Allow incremental refinement of performance results
cairo-perf-diff now accepts a -f command-line option to force it to
re-generate performance results even if something exists in the cache
already. It also now uses raw mode and appends to the cached file
rather than rewriting the results.

Finally, it also now allows a -- option on the command line and passes
all the subsequent command-line options to cairo-perf. This is handy for
limiting cairo-perf to run only on a subset of the tests of interest.
2006-11-10 10:34:35 -08:00
Carl Worth
439bf81e56 Fix broken size calculation for xrealloc
Another one of those "untested code == broken code" situations.
2006-11-10 10:00:31 -08:00
Carl Worth
f6b400a292 perf: Add world-map performance test case.
The map for this test case was originally demonstrated as a
performance problem in this mozilla bug report:

	A very slow SVG file with <path>s
	https://bugzilla.mozilla.org/show_bug.cgi?id=332413

I obtained permission from the creator of the original file to
include the data here, (see comments in world-map.h for details).
2006-11-08 06:07:01 -08:00
Carl Worth
2d927eaefa perf/Makefile.am: Add missing zrusin-another.h file to list 2006-11-08 06:07:01 -08:00
Carl Worth
0d1340f716 perf: Eliminate CAIRO_STATS_MIN_VALID_SAMPLES
We don't need this at this deep level since callers can now
implement this limiting manually since stats.iterations is
now returned. Also, this was interfering with the -i option
to cairo-perf anyway.
2006-11-08 06:07:01 -08:00
Carl Worth
6d5df0e3e2 cairo-perf-diff-files: Add support for diffing "raw" files from "cairo-perf -r" 2006-11-08 06:07:01 -08:00
Carl Worth
d1e1192090 cairo-perf: Print ticks_per_ms value in raw mode so raw analysis tools can report times 2006-11-08 06:07:01 -08:00
Carl Worth
5393989272 perf: Move statistics code into new cairo-stats.h for sharing 2006-11-08 06:07:01 -08:00
Carl Worth
0564b5074c cairo-perf: Add command line options for test cases to run, listing tests, and new raw mode. 2006-11-07 01:29:38 -08:00
Carl Worth
49b72f004d Add zrusin-another test cases (tessellate and fill).
This new test case is the 0th polygon polygon from Zack Rusin's
recent cairorender program as made avaialable here:

	http://ktown.kde.org/~zrusin/examples/cairorender.tar.bz2

This polygon contains about 1000 coordinates and looks like a
hand-drawn version of the word another.
2006-11-06 23:56:19 -08:00
Carl Worth
52eb7134bd cairo-perf-diff: Use two-part hash to avoid stale data when perf suite changes.
The perf tree's sha1 is now in the cache file name, so that
if the performance suite itself ever changes then new data
will be generated rather than using stale stuff from the cache.

Also, we now use the src tree's sha1 rather than the commit's
so that commits that don't change the src directory are also
treated as identical, (which they really should be as far as
performance of the library itself is concerned).
2006-11-06 09:39:02 -08:00
Carl Worth
e760d0927e Don't rely on NQUARTZ or OS2 surface types unless they exist.
This allows the cairo-perf stuff to build on older checkouts,
(such as 1.2.4), so that we can usefully do things like:

	cairo-perf-diff 1.2.4 HEAD
2006-11-06 09:39:02 -08:00
Carl Worth
941b517024 cairo-perf-diff: Build and run latest cairo-perf program rather than whatever was in the old checkout 2006-11-06 09:35:10 -08:00
Carl Worth
e2ede57fbb cairo-perf-diff: Fix to still function if run from the top-level directory containing .git 2006-11-06 09:35:10 -08:00
Carl Worth
5500c59b9b Remove typo (mean vs median)
This didn't end up making a difference in practice since the
median is assigned again later on.
2006-11-02 12:27:17 -08:00
Carl Worth
b717e98777 cairo-perf: Change outlier elimination and report minimum times.
Instead of just discarding the worst 15% of the results, we now
do IQR-based detection and elimination of outliers. Also, instead
of reporting mean times we now report minimum and median times.
We still do compute the mean and standard deviation for the
detection of when results seem stable for early bailout. And we
do still report the standard deviation.

A statistician might complain that it looks funny to report the
median and the standard deviation together, (instead of median
and average absolute deviation from the median, say), but I liked
the standard deviation since it is always larger, so it might
ensure better separatation if we use it to determine when two
sets of results are sufficiently different to be interesting.
2006-11-02 12:21:26 -08:00
Dan Amelang
d2d0d11bde Add new perf test "pattern_create_radial"
This test is really just for hammering the double to fixed-point conversion
(in _cairo_fixed_from_double) that happens as doubles from API calls gets
translated into internal cairo fixed-point numbers.
2006-11-02 10:38:00 -08:00
Carl Worth
a618fd2cf9 cairo-perf-diff: Simplify git usage and just run cairo-perf that gets built with cairo revision
Many thanks to Josh Triplett for help with theses fixes:

1. Simplify the usage of git to eliminate the fragile and nasty
   stuff we were doing previously, (such as manually symlinking
   things under .git rather than just using git-clone -s).

2. Don't try running latest cairo-perf with LD_LIBRARY_PATH
   pointing to built cairo version. Apparently stupid libtool
   and its use of rpath is foiling us here. Instead just run
   whatever cairo-perf gets built as part of the source that
   gets checked out.

This second point means that cairo-perf-diff won't yet be useful
for comparing the performance of old cairo revisions that pre-date
cairo-perf. I've since been reasing and we might be able to use
--disable-rpath to the configure script to get what we want.
2006-11-02 04:45:27 -08:00
Jamey Sharp
7442b40866 perf: cairo-perf-diff-files.c should generate cairo-perf-diff-files
... rather than overwriting the new cairo-perf-diff script, which
should (by the way) be included in dist tarballs.
2006-10-29 11:18:09 -08:00
Carl Worth
a9f51c2973 Add new cairo-perf-diff for finding the performance difference between any 2 revisions.
The old cairo-perf-diff is now named cairo-perf-diff-files, but
the new one calls out to it and can still be used in an identical
way.

The new cairo-perf-diff can also be used to see what the performance
impact of a single commit is like so:

	cairo-perf-diff HEAD

or between two commits:

	cairo-perf-diff 1.2.4 HEAD

The script is careful to always run the latest cairo-perf program
even when testing old versions of the library. Also, the output
from any given performance run is cached so it gets less painful
to run as the cache gets primed (the cache is in .perf next to
.git).

The script is still a bit fragile in spots. In particular it depends
on cairo-perf being built in advance but doesn't do anythin to ensure
that happens.
2006-10-25 17:15:22 -07:00
Behdad Esfahbod
838ff68cd5 [perf] Remove SUBDIRS=../boilerplate and add explicit dependencies
This is quite like what I just did in test/.  We can now require an older
version of automake as we used to.
2006-10-25 16:07:34 -04:00
Carl Worth
99e2e99a78 Use zero-size change bar for a speedup/slowdown of 1.0
Also use speedup/slowdown rather than faster/slower in the output
2006-10-18 15:47:18 -07:00
Carl Worth
a53eabf0a5 Add cairo-perf-diff program for comparing two cairo-perf reports. 2006-10-18 12:16:50 -07:00
Carl Worth
5c7798a646 perf: Print ticks as well as ms in output.
The ticks value is a bit more reliable since it won't exhibit
variation due to estimating the CPU frequency like the ms value
will.
2006-10-18 12:11:26 -07:00
Carl Worth
bb3d4b2f88 cairo-perf: Remove wasted whitespace in output. Squelch wanring. 2006-10-18 12:11:26 -07:00
Carl Worth
d8c23d5ed7 perf: Change minimum size of paint test to 256
The paint tests at sizes less than 256 were just too fast to be
significant.
2006-10-18 12:11:26 -07:00
Carl Worth
71037f3612 Rename wait_for_rendering to syncrhonize
We're not using this call both before and after rendering
so the old name just didn't make sense anymore.
2006-10-16 09:07:47 -07:00
Carl Worth
648f4bc830 perf: Make iterations adaptive (bailing as soon as std. deviation is <= 3% for 5 consecutive iterations
This makes the entire performance test suite about 10 times faster
on my system. And I don't think that the results are significantly
worse, (many tests are stable after only 5 iterations while some
still run to 100 iterations without reaching our stability criteria).
2006-10-12 15:12:01 -07:00
Carl Worth
d7c2f7e2d7 perf: Rename finalize to synchronize as it is used in both start() and stop() now 2006-10-05 15:14:14 -07:00
Carl Worth
8af5e14fd8 perf: Do backend synchronization in cairo_perf_timer_start as well as cairo_perf_timer_stop 2006-10-05 15:10:45 -07:00
Carl Worth
5412343a77 perf: Add subimage_copy test to demonstrate performance bug found by monty 2006-10-05 12:31:50 -07:00
Carl Worth
9285a1f7fe perf: Add text test 2006-10-05 12:31:50 -07:00
Carl Worth
bda77f505c perf: Bail if cairo_status returns non-success at the end of a test. 2006-10-04 17:14:12 -07:00
Carl Worth
d15b8f2d6e perf: Add linear and radial gradients to the coverage 2006-10-04 17:14:12 -07:00
Carl Worth
933d845728 Shorten test names in output (drop unneeded _source and _surface) 2006-10-04 17:14:12 -07:00
Carl Worth
fb61fe82d3 perf: Add stroke and fill tests 2006-10-04 17:14:12 -07:00
Carl Worth
d52256df7c perf: Move iteration over sources and operators from paint to new cairo-perf-cover
This will finally allow us to very easily add lots of other
tests that will similarly involve iterating over the various
sources and operators of interest.
2006-10-04 17:14:12 -07:00