meson.build revision 9f464c52
101e04c3fSmrg# Copyright © 2017 Intel Corporation 201e04c3fSmrg 301e04c3fSmrg# Permission is hereby granted, free of charge, to any person obtaining a copy 401e04c3fSmrg# of this software and associated documentation files (the "Software"), to deal 501e04c3fSmrg# in the Software without restriction, including without limitation the rights 601e04c3fSmrg# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 701e04c3fSmrg# copies of the Software, and to permit persons to whom the Software is 801e04c3fSmrg# furnished to do so, subject to the following conditions: 901e04c3fSmrg 1001e04c3fSmrg# The above copyright notice and this permission notice shall be included in 1101e04c3fSmrg# all copies or substantial portions of the Software. 1201e04c3fSmrg 1301e04c3fSmrg# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 1401e04c3fSmrg# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 1501e04c3fSmrg# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 1601e04c3fSmrg# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 1701e04c3fSmrg# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 1801e04c3fSmrg# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 1901e04c3fSmrg# SOFTWARE. 2001e04c3fSmrg 2101e04c3fSmrglibintel_compiler_files = files( 2201e04c3fSmrg 'brw_cfg.cpp', 2301e04c3fSmrg 'brw_cfg.h', 2401e04c3fSmrg 'brw_clip.h', 2501e04c3fSmrg 'brw_clip_line.c', 2601e04c3fSmrg 'brw_clip_point.c', 2701e04c3fSmrg 'brw_clip_tri.c', 2801e04c3fSmrg 'brw_clip_unfilled.c', 2901e04c3fSmrg 'brw_clip_util.c', 3001e04c3fSmrg 'brw_compile_clip.c', 3101e04c3fSmrg 'brw_compile_sf.c', 3201e04c3fSmrg 'brw_compiler.c', 3301e04c3fSmrg 'brw_compiler.h', 3401e04c3fSmrg 'brw_dead_control_flow.cpp', 3501e04c3fSmrg 'brw_dead_control_flow.h', 369f464c52Smaya 'brw_debug_recompile.c', 3701e04c3fSmrg 'brw_disasm.c', 3801e04c3fSmrg 'brw_disasm_info.c', 3901e04c3fSmrg 'brw_disasm_info.h', 4001e04c3fSmrg 'brw_eu.c', 4101e04c3fSmrg 'brw_eu_compact.c', 4201e04c3fSmrg 'brw_eu_defines.h', 4301e04c3fSmrg 'brw_eu_emit.c', 4401e04c3fSmrg 'brw_eu.h', 4501e04c3fSmrg 'brw_eu_util.c', 4601e04c3fSmrg 'brw_eu_validate.c', 4701e04c3fSmrg 'brw_fs_bank_conflicts.cpp', 4801e04c3fSmrg 'brw_fs_builder.h', 4901e04c3fSmrg 'brw_fs_cmod_propagation.cpp', 5001e04c3fSmrg 'brw_fs_combine_constants.cpp', 5101e04c3fSmrg 'brw_fs_copy_propagation.cpp', 5201e04c3fSmrg 'brw_fs.cpp', 5301e04c3fSmrg 'brw_fs_cse.cpp', 5401e04c3fSmrg 'brw_fs_dead_code_eliminate.cpp', 5501e04c3fSmrg 'brw_fs_generator.cpp', 5601e04c3fSmrg 'brw_fs.h', 5701e04c3fSmrg 'brw_fs_live_variables.cpp', 5801e04c3fSmrg 'brw_fs_live_variables.h', 5901e04c3fSmrg 'brw_fs_lower_pack.cpp', 609f464c52Smaya 'brw_fs_lower_regioning.cpp', 6101e04c3fSmrg 'brw_fs_nir.cpp', 6201e04c3fSmrg 'brw_fs_reg_allocate.cpp', 6301e04c3fSmrg 'brw_fs_register_coalesce.cpp', 6401e04c3fSmrg 'brw_fs_saturate_propagation.cpp', 6501e04c3fSmrg 'brw_fs_sel_peephole.cpp', 6601e04c3fSmrg 'brw_fs_validate.cpp', 6701e04c3fSmrg 'brw_fs_visitor.cpp', 6801e04c3fSmrg 'brw_inst.h', 6901e04c3fSmrg 'brw_interpolation_map.c', 7001e04c3fSmrg 'brw_ir_allocator.h', 7101e04c3fSmrg 'brw_ir_fs.h', 7201e04c3fSmrg 'brw_ir_vec4.h', 7301e04c3fSmrg 'brw_nir.h', 7401e04c3fSmrg 'brw_nir.c', 7501e04c3fSmrg 'brw_nir_analyze_boolean_resolves.c', 7601e04c3fSmrg 'brw_nir_analyze_ubo_ranges.c', 7701e04c3fSmrg 'brw_nir_attribute_workarounds.c', 789f464c52Smaya 'brw_nir_lower_conversions.c', 7901e04c3fSmrg 'brw_nir_lower_cs_intrinsics.c', 8001e04c3fSmrg 'brw_nir_lower_image_load_store.c', 819f464c52Smaya 'brw_nir_lower_mem_access_bit_sizes.c', 8201e04c3fSmrg 'brw_nir_opt_peephole_ffma.c', 8301e04c3fSmrg 'brw_nir_tcs_workarounds.c', 8401e04c3fSmrg 'brw_packed_float.c', 8501e04c3fSmrg 'brw_predicated_break.cpp', 8601e04c3fSmrg 'brw_reg.h', 8701e04c3fSmrg 'brw_reg_type.c', 8801e04c3fSmrg 'brw_reg_type.h', 8901e04c3fSmrg 'brw_schedule_instructions.cpp', 9001e04c3fSmrg 'brw_shader.cpp', 9101e04c3fSmrg 'brw_shader.h', 9201e04c3fSmrg 'brw_vec4_builder.h', 9301e04c3fSmrg 'brw_vec4_cmod_propagation.cpp', 9401e04c3fSmrg 'brw_vec4_copy_propagation.cpp', 9501e04c3fSmrg 'brw_vec4.cpp', 9601e04c3fSmrg 'brw_vec4_cse.cpp', 9701e04c3fSmrg 'brw_vec4_dead_code_eliminate.cpp', 9801e04c3fSmrg 'brw_vec4_generator.cpp', 9901e04c3fSmrg 'brw_vec4_gs_visitor.cpp', 10001e04c3fSmrg 'brw_vec4_gs_visitor.h', 10101e04c3fSmrg 'brw_vec4.h', 10201e04c3fSmrg 'brw_vec4_live_variables.cpp', 10301e04c3fSmrg 'brw_vec4_live_variables.h', 10401e04c3fSmrg 'brw_vec4_nir.cpp', 10501e04c3fSmrg 'brw_vec4_gs_nir.cpp', 10601e04c3fSmrg 'brw_vec4_reg_allocate.cpp', 10701e04c3fSmrg 'brw_vec4_surface_builder.cpp', 10801e04c3fSmrg 'brw_vec4_surface_builder.h', 10901e04c3fSmrg 'brw_vec4_tcs.cpp', 11001e04c3fSmrg 'brw_vec4_tcs.h', 11101e04c3fSmrg 'brw_vec4_tes.cpp', 11201e04c3fSmrg 'brw_vec4_tes.h', 11301e04c3fSmrg 'brw_vec4_visitor.cpp', 11401e04c3fSmrg 'brw_vec4_vs_visitor.cpp', 11501e04c3fSmrg 'brw_vec4_vs.h', 11601e04c3fSmrg 'brw_vue_map.c', 11701e04c3fSmrg 'brw_wm_iz.cpp', 11801e04c3fSmrg 'gen6_gs_visitor.cpp', 11901e04c3fSmrg 'gen6_gs_visitor.h', 12001e04c3fSmrg) 12101e04c3fSmrg 12201e04c3fSmrgbrw_nir_trig = custom_target( 12301e04c3fSmrg 'brw_nir_trig_workarounds.c', 12401e04c3fSmrg input : 'brw_nir_trig_workarounds.py', 12501e04c3fSmrg output : 'brw_nir_trig_workarounds.c', 12601e04c3fSmrg command : [ 12701e04c3fSmrg prog_python, '@INPUT@', 12801e04c3fSmrg '-p', join_paths(meson.source_root(), 'src/compiler/nir/'), 12901e04c3fSmrg ], 13001e04c3fSmrg depend_files : nir_algebraic_py, 13101e04c3fSmrg capture : true, 13201e04c3fSmrg) 13301e04c3fSmrg 13401e04c3fSmrglibintel_compiler = static_library( 13501e04c3fSmrg 'intel_compiler', 13601e04c3fSmrg [libintel_compiler_files, brw_nir_trig, ir_expression_operation_h], 13701e04c3fSmrg include_directories : [inc_common, inc_intel], 13801e04c3fSmrg c_args : [c_vis_args, no_override_init_args], 13901e04c3fSmrg cpp_args : [cpp_vis_args], 14001e04c3fSmrg dependencies : idep_nir_headers, 14101e04c3fSmrg build_by_default : false, 14201e04c3fSmrg) 14301e04c3fSmrg 14401e04c3fSmrgif with_tests 14501e04c3fSmrg # The last two tests are not C++ or gtest, pre comment in autotools make 14601e04c3fSmrg foreach t : ['fs_cmod_propagation', 'fs_copy_propagation', 14701e04c3fSmrg 'fs_saturate_propagation', 'vf_float_conversions', 14801e04c3fSmrg 'vec4_register_coalesce', 'vec4_copy_propagation', 14901e04c3fSmrg 'vec4_cmod_propagation', 'vec4_dead_code_eliminate', 15001e04c3fSmrg 'eu_compact', 'eu_validate'] 15101e04c3fSmrg test( 15201e04c3fSmrg t, 15301e04c3fSmrg executable( 15401e04c3fSmrg [t, ir_expression_operation_h], 15501e04c3fSmrg 'test_@0@.cpp'.format(t), 15601e04c3fSmrg include_directories : [inc_common, inc_intel], 15701e04c3fSmrg link_with : [ 15801e04c3fSmrg libintel_compiler, libintel_common, libintel_dev, libmesa_util, libisl, 15901e04c3fSmrg ], 16001e04c3fSmrg dependencies : [dep_thread, dep_dl, idep_gtest, idep_nir], 1619f464c52Smaya ), 1629f464c52Smaya suite : ['intel'], 16301e04c3fSmrg ) 16401e04c3fSmrg endforeach 16501e04c3fSmrgendif 166