Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • benchmark/mutex/pthreads.c

    rb4107c8 rdc33b5b  
    77
    88void __attribute__((noinline)) call() {
    9          pthread_mutex_lock( &mutex );
    10          pthread_mutex_unlock( &mutex );
     9         pthread_mutex_lock  (&mutex);
     10         pthread_mutex_unlock(&mutex);
    1111}
    12 int main( int argc, char * argv[] ) {
    13         BENCH_START()
     12
     13int main(int argc, char* argv[]) {
    1414        BENCH(
    15                 for ( size_t i = 0; i < times; i++ ) {
     15                for (size_t i = 0; i < n; i++) {
    1616                        call();
    1717                },
    1818                result
    1919        )
    20         printf( "%g\n", result );
     20
     21        printf("%g\n", result);
    2122}
    22 
    23 // Local Variables: //
    24 // tab-width: 4 //
    25 // End: //
Note: See TracChangeset for help on using the changeset viewer.