Ignore:
Timestamp:
Jan 7, 2020, 3:50:56 PM (5 years ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, pthread-emulation, qualifiedEnum
Children:
580c11b
Parents:
846c026
Message:

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

File:
1 edited

Legend:

Unmodified
Added
Removed
  • benchmark/mutex/pthreads.c

    r846c026 rb4107c8  
    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 
    13 int main(int argc, char* argv[]) {
     12int main( int argc, char * argv[] ) {
     13        BENCH_START()
    1414        BENCH(
    15                 for (size_t i = 0; i < n; i++) {
     15                for ( size_t i = 0; i < times; i++ ) {
    1616                        call();
    1717                },
    1818                result
    1919        )
     20        printf( "%g\n", result );
     21}
    2022
    21         printf("%g\n", result);
    22 }
     23// Local Variables: //
     24// tab-width: 4 //
     25// End: //
Note: See TracChangeset for help on using the changeset viewer.