Changes in src/benchmark/PthrdCtxSwitch.c [d67cdb7:f1dd17a]
- File:
-
- 1 edited
-
src/benchmark/PthrdCtxSwitch.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/benchmark/PthrdCtxSwitch.c
rd67cdb7 rf1dd17a 1 1 #include <stdio.h> 2 2 #include <stdlib.h> 3 #define _GNU_SOURCE 4 #include < pthread.h>3 4 #include <sched.h> 5 5 6 6 #include "bench.h" … … 12 12 StartTime = Time(); 13 13 for ( volatile unsigned int i = 0; i < NoOfTimes; i += 1 ) { 14 pthread_yield();14 sched_yield(); 15 15 } 16 16 EndTime = Time();
Note:
See TracChangeset
for help on using the changeset viewer.