/** Generate a SVGA3dShaderInstToken for the given SVGA3D shader opcode */
static inline SVGA3dShaderInstToken
-inst_token(unsigned opcode)
+inst_token(SVGA3dShaderOpCodeType opcode)
{
SVGA3dShaderInstToken inst;
* with the predication flag set.
*/
static inline SVGA3dShaderInstToken
-inst_token_predicated(unsigned opcode)
+inst_token_predicated(SVGA3dShaderOpCodeType opcode)
{
SVGA3dShaderInstToken inst;
* using the given comparison operator (one of SVGA3DOPCOMP_xx).
*/
static inline SVGA3dShaderInstToken
-inst_token_setp(unsigned operator)
+inst_token_setp(SVGA3dShaderOpCodeCompFnType operator)
{
SVGA3dShaderInstToken inst;
* temp registers AND constants (see emit_def_const()).
*/
static inline SVGA3dShaderDestToken
-dst_register(unsigned file, int number)
+dst_register(SVGA3dShaderRegType file, int number)
{
SVGA3dShaderDestToken dest;
/** Create a SVGA3dShaderSrcToken given a register file and number */
static inline SVGA3dShaderSrcToken
-src_token(unsigned file, int number)
+src_token(SVGA3dShaderRegType file, int number)
{
SVGA3dShaderSrcToken src;
/** Create a src_register given a register file and register number */
static inline struct src_register
-src_register(unsigned file, int number)
+src_register(SVGA3dShaderRegType file, int number)
{
struct src_register src;
static boolean emit_ps_postamble( struct svga_shader_emitter *emit );
-static unsigned
+static SVGA3dShaderOpCodeType
translate_opcode(enum tgsi_opcode opcode)
{
switch (opcode) {
}
-static unsigned
-translate_file(unsigned file)
+static SVGA3dShaderRegType
+translate_file(enum tgsi_file_type file)
{
switch (file) {
case TGSI_FILE_TEMPORARY: return SVGA3DREG_TEMP;
*/
static boolean
emit_conditional(struct svga_shader_emitter *emit,
- unsigned compare_func,
+ enum pipe_compare_func compare_func,
SVGA3dShaderDestToken dst,
struct src_register src0,
struct src_register src1,
*/
static boolean
emit_select(struct svga_shader_emitter *emit,
- unsigned compare_func,
+ enum pipe_compare_func compare_func,
SVGA3dShaderDestToken dst,
struct src_register src0,
struct src_register src1 )
*/
static boolean
emit_scalar_op1(struct svga_shader_emitter *emit,
- unsigned opcode,
+ SVGA3dShaderOpCodeType opcode,
const struct tgsi_full_instruction *insn)
{
SVGA3dShaderInstToken inst;
*/
static boolean
emit_simple_instruction(struct svga_shader_emitter *emit,
- unsigned opcode,
+ SVGA3dShaderOpCodeType opcode,
const struct tgsi_full_instruction *insn)
{
const struct tgsi_full_src_register *src = insn->Src;
return TRUE;
}
else {
- unsigned opcode;
+ SVGA3dShaderOpCodeType opcode;
const struct tgsi_full_src_register *reg = &insn->Src[0];
SVGA3dShaderInstToken inst;
SVGA3dShaderDestToken dst;
default:
{
- unsigned opcode = translate_opcode(insn->Instruction.Opcode);
+ SVGA3dShaderOpCodeType opcode =
+ translate_opcode(insn->Instruction.Opcode);
if (opcode == SVGA3DOP_LAST_INST)
return FALSE;