- Timestamp:
- Oct 29, 2019, 4:01:24 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, stuck-waitfor-destruct
- Children:
- 773db65, 9421f3d8
- Parents:
- 7951100 (diff), 8364209 (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. - Location:
- benchmark
- Files:
-
- 23 added
- 35 moved
-
Makefile.am (added)
-
Makefile.in (added)
-
Monitor.c (moved) (moved from src/benchmark/Monitor.c ) (2 diffs)
-
baselines/calc.py (added)
-
baselines/x64/compile.csv (added)
-
baselines/x64/ctxswitch.csv (added)
-
baselines/x64/mutex.csv (added)
-
baselines/x64/signal.csv (added)
-
baselines/x86/compile.csv (added)
-
baselines/x86/ctxswitch.csv (added)
-
baselines/x86/mutex.csv (added)
-
baselines/x86/signal.csv (added)
-
bench.h (moved) (moved from src/benchmark/bench.h ) (2 diffs)
-
c.c (added)
-
compile/empty.cfa (moved) (moved from src/benchmark/compile/empty.c )
-
creation/JavaThread.java (added)
-
creation/cfa_cor.cfa (moved) (moved from src/benchmark/creation/cfa_cor.c ) (3 diffs)
-
creation/cfa_thrd.cfa (moved) (moved from src/benchmark/creation/cfa_thrd.c ) (2 diffs)
-
creation/goroutine.go (moved) (moved from src/benchmark/creation/goroutine.go )
-
creation/pthreads.c (moved) (moved from src/benchmark/creation/pthreads.c ) (1 diff)
-
creation/upp_cor.cc (moved) (moved from src/benchmark/creation/upp_cor.cc ) (1 diff)
-
creation/upp_thrd.cc (moved) (moved from src/benchmark/creation/upp_thrd.cc ) (1 diff)
-
ctxswitch/JavaThread.java (added)
-
ctxswitch/cfa_cor.cfa (moved) (moved from src/benchmark/ctxswitch/cfa_cor.c ) (4 diffs)
-
ctxswitch/cfa_cor_then.cfa (added)
-
ctxswitch/cfa_gen.cfa (added)
-
ctxswitch/cfa_thrd.cfa (added)
-
ctxswitch/cfa_thrd2.cfa (moved) (moved from src/benchmark/ctxswitch/cfa_thrd2.c ) (4 diffs)
-
ctxswitch/goroutine.go (moved) (moved from src/benchmark/ctxswitch/goroutine.go )
-
ctxswitch/kos_fibre.cpp (moved) (moved from src/benchmark/ctxswitch/kos_fibre.cpp ) (1 diff)
-
ctxswitch/kos_fibre2.cpp (moved) (moved from src/benchmark/ctxswitch/kos_fibre2.cpp ) (1 diff)
-
ctxswitch/pthreads.c (moved) (moved from src/benchmark/ctxswitch/pthreads.c ) (1 diff)
-
ctxswitch/upp_cor.cc (moved) (moved from src/benchmark/ctxswitch/upp_cor.cc ) (1 diff)
-
ctxswitch/upp_thrd.cc (moved) (moved from src/benchmark/ctxswitch/upp_thrd.cc ) (1 diff)
-
cxx.cpp (added)
-
fetch_add.c (moved) (moved from src/benchmark/fetch_add.c ) (1 diff)
-
fixcsv.sh (added)
-
function.c (moved) (moved from src/benchmark/function.c ) (1 diff)
-
interrupt_linux.c (moved) (moved from src/benchmark/interrupt_linux.c )
-
loop.c (moved) (moved from src/benchmark/loop.c ) (1 diff)
-
mutex/JavaThread.java (added)
-
mutex/cfa1.cfa (moved) (moved from src/benchmark/mutex/cfa1.c ) (3 diffs)
-
mutex/cfa2.cfa (moved) (moved from src/benchmark/mutex/cfa2.c ) (3 diffs)
-
mutex/cfa4.cfa (moved) (moved from src/benchmark/mutex/cfa4.c ) (3 diffs)
-
mutex/pthreads.c (moved) (moved from src/benchmark/mutex/pthreads.c ) (1 diff)
-
mutex/upp.cc (moved) (moved from src/benchmark/mutex/upp.cc ) (1 diff)
-
schedext/cfa1.cfa (moved) (moved from src/benchmark/schedext/cfa1.c ) (5 diffs)
-
schedext/cfa2.cfa (moved) (moved from src/benchmark/schedext/cfa2.c ) (5 diffs)
-
schedext/cfa4.cfa (moved) (moved from src/benchmark/schedext/cfa4.c ) (5 diffs)
-
schedext/upp.cc (moved) (moved from src/benchmark/schedext/upp.cc ) (1 diff)
-
schedint/JavaThread.java (added)
-
schedint/cfa1.cfa (moved) (moved from src/benchmark/schedint/cfa1.c ) (5 diffs)
-
schedint/cfa2.cfa (moved) (moved from src/benchmark/schedint/cfa2.c ) (5 diffs)
-
schedint/cfa4.cfa (moved) (moved from src/benchmark/schedint/cfa4.c ) (5 diffs)
-
schedint/pthreads.c (moved) (moved from src/benchmark/schedint/pthreads.c ) (3 diffs)
-
schedint/upp.cc (moved) (moved from src/benchmark/schedint/upp.cc ) (2 diffs)
-
tls-fetch_add.c (added)
-
ttst_lock.c (added)
Legend:
- Unmodified
- Added
- Removed
-
benchmark/Monitor.c
r7951100 rb067d9b 1 #include <fstream >2 #include <stdlib >3 #include <thread >1 #include <fstream.hfa> 2 #include <stdlib.hfa> 3 #include <thread.hfa> 4 4 5 5 #include "bench.h" … … 29 29 EndTime = Time(); 30 30 31 sout | ( EndTime - StartTime ) / N | endl;31 sout | ( EndTime - StartTime ) / N; 32 32 } -
benchmark/bench.h
r7951100 rb067d9b 11 11 #else 12 12 } 13 #include <time >13 #include <time.hfa> 14 14 #endif 15 15 … … 45 45 statement; \ 46 46 EndTime = bench_time(); \ 47 unsigned long long intoutput = \48 ( EndTime - StartTime ) / n;47 double output = \ 48 (double)( EndTime - StartTime ) / n; 49 49 50 50 #if defined(__cforall) -
benchmark/creation/cfa_cor.cfa
r7951100 rb067d9b 1 1 #include <stdio.h> 2 #include <coroutine >2 #include <coroutine.hfa> 3 3 4 4 #include "bench.h" … … 7 7 void ?{} (MyCoroutine & this) { 8 8 #ifdef EAGER 9 prime(this);9 resume(this); 10 10 #endif 11 11 } 12 void main(MyCoroutine & this) {}12 void main(MyCoroutine &) {} 13 13 14 14 int main(int argc, char* argv[]) { 15 15 BENCH( 16 for ( size_t i = 0; i < n; i++) {16 for ( i; n ) { 17 17 MyCoroutine m; 18 18 }, … … 20 20 ) 21 21 22 printf("% llu\n", result);22 printf("%g\n", result); 23 23 } -
benchmark/creation/cfa_thrd.cfa
r7951100 rb067d9b 1 1 #include <stdio.h> 2 #include <thread >2 #include <thread.hfa> 3 3 4 4 #include "bench.h" 5 5 6 6 thread MyThread {}; 7 void main(MyThread & this) {}7 void main(MyThread &) {} 8 8 9 9 int main(int argc, char* argv[]) { 10 10 BENCH( 11 for ( size_t i = 0; i < n; i++) {11 for ( i; n ) { 12 12 MyThread m; 13 13 }, … … 15 15 ) 16 16 17 printf("% llu\n", result);17 printf("%g\n", result); 18 18 } -
benchmark/creation/pthreads.c
r7951100 rb067d9b 25 25 ) 26 26 27 printf("% llu\n", result);27 printf("%g\n", result); 28 28 } -
benchmark/creation/upp_cor.cc
r7951100 rb067d9b 15 15 ) 16 16 17 printf("% llu\n", result);17 printf("%g\n", result); 18 18 } -
benchmark/creation/upp_thrd.cc
r7951100 rb067d9b 15 15 ) 16 16 17 printf("% llu\n", result);17 printf("%g\n", result); 18 18 } -
benchmark/ctxswitch/cfa_cor.cfa
r7951100 rb067d9b 1 #include <stdio.h> 2 #include <kernel> 3 #include <thread> 1 #include <kernel.hfa> 2 #include <thread.hfa> 4 3 5 4 #include "bench.h" … … 11 10 } 12 11 13 void main( GreatSuspender & this ) {12 void main( __attribute__((unused)) GreatSuspender & this ) { 14 13 while( true ) { 15 14 suspend(); … … 21 20 22 21 BENCH( 23 for ( size_t i = 0; i < n; i++) {22 for ( i; n ) { 24 23 resume( s ); 25 24 }, … … 27 26 ) 28 27 29 printf("% llu\n", result);28 printf("%g\n", result); 30 29 } -
benchmark/ctxswitch/cfa_thrd2.cfa
r7951100 rb067d9b 1 #include <stdio.h> 2 #include <thread> 1 #include <thread.hfa> 3 2 4 3 #include "bench.h" … … 8 7 thread Fibre {}; 9 8 10 void main( Fibre & this) {9 void main(__attribute__((unused)) Fibre & this) { 11 10 while(!done) { 12 11 yield(); … … 17 16 Fibre f1; 18 17 BENCH( 19 for ( size_t i = 0; i < n; i++) {18 for ( i; n ) { 20 19 yield(); 21 20 }, … … 23 22 ) 24 23 25 printf("% llu\n", result);24 printf("%g\n", result); 26 25 done = true; 27 26 return 0; -
benchmark/ctxswitch/kos_fibre.cpp
r7951100 rb067d9b 10 10 result 11 11 ) 12 printf("% llu\n", result);12 printf("%g\n", result); 13 13 return 0; 14 14 } -
benchmark/ctxswitch/kos_fibre2.cpp
r7951100 rb067d9b 19 19 result 20 20 ) 21 printf("% llu\n", result);21 printf("%g\n", result); 22 22 done = true; 23 23 Fibre::yield(); -
benchmark/ctxswitch/pthreads.c
r7951100 rb067d9b 14 14 ) 15 15 16 printf("% llu\n", result);16 printf("%g\n", result); 17 17 } -
benchmark/ctxswitch/upp_cor.cc
r7951100 rb067d9b 30 30 ) 31 31 32 printf("% llu\n", result);32 printf("%g\n", result); 33 33 } -
benchmark/ctxswitch/upp_thrd.cc
r7951100 rb067d9b 11 11 ) 12 12 13 printf("% llu\n", result);13 printf("%g\n", result); 14 14 } -
benchmark/fetch_add.c
r7951100 rb067d9b 19 19 ) 20 20 21 printf("% llu\n", result);21 printf("%g\n", result); 22 22 } -
benchmark/function.c
r7951100 rb067d9b 15 15 ) 16 16 17 printf("% llu\n", result);17 printf("%g\n", result); 18 18 } -
benchmark/loop.c
r7951100 rb067d9b 11 11 ) 12 12 13 printf("% llu\n", result);13 printf("%g\n", result); 14 14 } -
benchmark/mutex/cfa1.cfa
r7951100 rb067d9b 1 #include <monitor >1 #include <monitor.hfa> 2 2 #include <stdio.h> 3 3 … … 10 10 M m; 11 11 BENCH( 12 for ( size_t i = 0; i < n; i++) {12 for ( i; n ) { 13 13 call(m); 14 14 }, … … 16 16 ) 17 17 18 printf("% llu\n", result);18 printf("%g\n", result); 19 19 } -
benchmark/mutex/cfa2.cfa
r7951100 rb067d9b 1 #include <monitor >1 #include <monitor.hfa> 2 2 #include <stdio.h> 3 3 … … 10 10 M m1, m2; 11 11 BENCH( 12 for ( size_t i = 0; i < n; i++) {12 for ( i; n ) { 13 13 call(m1, m2); 14 14 }, … … 16 16 ) 17 17 18 printf("% llu\n", result);18 printf("%g\n", result); 19 19 } -
benchmark/mutex/cfa4.cfa
r7951100 rb067d9b 1 #include <monitor >1 #include <monitor.hfa> 2 2 #include <stdio.h> 3 3 … … 11 11 M m1, m2, m3, m4; 12 12 BENCH( 13 for ( size_t i = 0; i < n; i++) {13 for ( i; n ) { 14 14 call(m1, m2, m3, m4); 15 15 }, … … 17 17 ) 18 18 19 printf("% llu\n", result);19 printf("%g\n", result); 20 20 } -
benchmark/mutex/pthreads.c
r7951100 rb067d9b 19 19 ) 20 20 21 printf("% llu\n", result);21 printf("%g\n", result); 22 22 } -
benchmark/mutex/upp.cc
r7951100 rb067d9b 17 17 ) 18 18 19 printf("% llu\n", result);19 printf("%g\n", result); 20 20 } -
benchmark/schedext/cfa1.cfa
r7951100 rb067d9b 1 #include <kernel >2 #include <monitor >3 #include <thread >1 #include <kernel.hfa> 2 #include <monitor.hfa> 3 #include <thread.hfa> 4 4 #include <stdio.h> 5 5 … … 18 18 go = 1; 19 19 BENCH( 20 for ( size_t i = 0; i < n; i++) {20 for ( i; n ) { 21 21 waitfor(call, a1); 22 22 }, … … 24 24 ) 25 25 26 printf("% llu\n", result);26 printf("%g\n", result); 27 27 go = 0; 28 28 return 0; … … 31 31 thread T {}; 32 32 void ^?{}( T & mutex this ) {} 33 void main( T & this) {33 void main( T & ) { 34 34 while(go == 0) { yield(); } 35 35 while(go == 1) { call(m1); } … … 37 37 } 38 38 39 int main(int margc, char* margv[]) { 40 argc = margc; 41 argv = margv; 39 int main(__attribute__((unused)) int argc, __attribute__((unused)) char* argv[]) { 42 40 T t; 43 41 return wait(m1); -
benchmark/schedext/cfa2.cfa
r7951100 rb067d9b 1 #include <kernel >2 #include <monitor >3 #include <thread >1 #include <kernel.hfa> 2 #include <monitor.hfa> 3 #include <thread.hfa> 4 4 #include <stdio.h> 5 5 … … 18 18 go = 1; 19 19 BENCH( 20 for ( size_t i = 0; i < n; i++) {20 for ( i; n ) { 21 21 waitfor(call, a1, a2); 22 22 }, … … 24 24 ) 25 25 26 printf("% llu\n", result);26 printf("%g\n", result); 27 27 go = 0; 28 28 return 0; … … 31 31 thread T {}; 32 32 void ^?{}( T & mutex this ) {} 33 void main( T & this) {33 void main( T & ) { 34 34 while(go == 0) { yield(); } 35 35 while(go == 1) { call(m1, m2); } … … 37 37 } 38 38 39 int main(int margc, char* margv[]) { 40 argc = margc; 41 argv = margv; 39 int main(__attribute__((unused)) int argc, __attribute__((unused)) char* argv[]) { 42 40 T t; 43 41 return wait(m1, m2); -
benchmark/schedext/cfa4.cfa
r7951100 rb067d9b 1 #include <kernel >2 #include <monitor >3 #include <thread >1 #include <kernel.hfa> 2 #include <monitor.hfa> 3 #include <thread.hfa> 4 4 #include <stdio.h> 5 5 … … 18 18 go = 1; 19 19 BENCH( 20 for ( size_t i = 0; i < n; i++) {20 for ( i; n ) { 21 21 waitfor(call, a1, a2, a3, a4); 22 22 }, … … 24 24 ) 25 25 26 printf("% llu\n", result);26 printf("%g\n", result); 27 27 go = 0; 28 28 return 0; … … 31 31 thread T {}; 32 32 void ^?{}( T & mutex this ) {} 33 void main( T & this) {33 void main( T & ) { 34 34 while(go == 0) { yield(); } 35 35 while(go == 1) { call(m1, m2, m3, m4); } … … 37 37 } 38 38 39 int main(int margc, char* margv[]) { 40 argc = margc; 41 argv = margv; 39 int main(__attribute__((unused)) int argc, __attribute__((unused)) char* argv[]) { 42 40 T t; 43 41 return wait(m1, m2, m3, m4); -
benchmark/schedext/upp.cc
r7951100 rb067d9b 20 20 ) 21 21 22 printf("% llu\n", result);22 printf("%g\n", result); 23 23 go = 0; 24 24 return 0; -
benchmark/schedint/cfa1.cfa
r7951100 rb067d9b 1 #include <kernel >2 #include <monitor >3 #include <thread >1 #include <kernel.hfa> 2 #include <monitor.hfa> 3 #include <thread.hfa> 4 4 #include <stdio.h> 5 5 … … 21 21 go = 1; 22 22 BENCH( 23 for ( size_t i = 0; i < n; i++) {23 for ( i; n ) { 24 24 wait(c); 25 25 }, … … 27 27 ) 28 28 29 printf("% llu\n", result);29 printf("%g\n", result); 30 30 go = 0; 31 31 return 0; … … 33 33 34 34 thread T {}; 35 void ^?{}( T & mutex this) {}36 void main( T & this) {35 void ^?{}( T & mutex ) {} 36 void main( T & ) { 37 37 while(go == 0) { yield(); } 38 38 while(go == 1) { call(m1); } … … 40 40 } 41 41 42 int main(int margc, char* margv[]) { 43 argc = margc; 44 argv = margv; 42 int main(__attribute__((unused)) int argc, __attribute__((unused)) char* argv[]) { 45 43 T t; 46 44 return wait(m1); -
benchmark/schedint/cfa2.cfa
r7951100 rb067d9b 1 #include <kernel >2 #include <monitor >3 #include <thread >1 #include <kernel.hfa> 2 #include <monitor.hfa> 3 #include <thread.hfa> 4 4 #include <stdio.h> 5 5 … … 21 21 go = 1; 22 22 BENCH( 23 for ( size_t i = 0; i < n; i++) {23 for ( i; n ) { 24 24 wait(c); 25 25 }, … … 27 27 ) 28 28 29 printf("% llu\n", result);29 printf("%g\n", result); 30 30 go = 0; 31 31 return 0; … … 34 34 thread T {}; 35 35 void ^?{}( T & mutex this ) {} 36 void main( T & this) {36 void main( T & ) { 37 37 while(go == 0) { yield(); } 38 38 while(go == 1) { call(m1, m2); } … … 40 40 } 41 41 42 int main(int margc, char* margv[]) { 43 argc = margc; 44 argv = margv; 42 int main(__attribute__((unused)) int argc, __attribute__((unused)) char* argv[]) { 45 43 T t; 46 44 return wait(m1, m2); -
benchmark/schedint/cfa4.cfa
r7951100 rb067d9b 1 #include <kernel >2 #include <monitor >3 #include <thread >1 #include <kernel.hfa> 2 #include <monitor.hfa> 3 #include <thread.hfa> 4 4 #include <stdio.h> 5 5 … … 21 21 go = 1; 22 22 BENCH( 23 for ( size_t i = 0; i < n; i++) {23 for ( i; n ) { 24 24 wait(c); 25 25 }, … … 27 27 ) 28 28 29 printf("% llu\n", result);29 printf("%g\n", result); 30 30 go = 0; 31 31 return 0; … … 34 34 thread T {}; 35 35 void ^?{}( T & mutex this ) {} 36 void main( T & this) {36 void main( T & ) { 37 37 while(go == 0) { yield(); } 38 38 while(go == 1) { call(m1, m2, m3, m4); } … … 40 40 } 41 41 42 int main(int margc, char* margv[]) { 43 argc = margc; 44 argv = margv; 42 int main(__attribute__((unused)) int argc, __attribute__((unused)) char* argv[]) { 45 43 T t; 46 44 return wait(m1, m2, m3, m4); -
benchmark/schedint/pthreads.c
r7951100 rb067d9b 27 27 ) 28 28 29 printf("% llu\n", result);29 printf("%g\n", result); 30 30 go = 0; 31 31 pthread_mutex_unlock(&m); … … 33 33 } 34 34 35 void* thread_main( void * a) {35 void* thread_main(__attribute__((unused)) void * arg ) { 36 36 while(go == 0) { sched_yield(); } 37 37 while(go == 1) { call(); } … … 39 39 } 40 40 41 int main(int margc, char* margv[]) { 42 argc = margc; 43 argv = margv; 41 int main(__attribute__((unused)) int argc, __attribute__((unused)) char* argv[]) { 44 42 pthread_t thread; 45 43 if (pthread_create(&thread, NULL, thread_main, NULL) < 0) { -
benchmark/schedint/upp.cc
r7951100 rb067d9b 23 23 ) 24 24 25 printf("% llu\n", result);25 printf("%g\n", result); 26 26 go = 0; 27 27 return 0; … … 39 39 }; 40 40 41 int main(int margc, char* margv[]) { 42 argc = margc; 43 argv = margv; 41 int main(__attribute__((unused)) int argc, __attribute__((unused)) char* argv[]) { 44 42 T t; 45 43 return m.wait();
Note:
See TracChangeset
for help on using the changeset viewer.