1 //
2 // Copyright (c) 2017 The Khronos Group Inc.
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 //    http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 #include "harness/compat.h"
17 
18 #include <stdio.h>
19 #include <string.h>
20 #include "procs.h"
21 #include "harness/testHarness.h"
22 
23 #if !defined(_WIN32)
24 #include <unistd.h>
25 #endif
26 
27 #if DENSE_PACK_VECS
28 const int g_vector_aligns[] = {0, 1, 2, 3, 4,
29                                5, 6, 7, 8,
30                                9, 10, 11, 12,
31                                13, 14, 15, 16};
32 
33 #else
34 const int g_vector_aligns[] = {0, 1, 2, 4, 4,
35                                8, 8, 8, 8,
36                                16, 16, 16, 16,
37                                16, 16, 16, 16};
38 #endif
39 
40 
41 const int g_vector_allocs[] = {0, 1, 2, 4, 4,
42                                8, 8, 8, 8,
43                                16, 16, 16, 16,
44                                16, 16, 16, 16};
45 
46 
47 test_definition test_list[] = {
48     ADD_TEST( relational_any ),
49     ADD_TEST( relational_all ),
50     ADD_TEST( relational_bitselect ),
51     ADD_TEST( relational_select_signed ),
52     ADD_TEST( relational_select_unsigned ),
53 
54     ADD_TEST( relational_isequal ),
55     ADD_TEST( relational_isnotequal ),
56     ADD_TEST( relational_isgreater ),
57     ADD_TEST( relational_isgreaterequal ),
58     ADD_TEST( relational_isless ),
59     ADD_TEST( relational_islessequal ),
60     ADD_TEST( relational_islessgreater ),
61 
62     ADD_TEST( shuffle_copy ),
63     ADD_TEST( shuffle_function_call ),
64     ADD_TEST( shuffle_array_cast ),
65     ADD_TEST( shuffle_built_in ),
66     ADD_TEST( shuffle_built_in_dual_input ),
67 };
68 
69 const int test_num = ARRAY_SIZE( test_list );
70 
main(int argc,const char * argv[])71 int main(int argc, const char *argv[])
72 {
73     return runTestHarness(argc, argv, test_num, test_list, false, 0);
74 }
75 
76