Lines Matching refs:DEF
72 #define DEF(s, oargs, iargs, cargs, flags) { #s, oargs, iargs, cargs, iargs + oargs + cargs, flags },
74 #undef DEF
223 TCGOpDef *def;
235 def = &tcg_op_defs[op];
236 n = def->nb_iargs + def->nb_oargs;
244 def = &tcg_op_defs[op];
245 def->args_ct = args_ct;
246 def->sorted_args = sorted_args;
247 n = def->nb_iargs + def->nb_oargs;
877 const TCGOpDef *def;
885 def = &tcg_op_defs[c];
897 nb_oargs = def->nb_oargs;
898 nb_iargs = def->nb_iargs;
899 nb_cargs = def->nb_cargs;
907 nb_cargs = def->nb_cargs;
909 fprintf(outfile, " %s ", def->name);
941 nb_oargs = def->nb_oargs;
942 nb_iargs = def->nb_iargs;
943 nb_cargs = def->nb_cargs;
944 fprintf(outfile, " %s %s,$", def->name,
957 fprintf(outfile, " %s ", def->name);
964 nb_oargs = def->nb_oargs;
965 nb_iargs = def->nb_iargs;
966 nb_cargs = def->nb_cargs;
1018 static int get_constraint_priority(const TCGOpDef *def, int k)
1023 arg_ct = &def->args_ct[k];
1040 static void sort_constraints(TCGOpDef *def, int start, int n)
1045 def->sorted_args[start + i] = start + i;
1050 p1 = get_constraint_priority(def, def->sorted_args[start + i]);
1051 p2 = get_constraint_priority(def, def->sorted_args[start + j]);
1053 tmp = def->sorted_args[start + i];
1054 def->sorted_args[start + i] = def->sorted_args[start + j];
1055 def->sorted_args[start + j] = tmp;
1064 TCGOpDef *def;
1073 def = &tcg_op_defs[op];
1076 assert(!def->used);
1077 def->used = 1;
1079 nb_args = def->nb_iargs + def->nb_oargs;
1084 tcg_regset_clear(def->args_ct[i].u.regs);
1085 def->args_ct[i].ct = 0;
1089 assert(oarg < def->nb_oargs);
1090 assert(def->args_ct[oarg].ct & TCG_CT_REG);
1093 def->args_ct[i] = def->args_ct[oarg];
1094 def->args_ct[oarg].ct = TCG_CT_ALIAS;
1095 def->args_ct[oarg].alias_index = i;
1096 def->args_ct[i].ct |= TCG_CT_IALIAS;
1097 def->args_ct[i].alias_index = oarg;
1104 def->args_ct[i].ct |= TCG_CT_CONST;
1108 if (target_parse_constraint(&def->args_ct[i], &ct_str) < 0) {
1110 ct_str, i, def->name);
1122 sort_constraints(def, 0, def->nb_oargs);
1123 sort_constraints(def, def->nb_oargs, def->nb_iargs);
1129 printf("%s: sorted=", def->name);
1130 for(i = 0; i < def->nb_oargs + def->nb_iargs; i++)
1131 printf(" %d", def->sorted_args[i]);
1214 const TCGOpDef *def;
1238 def = &tcg_op_defs[op];
1297 args -= def->nb_args;
1312 args -= def->nb_args;
1313 nb_iargs = def->nb_iargs;
1314 nb_oargs = def->nb_oargs;
1319 if (!(def->flags & TCG_OPF_SIDE_EFFECTS) && nb_oargs != 0) {
1325 tcg_set_nop(s, gen_opc_buf + op_index, args, def->nb_args);
1339 if (def->flags & TCG_OPF_BB_END) {
1341 } else if (def->flags & TCG_OPF_CALL_CLOBBER) {
1600 static void tcg_reg_alloc_mov(TCGContext *s, const TCGOpDef *def,
1610 arg_ct = &def->args_ct[0];
1660 const TCGOpDef *def, TCGOpcode opc,
1672 nb_oargs = def->nb_oargs;
1673 nb_iargs = def->nb_iargs;
1678 sizeof(TCGArg) * def->nb_cargs);
1683 i = def
1685 arg_ct = &def->args_ct[i];
1741 if (def->flags & TCG_OPF_BB_END) {
1757 if (def->flags & TCG_OPF_CALL_CLOBBER) {
1775 i = def->sorted_args[k];
1777 arg_ct = &def->args_ct[i];
1826 static int tcg_reg_alloc_call(TCGContext *s, const TCGOpDef *def,
1917 arg_ct = &def->args_ct[0];
2001 return nb_iargs + nb_oargs + def->nb_cargs + 1;
2026 const TCGOpDef *def;
2090 def = &tcg_op_defs[opc];
2092 printf("%s: %d %d %d\n", def->name,
2093 def->nb_oargs, def->nb_iargs, def->nb_cargs);
2102 tcg_reg_alloc_mov(s, def, args, dead_iargs);
2139 args += tcg_reg_alloc_call(s, def, opc, args, dead_iargs);
2148 tcg_reg_alloc_op(s, def, opc, args, dead_iargs);
2151 args += def->nb_args;