Home
last modified time | relevance | path

Searched refs:nir_alu_instr (Results 1 – 25 of 145) sorted by relevance

123456

/third_party/mesa3d/src/compiler/nir/
Dnir_search_helpers.h36 is_pos_power_of_two(UNUSED struct hash_table *ht, const nir_alu_instr *instr, in is_pos_power_of_two()
68 is_neg_power_of_two(UNUSED struct hash_table *ht, const nir_alu_instr *instr, in is_neg_power_of_two()
97 is_bitcount2(UNUSED struct hash_table *ht, const nir_alu_instr *instr, in is_bitcount2()
117 const nir_alu_instr *instr, \
142 is_zero_to_one(UNUSED struct hash_table *ht, const nir_alu_instr *instr, in is_zero_to_one()
174 is_gt_0_and_lt_1(UNUSED struct hash_table *ht, const nir_alu_instr *instr, in is_gt_0_and_lt_1()
200 is_not_const_zero(UNUSED struct hash_table *ht, const nir_alu_instr *instr, in is_not_const_zero()
230 is_ult_0xfffc07fc(UNUSED struct hash_table *ht, const nir_alu_instr *instr, in is_ult_0xfffc07fc()
251 is_first_5_bits_uge_2(UNUSED struct hash_table *ht, const nir_alu_instr *instr, in is_first_5_bits_uge_2()
271 is_not_const(UNUSED struct hash_table *ht, const nir_alu_instr *instr, in is_not_const()
[all …]
Dnir_opt_rematerialize_compares.c31 is_two_src_comparison(const nir_alu_instr *instr) in is_two_src_comparison()
61 all_srcs_are_ssa(const nir_alu_instr *instr) in all_srcs_are_ssa()
73 all_uses_are_bcsel(const nir_alu_instr *instr) in all_uses_are_bcsel()
82 nir_alu_instr *const alu = nir_instr_as_alu(use->parent_instr); in all_uses_are_bcsel()
107 nir_alu_instr *const alu = nir_instr_as_alu(instr); in nir_opt_rematerialize_compares_impl()
136 nir_alu_instr *clone = nir_alu_instr_clone(shader, alu); in nir_opt_rematerialize_compares_impl()
140 nir_alu_instr *const use_alu = nir_instr_as_alu(use_instr); in nir_opt_rematerialize_compares_impl()
163 nir_alu_instr *clone = nir_alu_instr_clone(shader, alu); in nir_opt_rematerialize_compares_impl()
Dnir_opt_copy_propagate.c36 is_swizzleless_move(nir_alu_instr *instr) in is_swizzleless_move()
60 rewrite_to_vec(nir_function_impl *impl, nir_alu_instr *mov, nir_alu_instr *vec) in rewrite_to_vec()
70 nir_alu_instr *new_vec = nir_alu_instr_create(b.shader, nir_op_vec(num_comp)); in rewrite_to_vec()
84 copy_propagate_alu(nir_function_impl *impl, nir_alu_src *src, nir_alu_instr *copy) in copy_propagate_alu()
87 nir_alu_instr *user = nir_instr_as_alu(src->src.parent_instr); in copy_propagate_alu()
115 copy_propagate(nir_src *src, nir_alu_instr *copy) in copy_propagate()
126 copy_propagate_if(nir_src *src, nir_alu_instr *copy) in copy_propagate_if()
142 nir_alu_instr *mov = nir_instr_as_alu(instr); in copy_prop_instr()
Dnir_lower_flrp.c37 append_flrp_to_dead_list(struct u_vector *dead_flrp, struct nir_alu_instr *alu) in append_flrp_to_dead_list()
39 struct nir_alu_instr **tail = u_vector_add(dead_flrp); in append_flrp_to_dead_list()
48 struct nir_alu_instr *alu) in replace_with_strict_ffma()
77 struct nir_alu_instr *alu) in replace_with_single_ffma()
110 struct nir_alu_instr *alu) in replace_with_strict()
146 struct nir_alu_instr *alu) in replace_with_fast()
181 struct nir_alu_instr *alu, bool subtract_c) in replace_with_expanded_ffma_and_add()
225 all_same_constant(const nir_alu_instr *instr, unsigned src, double *result) in all_same_constant()
259 sources_are_constants_with_similar_magnitudes(const nir_alu_instr *instr) in sources_are_constants_with_similar_magnitudes()
330 get_similar_flrp_stats(nir_alu_instr *alu, struct similar_flrp_stats *st) in get_similar_flrp_stats()
[all …]
Dnir_opt_comparison_pre.c108 if (!u_vector_init_pow2(&bi->instructions, 8, sizeof(nir_alu_instr *))) { in push_block()
128 nir_alu_instr *alu) in add_instruction_for_block()
130 nir_alu_instr **data = in add_instruction_for_block()
137 rewrite_compare_instruction(nir_builder *bld, nir_alu_instr *orig_cmp, in rewrite_compare_instruction()
138 nir_alu_instr *orig_add, bool zero_on_left) in rewrite_compare_instruction()
173 nir_alu_instr *mov_add = nir_alu_instr_create(bld->shader, nir_op_mov); in rewrite_compare_instruction()
182 nir_alu_instr *mov_cmp = nir_alu_instr_create(bld->shader, nir_op_mov); in rewrite_compare_instruction()
228 nir_alu_instr *const alu = nir_instr_as_alu(instr); in comparison_pre_block()
247 nir_alu_instr **a; in comparison_pre_block()
251 nir_alu_instr *const cmp = *a; in comparison_pre_block()
Dnir_opt_remove_phis.c31 static nir_alu_instr *
37 nir_alu_instr *alu = nir_instr_as_alu(ssa->parent_instr); in get_parent_mov()
42 matching_mov(nir_alu_instr *mov1, nir_ssa_def *ssa) in matching_mov()
47 nir_alu_instr *mov2 = get_parent_mov(ssa); in matching_mov()
78 nir_alu_instr *mov = NULL; in remove_phis_block()
Dnir_lower_alu_width.c49 nir_alu_instr *alu = nir_instr_as_alu(instr); in inst_is_vector_alu()
74 alu_is_swizzled_in_bounds(const nir_alu_instr *alu, unsigned width) in alu_is_swizzled_in_bounds()
91 nir_alu_ssa_dest_init(nir_alu_instr *alu, unsigned num_components, in nir_alu_ssa_dest_init()
100 lower_reduction(nir_alu_instr *alu, nir_op chan_op, nir_op merge_op, in lower_reduction()
107 nir_alu_instr *chan = nir_alu_instr_create(builder->shader, chan_op); in lower_reduction()
146 lower_fdot(nir_alu_instr *alu, nir_builder *builder) in lower_fdot()
158 nir_alu_instr *instr = nir_alu_instr_create( in lower_fdot()
181 nir_alu_instr *alu = nir_instr_as_alu(instr); in lower_alu_instr_width()
377 nir_alu_instr *vec = nir_alu_instr_create(b->shader, nir_op_vec(num_components)); in lower_alu_instr_width()
381 nir_alu_instr *lower = nir_alu_instr_create(b->shader, alu->op); in lower_alu_instr_width()
Dnir_lower_vec_to_movs.c62 insert_mov(nir_alu_instr *vec, unsigned start_idx, nir_shader *shader) in insert_mov()
70 nir_alu_instr *mov = nir_alu_instr_create(shader, nir_op_mov); in insert_mov()
117 has_replicated_dest(nir_alu_instr *alu) in has_replicated_dest()
131 try_coalesce(nir_alu_instr *vec, unsigned start_idx, void *_data) in try_coalesce()
161 nir_alu_instr *src_alu = in try_coalesce()
242 nir_alu_instr *vec = nir_instr_as_alu(instr); in nir_lower_vec_to_movs_instr()
Dnir_opt_undef.c39 opt_undef_csel(nir_alu_instr *instr) in opt_undef_csel()
77 opt_undef_vecN(nir_builder *b, nir_alu_instr *alu) in opt_undef_vecN()
109 nir_alu_instr *alu = nir_instr_as_alu(instr); in nir_get_undef_mask()
174 nir_alu_instr *alu = nir_instr_as_alu(instr); in nir_opt_undef_instr()
Dnir_opt_vectorize.c73 nir_alu_instr *alu = nir_instr_as_alu(instr); in hash_instr()
120 nir_alu_instr *alu1 = nir_instr_as_alu(instr1); in instrs_equal()
121 nir_alu_instr *alu2 = nir_instr_as_alu(instr2); in instrs_equal()
142 nir_alu_instr *alu = nir_instr_as_alu(instr); in instr_can_rewrite()
192 nir_alu_instr *alu1 = nir_instr_as_alu(instr1); in instr_try_combine()
193 nir_alu_instr *alu2 = nir_instr_as_alu(instr2); in instr_try_combine()
208 nir_alu_instr *new_alu = nir_alu_instr_create(b.shader, alu1->op); in instr_try_combine()
290 nir_alu_instr *use = nir_instr_as_alu(src->parent_instr); in instr_try_combine()
Dnir_lower_to_source_mods.c60 nir_alu_instr *alu = nir_instr_as_alu(instr); in nir_lower_to_source_mods_block()
72 nir_alu_instr *parent = nir_instr_as_alu(alu->src[i].src.ssa->parent_instr); in nir_lower_to_source_mods_block()
171 nir_alu_instr *child_alu = nir_instr_as_alu(child); in nir_lower_to_source_mods_block()
191 nir_alu_instr *child_alu = nir_instr_as_alu(child_src->parent_instr); in nir_lower_to_source_mods_block()
Dnir_builder.c66 nir_builder_alu_instr_finish_and_insert(nir_builder *build, nir_alu_instr *instr) in nir_builder_alu_instr_finish_and_insert()
131 nir_alu_instr *instr = nir_alu_instr_create(build->shader, op); in nir_build_alu()
149 nir_alu_instr *instr = nir_alu_instr_create(build->shader, op); in nir_build_alu1()
162 nir_alu_instr *instr = nir_alu_instr_create(build->shader, op); in nir_build_alu2()
176 nir_alu_instr *instr = nir_alu_instr_create(build->shader, op); in nir_build_alu3()
191 nir_alu_instr *instr = nir_alu_instr_create(build->shader, op); in nir_build_alu4()
208 nir_alu_instr *instr = nir_alu_instr_create(build->shader, op); in nir_build_alu_src_arr()
222 nir_alu_instr *instr = nir_alu_instr_create(build->shader, op); in nir_vec_scalars()
271 nir_ssa_for_alu_src(nir_builder *build, nir_alu_instr *instr, unsigned srcn) in nir_ssa_for_alu_src()
Dnir_search.h195 typedef bool (*nir_search_expression_cond)(const nir_alu_instr *instr);
197 const nir_alu_instr *instr,
241 nir_replace_instr(struct nir_builder *b, nir_alu_instr *instr,
Dnir_instr_set.c110 hash_alu(uint32_t hash, const nir_alu_instr *instr) in hash_alu()
360 static nir_alu_instr *
363 nir_alu_instr *alu = nir_src_as_alu_instr(s); in get_neg_instr()
426 nir_alu_srcs_negative_equal(const nir_alu_instr *alu1, in nir_alu_srcs_negative_equal()
427 const nir_alu_instr *alu2, in nir_alu_srcs_negative_equal()
487 nir_alu_instr *neg1 = get_neg_instr(alu1->src[src1].src); in nir_alu_srcs_negative_equal()
504 nir_alu_instr *neg2 = get_neg_instr(alu2->src[src2].src); in nir_alu_srcs_negative_equal()
529 nir_alu_srcs_equal(const nir_alu_instr *alu1, const nir_alu_instr *alu2, in nir_alu_srcs_equal()
560 nir_alu_instr *alu1 = nir_instr_as_alu(instr1); in nir_instrs_equal()
561 nir_alu_instr *alu2 = nir_instr_as_alu(instr2); in nir_instrs_equal()
Dnir_opt_intrinsics.c56 try_opt_bcsel_of_shuffle(nir_builder *b, nir_alu_instr *alu, in try_opt_bcsel_of_shuffle()
94 opt_intrinsics_alu(nir_builder *b, nir_alu_instr *alu, in opt_intrinsics_alu()
134 nir_alu_instr *alu = nir_instr_as_alu(use_src->parent_instr); in opt_intrinsics_intrin()
/third_party/mesa3d/src/compiler/nir/tests/
Dserialize_tests.cpp38 nir_alu_instr *get_last_alu(nir_shader *);
39 void ASSERT_SWIZZLE_EQ(nir_alu_instr *, nir_alu_instr *, unsigned count, unsigned src);
88 nir_alu_instr *
96 nir_serialize_test::ASSERT_SWIZZLE_EQ(nir_alu_instr *a, nir_alu_instr *b, unsigned c, unsigned s) in ASSERT_SWIZZLE_EQ()
130 nir_alu_instr *fmax_alu = nir_instr_as_alu(fmax->parent_instr); in TEST_P()
137 nir_alu_instr *fmax_alu_dup = get_last_alu(dup); in TEST_P()
154 nir_alu_instr *vec_alu = nir_instr_as_alu(vec->parent_instr); in TEST_P()
160 nir_alu_instr *vec_alu_dup = get_last_alu(dup); in TEST_P()
169 nir_alu_instr *fma_alu = nir_instr_as_alu(fma->parent_instr); in TEST_P()
180 nir_alu_instr *fma_alu_dup = get_last_alu(dup); in TEST_P()
[all …]
Dssa_def_bits_used_tests.cpp45 nir_alu_instr *build_alu_instr(nir_op op, nir_ssa_def *, nir_ssa_def *);
57 nir_alu_instr *
66 nir_alu_instr *alu = nir_instr_as_alu(def->parent_instr); in build_alu_instr()
86 nir_alu_instr *alu = build_alu_instr(nir_op_iand, src0, src1); in TEST_F()
115 nir_alu_instr *alu = build_alu_instr(nir_op_ior, src0, src1); in TEST_F()
147 nir_alu_instr *alu = build_alu_instr(nir_op_extract_i16, src0, src1); in TEST_F()
178 nir_alu_instr *alu = build_alu_instr(nir_op_extract_u16, src0, src1); in TEST_F()
209 nir_alu_instr *alu = build_alu_instr(nir_op_extract_i8, src0, src1); in TEST_F()
240 nir_alu_instr *alu = build_alu_instr(nir_op_extract_u8, src0, src1); in TEST_F()
Dnegative_equal_tests.cpp141 nir_alu_instr *instr = nir_instr_as_alu(result->parent_instr);
155 nir_alu_instr *instr = nir_instr_as_alu(result->parent_instr); in TEST_F()
175 nir_alu_instr *instr = nir_instr_as_alu(result->parent_instr); in TEST_F()
195 nir_alu_instr *instr = nir_instr_as_alu(result->parent_instr); in TEST_F()
219 nir_alu_instr *instr = nir_instr_as_alu(result->parent_instr); \
259 nir_alu_instr *instr = nir_instr_as_alu(result->parent_instr); \ in compare_with_self()
286 nir_alu_instr *instr = nir_alu_instr_create(bld.shader, nir_op_fadd);
306 nir_alu_instr *instr = nir_instr_as_alu(result->parent_instr); in TEST_F()
/third_party/mesa3d/src/gallium/drivers/r600/sfn/
Dsfn_instr_alu.cpp1089 static bool emit_alu_b2x(const nir_alu_instr& alu, AluInlineConstants mask, Shader& shader);
1091 static bool emit_alu_op1(const nir_alu_instr& alu, EAluOp opcode, Shader& shader,
1093 static bool emit_alu_op1_64bit(const nir_alu_instr& alu, EAluOp opcode, Shader& shader, bool switch…
1094 static bool emit_alu_mov_64bit(const nir_alu_instr& alu, Shader& shader);
1095 static bool emit_alu_neg(const nir_alu_instr& alu, Shader& shader);
1096 static bool emit_alu_op1_64bit_trans(const nir_alu_instr& alu, EAluOp opcode, Shader& shader);
1097 static bool emit_alu_op2_64bit(const nir_alu_instr& alu, EAluOp opcode, Shader& shader, bool switch…
1098 static bool emit_alu_op2_64bit_one_dst(const nir_alu_instr& alu, EAluOp opcode, Shader& shader, boo…
1099 static bool emit_alu_fma_64bit(const nir_alu_instr& alu, EAluOp opcode, Shader& shader);
1100 static bool emit_alu_b2f64(const nir_alu_instr& alu, Shader& shader);
[all …]
/third_party/mesa3d/src/imagination/rogue/
Drogue_nir_helpers.h40 static inline unsigned nir_alu_dest_regindex(const nir_alu_instr *alu) in nir_alu_dest_regindex()
47 static inline unsigned nir_alu_dest_comp(const nir_alu_instr *alu) in nir_alu_dest_comp()
55 static inline unsigned nir_alu_src_regindex(const nir_alu_instr *alu, in nir_alu_src_regindex()
64 static inline uint32_t nir_alu_src_const(const nir_alu_instr *alu, size_t src) in nir_alu_src_const()
74 static inline bool nir_alu_src_is_const(const nir_alu_instr *alu, size_t src) in nir_alu_src_is_const()
Drogue.c147 setup_alu_dest(struct rogue_instr *instr, size_t dest_index, nir_alu_instr *alu) in setup_alu_dest()
190 static bool trans_nir_alu_fmax(struct rogue_shader *shader, nir_alu_instr *alu) in trans_nir_alu_fmax()
218 static bool trans_nir_alu_fmin(struct rogue_shader *shader, nir_alu_instr *alu) in trans_nir_alu_fmin()
247 nir_alu_instr *alu) in trans_nir_alu_mov_imm()
263 static bool trans_nir_alu_mov(struct rogue_shader *shader, nir_alu_instr *alu) in trans_nir_alu_mov()
290 nir_alu_instr *alu) in trans_nir_alu_pack_unorm_4x8()
318 static bool trans_nir_alu_fmul(struct rogue_shader *shader, nir_alu_instr *alu) in trans_nir_alu_fmul()
339 static bool trans_nir_alu_ffma(struct rogue_shader *shader, nir_alu_instr *alu) in trans_nir_alu_ffma()
365 static bool trans_nir_alu(struct rogue_shader *shader, nir_alu_instr *alu) in trans_nir_alu()
/third_party/mesa3d/src/intel/compiler/
Dbrw_nir_opt_peephole_ffma.c48 nir_alu_instr *use_alu = nir_instr_as_alu(use_instr); in are_all_uses_fadd()
69 static nir_alu_instr *
80 nir_alu_instr *alu = nir_instr_as_alu(instr); in get_mul_for_src()
173 nir_alu_instr *add = nir_instr_as_alu(instr); in brw_nir_opt_peephole_ffma_instr()
191 nir_alu_instr *mul; in brw_nir_opt_peephole_ffma_instr()
237 nir_alu_instr *ffma = nir_alu_instr_create(b->shader, nir_op_ffma); in brw_nir_opt_peephole_ffma_instr()
Dbrw_nir_lower_conversions.c54 split_conversion(nir_builder *b, nir_alu_instr *alu, nir_op op1, nir_op op2) in split_conversion()
66 lower_alu_instr(nir_builder *b, nir_alu_instr *alu) in lower_alu_instr()
134 nir_alu_instr *alu = nir_instr_as_alu(instr); in lower_instr()
/third_party/mesa3d/src/gallium/drivers/etnaviv/
Detnaviv_nir.c75 nir_alu_instr *alu = nir_instr_as_alu(ssa->parent_instr); in etna_lower_io()
128 nir_alu_instr *vec = nir_alu_instr_create(shader, nir_op_vec4); in etna_lower_io()
163 nir_alu_instr *alu = nir_instr_as_alu(instr); in etna_lower_alu_impl()
188 nir_alu_instr *mul = nir_alu_instr_create(shader, nir_op_fmul); in etna_lower_alu_impl()
/third_party/mesa3d/src/freedreno/ir3/
Dir3_nir_opt_preamble.c58 nir_alu_instr *use_alu = nir_instr_as_alu(use_instr); in all_uses_float()
89 nir_alu_instr *use_alu = nir_instr_as_alu(use_instr); in all_uses_bit()
127 nir_alu_instr *alu = nir_instr_as_alu(instr); in instr_cost()
233 nir_alu_instr *alu = nir_instr_as_alu(parent_instr); in rewrite_cost()

123456