diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2010-03-30 04:10:28 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2010-03-30 15:28:37 +0100 |
commit | 72481acf0d1e8648c5d03ce51f84c639132475a9 (patch) | |
tree | 1da9fc191e1b4a9b3e4913bef4a47bb4bb4b6917 /perf | |
parent | 2a98d0586c19fbb2b555f471895d73f253c4943b (diff) |
perf: Compute ops per second
Provide a hook for the test to be able to compute the number of ops per
second. For instance, the glyphs test uses it to report the number of
kiloglyph per second Cairo is able to render.
Diffstat (limited to 'perf')
-rw-r--r-- | perf/cairo-perf-micro.c | 47 | ||||
-rw-r--r-- | perf/cairo-perf.h | 9 | ||||
-rw-r--r-- | perf/micro/box-outline.c | 4 | ||||
-rw-r--r-- | perf/micro/cairo-perf-cover.c | 5 | ||||
-rw-r--r-- | perf/micro/composite-checker.c | 2 | ||||
-rw-r--r-- | perf/micro/dragon.c | 10 | ||||
-rw-r--r-- | perf/micro/fill.c | 6 | ||||
-rw-r--r-- | perf/micro/glyphs.c | 35 | ||||
-rw-r--r-- | perf/micro/intersections.c | 8 | ||||
-rw-r--r-- | perf/micro/long-dashed-lines.c | 2 | ||||
-rw-r--r-- | perf/micro/long-lines.c | 8 | ||||
-rw-r--r-- | perf/micro/mask.c | 18 | ||||
-rw-r--r-- | perf/micro/mosaic.c | 8 | ||||
-rw-r--r-- | perf/micro/paint-with-alpha.c | 2 | ||||
-rw-r--r-- | perf/micro/paint.c | 2 | ||||
-rw-r--r-- | perf/micro/pattern_create_radial.c | 2 | ||||
-rw-r--r-- | perf/micro/pythagoras-tree.c | 2 | ||||
-rw-r--r-- | perf/micro/rectangles.c | 6 | ||||
-rw-r--r-- | perf/micro/rounded-rectangles.c | 6 | ||||
-rw-r--r-- | perf/micro/spiral.c | 28 | ||||
-rw-r--r-- | perf/micro/stroke.c | 4 | ||||
-rw-r--r-- | perf/micro/subimage_copy.c | 2 | ||||
-rw-r--r-- | perf/micro/tessellate.c | 6 | ||||
-rw-r--r-- | perf/micro/text.c | 2 | ||||
-rw-r--r-- | perf/micro/twin.c | 2 | ||||
-rw-r--r-- | perf/micro/unaligned-clip.c | 2 | ||||
-rw-r--r-- | perf/micro/world-map.c | 2 | ||||
-rw-r--r-- | perf/micro/zrusin.c | 4 |
28 files changed, 142 insertions, 92 deletions
diff --git a/perf/cairo-perf-micro.c b/perf/cairo-perf-micro.c index ec40409c..e8b28207 100644 --- a/perf/cairo-perf-micro.c +++ b/perf/cairo-perf-micro.c @@ -130,14 +130,16 @@ cairo_perf_calibrate (cairo_perf_t *perf, cairo_perf_ticks_t calibration0, calibration; unsigned loops, min_loops; - calibration0 = perf_func (perf->cr, perf->size, perf->size, 1); + min_loops = 1; + calibration0 = perf_func (perf->cr, perf->size, perf->size, min_loops); if (perf->fast_and_sloppy) { calibration = calibration0; } else { - loops = cairo_perf_ticks_per_second () / 100 / calibration0; - if (loops < 3) - loops = 3; - calibration = (calibration0 + perf_func (perf->cr, perf->size, perf->size, loops)) / (loops + 1); + calibration = 0.01 * cairo_perf_ticks_per_second (); + while (calibration0 < calibration) { + min_loops *= 10; + calibration0 = perf_func (perf->cr, perf->size, perf->size, min_loops); + } } /* XXX @@ -151,7 +153,7 @@ cairo_perf_calibrate (cairo_perf_t *perf, * a more rigorous analysis of the synchronisation overhead, * that is to estimate the time for loop=0. */ - loops = perf->ms_per_iteration * 0.001 * cairo_perf_ticks_per_second () / calibration; + loops = perf->ms_per_iteration * 0.001 * cairo_perf_ticks_per_second () * min_loops / calibration; min_loops = perf->fast_and_sloppy ? 1 : 10; if (loops < min_loops) loops = min_loops; @@ -162,7 +164,8 @@ cairo_perf_calibrate (cairo_perf_t *perf, void cairo_perf_run (cairo_perf_t *perf, const char *name, - cairo_perf_func_t perf_func) + cairo_perf_func_t perf_func, + cairo_count_func_t count_func) { static cairo_bool_t first_run = TRUE; unsigned int i, similar, has_similar; @@ -256,8 +259,7 @@ cairo_perf_run (cairo_perf_t *perf, if (i > 0) { _cairo_stats_compute (&stats, times, i+1); - if (stats.std_dev <= CAIRO_PERF_LOW_STD_DEV) - { + if (stats.std_dev <= CAIRO_PERF_LOW_STD_DEV) { low_std_dev_count++; if (low_std_dev_count >= CAIRO_PERF_STABLE_STD_DEV_COUNT) break; @@ -273,12 +275,23 @@ cairo_perf_run (cairo_perf_t *perf, if (perf->summary) { _cairo_stats_compute (&stats, times, i); - fprintf (perf->summary, - "%10lld %#8.3f %#8.3f %#5.2f%% %3d\n", - (long long) stats.min_ticks, - (stats.min_ticks * 1000.0) / cairo_perf_ticks_per_second (), - (stats.median_ticks * 1000.0) / cairo_perf_ticks_per_second (), - stats.std_dev * 100.0, stats.iterations); + if (count_func != NULL) { + double count = count_func (perf->cr, perf->size, perf->size); + fprintf (perf->summary, + "%10lld %#8.3f %#8.3f %#5.2f%% %3d: %.2f\n", + (long long) stats.min_ticks, + (stats.min_ticks * 1000.0) / cairo_perf_ticks_per_second (), + (stats.median_ticks * 1000.0) / cairo_perf_ticks_per_second (), + stats.std_dev * 100.0, stats.iterations, + count * cairo_perf_ticks_per_second () / stats.min_ticks); + } else { + fprintf (perf->summary, + "%10lld %#8.3f %#8.3f %#5.2f%% %3d\n", + (long long) stats.min_ticks, + (stats.min_ticks * 1000.0) / cairo_perf_ticks_per_second (), + (stats.median_ticks * 1000.0) / cairo_perf_ticks_per_second (), + stats.std_dev * 100.0, stats.iterations); + } fflush (perf->summary); } @@ -517,8 +530,8 @@ const cairo_perf_case_t perf_cases[] = { { fill, 64, 512}, { stroke, 64, 512}, { text, 64, 512}, - { glyphs, 64, 512}, - { mask, 64, 512}, + { glyphs, 64, 512}, + { mask, 64, 512}, { tessellate, 100, 100}, { subimage_copy, 16, 512}, { pattern_create_radial, 16, 16}, diff --git a/perf/cairo-perf.h b/perf/cairo-perf.h index 6d1741aa..c4eeb167 100644 --- a/perf/cairo-perf.h +++ b/perf/cairo-perf.h @@ -99,6 +99,9 @@ typedef struct _cairo_perf { typedef cairo_perf_ticks_t (*cairo_perf_func_t) (cairo_t *cr, int width, int height, int loops); +typedef double +(*cairo_count_func_t) (cairo_t *cr, int width, int height); + cairo_bool_t cairo_perf_can_run (cairo_perf_t *perf, const char *name, @@ -107,12 +110,14 @@ cairo_perf_can_run (cairo_perf_t *perf, void cairo_perf_run (cairo_perf_t *perf, const char *name, - cairo_perf_func_t perf_func); + cairo_perf_func_t perf_func, + cairo_count_func_t count_func); void cairo_perf_cover_sources_and_operators (cairo_perf_t *perf, const char *name, - cairo_perf_func_t perf_func); + cairo_perf_func_t perf_func, + cairo_count_func_t count_func); /* reporter convenience routines */ diff --git a/perf/micro/box-outline.c b/perf/micro/box-outline.c index e216b79a..fe0719f9 100644 --- a/perf/micro/box-outline.c +++ b/perf/micro/box-outline.c @@ -97,6 +97,6 @@ box_outline (cairo_perf_t *perf, cairo_t *cr, int width, int height) if (! cairo_perf_can_run (perf, "box-outline", NULL)) return; - cairo_perf_run (perf, "box-outline-stroke", box_outline_stroke); - cairo_perf_run (perf, "box-outline-fill", box_outline_fill); + cairo_perf_run (perf, "box-outline-stroke", box_outline_stroke, NULL); + cairo_perf_run (perf, "box-outline-fill", box_outline_fill, NULL); } diff --git a/perf/micro/cairo-perf-cover.c b/perf/micro/cairo-perf-cover.c index 48f13a8b..151a2e67 100644 --- a/perf/micro/cairo-perf-cover.c +++ b/perf/micro/cairo-perf-cover.c @@ -295,7 +295,8 @@ typedef void (*set_source_func_t) (cairo_t *cr, int width, int height); void cairo_perf_cover_sources_and_operators (cairo_perf_t *perf, const char *name, - cairo_perf_func_t perf_func) + cairo_perf_func_t perf_func, + cairo_count_func_t count_func) { unsigned int i, j; char *expanded_name; @@ -332,7 +333,7 @@ cairo_perf_cover_sources_and_operators (cairo_perf_t *perf, xasprintf (&expanded_name, "%s_%s_%s", name, sources[i].name, operators[j].name); - cairo_perf_run (perf, expanded_name, perf_func); + cairo_perf_run (perf, expanded_name, perf_func, count_func); free (expanded_name); } } diff --git a/perf/micro/composite-checker.c b/perf/micro/composite-checker.c index 0e61ec8d..27dc364f 100644 --- a/perf/micro/composite-checker.c +++ b/perf/micro/composite-checker.c @@ -107,7 +107,7 @@ composite_checker (cairo_perf_t *perf, cairo_pattern_set_filter (src_pattern, CAIRO_FILTER_NEAREST); cairo_surface_destroy (image); - cairo_perf_run (perf, "composite-checker", do_composite_checker); + cairo_perf_run (perf, "composite-checker", do_composite_checker, NULL); cairo_pattern_destroy (checkerboard); cairo_pattern_destroy (src_pattern); diff --git a/perf/micro/dragon.c b/perf/micro/dragon.c index eb8251c8..78da5b2c 100644 --- a/perf/micro/dragon.c +++ b/perf/micro/dragon.c @@ -241,9 +241,9 @@ dragon (cairo_perf_t *perf, cairo_t *cr, int width, int height) if (! cairo_perf_can_run (perf, "dragon", NULL)) return; - cairo_perf_run (perf, "dragon-solid", do_dragon_solid); - cairo_perf_run (perf, "dragon-solid-aligned-clip", do_dragon_solid_aligned_clip); - cairo_perf_run (perf, "dragon-solid-unaligned-clip", do_dragon_solid_unaligned_clip); - cairo_perf_run (perf, "dragon-solid-circle-clip", do_dragon_solid_circle_clip); - cairo_perf_run (perf, "dragon", do_dragon); + cairo_perf_run (perf, "dragon-solid", do_dragon_solid, NULL); + cairo_perf_run (perf, "dragon-solid-aligned-clip", do_dragon_solid_aligned_clip, NULL); + cairo_perf_run (perf, "dragon-solid-unaligned-clip", do_dragon_solid_unaligned_clip, NULL); + cairo_perf_run (perf, "dragon-solid-circle-clip", do_dragon_solid_circle_clip, NULL); + cairo_perf_run (perf, "dragon", do_dragon, NULL); } diff --git a/perf/micro/fill.c b/perf/micro/fill.c index c65a649d..a11298f7 100644 --- a/perf/micro/fill.c +++ b/perf/micro/fill.c @@ -113,7 +113,7 @@ fill (cairo_perf_t *perf, cairo_t *cr, int width, int height) if (! cairo_perf_can_run (perf, "fill", NULL)) return; - cairo_perf_cover_sources_and_operators (perf, "fill", do_fill); - cairo_perf_cover_sources_and_operators (perf, "fill-annuli", do_fill_annuli); - cairo_perf_cover_sources_and_operators (perf, "fill-eo-noaa", do_fill_eo_noaa); + cairo_perf_cover_sources_and_operators (perf, "fill", do_fill, NULL); + cairo_perf_cover_sources_and_operators (perf, "fill-annuli", do_fill_annuli, NULL); + cairo_perf_cover_sources_and_operators (perf, "fill-eo-noaa", do_fill_eo_noaa, NULL); } diff --git a/perf/micro/glyphs.c b/perf/micro/glyphs.c index 25175d54..0012e85d 100644 --- a/perf/micro/glyphs.c +++ b/perf/micro/glyphs.c @@ -57,11 +57,11 @@ do_glyphs (cairo_t *cr, int width, int height, int loops) cairo_scaled_font_glyph_extents (scaled_font, glyphs, num_glyphs, &extents); - y = 0; cairo_perf_timer_start (); while (loops--) { + y = 0; do { x = 0; do { @@ -89,11 +89,42 @@ out: return cairo_perf_timer_elapsed (); } +static double +count_glyphs (cairo_t *cr, int width, int height) +{ + const char text[] = "the jay, pig, fox, zebra and my wolves quack"; + cairo_scaled_font_t *scaled_font; + cairo_glyph_t *glyphs = NULL; + cairo_text_extents_t extents; + cairo_status_t status; + int num_glyphs; + int glyphs_per_line, lines_per_loop; + + cairo_set_font_size (cr, 9); + scaled_font = cairo_get_scaled_font (cr); + status = cairo_scaled_font_text_to_glyphs (scaled_font, 0., 0., + text, -1, + &glyphs, &num_glyphs, + NULL, NULL, + NULL); + if (status) + return 0; + + cairo_scaled_font_glyph_extents (scaled_font, + glyphs, num_glyphs, + &extents); + cairo_glyph_free (glyphs); + + glyphs_per_line = num_glyphs * width / extents.width + 1; + lines_per_loop = height / extents.height + 1; + return glyphs_per_line * lines_per_loop / 1000.; /* kiloglyphs */ +} + void glyphs (cairo_perf_t *perf, cairo_t *cr, int width, int height) { if (! cairo_perf_can_run (perf, "glyphs", NULL)) return; - cairo_perf_cover_sources_and_operators (perf, "glyphs", do_glyphs); + cairo_perf_cover_sources_and_operators (perf, "glyphs", do_glyphs, count_glyphs); } diff --git a/perf/micro/intersections.c b/perf/micro/intersections.c index 0418ee31..8f551653 100644 --- a/perf/micro/intersections.c +++ b/perf/micro/intersections.c @@ -149,9 +149,9 @@ intersections (cairo_perf_t *perf, cairo_t *cr, int width, int height) if (! cairo_perf_can_run (perf, "intersections", NULL)) return; - cairo_perf_run (perf, "intersections-nz-fill", random_nz); - cairo_perf_run (perf, "intersections-eo-fill", random_eo); + cairo_perf_run (perf, "intersections-nz-fill", random_nz, NULL); + cairo_perf_run (perf, "intersections-eo-fill", random_eo, NULL); - cairo_perf_run (perf, "intersections-nz-curve-fill", random_curve_nz); - cairo_perf_run (perf, "intersections-eo-curve-fill", random_curve_eo); + cairo_perf_run (perf, "intersections-nz-curve-fill", random_curve_nz, NULL); + cairo_perf_run (perf, "intersections-eo-curve-fill", random_curve_eo, NULL); } diff --git a/perf/micro/long-dashed-lines.c b/perf/micro/long-dashed-lines.c index c4de24f5..74de1583 100644 --- a/perf/micro/long-dashed-lines.c +++ b/perf/micro/long-dashed-lines.c @@ -67,5 +67,5 @@ long_dashed_lines (cairo_perf_t *perf, cairo_t *cr, int width, int height) if (! cairo_perf_can_run (perf, "long-dashed-lines", NULL)) return; - cairo_perf_run (perf, "long-dashed-lines", do_long_dashed_lines); + cairo_perf_run (perf, "long-dashed-lines", do_long_dashed_lines, NULL); } diff --git a/perf/micro/long-lines.c b/perf/micro/long-lines.c index 2b72879c..577f17c8 100644 --- a/perf/micro/long-lines.c +++ b/perf/micro/long-lines.c @@ -138,8 +138,8 @@ long_lines (cairo_perf_t *perf, cairo_t *cr, int width, int height) if (! cairo_perf_can_run (perf, "long-lines", NULL)) return; - cairo_perf_run (perf, "long-lines-uncropped", long_lines_uncropped); - cairo_perf_run (perf, "long-lines-uncropped-once", long_lines_uncropped_once); - cairo_perf_run (perf, "long-lines-cropped", long_lines_cropped); - cairo_perf_run (perf, "long-lines-cropped-once", long_lines_cropped_once); + cairo_perf_run (perf, "long-lines-uncropped", long_lines_uncropped, NULL); + cairo_perf_run (perf, "long-lines-uncropped-once", long_lines_uncropped_once, NULL); + cairo_perf_run (perf, "long-lines-cropped", long_lines_cropped, NULL); + cairo_perf_run (perf, "long-lines-cropped-once", long_lines_cropped_once, NULL); } diff --git a/perf/micro/mask.c b/perf/micro/mask.c index 3050b447..840d43fc 100644 --- a/perf/micro/mask.c +++ b/perf/micro/mask.c @@ -279,21 +279,21 @@ mask (cairo_perf_t *perf, cairo_t *cr, int width, int height) return; cairo_perf_cover_sources_and_operators (perf, "mask-solid", - do_mask_solid); + do_mask_solid, NULL); cairo_perf_cover_sources_and_operators (perf, "mask-image", - do_mask_image); + do_mask_image, NULL); cairo_perf_cover_sources_and_operators (perf, "mask-image-half", - do_mask_image_half); + do_mask_image_half, NULL); cairo_perf_cover_sources_and_operators (perf, "mask-image-double", - do_mask_image_double); + do_mask_image_double, NULL); cairo_perf_cover_sources_and_operators (perf, "mask-similar", - do_mask_similar); + do_mask_similar, NULL); cairo_perf_cover_sources_and_operators (perf, "mask-similar-half", - do_mask_similar_half); + do_mask_similar_half, NULL); cairo_perf_cover_sources_and_operators (perf, "mask-similar-double", - do_mask_similar_double); + do_mask_similar_double, NULL); cairo_perf_cover_sources_and_operators (perf, "mask-linear", - do_mask_linear); + do_mask_linear, NULL); cairo_perf_cover_sources_and_operators (perf, "mask-radial", - do_mask_radial); + do_mask_radial, NULL); } diff --git a/perf/micro/mosaic.c b/perf/micro/mosaic.c index b7621057..a63166cb 100644 --- a/perf/micro/mosaic.c +++ b/perf/micro/mosaic.c @@ -166,8 +166,8 @@ mosaic (cairo_perf_t *perf, cairo_t *cr, int width, int height) if (! cairo_perf_can_run (perf, "mosaic", NULL)) return; - cairo_perf_run (perf, "mosaic-fill-curves", mosaic_fill_curves); - cairo_perf_run (perf, "mosaic-fill-lines", mosaic_fill_lines); - cairo_perf_run (perf, "mosaic-tessellate-curves", mosaic_tessellate_curves); - cairo_perf_run (perf, "mosaic-tessellate-lines", mosaic_tessellate_lines); + cairo_perf_run (perf, "mosaic-fill-curves", mosaic_fill_curves, NULL); + cairo_perf_run (perf, "mosaic-fill-lines", mosaic_fill_lines, NULL); + cairo_perf_run (perf, "mosaic-tessellate-curves", mosaic_tessellate_curves, NULL); + cairo_perf_run (perf, "mosaic-tessellate-lines", mosaic_tessellate_lines, NULL); } diff --git a/perf/micro/paint-with-alpha.c b/perf/micro/paint-with-alpha.c index 5c23fe45..048cdb01 100644 --- a/perf/micro/paint-with-alpha.c +++ b/perf/micro/paint-with-alpha.c @@ -45,5 +45,5 @@ paint_with_alpha (cairo_perf_t *perf, cairo_t *cr, int width, int height) return; cairo_perf_cover_sources_and_operators (perf, "paint-with-alpha", - do_paint_with_alpha); + do_paint_with_alpha, NULL); } diff --git a/perf/micro/paint.c b/perf/micro/paint.c index bdc014c7..ce8cfd37 100644 --- a/perf/micro/paint.c +++ b/perf/micro/paint.c @@ -44,5 +44,5 @@ paint (cairo_perf_t *perf, cairo_t *cr, int width, int height) if (! cairo_perf_can_run (perf, "paint", NULL)) return; - cairo_perf_cover_sources_and_operators (perf, "paint", do_paint); + cairo_perf_cover_sources_and_operators (perf, "paint", do_paint, NULL); } diff --git a/perf/micro/pattern_create_radial.c b/perf/micro/pattern_create_radial.c index 2959e740..7104c00f 100644 --- a/perf/micro/pattern_create_radial.c +++ b/perf/micro/pattern_create_radial.c @@ -99,5 +99,5 @@ pattern_create_radial (cairo_perf_t *perf, cairo_t *cr, int width, int height) } cairo_perf_run (perf, "pattern-create-radial", - do_pattern_create_radial); + do_pattern_create_radial, NULL); } diff --git a/perf/micro/pythagoras-tree.c b/perf/micro/pythagoras-tree.c index f2200c98..964d5c12 100644 --- a/perf/micro/pythagoras-tree.c +++ b/perf/micro/pythagoras-tree.c @@ -87,5 +87,5 @@ pythagoras_tree (cairo_perf_t *perf, cairo_t *cr, int width, int height) if (! cairo_perf_can_run (perf, "pythagoras-tree", NULL)) return; - cairo_perf_run (perf, "pythagoras-tree", do_pythagoras_tree); + cairo_perf_run (perf, "pythagoras-tree", do_pythagoras_tree, NULL); } diff --git a/perf/micro/rectangles.c b/perf/micro/rectangles.c index 601a0c59..6bfbc657 100644 --- a/perf/micro/rectangles.c +++ b/perf/micro/rectangles.c @@ -112,7 +112,7 @@ rectangles (cairo_perf_t *perf, cairo_t *cr, int width, int height) rects[i].height = (rand () % (height / 10)) + 1; } - MODE (perf, "one-rectangle", do_rectangle); - MODE (perf, "rectangles", do_rectangles); - MODE (perf, "rectangles-once", do_rectangles_once); + MODE (perf, "one-rectangle", do_rectangle, NULL); + MODE (perf, "rectangles", do_rectangles, NULL); + MODE (perf, "rectangles-once", do_rectangles_once, NULL); } diff --git a/perf/micro/rounded-rectangles.c b/perf/micro/rounded-rectangles.c index 477abf2c..4db62fc8 100644 --- a/perf/micro/rounded-rectangles.c +++ b/perf/micro/rounded-rectangles.c @@ -135,7 +135,7 @@ rounded_rectangles (cairo_perf_t *perf, cairo_t *cr, int width, int height) rects[i].height = (rand () % (height / 10)) + 1; } - MODE (perf, "one-rounded-rectangle", do_rectangle); - MODE (perf, "rounded-rectangles", do_rectangles); - MODE (perf, "rounded-rectangles-once", do_rectangles_once); + MODE (perf, "one-rounded-rectangle", do_rectangle, NULL); + MODE (perf, "rounded-rectangles", do_rectangles, NULL); + MODE (perf, "rounded-rectangles-once", do_rectangles_once, NULL); } diff --git a/perf/micro/spiral.c b/perf/micro/spiral.c index 046351c0..10bb9184 100644 --- a/perf/micro/spiral.c +++ b/perf/micro/spiral.c @@ -332,18 +332,18 @@ spiral (cairo_perf_t *perf, cairo_t *cr, int width, int height) if (! cairo_perf_can_run (perf, "spiral", NULL)) return; - cairo_perf_run (perf, "spiral-box-nonalign-evenodd-fill", draw_spiral_eo_na_box); - cairo_perf_run (perf, "spiral-box-nonalign-nonzero-fill", draw_spiral_nz_na_box); - cairo_perf_run (perf, "spiral-box-pixalign-evenodd-fill", draw_spiral_eo_pa_box); - cairo_perf_run (perf, "spiral-box-pixalign-nonzero-fill", draw_spiral_nz_pa_box); - cairo_perf_run (perf, "spiral-diag-nonalign-evenodd-fill", draw_spiral_eo_na_di); - cairo_perf_run (perf, "spiral-diag-nonalign-nonzero-fill", draw_spiral_nz_na_di); - cairo_perf_run (perf, "spiral-diag-pixalign-evenodd-fill", draw_spiral_eo_pa_di); - cairo_perf_run (perf, "spiral-diag-pixalign-nonzero-fill", draw_spiral_nz_pa_di); - cairo_perf_run (perf, "spiral-rect-nonalign-evenodd-fill", draw_spiral_eo_na_re); - cairo_perf_run (perf, "spiral-rect-nonalign-nonzero-fill", draw_spiral_nz_na_re); - cairo_perf_run (perf, "spiral-rect-pixalign-evenodd-fill", draw_spiral_eo_pa_re); - cairo_perf_run (perf, "spiral-rect-pixalign-nonzero-fill", draw_spiral_nz_pa_re); - cairo_perf_run (perf, "spiral-nonalign-stroke", draw_spiral_stroke_na); - cairo_perf_run (perf, "spiral-pixalign-stroke", draw_spiral_stroke_pa); + cairo_perf_run (perf, "spiral-box-nonalign-evenodd-fill", draw_spiral_eo_na_box, NULL); + cairo_perf_run (perf, "spiral-box-nonalign-nonzero-fill", draw_spiral_nz_na_box, NULL); + cairo_perf_run (perf, "spiral-box-pixalign-evenodd-fill", draw_spiral_eo_pa_box, NULL); + cairo_perf_run (perf, "spiral-box-pixalign-nonzero-fill", draw_spiral_nz_pa_box, NULL); + cairo_perf_run (perf, "spiral-diag-nonalign-evenodd-fill", draw_spiral_eo_na_di, NULL); + cairo_perf_run (perf, "spiral-diag-nonalign-nonzero-fill", draw_spiral_nz_na_di, NULL); + cairo_perf_run (perf, "spiral-diag-pixalign-evenodd-fill", draw_spiral_eo_pa_di, NULL); + cairo_perf_run (perf, "spiral-diag-pixalign-nonzero-fill", draw_spiral_nz_pa_di, NULL); + cairo_perf_run (perf, "spiral-rect-nonalign-evenodd-fill", draw_spiral_eo_na_re, NULL); + cairo_perf_run (perf, "spiral-rect-nonalign-nonzero-fill", draw_spiral_nz_na_re, NULL); + cairo_perf_run (perf, "spiral-rect-pixalign-evenodd-fill", draw_spiral_eo_pa_re, NULL); + cairo_perf_run (perf, "spiral-rect-pixalign-nonzero-fill", draw_spiral_nz_pa_re, NULL); + cairo_perf_run (perf, "spiral-nonalign-stroke", draw_spiral_stroke_na, NULL); + cairo_perf_run (perf, "spiral-pixalign-stroke", draw_spiral_stroke_pa, NULL); } diff --git a/perf/micro/stroke.c b/perf/micro/stroke.c index 660dce57..950fb486 100644 --- a/perf/micro/stroke.c +++ b/perf/micro/stroke.c @@ -92,6 +92,6 @@ stroke (cairo_perf_t *perf, cairo_t *cr, int width, int height) if (! cairo_perf_can_run (perf, "stroke", NULL)) return; - cairo_perf_cover_sources_and_operators (perf, "stroke", do_stroke); - cairo_perf_cover_sources_and_operators (perf, "strokes", do_strokes); + cairo_perf_cover_sources_and_operators (perf, "stroke", do_stroke, NULL); + cairo_perf_cover_sources_and_operators (perf, "strokes", do_strokes, NULL); } diff --git a/perf/micro/subimage_copy.c b/perf/micro/subimage_copy.c index 0bfad80c..8c70464a 100644 --- a/perf/micro/subimage_copy.c +++ b/perf/micro/subimage_copy.c @@ -73,5 +73,5 @@ subimage_copy (cairo_perf_t *perf, cairo_t *cr, int width, int height) cairo_set_source_surface (cr, image, 0, 0); cairo_surface_destroy (image); - cairo_perf_run (perf, "subimage-copy", do_subimage_copy); + cairo_perf_run (perf, "subimage-copy", do_subimage_copy, NULL); } diff --git a/perf/micro/tessellate.c b/perf/micro/tessellate.c index 9debc539..38effff8 100644 --- a/perf/micro/tessellate.c +++ b/perf/micro/tessellate.c @@ -147,9 +147,9 @@ tessellate (cairo_perf_t *perf, cairo_t *cr, int width, int height) if (! cairo_perf_can_run (perf, "tessellate", NULL)) return; - cairo_perf_run (perf, "tessellate-16", tessellate_16); - cairo_perf_run (perf, "tessellate-64", tessellate_64); - cairo_perf_run (perf, "tessellate-256", tessellate_256); + cairo_perf_run (perf, "tessellate-16", tessellate_16, NULL); + cairo_perf_run (perf, "tessellate-64", tessellate_64, NULL); + cairo_perf_run (perf, "tessellate-256", tessellate_256, NULL); } #if 0 diff --git a/perf/micro/text.c b/perf/micro/text.c index 827bb883..190c3c28 100644 --- a/perf/micro/text.c +++ b/perf/micro/text.c @@ -62,5 +62,5 @@ text (cairo_perf_t *perf, cairo_t *cr, int width, int height) if (! cairo_perf_can_run (perf, "text", NULL)) return; - cairo_perf_cover_sources_and_operators (perf, "text", do_text); + cairo_perf_cover_sources_and_operators (perf, "text", do_text, NULL); } diff --git a/perf/micro/twin.c b/perf/micro/twin.c index b2c37a25..2bc01edf 100644 --- a/perf/micro/twin.c +++ b/perf/micro/twin.c @@ -52,5 +52,5 @@ twin (cairo_perf_t *perf, if (! cairo_perf_can_run (perf, "twin", NULL)) return; - cairo_perf_run (perf, "twin", do_twin); + cairo_perf_run (perf, "twin", do_twin, NULL); } diff --git a/perf/micro/unaligned-clip.c b/perf/micro/unaligned-clip.c index 284c832a..adc44fe8 100644 --- a/perf/micro/unaligned-clip.c +++ b/perf/micro/unaligned-clip.c @@ -66,5 +66,5 @@ unaligned_clip (cairo_perf_t *perf, cairo_t *cr, int width, int height) if (! cairo_perf_can_run (perf, "unaligned-clip", NULL)) return; - cairo_perf_run (perf, "unaligned-clip", do_unaligned_clip); + cairo_perf_run (perf, "unaligned-clip", do_unaligned_clip, NULL); } diff --git a/perf/micro/world-map.c b/perf/micro/world-map.c index 2a455002..42b8da51 100644 --- a/perf/micro/world-map.c +++ b/perf/micro/world-map.c @@ -112,5 +112,5 @@ world_map (cairo_perf_t *perf, cairo_t *cr, int width, int height) if (! cairo_perf_can_run (perf, "world-map", NULL)) return; - cairo_perf_run (perf, "world-map", do_world_map); + cairo_perf_run (perf, "world-map", do_world_map, NULL); } diff --git a/perf/micro/zrusin.c b/perf/micro/zrusin.c index 24aff142..87c8da33 100644 --- a/perf/micro/zrusin.c +++ b/perf/micro/zrusin.c @@ -90,6 +90,6 @@ zrusin (cairo_perf_t *perf, cairo_t *cr, int width, int height) if (! cairo_perf_can_run (perf, "zrusin", NULL)) return; - cairo_perf_run (perf, "zrusin-another-tessellate", zrusin_another_tessellate); - cairo_perf_run (perf, "zrusin-another-fill", zrusin_another_fill); + cairo_perf_run (perf, "zrusin-another-tessellate", zrusin_another_tessellate, NULL); + cairo_perf_run (perf, "zrusin-another-fill", zrusin_another_fill, NULL); } |