[cairo-commit] 2 commits - perf/cairo-perf.c perf/fill.c
Chris Wilson
ickle at kemper.freedesktop.org
Fri Feb 13 06:30:23 PST 2009
perf/cairo-perf.c | 3 +++
perf/fill.c | 21 +++++++++++++++++++++
2 files changed, 24 insertions(+)
New commits:
commit fa66291c8862ed592fca469ceab0ac9b1d270835
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date: Wed Jan 28 14:22:58 2009 +0000
[perf] Test non-antialiased fill.
Just because the i915 can special case such fills using a single-pass
tessellation in the stencil buffer.
diff --git a/perf/fill.c b/perf/fill.c
index 6ebe70e..f068561 100644
--- a/perf/fill.c
+++ b/perf/fill.c
@@ -42,6 +42,26 @@ do_fill (cairo_t *cr, int width, int height)
return cairo_perf_timer_elapsed ();
}
+static cairo_perf_ticks_t
+do_fill_eo_noaa (cairo_t *cr, int width, int height)
+{
+ cairo_set_antialias (cr, CAIRO_ANTIALIAS_NONE);
+ cairo_set_fill_rule (cr, CAIRO_FILL_RULE_EVEN_ODD);
+
+ cairo_arc (cr,
+ width/2.0, height/2.0,
+ width/3.0,
+ 0, 2 * M_PI);
+
+ cairo_perf_timer_start ();
+
+ cairo_fill (cr);
+
+ cairo_perf_timer_stop ();
+
+ return cairo_perf_timer_elapsed ();
+}
+
void
fill (cairo_perf_t *perf, cairo_t *cr, int width, int height)
{
@@ -49,4 +69,5 @@ fill (cairo_perf_t *perf, cairo_t *cr, int width, int height)
return;
cairo_perf_cover_sources_and_operators (perf, "fill", do_fill);
+ cairo_perf_cover_sources_and_operators (perf, "fill-eo-noaa", do_fill_eo_noaa);
}
commit aab9ed3432f0ea7b8b24990de4aa134bb599a3e5
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date: Fri Jan 30 10:22:47 2009 +0000
[perf] Env variable to ignore similar targets whilst benchmarking.
Use CAIRO_TEST_IGNORE_SIMILAR to skip similar targets.
diff --git a/perf/cairo-perf.c b/perf/cairo-perf.c
index efe6e8d..c66113f 100644
--- a/perf/cairo-perf.c
+++ b/perf/cairo-perf.c
@@ -134,6 +134,9 @@ cairo_perf_has_similar (cairo_perf_t *perf)
{
cairo_surface_t *target = cairo_get_target (perf->cr);
+ if (getenv ("CAIRO_TEST_IGNORE_SIMILAR"))
+ return FALSE;
+
/* exclude the image backend */
if (cairo_surface_get_type (target) == CAIRO_SURFACE_TYPE_IMAGE)
return FALSE;
More information about the cairo-commit
mailing list