Lines Matching refs:uses
507 std::vector<uint16_t> uses;
1212 /* Remove superfluous s_and when the VOPC instruction uses the same exec and thus
2068 if (!--ctx.uses[instr->definitions[0].tempId()]) {
2071 ctx.uses[op.tempId()]--;
2081 if (!ignore_uses && ctx.uses[op.tempId()] > 1)
2088 if (instr->definitions[1].isTemp() && ctx.uses[instr->definitions[1].tempId()])
2102 if (instr->definitions[1].isTemp() && ctx.uses[instr->definitions[1].tempId()])
2156 ctx.uses[op[0].id()]++;
2157 ctx.uses[op[1].id()]++;
2199 if (instr->definitions[1].isTemp() && ctx.uses[instr->definitions[1].tempId()])
2234 ctx.uses[cmp->operands[0].tempId()]++;
2235 ctx.uses[cmp->operands[1].tempId()]++;
2300 if (instr->definitions[1].isTemp() && ctx.uses[instr->definitions[1].tempId()])
2358 ctx.uses[cmp->operands[0].tempId()]++;
2360 ctx.uses[cmp->operands[1].tempId()]++;
2397 if (ctx.uses[instr->definitions[1].tempId()])
2409 ctx.uses[cmp->operands[0].tempId()]++;
2411 ctx.uses[cmp->operands[1].tempId()]++;
2580 ctx.uses[instr->operands[swap].tempId()]--;
2650 ctx.uses[instr->operands[i].tempId()]--;
2675 ctx.uses[instr->operands[swap].tempId()]--;
2697 if (instr->definitions[1].isTemp() && ctx.uses[instr->definitions[1].tempId()])
2716 ctx.uses[instr->operands[0].tempId()]--;
2747 if (ctx.uses[op2_instr->definitions[1].tempId()] || fixed_to_exec(op2_instr->operands[0]))
2754 ctx.uses[instr->operands[i].tempId()]--;
2776 if (instr->opcode == aco_opcode::s_add_i32 && ctx.uses[instr->definitions[1].tempId()])
2782 ctx.uses[op2_instr->definitions[1].tempId()])
2795 ctx.uses[instr->operands[i].tempId()]--;
2819 ctx.uses[instr->operands[i].tempId()] == 1) {
2832 ctx.uses[instr->operands[i].tempId()]--;
2839 /* Make sure the uses vector is large enough and the number of
2840 * uses properly initialized to 0.
2842 ctx.uses.push_back(0);
2870 ctx.uses[instr->operands[i].tempId()]--;
3038 ctx.uses[instr->operands[swap].tempId()]--;
3090 uint16_t uses = ctx.uses[instr->operands[i].tempId()];
3091 if (sgpr_info_id == 0 || uses < ctx.uses[sgpr_info_id]) {
3103 if (!info.is_extract() && num_sgprs && ctx.uses[sgpr_info_id] > 1 && !instr->isVOP3() &&
3138 ctx.uses[sgpr_info_id]--;
3139 ctx.uses[sgpr.id()]++;
3171 if (instr->definitions.empty() || ctx.uses[instr->definitions[0].tempId()] != 1 ||
3197 if (!ctx.uses[def_info.instr->definitions[0].tempId()])
3220 ctx.uses[def_info.instr->definitions[0].tempId()]--;
3231 if (instr->definitions.empty() || ctx.uses[instr->definitions[0].tempId()] != 1)
3239 if (!ctx.uses[def_info.instr->definitions[0].tempId()])
3258 ctx.uses[def_info.instr->definitions[0].tempId()]--;
3271 ctx.uses[extract->operands[0].tempId()] > 1)
3309 ctx.uses[extract->definitions[0].tempId()] = 0;
3340 ctx.uses[instr->operands[i].tempId()]--;
3341 if (ctx.uses[instr->operands[i].tempId()])
3342 ctx.uses[op_instr->operands[2].tempId()]++;
3406 ctx.uses[instr->operands[i].tempId()]--;
3453 vop3p->clamp && instr->operands[0].isTemp() && ctx.uses[instr->operands[0].tempId()] == 1 &&
3463 ctx.uses[instr->definitions[0].tempId()]--;
3508 if (--ctx.uses[fneg->definitions[0].tempId()])
3509 ctx.uses[fneg->operands[0].tempId()]++;
3522 uint32_t uses = UINT32_MAX;
3539 if (ctx.uses[instr->operands[i].tempId()] >= uses || !check_vop3_operands(ctx, 3, op))
3550 uses = ctx.uses[instr->operands[i].tempId()];
3558 ctx.uses[mul_instr->definitions[0].tempId()]--;
3559 if (ctx.uses[mul_instr->definitions[0].tempId()]) {
3561 ctx.uses[op[0].tempId()]++;
3563 ctx.uses[op[1].tempId()]++;
3673 if (!can_use_mad_mix(ctx, instr) || ctx.uses[instr->definitions[0].tempId()] != 1)
3676 if (!ctx.uses[conv->definitions[0].tempId()])
3690 ctx.uses[conv->definitions[0].tempId()]--;
3737 if (--ctx.uses[tmp.id()])
3738 ctx.uses[conv->operands[0].tempId()]++;
3755 // this would mean that we'd have to fix the instruction uses while value propagation
3787 if (instr->definitions.empty() || is_dead(ctx.uses, instr.get()))
3800 /* if there are that many uses, there are likely better combinations */
3802 if (ctx.uses[op.tempId()] > 4) {
3810 /* Increase use count of the extract's operand if the extract still has uses. */
3812 if (--ctx.uses[instr->operands[i].tempId()])
3813 ctx.uses[info.instr->operands[0].tempId()]++;
3837 if (--ctx.uses[instr->operands[0].tempId()])
3838 ctx.uses[info.instr->operands[0].tempId()]++;
3857 ctx.uses[instr->operands[1].tempId()] == 1) {
3878 ctx.uses[mul_instr->definitions[0].tempId()]--;
3923 uint32_t uses = UINT32_MAX;
3976 ctx.uses[instr->operands[i].tempId()] > uses)
3979 if (ctx.uses[instr->operands[i].tempId()] == uses) {
3988 uses = ctx.uses[instr->operands[i].tempId()];
3996 ctx.uses[mul_instr->definitions[0].tempId()]--;
3997 if (ctx.uses[mul_instr->definitions[0].tempId()]) {
3999 ctx.uses[op[0].tempId()]++;
4001 ctx.uses[op[1].tempId()]++;
4125 ctx.uses[instr->operands[i].tempId()] == 1 && instr->operands[!i].isTemp() &&
4127 ctx.uses[instr->operands[i].tempId()]--;
4128 ctx.uses[ctx.info[instr->operands[i].tempId()].temp.id()]++;
4183 bool carry_out = ctx.uses[instr->definitions[1].tempId()] > 0;
4193 instr->opcode != aco_opcode::v_sub_u32 && ctx.uses[instr->definitions[1].tempId()] > 0;
4220 * since ctx.uses[mad_info::mul_temp_id] is always 0, we don't have to worry about
4267 ctx.uses[op.tempId()]--;
4287 ctx.uses[op.tempId()]++;
4301 if (is_dead(ctx.uses, instr.get())) {
4313 if (ctx.uses[instr->definitions[i].tempId()]) {
4321 ctx.uses[instr->operands[0].tempId()] == 1) {
4334 ctx.uses[instr->operands[0].tempId()]--;
4337 ctx.uses[vec_op.tempId()]--;
4340 ctx.uses[op.tempId()]++;
4369 if (ctx.uses[mad_info->mul_temp_id] && mad_info->add_instr) {
4370 ctx.uses[mad_info->mul_temp_id]++;
4372 ctx.uses[instr->operands[0].tempId()]--;
4374 ctx.uses[instr->operands[1].tempId()]--;
4412 literal_uses = ctx.uses[instr->operands[2].tempId()];
4429 ctx.uses[instr->operands[i].tempId()] < literal_uses) {
4431 literal_uses = ctx.uses[instr->operands[i].tempId()];
4441 * uses below threshold
4444 ctx.uses[instr->operands[literal_idx].tempId()]--;
4475 /* Transform uniform bitwise boolean operations to 32-bit when there are no divergent uses. */
4476 if (instr->definitions.size() && ctx.uses[instr->definitions[0].tempId()] == 0 &&
4526 if (--ctx.uses[info.instr->definitions[0].tempId()])
4527 ctx.uses[info.instr->operands[0].tempId()]++;
4575 if (ctx.uses[op.tempId()] < literal_uses) {
4579 literal_uses = ctx.uses[op.tempId()];
4606 ctx.uses[instr->operands[i].tempId()]--;
4729 (ctx.uses[instr->operands[info->literal_idx].tempId()] == 0 || info->literal_idx == 2)) {
4766 if (op.isTemp() && ctx.info[op.tempId()].is_literal(bits) && ctx.uses[op.tempId()] == 0) {
4780 if (instr->opcode == aco_opcode::s_add_u32 && ctx.uses[instr->definitions[1].tempId()] == 0 &&
4802 ctx.uses = dead_code_analysis(program);