Changeset 3d5701e for benchmark/basic/ttst_lock.c
- Timestamp:
- Feb 25, 2020, 1:17:33 PM (6 years ago)
- 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:
- 7dc2e015
- Parents:
- 9fb8f01 (diff), dd9e1ca (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)links above to see all the changes relative to each parent. - File:
-
- 1 moved
-
benchmark/basic/ttst_lock.c (moved) (moved from benchmark/ttst_lock.c ) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
benchmark/basic/ttst_lock.c
r9fb8f01 r3d5701e 3 3 4 4 #include "bench.h" 5 6 // Does a "lock xchg" on entry but a simple "mov" on exit => cheaper as 0 contention. While it has much more code, the 7 // bulk is never run. 5 8 6 9 #define CALIGN __attribute__(( aligned (CACHE_ALIGN) )) … … 35 38 } 36 39 37 int main(int argc, char* argv[]) { 40 int main( int argc, char * argv[] ) { 41 BENCH_START() 38 42 BENCH( 39 for (size_t i = 0; i < n; i++) {43 for (size_t i = 0; i < times; i++) { 40 44 do_call(); 41 45 }, 42 46 result 43 ) 44 45 printf("%g\n", result); 47 ) 48 printf( "%g\n", result ); 46 49 } 47 50
Note:
See TracChangeset
for help on using the changeset viewer.