Commit graph

14 commits

Author SHA1 Message Date
Andrea Canciani
c65d4e35dc Use xstrdup instead of xmalloc when possible
Don't open code xstrdup, just use it.
2011-11-12 20:49:08 +01:00
Chris Wilson
af9fbd176b Introduce a new compositor architecture
Having spent the last dev cycle looking at how we could specialize the
compositors for various backends, we once again look for the
commonalities in order to reduce the duplication. In part this is
motivated by the idea that spans is a good interface for both the
existent GL backend and pixman, and so they deserve a dedicated
compositor. xcb/xlib target an identical rendering system and so they
should be using the same compositor, and it should be possible to run
that same compositor locally against pixman to generate reference tests.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>

P.S. This brings massive upheaval (read breakage) I've tried delaying in
order to fix as many things as possible but now this one patch does far,
far, far too much. Apologies in advance for breaking your favourite
backend, but trust me in that the end result will be much better. :)
2011-09-12 08:29:48 +01:00
Andrea Canciani
761ef7ae8b cairo-missing: Fix and cleanup ssize_t type definition
The definition of ssize_t is needed in cairo-missing.h and can be
dropped from files which include it.
2011-09-04 16:23:37 -07:00
Andrea Canciani
9172e2aec0 perf: Drop cairo_perf_ticks_t in favor of cairo_time_t
cairo_time_t offers a superset of the functions provided by
cairo_perf_ticks_t.
2011-09-02 12:45:49 +02:00
Andrea Canciani
6d6bfbd641 Introduce the cairo-missing library
The cairo-missing library provides the functions which are needed in
order to correctly compile cairo (or its utilities) and which were not
found during configuration.

Fixes the build on MacOS X Lion, which failed because of collisons
between the cairo internal getline and strndup and those in libc:

cairo-analyse-trace.c:282: error: static declaration of ‘getline’ follows non-static declaration
/usr/include/stdio.h:449: error: previous declaration of ‘getline’ was here
cairo-analyse-trace.c:307: error: static declaration of ‘strndup’ follows non-static declaration
...
2011-09-02 12:27:13 +02:00
Andrea Canciani
e04e368748 Remove useless checks for NULL before freeing
This patch has been generated by the following Coccinelle semantic patch:
// Remove useless checks for NULL before freeing
//
// free (NULL) is a no-op, so there is no need to avoid it

@@
expression E;
@@
+ free (E);
+ E = NULL;
- if (unlikely (E != NULL)) {
-   free(E);
(
-   E = NULL;
|
-   E = 0;
)
   ...
- }

@@
expression E;
@@
+ free (E);
- if (unlikely (E != NULL)) {
-   free (E);
- }
2011-07-31 16:46:36 +02:00
M Joonas Pihlaja
b036a09972 whitespace: Fixup formal arguments and tabs in boilerplate/ and perf/.
Ran a script to align the formal parameters of functions and
collapse spaces to tabs in code.
2010-06-24 15:02:53 +03:00
Chris Wilson
f23ae97e30 [perf] Support parsing reports from stdin 2009-09-29 03:03:51 +01:00
Chris Wilson
0db9e010fa [perf] Calibrate tests to run for at least 2 seconds
By ensuring that tests take longer than a couple of seconds we eliminate
systematic errors in our measurements. However, we also effectively
eliminate the synchronisation overhead. To compensate, we attempt to
estimate the overhead by reporting the difference between a single
instance and the minimum averaged instance.
2009-08-06 10:15:40 +01:00
Chris Wilson
c11f369057 [perf] Avoid NULL derefs on broken result files.
Instead of testing for a NULL return we checked that the pointer didn't
point to NIL. Oops.
2009-07-28 13:02:10 +01:00
Chris Wilson
55f4e0e4e8 [perf] Change seperators from '-' to '.'
This allows the perf tests to use '-' in the name which is easier to read
and differentiates with using '_' to separate source and operators.
2009-06-02 15:13:46 +01:00
Chris Wilson
6801f28f6d [perf] Add a utility to compare backends.
A minor variation on cairo-perf-diff-files that compares tests with the
same name for multiple backends.
2009-01-14 16:51:09 +00:00
Chris Wilson
6662eede2a [perf] Fix errors reported by cppcheck
Trivial mistakes, identified in bugs
http://bugs.freedesktop.org/show_bug.cgi?id=19206 and
http://bugs.freedesktop.org/show_bug.cgi?id=19207.
2009-01-02 09:53:20 +00:00
Chris Wilson
f2ff794426 [perf] A crude tool to visualise performance changes across a series.
Generate a cairo-perf-diff graph for a series of commits in order to be
able to identify significant commits. Still very crude, but minimally
functional.
2008-10-19 09:36:53 +01:00