Skip to content

Commit 509fe73

Browse files
committed
test suite
1 parent 276b6a9 commit 509fe73

File tree

3 files changed

+12
-11
lines changed

3 files changed

+12
-11
lines changed

script/testga.ijs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ ECHOFILENAME=: 1 NB. echo file name
1414

1515
stdout LF ,~ 9!:14''
1616

17-
NB. ddall=: ddall -. blacklist=: blacklist, ('OpenBSD'-:UNAME)#(<testpath),each <'gstack.ijs' NB. temporarily disable
17+
ddall=: ddall -. blacklist=: blacklist, ('OpenBSD'-:UNAME)#(<testpath),each <'gstack.ijs' NB. temporarily disable
1818
NB. ddall=: ddall -. blacklist=: blacklist, ('FreeBSD'-:UNAME)#(<testpath),each 'gtdot.ijs';'gtdot1.ijs';'gtdot2.ijs';'gtdot3.ijs';'g13x.ijs';'g7x.ijs' NB. temporarily disable
1919
ddall=: ~. ddall ,~ (IF64*.(<UNAME)e.'Win';'Darwin')#(<testpath),each <'gcip1.ijs'
2020
ddall=: ~. ddall ,~ ((<UNAME)e.'Win';'Darwin')#(<testpath),each <'glapack.ijs'

test/gtdot3.ijs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,9 @@ assert. 2 <: 1 T. ''
5858
NB. verify that tasks go to different threads if possible. We can ensure this only for as many threads as there are cores
5959
setth nwthreads=. 1 >. <: 0 { 8 T. '' NB. one worker thread per core, -1
6060
wthr nwthreads
61-
assert. GITHUBCI +. (>: i. nwthreads) *./@e. aaa__ =: > (3&T.@'')@(6!:3) t.'' "(0) (0.1 #~ <:nwthreads), 0.6
61+
assert. (0[GITHUBCI) +. (>: i. nwthreads) *./@e. aaa__ =: > (3&T.@'')@(6!:3) t.'' "(0) (0.1 #~ <:nwthreads), 0.6
6262
wthr nwthreads
63-
assert. GITHUBCI +. (>: i. nwthreads) *./@e. > (3&T.@'')@(6!:3) t.'' "(0) (0.6 #~ <:nwthreads), 0.1
63+
assert. (0[GITHUBCI) +. (>: i. nwthreads) *./@e. > (3&T.@'')@(6!:3) t.'' "(0) (0.6 #~ <:nwthreads), 0.1
6464
wthr nwthreads
6565
assert. (ccc__ =: ((<_1000) #~ <: nwthreads),(>: i. nwthreads);_1001) e.~&> bbb__ =: 4 T. aaa__ =: (3&T.@'')@(6!:3) t.'' "(0) (0.3 #~ <: nwthreads), 2 1 NB. last thread should run in master; earlier ones complete first
6666
wthr nwthreads
@@ -131,14 +131,14 @@ techo^:chk 'gtdot3 a32b'
131131
NB. the following line hang on freebsd
132132
assert. 1 = 11 T. mtx;2.0
133133
techo^:chk 'gtdot3 a32c'
134-
assert. GITHUBCI +. (2.3 > dly) *. (2-granularity) <: dly =. tod-~6!:1'' NB. verify delay
134+
assert. (0[GITHUBCI) +. (2.3 > dly) *. (2-granularity) <: dly =. tod-~6!:1'' NB. verify delay
135135
techo^:chk 'gtdot3 a32d'
136136
tod =. 6!:1''
137137
assert. 1 = 11 T. mtx;0.1
138-
assert. GITHUBCI +. (0.3 > dly) *. (0.1-granularity) <: dly =. tod-~6!:1'' NB. verify delay
138+
assert. (0[GITHUBCI) +. (0.3 > dly) *. (0.1-granularity) <: dly =. tod-~6!:1'' NB. verify delay
139139
tod =. 6!:1''
140140
assert. 1 = 11 T. mtx;0
141-
assert. GITHUBCI +. (0.3 > dly) *. 0 <: dly =. tod-~6!:1'' NB. verify no delay
141+
assert. (0[GITHUBCI) +. (0.3 > dly) *. 0 <: dly =. tod-~6!:1'' NB. verify no delay
142142
mtx=.10 T. 1 NB. recursive
143143
assert. 0 = 11 T. mtx
144144
assert. 0 = 11 T. mtx NB. lock count=2

test/gtdot4.ijs

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,23 +14,24 @@ NB. Create 1 thread in pool 1; then verify that jobs in pool 1 are faster than t
1414
1: 0 T. 1
1515
1 -: 2 { 2 T. 1 NB. can't rely on waiters: terminating threads may still be waiting, or not started
1616
0 -: 2 { 2 T. 0
17+
granularity=: 2e_13
1718
stime =: 6!:1''
1819
1 = > 6!:3 t. 0"0 ] 6 # 1
19-
GITHUBCI +. 5 < stime -~ 6!:1''
20+
(0[GITHUBCI) +. (5-granularity) < stime -~ 6!:1''
2021
stime =: 6!:1''
2122
1 = > 6!:3 t. 1"0 ] 6 # 1
22-
GITHUBCI +. 5 > stime -~ 6!:1''
23+
(0[GITHUBCI) +. (5-granularity) > stime -~ 6!:1''
2324
delth'' NB. clear all threadpools
2425
0 -: 2 { 2 T. 1
2526
0 -: 2 { 2 T. 0
2627
stime =: 6!:1''
2728
1 = > 6!:3 t. 0"0 ] 6 # 1
28-
GITHUBCI +. 5 < stime -~ 6!:1''
29+
(0[GITHUBCI) +. (5-granularity) < stime -~ 6!:1''
2930
stime =: 6!:1''
3031
1 = > 6!:3 t. 1"0 ] 6 # 1
31-
GITHUBCI +. 5 < stime -~ 6!:1''
32+
(0[GITHUBCI) +. (5-granularity) < stime -~ 6!:1''
3233

33-
4!:55 ;:'delth stime'
34+
4!:55 ;:'delth granularity stime'
3435

3536
epilog''
3637

0 commit comments

Comments
 (0)