blob: a2a54cce56a6bfa20ce6cbe70ee6bbd1ed9501d7 [file] [log] [blame]
Ben Clayton7d81e552023-08-17 12:01:50 +00001# Copyright 2023 The Tint Authors.
2#
3# Licensed under the Apache License, Version 2.0 (the "License");
4# you may not use this file except in compliance with the License.
5# You may obtain a copy of the License at
6#
7# http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS,
11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12# See the License for the specific language governing permissions and
13# limitations under the License.
14
15################################################################################
Ben Clayton57ded6a2023-08-22 13:22:22 +000016# File generated by 'tools/src/cmd/gen' using the template:
Ben Clayton7d81e552023-08-17 12:01:50 +000017# tools/src/cmd/gen/build/BUILD.gn.tmpl
18#
Ben Clayton57ded6a2023-08-22 13:22:22 +000019# To regenerate run: './tools/run gen'
20#
21# Do not modify this file directly
Ben Clayton7d81e552023-08-17 12:01:50 +000022################################################################################
23
Ben Clayton66630762023-08-18 08:29:51 +000024import("../../../../../scripts/tint_overrides_with_defaults.gni")
Ben Clayton7d81e552023-08-17 12:01:50 +000025
26import("${tint_src_dir}/tint.gni")
Ben Clayton0781a512023-08-18 08:25:01 +000027
28if (tint_build_unittests) {
29 import("//testing/test.gni")
30}
dan sinclair3b4b3fd2023-09-07 02:59:30 +000031
32libtint_source_set("ir") {
33 sources = [
34 "access.cc",
35 "access.h",
36 "binary.cc",
37 "binary.h",
38 "bitcast.cc",
39 "bitcast.h",
40 "block.cc",
41 "block.h",
42 "block_param.cc",
43 "block_param.h",
44 "break_if.cc",
45 "break_if.h",
46 "builder.cc",
47 "builder.h",
48 "builtin_call.cc",
49 "builtin_call.h",
50 "call.cc",
51 "call.h",
dan sinclair16cb4bd2023-09-21 08:52:11 +000052 "clone_context.cc",
53 "clone_context.h",
dan sinclair3b4b3fd2023-09-07 02:59:30 +000054 "constant.cc",
55 "constant.h",
56 "construct.cc",
57 "construct.h",
58 "continue.cc",
59 "continue.h",
60 "control_instruction.cc",
61 "control_instruction.h",
62 "convert.cc",
63 "convert.h",
64 "core_builtin_call.cc",
65 "core_builtin_call.h",
66 "disassembler.cc",
67 "disassembler.h",
68 "discard.cc",
69 "discard.h",
70 "exit.cc",
71 "exit.h",
72 "exit_if.cc",
73 "exit_if.h",
74 "exit_loop.cc",
75 "exit_loop.h",
76 "exit_switch.cc",
77 "exit_switch.h",
78 "function.cc",
79 "function.h",
80 "function_param.cc",
81 "function_param.h",
82 "if.cc",
83 "if.h",
84 "instruction.cc",
85 "instruction.h",
86 "instruction_result.cc",
87 "instruction_result.h",
dan sinclair3b4b3fd2023-09-07 02:59:30 +000088 "let.cc",
89 "let.h",
90 "load.cc",
91 "load.h",
92 "load_vector_element.cc",
93 "load_vector_element.h",
94 "location.h",
95 "loop.cc",
96 "loop.h",
97 "module.cc",
98 "module.h",
99 "multi_in_block.cc",
100 "multi_in_block.h",
101 "next_iteration.cc",
102 "next_iteration.h",
103 "operand_instruction.cc",
104 "operand_instruction.h",
105 "return.cc",
106 "return.h",
107 "store.cc",
108 "store.h",
109 "store_vector_element.cc",
110 "store_vector_element.h",
111 "switch.cc",
112 "switch.h",
113 "swizzle.cc",
114 "swizzle.h",
115 "terminate_invocation.cc",
116 "terminate_invocation.h",
117 "terminator.cc",
118 "terminator.h",
119 "unary.cc",
120 "unary.h",
121 "unreachable.cc",
122 "unreachable.h",
123 "user_call.cc",
124 "user_call.h",
125 "validator.cc",
126 "validator.h",
127 "value.cc",
128 "value.h",
129 "var.cc",
130 "var.h",
131 ]
132 deps = [
133 "${tint_src_dir}/api/common",
134 "${tint_src_dir}/lang/core",
135 "${tint_src_dir}/lang/core/constant",
136 "${tint_src_dir}/lang/core/intrinsic",
137 "${tint_src_dir}/lang/core/intrinsic/data",
138 "${tint_src_dir}/lang/core/type",
139 "${tint_src_dir}/utils/containers",
140 "${tint_src_dir}/utils/diagnostic",
141 "${tint_src_dir}/utils/ice",
142 "${tint_src_dir}/utils/id",
143 "${tint_src_dir}/utils/macros",
144 "${tint_src_dir}/utils/math",
145 "${tint_src_dir}/utils/memory",
146 "${tint_src_dir}/utils/reflection",
147 "${tint_src_dir}/utils/result",
148 "${tint_src_dir}/utils/rtti",
149 "${tint_src_dir}/utils/symbol",
150 "${tint_src_dir}/utils/text",
151 "${tint_src_dir}/utils/traits",
152 ]
153}
154if (tint_build_unittests) {
155 tint_unittests_source_set("unittests") {
156 testonly = true
Ben Clayton7d81e552023-08-17 12:01:50 +0000157 sources = [
dan sinclair3b4b3fd2023-09-07 02:59:30 +0000158 "access_test.cc",
159 "binary_test.cc",
160 "bitcast_test.cc",
161 "block_param_test.cc",
162 "block_test.cc",
163 "break_if_test.cc",
164 "constant_test.cc",
165 "construct_test.cc",
166 "continue_test.cc",
167 "convert_test.cc",
168 "core_builtin_call_test.cc",
169 "discard_test.cc",
170 "exit_if_test.cc",
171 "exit_loop_test.cc",
172 "exit_switch_test.cc",
173 "function_param_test.cc",
174 "function_test.cc",
175 "if_test.cc",
176 "instruction_result_test.cc",
177 "instruction_test.cc",
178 "ir_helper_test.h",
179 "let_test.cc",
180 "load_test.cc",
181 "load_vector_element_test.cc",
182 "loop_test.cc",
183 "module_test.cc",
184 "multi_in_block_test.cc",
185 "next_iteration_test.cc",
186 "operand_instruction_test.cc",
187 "return_test.cc",
188 "store_test.cc",
189 "store_vector_element_test.cc",
190 "switch_test.cc",
191 "swizzle_test.cc",
dan sinclair16cb4bd2023-09-21 08:52:11 +0000192 "terminate_invocation_test.cc",
dan sinclair3b4b3fd2023-09-07 02:59:30 +0000193 "unary_test.cc",
dan sinclair16cb4bd2023-09-21 08:52:11 +0000194 "unreachable_test.cc",
dan sinclair3b4b3fd2023-09-07 02:59:30 +0000195 "user_call_test.cc",
196 "validator_test.cc",
197 "value_test.cc",
198 "var_test.cc",
Ben Clayton7d81e552023-08-17 12:01:50 +0000199 ]
200 deps = [
dan sinclair3b4b3fd2023-09-07 02:59:30 +0000201 "${tint_src_dir}:gmock_and_gtest",
Ben Clayton7d81e552023-08-17 12:01:50 +0000202 "${tint_src_dir}/api/common",
203 "${tint_src_dir}/lang/core",
204 "${tint_src_dir}/lang/core/constant",
dan sinclairb88e1c72023-09-07 13:59:10 +0000205 "${tint_src_dir}/lang/core/intrinsic",
206 "${tint_src_dir}/lang/core/intrinsic/data",
dan sinclair3b4b3fd2023-09-07 02:59:30 +0000207 "${tint_src_dir}/lang/core/ir",
Ben Clayton7d81e552023-08-17 12:01:50 +0000208 "${tint_src_dir}/lang/core/type",
209 "${tint_src_dir}/utils/containers",
210 "${tint_src_dir}/utils/diagnostic",
211 "${tint_src_dir}/utils/ice",
212 "${tint_src_dir}/utils/id",
213 "${tint_src_dir}/utils/macros",
214 "${tint_src_dir}/utils/math",
215 "${tint_src_dir}/utils/memory",
216 "${tint_src_dir}/utils/reflection",
217 "${tint_src_dir}/utils/result",
218 "${tint_src_dir}/utils/rtti",
219 "${tint_src_dir}/utils/symbol",
220 "${tint_src_dir}/utils/text",
221 "${tint_src_dir}/utils/traits",
222 ]
223 }
224}