2016-05-22 18:17:39 +00:00
|
|
|
# Copyright (c) 2016 Google Inc.
|
|
|
|
#
|
2016-09-01 19:33:59 +00:00
|
|
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
# you may not use this file except in compliance with the License.
|
|
|
|
# You may obtain a copy of the License at
|
2016-05-22 18:17:39 +00:00
|
|
|
#
|
2016-09-01 19:33:59 +00:00
|
|
|
# http://www.apache.org/licenses/LICENSE-2.0
|
2016-05-22 18:17:39 +00:00
|
|
|
#
|
2016-09-01 19:33:59 +00:00
|
|
|
# Unless required by applicable law or agreed to in writing, software
|
|
|
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
# See the License for the specific language governing permissions and
|
|
|
|
# limitations under the License.
|
2016-05-22 18:17:39 +00:00
|
|
|
|
2017-11-27 21:21:26 +00:00
|
|
|
add_subdirectory(dominator_tree)
|
2017-12-21 14:47:25 +00:00
|
|
|
add_subdirectory(loop_optimizations)
|
2017-11-27 21:21:26 +00:00
|
|
|
|
2016-08-25 16:55:44 +00:00
|
|
|
add_spvtools_unittest(TARGET instruction
|
2016-09-22 15:05:30 +00:00
|
|
|
SRCS instruction_test.cpp
|
2016-09-16 20:12:04 +00:00
|
|
|
LIBS SPIRV-Tools-opt
|
2016-08-25 16:55:44 +00:00
|
|
|
)
|
|
|
|
|
2017-10-13 18:25:21 +00:00
|
|
|
add_spvtools_unittest(TARGET instruction_list
|
2017-12-18 22:02:19 +00:00
|
|
|
SRCS instruction_list_test.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
2017-10-13 18:25:21 +00:00
|
|
|
|
2016-05-22 18:17:39 +00:00
|
|
|
add_spvtools_unittest(TARGET ir_loader
|
2016-09-22 15:05:30 +00:00
|
|
|
SRCS ir_loader_test.cpp
|
2016-09-16 20:12:04 +00:00
|
|
|
LIBS SPIRV-Tools-opt
|
2016-05-22 18:17:39 +00:00
|
|
|
)
|
2016-06-28 18:58:17 +00:00
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET pass_manager
|
2016-08-25 22:36:03 +00:00
|
|
|
SRCS module_utils.h
|
2016-09-22 15:05:30 +00:00
|
|
|
pass_manager_test.cpp
|
2016-09-16 20:12:04 +00:00
|
|
|
LIBS SPIRV-Tools-opt
|
2016-06-28 18:58:17 +00:00
|
|
|
)
|
|
|
|
|
2017-04-02 06:17:41 +00:00
|
|
|
add_spvtools_unittest(TARGET optimizer
|
|
|
|
SRCS optimizer_test.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2016-06-28 18:58:17 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_strip_debug_info
|
2016-09-22 15:05:30 +00:00
|
|
|
SRCS strip_debug_info_test.cpp pass_utils.cpp
|
2016-09-16 20:12:04 +00:00
|
|
|
LIBS SPIRV-Tools-opt
|
2016-06-28 18:58:17 +00:00
|
|
|
)
|
|
|
|
|
2018-03-09 21:08:57 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_strip_reflect_info
|
|
|
|
SRCS strip_reflect_info_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2017-04-11 19:11:04 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_compact_ids
|
|
|
|
SRCS compact_ids_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2017-04-01 20:10:16 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_flatten_decoration
|
|
|
|
SRCS flatten_decoration_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2016-07-26 16:11:03 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_freeze_spec_const
|
2016-09-22 15:05:30 +00:00
|
|
|
SRCS freeze_spec_const_test.cpp pass_utils.cpp
|
2017-06-07 21:28:53 +00:00
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET pass_block_merge
|
|
|
|
SRCS block_merge_test.cpp pass_utils.cpp
|
2016-09-16 20:12:04 +00:00
|
|
|
LIBS SPIRV-Tools-opt
|
2016-07-26 16:11:03 +00:00
|
|
|
)
|
|
|
|
|
2016-11-10 17:11:50 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_inline
|
|
|
|
SRCS inline_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2017-08-15 23:58:28 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_inline_opaque
|
|
|
|
SRCS inline_opaque_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2017-05-26 16:33:11 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_insert_extract_elim
|
|
|
|
SRCS insert_extract_elim_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2018-01-27 00:05:33 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_dead_insert_elim
|
|
|
|
SRCS dead_insert_elim_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2017-06-16 21:37:31 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_local_ssa_elim
|
|
|
|
SRCS local_ssa_elim_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2017-05-18 20:51:55 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_local_single_block_elim
|
|
|
|
SRCS local_single_block_elim.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2017-05-12 23:27:21 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_local_access_chain_convert
|
|
|
|
SRCS local_access_chain_convert_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2017-05-19 23:31:28 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_local_single_store_elim
|
|
|
|
SRCS local_single_store_elim_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2017-06-02 19:23:20 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_dead_branch_elim
|
|
|
|
SRCS dead_branch_elim_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2017-10-20 16:17:41 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_dead_variable_elim
|
2017-12-18 22:02:19 +00:00
|
|
|
SRCS dead_variable_elim_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
2017-10-20 16:17:41 +00:00
|
|
|
|
2017-06-08 16:37:21 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_aggressive_dce
|
|
|
|
SRCS aggressive_dead_code_elim_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2017-07-03 23:23:04 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_common_uniform_elim
|
|
|
|
SRCS common_uniform_elim_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2016-07-29 15:35:58 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_eliminate_dead_const
|
2016-09-22 15:05:30 +00:00
|
|
|
SRCS eliminate_dead_const_test.cpp pass_utils.cpp
|
2016-09-16 20:12:04 +00:00
|
|
|
LIBS SPIRV-Tools-opt
|
2016-07-29 15:35:58 +00:00
|
|
|
)
|
|
|
|
|
2017-09-19 14:12:13 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_eliminate_dead_functions
|
|
|
|
SRCS eliminate_dead_functions_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET pass_pass
|
|
|
|
SRCS pass_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2016-06-28 18:58:17 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_utils
|
2016-09-22 15:05:30 +00:00
|
|
|
SRCS utils_test.cpp pass_utils.cpp
|
2016-09-16 20:12:04 +00:00
|
|
|
LIBS SPIRV-Tools-opt
|
2016-06-28 18:58:17 +00:00
|
|
|
)
|
2016-07-27 21:37:04 +00:00
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET def_use
|
2016-09-22 15:05:30 +00:00
|
|
|
SRCS def_use_test.cpp pass_utils.cpp
|
2016-09-16 20:12:04 +00:00
|
|
|
LIBS SPIRV-Tools-opt
|
2016-07-27 21:37:04 +00:00
|
|
|
)
|
2016-08-02 16:08:40 +00:00
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET assembly_builder
|
2016-09-22 15:05:30 +00:00
|
|
|
SRCS assembly_builder_test.cpp pass_utils.cpp
|
2016-09-16 20:12:04 +00:00
|
|
|
LIBS SPIRV-Tools-opt
|
2016-08-02 16:08:40 +00:00
|
|
|
)
|
2016-07-28 16:11:01 +00:00
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET types
|
2016-09-22 15:05:30 +00:00
|
|
|
SRCS types_test.cpp
|
2016-07-28 16:11:01 +00:00
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
2016-07-28 16:15:14 +00:00
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET type_manager
|
2016-09-22 15:05:30 +00:00
|
|
|
SRCS type_manager_test.cpp
|
2016-09-16 20:12:04 +00:00
|
|
|
LIBS SPIRV-Tools-opt
|
2016-07-28 16:15:14 +00:00
|
|
|
)
|
2016-08-10 14:02:28 +00:00
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET iterator
|
2016-09-22 15:05:30 +00:00
|
|
|
SRCS iterator_test.cpp
|
2016-09-16 20:12:04 +00:00
|
|
|
LIBS SPIRV-Tools-opt
|
2016-08-10 14:02:28 +00:00
|
|
|
)
|
2016-08-20 09:51:15 +00:00
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET module
|
2016-08-25 22:36:03 +00:00
|
|
|
SRCS module_utils.h
|
2016-09-22 15:05:30 +00:00
|
|
|
module_test.cpp
|
2016-09-16 20:12:04 +00:00
|
|
|
LIBS SPIRV-Tools-opt
|
2016-08-20 09:51:15 +00:00
|
|
|
)
|
2016-08-04 17:24:08 +00:00
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET pass_fold_spec_const_op_composite
|
2016-09-22 15:05:30 +00:00
|
|
|
SRCS fold_spec_const_op_composite_test.cpp pass_utils.cpp
|
2016-09-16 20:12:04 +00:00
|
|
|
LIBS SPIRV-Tools-opt
|
2016-08-17 21:19:48 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET pass_unify_const
|
2016-09-22 15:05:30 +00:00
|
|
|
SRCS unify_const_test.cpp
|
2016-09-16 20:12:04 +00:00
|
|
|
LIBS SPIRV-Tools-opt
|
2016-08-31 23:37:13 +00:00
|
|
|
)
|
|
|
|
|
2016-08-30 18:57:56 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_set_spec_const_default_value
|
2016-09-22 15:05:30 +00:00
|
|
|
SRCS set_spec_const_default_value_test.cpp pass_utils.cpp
|
2016-09-16 20:12:04 +00:00
|
|
|
LIBS SPIRV-Tools-opt
|
2016-08-30 18:57:56 +00:00
|
|
|
)
|
|
|
|
|
2016-08-31 23:37:13 +00:00
|
|
|
add_spvtools_unittest(TARGET line_debug_info
|
2016-09-22 15:05:30 +00:00
|
|
|
SRCS line_debug_info_test.cpp pass_utils.cpp
|
2016-09-16 20:12:04 +00:00
|
|
|
LIBS SPIRV-Tools-opt
|
2016-08-31 23:37:13 +00:00
|
|
|
)
|
2017-09-08 16:08:03 +00:00
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET pass_strength_reduction
|
|
|
|
SRCS strength_reduction_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
2017-09-06 12:56:41 +00:00
|
|
|
|
2017-11-30 22:03:06 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_scalar_replacement
|
|
|
|
SRCS scalar_replacement_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2017-09-06 12:56:41 +00:00
|
|
|
add_spvtools_unittest(TARGET cfg_cleanup
|
|
|
|
SRCS cfg_cleanup_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
2017-11-02 18:25:48 +00:00
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET ir_context
|
|
|
|
SRCS ir_context_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2017-11-30 22:03:06 +00:00
|
|
|
add_spvtools_unittest(TARGET feature_manager
|
|
|
|
SRCS feature_manager_test.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2017-11-08 21:22:10 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_merge_return
|
|
|
|
SRCS pass_merge_return_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
2017-11-11 01:26:55 +00:00
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET value_table
|
|
|
|
SRCS value_table_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET local_redundancy_elimination
|
|
|
|
SRCS local_redundancy_elimination_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
2017-11-17 13:59:25 +00:00
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET propagator
|
|
|
|
SRCS propagator_test.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
2017-12-04 17:29:51 +00:00
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET redundancy_elimination
|
|
|
|
SRCS redundancy_elimination_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2017-12-11 18:10:24 +00:00
|
|
|
add_spvtools_unittest(TARGET private_to_local
|
|
|
|
SRCS private_to_local_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2017-11-29 23:29:34 +00:00
|
|
|
add_spvtools_unittest(TARGET decoration_manager
|
|
|
|
SRCS decoration_manager_test.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET pass_remove_duplicates
|
|
|
|
SRCS pass_remove_duplicates_test.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
2017-12-05 16:39:25 +00:00
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET ccp
|
|
|
|
SRCS ccp_test.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
2018-01-17 19:57:37 +00:00
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET pass_workaround1209
|
|
|
|
SRCS workaround1209_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
2018-01-18 17:14:58 +00:00
|
|
|
|
2018-01-16 16:15:06 +00:00
|
|
|
add_spvtools_unittest(TARGET pass_if_conversion
|
|
|
|
SRCS if_conversion_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2018-01-18 17:14:58 +00:00
|
|
|
add_spvtools_unittest(TARGET ir_builder
|
|
|
|
SRCS ir_builder.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
2018-01-09 17:45:46 +00:00
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET instruction_folding
|
|
|
|
SRCS fold_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
2018-01-30 16:24:03 +00:00
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET replace_invalid_opc
|
|
|
|
SRCS replace_invalid_opc_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
2018-02-02 16:55:05 +00:00
|
|
|
|
2018-04-17 14:31:09 +00:00
|
|
|
add_spvtools_unittest(TARGET register_liveness
|
|
|
|
SRCS register_liveness.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2018-02-02 16:55:05 +00:00
|
|
|
add_spvtools_unittest(TARGET simplification
|
|
|
|
SRCS simplification_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
2018-03-29 12:39:54 +00:00
|
|
|
|
2018-03-21 03:33:24 +00:00
|
|
|
add_spvtools_unittest(TARGET copy_prop_array
|
|
|
|
SRCS copy_prop_array_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
2018-03-28 13:19:55 +00:00
|
|
|
|
|
|
|
add_spvtools_unittest(TARGET scalar_analysis
|
|
|
|
SRCS scalar_analysis.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2018-04-23 15:13:07 +00:00
|
|
|
add_spvtools_unittest(TARGET vector_dce
|
|
|
|
SRCS vector_dce_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|
|
|
|
|
2018-05-07 16:31:03 +00:00
|
|
|
add_spvtools_unittest(TARGET reduce_load_size
|
|
|
|
SRCS reduce_load_size_test.cpp pass_utils.cpp
|
|
|
|
LIBS SPIRV-Tools-opt
|
|
|
|
)
|