mesa-gl:moved to "simplified /usr" and towards RCS
[nyanlinux.git] / builders / mesa-gl-amd-sh-fcf1a8062ba3a058d25620f90d5af8f4bfa0cce7 / contrib / compiler_aco.sh
blob54cd0e6b45ff7cf15d012494968b37a349c13979
1 printf "\tbuilding aco compiler sub-components-->\n"
2 #===============================================================================
3 mkdir -p $build_dir/src/amd/compiler
4 #------------------------------------------------------------------------------
5 # Gaben did not get the memo about c++ toxicity. That said, this is orders
6 # of magnitude less worse than llvm.
7 libaco_cxx_pathnames="\
8 $src_dir/src/amd/compiler/aco_form_hard_clauses.cpp \
9 $src_dir/src/amd/compiler/aco_dead_code_analysis.cpp \
10 $src_dir/src/amd/compiler/aco_dominance.cpp \
11 $src_dir/src/amd/compiler/aco_instruction_selection.cpp \
12 $src_dir/src/amd/compiler/aco_instruction_selection_setup.cpp \
13 $src_dir/src/amd/compiler/aco_interface.cpp \
14 $src_dir/src/amd/compiler/aco_assembler.cpp \
15 $src_dir/src/amd/compiler/aco_insert_exec_mask.cpp \
16 $src_dir/src/amd/compiler/aco_insert_NOPs.cpp \
17 $src_dir/src/amd/compiler/aco_insert_waitcnt.cpp \
18 $src_dir/src/amd/compiler/aco_ir.cpp \
19 $src_dir/src/amd/compiler/aco_reduce_assign.cpp \
20 $src_dir/src/amd/compiler/aco_reindex_ssa.cpp \
21 $src_dir/src/amd/compiler/aco_register_allocation.cpp \
22 $src_dir/src/amd/compiler/aco_live_var_analysis.cpp \
23 $src_dir/src/amd/compiler/aco_lower_phis.cpp \
24 $src_dir/src/amd/compiler/aco_lower_to_cssa.cpp \
25 $src_dir/src/amd/compiler/aco_lower_to_hw_instr.cpp \
26 $build_dir/src/amd/compiler/aco_opcodes.cpp \
27 $src_dir/src/amd/compiler/aco_optimizer.cpp \
28 $src_dir/src/amd/compiler/aco_optimizer_postRA.cpp \
29 $src_dir/src/amd/compiler/aco_opt_value_numbering.cpp \
30 $src_dir/src/amd/compiler/aco_print_asm.cpp \
31 $src_dir/src/amd/compiler/aco_print_ir.cpp \
32 $src_dir/src/amd/compiler/aco_scheduler.cpp \
33 $src_dir/src/amd/compiler/aco_scheduler_ilp.cpp \
34 $src_dir/src/amd/compiler/aco_ssa_elimination.cpp \
35 $src_dir/src/amd/compiler/aco_spill.cpp \
36 $src_dir/src/amd/compiler/aco_statistics.cpp \
37 $src_dir/src/amd/compiler/aco_validate.cpp \
39 #------------------------------------------------------------------------------
40 for src_pathname in $libaco_cxx_pathnames
42 cxxpp_filename=$(basename $src_pathname .cpp).cpp.cxx
43 printf "CXXPP $src_pathname --> $build_dir/src/amd/compiler/$cxxpp_filename\n"
44 $cxxpp $src_pathname -o $build_dir/src/amd/compiler/$cxxpp_filename \
45 -I$cc_internal_fixed_incdir \
46 -I$cc_internal_incdir \
47 -I$cxx_internal_incdir \
48 -I$linux_incdir \
49 -I$syslib_incdir \
51 -I$build_dir/src/amd/compiler \
52 -I$src_dir/src/amd/compiler \
53 -I$src_dir/src/amd/vulkan \
54 -I$build_dir/src/amd/common \
55 -I$src_dir/src/amd/common \
56 -I$build_dir/src/amd \
57 -I$src_dir/src/amd \
58 -I$build_dir/src/compiler/nir \
59 -I$src_dir/src/compiler/nir \
60 -I$build_dir/src/compiler \
61 -I$src_dir/src/compiler \
62 -I$build_dir/src/mesa \
63 -I$src_dir/src/mesa \
64 -I$build_dir/src/gallium/include \
65 -I$src_dir/src/gallium/include \
66 -I$build_dir/src \
67 -I$src_dir/src \
68 -I$build_dir/include \
69 -I$src_dir/include \
71 $syslib_cpp_flags_defs \
72 $linux_cpp_flags_defs \
73 $cc_builtins_cpp_flags_defs \
74 $cc_attributes_cpp_flags_defs \
75 $mesa_cpp_flags_defs \
77 $external_deps_cpp_flags &
78 done
79 #------------------------------------------------------------------------------
80 wait
81 #------------------------------------------------------------------------------
82 for src_pathname in $libaco_cxx_pathnames
84 cxxpp_filename=$(basename $src_pathname .cpp).cpp.cxx
85 asm_filename=$(basename $src_pathname .cpp).cpp.cxx.s
86 printf "CXX_S $build_dir/src/amd/compiler/$cxxpp_filename --> $build_dir/src/amd/compiler/$asm_filename\n"
87 $cxx_s $build_dir/src/amd/compiler/$cxxpp_filename -o $build_dir/src/amd/compiler/$asm_filename &
88 done
89 #------------------------------------------------------------------------------
90 wait
91 #------------------------------------------------------------------------------
92 libaco_a=
93 for src_pathname in $libaco_cxx_pathnames
95 asm_filename=$(basename $src_pathname .cpp).cpp.cxx.s
96 o_filename=$(basename $src_pathname .cpp).cpp.cxx.s.o
97 libaco_a="$libaco_a $build_dir/src/amd/compiler/$o_filename"
98 printf "AS $build_dir/src/amd/compiler/$asm_filename --> $build_dir/src/amd/compiler/$o_filename\n"
99 $as $build_dir/src/amd/compiler/$asm_filename -o $build_dir/src/amd/compiler/$o_filename &
100 done
101 #------------------------------------------------------------------------------
102 wait
103 #------------------------------------------------------------------------------
104 printf "AR RCS $build_dir/libaco.a $libaco_a\n"
105 $ar_rcs $build_dir/libaco.a $libaco_a &
106 #===============================================================================
107 printf "\t<--aco compiler sub-components built\n"