@@ -4,11 +4,11 @@ using Test
44
55function nditeration_testsuite ()
66 @testset " iteration" begin
7- let ndrange = NDRange {2, DynamicSize, DynamicSize} (CartesianIndices ((256 , 256 )), CartesianIndices ((32 , 32 )));
7+ let ndrange = NDRange {2, DynamicSize, DynamicSize} (CartesianIndices ((256 , 256 )), CartesianIndices ((32 , 32 )))
88 @test length (ndrange) == 256 * 256
99 @test all (p -> p[1 ] == p[2 ], zip (ndrange, CartesianIndices ((256 , 256 ))))
1010 end
11- let ndrange = NDRange {2, StaticSize{(256, 256)}, DynamicSize} (nothing , CartesianIndices ((32 , 32 )));
11+ let ndrange = NDRange {2, StaticSize{(256, 256)}, DynamicSize} (nothing , CartesianIndices ((32 , 32 )))
1212 @test length (ndrange) == 256 * 256
1313 @test all (p -> p[1 ] == p[2 ], zip (ndrange, CartesianIndices ((256 , 256 ))))
1414 end
@@ -34,14 +34,14 @@ function nditeration_testsuite()
3434 @testset " linear_iteration" begin
3535 Dim_x = 32
3636 Dim_y = 32
37- let ndrange = NDRange {2, StaticSize{(4, 4)}, StaticSize{(Dim_x, Dim_y)}} ();
37+ let ndrange = NDRange {2, StaticSize{(4, 4)}, StaticSize{(Dim_x, Dim_y)}} ()
3838 idx = linear_iteration (ndrange)
3939 for (i, I) in zip (1 : length (blocks (ndrange)), blocks (ndrange))
4040 I = Tuple (I)
4141 @test check (idx, i - 1 , ntuple (i -> I[i] - 1 , length (I))... , Dim_x, Dim_y)
4242 end
4343 end
44- let ndrange = NDRange {2, DynamicSize, DynamicSize} (CartesianIndices ((4 , 4 )), CartesianIndices ((Dim_x, Dim_y)));
44+ let ndrange = NDRange {2, DynamicSize, DynamicSize} (CartesianIndices ((4 , 4 )), CartesianIndices ((Dim_x, Dim_y)))
4545 idx = linear_iteration (ndrange)
4646 for (i, I) in zip (1 : length (blocks (ndrange)), blocks (ndrange))
4747 I = Tuple (I)
@@ -51,15 +51,15 @@ function nditeration_testsuite()
5151
5252 Dim_x = 32
5353 Dim_y = 1
54- let ndrange = NDRange {2, StaticSize{(4, 4 * 32)}, StaticSize{(Dim_x, Dim_y)}} ();
54+ let ndrange = NDRange {2, StaticSize{(4, 4 * 32)}, StaticSize{(Dim_x, Dim_y)}} ()
5555 idx = linear_iteration (ndrange)
5656 N = length (workitems (ndrange))
5757 for (i, I) in zip (1 : length (blocks (ndrange)), blocks (ndrange))
5858 I = Tuple (I)
5959 @test check (idx, i - 1 , ntuple (i -> I[i] - 1 , length (I))... , Dim_x, Dim_y)
6060 end
6161 end
62- let ndrange = NDRange {2, DynamicSize, DynamicSize} (CartesianIndices ((4 , 4 * 32 )), CartesianIndices ((Dim_x, Dim_y)));
62+ let ndrange = NDRange {2, DynamicSize, DynamicSize} (CartesianIndices ((4 , 4 * 32 )), CartesianIndices ((Dim_x, Dim_y)))
6363 idx = linear_iteration (ndrange)
6464 for (i, I) in zip (1 : length (blocks (ndrange)), blocks (ndrange))
6565 I = Tuple (I)
@@ -69,15 +69,15 @@ function nditeration_testsuite()
6969
7070 Dim_x = 1
7171 Dim_y = 32
72- let ndrange = NDRange {2, StaticSize{(4 * 32, 4)}, StaticSize{(Dim_x, Dim_y)}} ();
72+ let ndrange = NDRange {2, StaticSize{(4 * 32, 4)}, StaticSize{(Dim_x, Dim_y)}} ()
7373 idx = linear_iteration (ndrange)
7474 N = length (workitems (ndrange))
7575 for (i, I) in zip (1 : length (blocks (ndrange)), blocks (ndrange))
7676 I = Tuple (I)
7777 @test check (idx, i - 1 , ntuple (i -> I[i] - 1 , length (I))... , Dim_x, Dim_y)
7878 end
7979 end
80- let ndrange = NDRange {2, DynamicSize, DynamicSize} (CartesianIndices ((4 * 32 , 4 )), CartesianIndices ((Dim_x, Dim_y)));
80+ let ndrange = NDRange {2, DynamicSize, DynamicSize} (CartesianIndices ((4 * 32 , 4 )), CartesianIndices ((Dim_x, Dim_y)))
8181 idx = linear_iteration (ndrange)
8282 for (i, I) in zip (1 : length (blocks (ndrange)), blocks (ndrange))
8383 I = Tuple (I)
0 commit comments