8 Tester
:= Object clone do(
12 self t1
:= Date clone now
16 mps
:= 1 / Date clone now
secondsSince(t1
)
17 //write(t1 asString
, " -> ", Date clone now asString
, "\n")
19 write("Io ", s
, " := ", mps
asString(0,2) , "\n")
25 (oneMillion
/8) repeat(
29 endTimer("slotAccesses ")
32 // t
:= method(x
:= 1; loop(x
= 1)); t
34 testSetSlot
:= method(
37 updateSlot := getSlot("updateSlot")
38 (oneMillion
/8) repeat(
39 x
= 1; x
= 1; x
= 1; x
= 1;
40 x
= 1; x
= 1; x
= 1; x
= 1;
47 (oneMillion
/8) repeat(
51 endTimer("blockActivations ")
54 testInstantiations
:= method(
56 (oneMillion
/8) repeat(
57 Tester
clone; Tester
clone; Tester
clone; Tester
clone;
58 Tester
clone; Tester
clone; Tester
clone; Tester
clone;
60 endTimer("instantiations ")
66 (oneMillion
/8) repeat(
70 endTimer("localAccesses ")
73 testSetLocals
:= method(
75 //updateSlot := getSlot("updateSlot")
77 (oneMillion
/8) repeat(
78 v
= 1; v
= 2; v
= 3; v
= 4;
79 v
= 1; v
= 2; v
= 3; v
= 4;
82 (oneMillion/8) repeat(
83 v = 1; v = 2; v = 3; v = 4;
84 v = 1; v = 2; v = 3; v = 4;
87 endTimer("localSets ")
92 v
:= self getSlot("thisContext")
93 (oneMillion
/8) repeat(
97 endTimer("cfuncActivations ")
111 write("Io version := ", System version
)
113 write("// values in millions per second\n")
117 //1000 repeat(Tester testSetLocals
)