Home
last modified time | relevance | path

Searched refs:Swizzle (Results 1 - 25 of 133) sorted by relevance

123456

/third_party/mesa3d/src/mesa/program/
H A Dprogramopt.c95 newInst[i].SrcReg[0].Swizzle = SWIZZLE_NOOP; in insert_mvp_dp4_code()
98 newInst[i].SrcReg[1].Swizzle = SWIZZLE_NOOP; in insert_mvp_dp4_code()
166 newInst[0].SrcReg[0].Swizzle = SWIZZLE_XXXX; in insert_mvp_mad_code()
169 newInst[0].SrcReg[1].Swizzle = SWIZZLE_NOOP; in insert_mvp_mad_code()
178 newInst[i].SrcReg[0].Swizzle = MAKE_SWIZZLE4(i,i,i,i); in insert_mvp_mad_code()
181 newInst[i].SrcReg[1].Swizzle = SWIZZLE_NOOP; in insert_mvp_mad_code()
184 newInst[1].SrcReg[2].Swizzle = SWIZZLE_NOOP; in insert_mvp_mad_code()
193 newInst[3].SrcReg[0].Swizzle = SWIZZLE_WWWW; in insert_mvp_mad_code()
196 newInst[3].SrcReg[1].Swizzle = SWIZZLE_NOOP; in insert_mvp_mad_code()
199 newInst[3].SrcReg[2].Swizzle in insert_mvp_mad_code()
[all...]
H A Dprog_instruction.c49 inst[i].SrcReg[0].Swizzle = SWIZZLE_NOOP; in _mesa_init_instructions()
51 inst[i].SrcReg[1].Swizzle = SWIZZLE_NOOP; in _mesa_init_instructions()
53 inst[i].SrcReg[2].Swizzle = SWIZZLE_NOOP; in _mesa_init_instructions()
/third_party/mesa3d/src/gallium/drivers/r300/compiler/tests/
H A Drc_test_helpers.c121 struct match_info Swizzle; member
161 tokens.Swizzle.String = src_str + matches[5].rm_so; in init_rc_normal_src()
162 tokens.Swizzle.Length = match_length(matches, 5); in init_rc_normal_src()
193 /* Swizzle */ in init_rc_normal_src()
194 if (tokens.Swizzle.Length == 0) { in init_rc_normal_src()
195 src_reg->Swizzle = RC_SWIZZLE_XYZW; in init_rc_normal_src()
198 src_reg->Swizzle = RC_MAKE_SWIZZLE_SMEAR(RC_SWIZZLE_UNUSED); in init_rc_normal_src()
199 if (tokens.Swizzle.String[0] != '.') { in init_rc_normal_src()
203 for (i = 0; i < 4 && str_index < tokens.Swizzle.Length; in init_rc_normal_src()
205 if (tokens.Swizzle in init_rc_normal_src()
[all...]
/third_party/mesa3d/src/mesa/main/
H A Dformat_parser.py109 class Swizzle: class
112 A Swizzle is a mapping from one set of channels in one format to the
124 Sometimes a Swizzle is represented by a 4-character string. In this
146 """Creates a Swizzle object from a string or array."""
148 swizzle = [Swizzle.__identity_str.index(c) for c in swizzle]
152 assert isinstance(s, int) and 0 <= s and s <= Swizzle.SWIZZLE_NONE
156 self.__list = swizzle + [Swizzle.SWIZZLE_NONE] * (4 - len(swizzle))
160 """Returns an iterator that iterates over this Swizzle.
168 """Returns a string representation of this Swizzle."""
169 return ''.join(Swizzle
[all...]
/third_party/skia/third_party/externals/tint/src/sem/
H A Dmember_accessor_expression.cc22 TINT_INSTANTIATE_TYPEINFO(tint::sem::Swizzle); variable
44 Swizzle::Swizzle(const ast::MemberAccessorExpression* declaration, in Swizzle() function in tint::sem::Swizzle
50 Swizzle::~Swizzle() = default;
H A Dmember_accessor_expression.h78 /// Swizzle holds the semantic information for a ast::MemberAccessorExpression
80 class Swizzle : public Castable<Swizzle, MemberAccessorExpression> { class
87 Swizzle(const ast::MemberAccessorExpression* declaration,
93 ~Swizzle() override;
/third_party/mesa3d/src/gallium/drivers/r300/compiler/
H A Dradeon_dataflow_swizzles.c49 if (GET_SWZ(inst->U.I.SrcReg[src].Swizzle, chan) != RC_SWIZZLE_UNUSED) in rewrite_source()
68 SET_SWZ(mov->U.I.SrcReg[0].Swizzle, chan, RC_SWIZZLE_UNUSED); in rewrite_source()
81 inst->U.I.SrcReg[src].Swizzle = 0; in rewrite_source()
85 SET_SWZ(inst->U.I.SrcReg[src].Swizzle, chan, in rewrite_source()
110 unsigned swz = GET_SWZ(reg->Swizzle, chan); in try_rewrite_constant()
120 new_swizzle = reg->Swizzle; in try_rewrite_constant()
130 unsigned chan_swz = GET_SWZ(reg->Swizzle, chan); in try_rewrite_constant()
151 /* Swizzle .W. is never legal. */ in try_rewrite_constant()
322 swz3 = GET_SWZ(reg->Swizzle, 3); in try_rewrite_constant()
329 unsigned old_swz = GET_SWZ(reg->Swizzle, cha in try_rewrite_constant()
[all...]
H A Dradeon_pair_translate.c48 inst->SrcReg[1].Swizzle = RC_SWIZZLE_1111; in final_rewrite()
69 inst->SrcReg[1].Swizzle = RC_SWIZZLE_1111; in final_rewrite()
71 inst->SrcReg[2].Swizzle = RC_SWIZZLE_0000; in final_rewrite()
76 inst->SrcReg[2].Swizzle = RC_SWIZZLE_0000; in final_rewrite()
139 unsigned int swz = GET_SWZ(src.Swizzle, j); in src_uses()
226 unsigned int swz = GET_SWZ(inst->SrcReg[i].Swizzle, j); in set_pair_instruction()
244 pair->RGB.Arg[i].Swizzle = in set_pair_instruction()
245 rc_init_swizzle(inst->SrcReg[i].Swizzle, 3); in set_pair_instruction()
254 swz = rc_get_scalar_src_swz(inst->SrcReg[i].Swizzle); in set_pair_instruction()
256 swz = GET_SWZ(inst->SrcReg[i].Swizzle, in set_pair_instruction()
[all...]
H A Dradeon_program_tex.c41 reg.Swizzle = combine_swizzles(RC_SWIZZLE_0000, in shadow_fail_value()
52 reg.Swizzle = combine_swizzles(RC_SWIZZLE_1111, in shadow_pass_value()
96 inst_rcp->U.I.SrcReg[0].Swizzle = in projective_divide()
97 RC_MAKE_SWIZZLE_SMEAR(GET_SWZ(inst->U.I.SrcReg[0].Swizzle, 3)); in projective_divide()
106 inst_mul->U.I.SrcReg[1].Swizzle = RC_SWIZZLE_WWWW; in projective_divide()
184 inst_rcp->U.I.SrcReg[0].Swizzle = in radeonTransformTEX()
185 RC_MAKE_SWIZZLE_SMEAR(GET_SWZ(inst->U.I.SrcReg[0].Swizzle, 3)); in radeonTransformTEX()
196 inst_mul->U.I.SrcReg[0].Swizzle = in radeonTransformTEX()
197 RC_MAKE_SWIZZLE_SMEAR(GET_SWZ(inst->U.I.SrcReg[0].Swizzle, 2)); in radeonTransformTEX()
201 inst_mul->U.I.SrcReg[1].Swizzle in radeonTransformTEX()
[all...]
H A Dradeon_compiler_util.c210 sub->Arg[i].Swizzle = in rc_pair_rewrite_writemask()
211 rc_adjust_channels(sub->Arg[i].Swizzle, in rc_pair_rewrite_writemask()
222 src->Swizzle = rc_adjust_channels(src->Swizzle, *conversion_swizzle); in normal_rewrite_writemask_cb()
299 tmp.Swizzle = 0; in lmul_swizzle()
304 tmp.Swizzle |= GET_SWZ(srcreg.Swizzle, swz) << (i*3); in lmul_swizzle()
307 tmp.Swizzle |= swz << (i*3); in lmul_swizzle()
316 reg->Swizzle = RC_SWIZZLE_XYZW; in reset_srcreg()
415 rc_source_type_swz(src->Swizzle)); in can_use_presub_read_cb()
[all...]
H A Dr500_fragprog.c100 if (GET_SWZ(inst_if->U.I.SrcReg[0].Swizzle, 0) == RC_SWIZZLE_X) { in r500_transform_IF()
116 inst_mov->U.I.SrcReg[0].Swizzle = combine_swizzles4( in r500_transform_IF()
117 inst_mov->U.I.SrcReg[0].Swizzle, in r500_transform_IF()
121 inst_mov->U.I.SrcReg[0].Swizzle = combine_swizzles4( in r500_transform_IF()
122 inst_mov->U.I.SrcReg[0].Swizzle, in r500_transform_IF()
176 inst_if->U.I.SrcReg[0].Swizzle = RC_MAKE_SWIZZLE( in r500_transform_IF()
198 if (opcode == RC_OPCODE_KIL && (reg.Swizzle != RC_SWIZZLE_XYZW || reg.Negate != RC_MASK_NONE)) in r500_swizzle_is_native()
202 unsigned int swz = GET_SWZ(reg.Swizzle, i); in r500_swizzle_is_native()
218 if (reg.Swizzle == RC_SWIZZLE_XYZW && !reg.Abs && !reg.Negate) in r500_swizzle_is_native()
226 unsigned int swz = GET_SWZ(reg.Swizzle, in r500_swizzle_is_native()
[all...]
H A Dradeon_optimize.c61 combine.Negate = swizzle_mask(outer.Swizzle, inner.Negate); in chain_srcregs()
64 combine.Swizzle = combine_swizzles(inner.Swizzle, outer.Swizzle); in chain_srcregs()
76 rc_swizzle_to_writemask(src->Swizzle), in copy_propagate_scan_read()
115 && (rc_swizzle_to_writemask(src->Swizzle) & sc_data->Mask)) { in src_clobbered_reads_cb()
206 unsigned int swz = GET_SWZ(src.Swizzle, chan); in is_src_uniform_constant()
284 inst->U.I.SrcReg[0].Swizzle = RC_SWIZZLE_0000; in constant_folding_mul()
297 inst->U.I.SrcReg[0].Swizzle = RC_SWIZZLE_0000; in constant_folding_mul()
342 if (GET_SWZ(inst->U.I.SrcReg[src].Swizzle, cha in constant_folding()
[all...]
H A Dr3xx_vertprog.c149 t_swizzle(GET_SWZ(src->Swizzle, 0)), in t_src()
150 t_swizzle(GET_SWZ(src->Swizzle, 1)), in t_src()
151 t_swizzle(GET_SWZ(src->Swizzle, 2)), in t_src()
152 t_swizzle(GET_SWZ(src->Swizzle, 3)), in t_src()
164 unsigned int swz = rc_get_scalar_src_swz(src->Swizzle); in t_src_scalar()
253 inst[1] = PVS_SRC_OPERAND(t_src_index(vp, &vpi->SrcReg[0]), t_swizzle(GET_SWZ(vpi->SrcReg[0].Swizzle, 0)), // X in ei_lit()
254 t_swizzle(GET_SWZ(vpi->SrcReg[0].Swizzle, 3)), // W in ei_lit()
256 t_swizzle(GET_SWZ(vpi->SrcReg[0].Swizzle, 1)), // Y in ei_lit()
260 inst[2] = PVS_SRC_OPERAND(t_src_index(vp, &vpi->SrcReg[0]), t_swizzle(GET_SWZ(vpi->SrcReg[0].Swizzle, 1)), // Y in ei_lit()
261 t_swizzle(GET_SWZ(vpi->SrcReg[0].Swizzle, in ei_lit()
[all...]
H A Dradeon_vert_fc.c45 src->Swizzle = RC_MAKE_SWIZZLE(RC_SWIZZLE_UNUSED, RC_SWIZZLE_UNUSED, in build_pred_src()
132 new_inst->U.I.SrcReg[0].Swizzle = RC_SWIZZLE_0000; in lower_bgnloop()
152 new_inst->U.I.SrcReg[1].Swizzle = RC_SWIZZLE_0000; in lower_bgnloop()
166 inst->U.I.SrcReg[0].Swizzle = RC_SWIZZLE_0000; in lower_brk()
212 swz = rc_get_scalar_src_swz(inst->U.I.SrcReg[1].Swizzle); in lower_if()
215 inst->U.I.SrcReg[1].Swizzle = RC_MAKE_SWIZZLE(RC_SWIZZLE_UNUSED, in lower_if()
H A Dr300_fragprog_swizzle.c123 unsigned int swz = GET_SWZ(reg.Swizzle, j); in r300_swizzle_is_native()
136 if (GET_SWZ(reg.Swizzle, j) != RC_SWIZZLE_UNUSED) in r300_swizzle_is_native()
142 sd = lookup_native_swizzle(reg.Swizzle); in r300_swizzle_is_native()
169 swz = GET_SWZ(src.Swizzle, comp); in r300_swizzle_split()
H A Dradeon_compiler.c202 inst->U.I.SrcReg[0].Swizzle = RC_SWIZZLE_XYZW; in rc_copy_output()
211 inst->U.I.SrcReg[0].Swizzle = RC_SWIZZLE_XYZW; in rc_copy_output()
243 inst_rcp->U.I.SrcReg[0].Swizzle = RC_SWIZZLE_WWWW; in rc_transform_fragment_wpos()
257 inst_mul->U.I.SrcReg[1].Swizzle = RC_SWIZZLE_WWWW; in rc_transform_fragment_wpos()
269 inst_mad->U.I.SrcReg[0].Swizzle = RC_SWIZZLE_XYZ0; in rc_transform_fragment_wpos()
272 inst_mad->U.I.SrcReg[1].Swizzle = RC_SWIZZLE_XYZ0; in rc_transform_fragment_wpos()
275 inst_mad->U.I.SrcReg[2].Swizzle = RC_SWIZZLE_XYZ0; in rc_transform_fragment_wpos()
322 inst_add->U.I.SrcReg[0].Swizzle = RC_SWIZZLE_1111; in rc_transform_fragment_face()
326 inst_add->U.I.SrcReg[1].Swizzle = RC_SWIZZLE_XXXX; in rc_transform_fragment_face()
/third_party/skia/src/sksl/ir/
H A DSkSLSwizzle.cpp222 newArgs.push_back(Swizzle::Make(context, std::move(newArg), in optimize_constructor_swizzle()
236 std::unique_ptr<Expression> Swizzle::Convert(const Context& context, in Convert()
274 std::unique_ptr<Expression> Swizzle::Convert(const Context& context, in Convert()
368 std::unique_ptr<Expression> expr = Swizzle::Make(context, std::move(base), maskComponents); in Convert()
433 return Swizzle::Make(context, std::move(expr), swizzleComponents); in Convert()
436 std::unique_ptr<Expression> Swizzle::Make(const Context& context, in Make()
476 if (expr->is<Swizzle>()) { in Make()
477 Swizzle& base = expr->as<Swizzle>(); in Make()
485 return Swizzle in Make()
[all...]
H A DSkSLSwizzle.h22 struct Swizzle final : public Expression {
25 Swizzle(const Context& context, std::unique_ptr<Expression> base, in Swizzle() function
34 // Swizzle::Convert permits component arrays containing ZERO or ONE, does typechecking, reports
45 // Swizzle::Make does not permit ZERO or ONE in the component array, just X/Y/Z/W; errors are
68 return std::unique_ptr<Expression>(new Swizzle(&this->type(), this->base()->clone(),
81 Swizzle(const Type* type, std::unique_ptr<Expression> base, const ComponentArray& components) in Swizzle() function
H A DSkSLFunctionDefinition.cpp30 using SkSL::dsl::Swizzle; // disambiguate from SkSL::Swizzle in append_rtadjust_fixup_to_vertex_main()
62 Pos() = Float4(Swizzle(Pos(), X, Y) * Swizzle(Adjust(), X, Z) + in append_rtadjust_fixup_to_vertex_main()
63 Swizzle(Pos(), W, W) * Swizzle(Adjust(), Y, W), in append_rtadjust_fixup_to_vertex_main()
/third_party/mesa3d/src/gallium/drivers/r600/sfn/
H A Dsfn_instr.h60 int sel_and_szw_from_string(const std::string& str, RegisterVec4::Swizzle& swz, bool& is_ssa);
244 InstrWithVectorResult(const RegisterVec4& dest, const RegisterVec4::Swizzle& dest_swizzle);
246 void set_dest_swizzle(const RegisterVec4::Swizzle& swz) {m_dest_swizzle = swz;} in set_dest_swizzle()
248 const RegisterVec4::Swizzle& all_dest_swizzle() const { return m_dest_swizzle;} in all_dest_swizzle()
255 bool comp_dest(const RegisterVec4& dest, const RegisterVec4::Swizzle& dest_swizzle) const;
259 RegisterVec4::Swizzle m_dest_swizzle;
H A Dsfn_instr_fetch.h64 const RegisterVec4::Swizzle& dest_swizzle,
159 QueryBufferSizeInstr(const RegisterVec4& dst, const RegisterVec4::Swizzle& swizzle, uint32_t resid);
165 LoadFromBuffer(const RegisterVec4& dst, const RegisterVec4::Swizzle& swizzle,
173 LoadFromScratch(const RegisterVec4& dst, const RegisterVec4::Swizzle& swizzle, PVirtualValue addr, uint32_t offset);
/third_party/skia/src/sksl/dsl/
H A DDSLExpression.cpp136 return Swizzle(std::move(*this), X, pos); in x()
140 return Swizzle(std::move(*this), Y, pos); in y()
144 return Swizzle(std::move(*this), Z, pos); in z()
148 return Swizzle(std::move(*this), W, pos); in w()
152 return Swizzle(std::move(*this), R, pos); in r()
156 return Swizzle(std::move(*this), G, pos); in g()
160 return Swizzle(std::move(*this), B, pos); in b()
164 return Swizzle(std::move(*this), A, pos); in a()
H A DDSLCore.cpp293 static DSLExpression Swizzle(DSLExpression base, SkSL::SwizzleComponent::Type a, in Swizzle() function in SkSL::dsl::DSLCore
295 return DSLExpression(Swizzle::Convert(ThreadContext::Context(), base.release(), in Swizzle()
300 static DSLExpression Swizzle(DSLExpression base, in Swizzle() function in SkSL::dsl::DSLCore
304 return DSLExpression(Swizzle::Convert(ThreadContext::Context(), base.release(), in Swizzle()
309 static DSLExpression Swizzle(DSLExpression base, in Swizzle() function in SkSL::dsl::DSLCore
314 return DSLExpression(Swizzle::Convert(ThreadContext::Context(), base.release(), in Swizzle()
319 static DSLExpression Swizzle(DSLExpression base, in Swizzle() function in SkSL::dsl::DSLCore
325 return DSLExpression(Swizzle::Convert(ThreadContext::Context(), base.release(), in Swizzle()
678 DSLExpression Swizzle(DSLExpression base, SkSL::SwizzleComponent::Type a, in Swizzle() function
680 return DSLCore::Swizzle(st in Swizzle()
683 DSLExpression Swizzle(DSLExpression base, Swizzle() function
690 DSLExpression Swizzle(DSLExpression base, Swizzle() function
698 DSLExpression Swizzle(DSLExpression base, Swizzle() function
[all...]
/third_party/mesa3d/src/gallium/drivers/r600/sfn/tests/
H A Dsfn_instrfromstring_test.cpp442 QueryBufferSizeInstr expect(RegisterVec4(1002),RegisterVec4::Swizzle({0,1,2,3}), 1); in TEST_F()
446 RegisterVec4(1002),RegisterVec4::Swizzle({0,1,2,3}), in TEST_F()
464 LoadFromBuffer expect(RegisterVec4(200), RegisterVec4::Swizzle({0,2,3,1}), in TEST_F()
471 RegisterVec4(200),RegisterVec4::Swizzle({0,2,3,1}), in TEST_F()
491 LoadFromScratch expect(RegisterVec4(200), RegisterVec4::Swizzle({0,2,3,1}), in TEST_F()
496 RegisterVec4(200),RegisterVec4::Swizzle({0,2,3,1}), in TEST_F()
553 LoadFromScratch expect(RegisterVec4(200), RegisterVec4::Swizzle({0,2,3,1}), in TEST_F()
558 RegisterVec4(200),RegisterVec4::Swizzle({0,2,3,1}), in TEST_F()
722 RegisterVec4::Swizzle dummy; in add_dest_vec4_from_string()
H A Dsfn_liverange_test.cpp65 RegisterVec4::Swizzle dummy; in TEST_F()
84 RegisterVec4::Swizzle dummy; in TEST_F()
111 RegisterVec4::Swizzle dummy; in TEST_F()
166 RegisterVec4::Swizzle dummy; in TEST_F()

Completed in 16 milliseconds

123456