@@ -7,7 +7,6 @@ module Main where
77
88import Foreign.C (CInt )
99import SDL
10- import SDL.Vect
1110import Weigh
1211
1312-- | Main entry point.
@@ -17,76 +16,76 @@ main =
1716
1817 mainWith
1918 (do setColumns [Case , Allocated , GCs ]
20- -- sequence_
21- -- [ validateAction
22- -- ("pollEvent " ++ show i)
23- -- pollEventTest
24- -- i
25- -- (\weight ->
26- -- if weightGCs weight > 0
27- -- then Just "Non-zero number of garbage collections!"
28- -- else if weightAllocatedBytes weight > 2000
29- -- then Just
30- -- "Allocated >2KB! Allocations should be constant."
31- -- else Nothing)
32- -- | i <- [1, 10, 100, 1000, 10000]
33- -- ]
34- -- sequence_
35- -- [ validateAction
36- -- ("pollEvent + clear " ++ show i)
37- -- pollEventClearTest
38- -- i
39- -- (\weight ->
40- -- if weightGCs weight > 0
41- -- then Just "Non-zero number of garbage collections!"
42- -- else if weightAllocatedBytes weight > 3000
43- -- then Just
44- -- "Allocated >3KB! Allocations should be constant."
45- -- else Nothing)
46- -- | i <- [1, 10, 100, 1000, 10000]
47- -- ]
48- -- sequence_
49- -- [ validateAction
50- -- ("pollEvent + present " ++ show i)
51- -- pollEventPresentTest
52- -- i
53- -- (\weight ->
54- -- if weightGCs weight > 0
55- -- then Just "Non-zero number of garbage collections!"
56- -- else if weightAllocatedBytes weight > 4000
57- -- then Just
58- -- "Allocated >4KB! Allocations should be constant."
59- -- else Nothing)
60- -- | i <- [1, 10, 100, 1000]
61- -- ]
62- -- sequence_
63- -- [ validateAction
64- -- ("pollEvent + drawColor " ++ show i)
65- -- pollEventDrawColorTest
66- -- i
67- -- (\weight ->
68- -- if weightGCs weight > 0
69- -- then Just "Non-zero number of garbage collections!"
70- -- else if weightAllocatedBytes weight > 4000
71- -- then Just
72- -- "Allocated >KB! Allocations should be constant."
73- -- else Nothing)
74- -- | i <- [1, 10, 100, 1000, 2000]
75- -- ]
76- -- sequence_
77- -- [ validateAction
78- -- ("pollEvent + drawRect " ++ show i)
79- -- pollEventDrawRectTest
80- -- i
81- -- (\weight ->
82- -- if weightGCs weight > 0
83- -- then Just "Non-zero number of garbage collections!"
84- -- else if weightAllocatedBytes weight > 4000
85- -- then Just
86- -- "Allocated >4KB! Allocations should be constant."
87- -- else Nothing)
88- -- | i <- [1, 10, 100, 1000]
89- -- ]
19+ sequence_
20+ [ validateAction
21+ (" pollEvent " ++ show i)
22+ pollEventTest
23+ i
24+ (\ weight ->
25+ if weightGCs weight > 0
26+ then Just " Non-zero number of garbage collections!"
27+ else if weightAllocatedBytes weight > 2000
28+ then Just
29+ " Allocated >2KB! Allocations should be constant."
30+ else Nothing )
31+ | i <- [1 , 10 , 100 , 1000 , 10000 ]
32+ ]
33+ sequence_
34+ [ validateAction
35+ (" pollEvent + clear " ++ show i)
36+ pollEventClearTest
37+ i
38+ (\ weight ->
39+ if weightGCs weight > 0
40+ then Just " Non-zero number of garbage collections!"
41+ else if weightAllocatedBytes weight > 3000
42+ then Just
43+ " Allocated >3KB! Allocations should be constant."
44+ else Nothing )
45+ | i <- [1 , 10 , 100 , 1000 , 10000 ]
46+ ]
47+ sequence_
48+ [ validateAction
49+ (" pollEvent + present " ++ show i)
50+ pollEventPresentTest
51+ i
52+ (\ weight ->
53+ if weightGCs weight > 0
54+ then Just " Non-zero number of garbage collections!"
55+ else if weightAllocatedBytes weight > 4000
56+ then Just
57+ " Allocated >4KB! Allocations should be constant."
58+ else Nothing )
59+ | i <- [1 , 10 , 100 , 1000 ]
60+ ]
61+ sequence_
62+ [ validateAction
63+ (" pollEvent + drawColor " ++ show i)
64+ pollEventDrawColorTest
65+ i
66+ (\ weight ->
67+ if weightGCs weight > 0
68+ then Just " Non-zero number of garbage collections!"
69+ else if weightAllocatedBytes weight > 4000
70+ then Just
71+ " Allocated >KB! Allocations should be constant."
72+ else Nothing )
73+ | i <- [1 , 10 , 100 , 1000 , 2000 ]
74+ ]
75+ sequence_
76+ [ validateAction
77+ (" pollEvent + drawRect " ++ show i)
78+ pollEventDrawRectTest
79+ i
80+ (\ weight ->
81+ if weightGCs weight > 0
82+ then Just " Non-zero number of garbage collections!"
83+ else if weightAllocatedBytes weight > 4000
84+ then Just
85+ " Allocated >4KB! Allocations should be constant."
86+ else Nothing )
87+ | i <- [1 , 10 , 100 , 1000 ]
88+ ]
9089 sequence_
9190 [ validateAction
9291 (" animated rect " ++ show i)
0 commit comments