}
static struct tgsi_instruction
-tgsi_build_instruction(unsigned opcode,
+tgsi_build_instruction(enum tgsi_opcode opcode,
unsigned saturate,
unsigned precise,
unsigned num_dst_regs,
struct tgsi_full_src_register *src0 = &inst->Src[0];
struct tgsi_full_src_register *src1 = &inst->Src[1];
struct tgsi_full_instruction new_inst;
- unsigned opcode = inst->Instruction.Opcode;
+ enum tgsi_opcode opcode = inst->Instruction.Opcode;
/* NOTE: any potential last instruction must replicate src on all
* components (since it could be re-written to write to final dst)
struct tgsi_full_dst_register *dst = &inst->Dst[0];
struct tgsi_full_src_register *src0 = &inst->Src[0];
struct tgsi_full_instruction new_inst;
- unsigned opcode = inst->Instruction.Opcode;
+ enum tgsi_opcode opcode = inst->Instruction.Opcode;
if (dst->Register.WriteMask & TGSI_WRITEMASK_XYZW) {
/* FLR: FRC tmpA, src CEIL: FRC tmpA, -src */
/* mask is clamped coords, pmask is all coords (for projection): */
unsigned mask = 0, pmask = 0, smask;
unsigned tex = inst->Texture.Texture;
- unsigned opcode = inst->Instruction.Opcode;
+ enum tgsi_opcode opcode = inst->Instruction.Opcode;
bool lower_txp = (opcode == TGSI_OPCODE_TXP) &&
(ctx->config->lower_TXP & (1 << tex));
static bool
-is_mem_query_inst(unsigned opcode)
+is_mem_query_inst(enum tgsi_opcode opcode)
{
return opcode == TGSI_OPCODE_RESQ ||
opcode == TGSI_OPCODE_TXQ ||
* texture map?
*/
static bool
-is_texture_inst(unsigned opcode)
+is_texture_inst(enum tgsi_opcode opcode)
{
return (!is_mem_query_inst(opcode) &&
tgsi_get_opcode_info(opcode)->is_tex);
* implicitly?
*/
static bool
-computes_derivative(unsigned opcode)
+computes_derivative(enum tgsi_opcode opcode)
{
if (tgsi_get_opcode_info(opcode)->is_tex) {
return opcode != TGSI_OPCODE_TG4 &&
{
struct tgsi_full_instruction *fullinst
= &parse.FullToken.FullInstruction;
- unsigned opcode = fullinst->Instruction.Opcode;
+ enum tgsi_opcode opcode = fullinst->Instruction.Opcode;
if (first_instruction && ctx->prolog) {
ctx->prolog(ctx);
*/
static inline void
tgsi_transform_op1_inst(struct tgsi_transform_context *ctx,
- unsigned opcode,
+ enum tgsi_opcode opcode,
unsigned dst_file,
unsigned dst_index,
unsigned dst_writemask,
static inline void
tgsi_transform_op2_inst(struct tgsi_transform_context *ctx,
- unsigned opcode,
+ enum tgsi_opcode opcode,
unsigned dst_file,
unsigned dst_index,
unsigned dst_writemask,
static inline void
tgsi_transform_op3_inst(struct tgsi_transform_context *ctx,
- unsigned opcode,
+ enum tgsi_opcode opcode,
unsigned dst_file,
unsigned dst_index,
unsigned dst_writemask,
static inline void
tgsi_transform_op1_swz_inst(struct tgsi_transform_context *ctx,
- unsigned opcode,
+ enum tgsi_opcode opcode,
unsigned dst_file,
unsigned dst_index,
unsigned dst_writemask,
static inline void
tgsi_transform_op2_swz_inst(struct tgsi_transform_context *ctx,
- unsigned opcode,
+ enum tgsi_opcode opcode,
unsigned dst_file,
unsigned dst_index,
unsigned dst_writemask,
static inline void
tgsi_transform_op3_swz_inst(struct tgsi_transform_context *ctx,
- unsigned opcode,
+ enum tgsi_opcode opcode,
unsigned dst_file,
unsigned dst_index,
unsigned dst_writemask,