aboutsummaryrefslogtreecommitdiffstats
path: root/src/benchmarks/eo/eo_bench_eo_do.c
blob: f03aa910e04890fc27632a056a5f3fc7652d4bc8 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#ifdef HAVE_CONFIG_H
# include <config.h>
#endif

#include "Eo.h"
#include "eo_bench.h"
#include "class_simple.h"

static void
bench_eo_do_general(int request)
{
   int i;
   Eo *obj = eo_add(SIMPLE_CLASS, NULL);
   for (i = 0 ; i < request ; i++)
     {
        eo_do(obj, simple_a_set(i));
     }

   eo_unref(obj);
}

void eo_bench_eo_do(Eina_Benchmark *bench)
{
   eina_benchmark_register(bench, "various",
         EINA_BENCHMARK(bench_eo_do_general), 1000, 100000, 500);
}