source: benchmark/mutex/upp.cc @ d1f5054

Last change on this file since d1f5054 was b4107c8, checked in by Peter A. Buhr <pabuhr@…>, 5 years ago

update existing benchmarks for changes to bench.h, add new benchmarks in new programming languages

  • Property mode set to 100644
File size: 343 bytes
Line 
1#include <cstdio>
2
3#include "bench.h"
4
5_Monitor MyMonitor {
6public:
7        void __attribute__((noinline)) call() {}
8};
9
10int main( int argc, char * argv[] ) {
11        BENCH_START()
12        MyMonitor m;
13        BENCH(
14                for ( size_t i = 0; i < times; i++ ) {
15                        m.call();
16                },
17                result
18        )
19        printf( "%g\n", result );
20}
21
22// Local Variables: //
23// tab-width: 4 //
24// End: //
Note: See TracBrowser for help on using the repository browser.