Lines Matching full:ac
283 int32_t ac, in mipsdsp_sat64_acc_add_q63() argument
289 ret[0] = env->active_tc.LO[ac] + a[0]; in mipsdsp_sat64_acc_add_q63()
290 ret[1] = env->active_tc.HI[ac] + a[1]; in mipsdsp_sat64_acc_add_q63()
292 if (((uint64_t)ret[0] < (uint64_t)env->active_tc.LO[ac]) && in mipsdsp_sat64_acc_add_q63()
305 set_DSPControl_overflow_flag(1, 16 + ac, env); in mipsdsp_sat64_acc_add_q63()
310 int32_t ac, in mipsdsp_sat64_acc_sub_q63() argument
316 ret[0] = env->active_tc.LO[ac] - a[0]; in mipsdsp_sat64_acc_sub_q63()
317 ret[1] = env->active_tc.HI[ac] - a[1]; in mipsdsp_sat64_acc_sub_q63()
319 if ((uint64_t)ret[0] > (uint64_t)env->active_tc.LO[ac]) { in mipsdsp_sat64_acc_sub_q63()
331 set_DSPControl_overflow_flag(1, 16 + ac, env); in mipsdsp_sat64_acc_sub_q63()
504 int32_t ac, in mipsdsp_rndrashift_short_acc() argument
510 acc = ((int64_t)env->active_tc.HI[ac] << 32) | in mipsdsp_rndrashift_short_acc()
511 ((int64_t)env->active_tc.LO[ac] & 0xFFFFFFFF); in mipsdsp_rndrashift_short_acc()
519 uint32_t ac, in mipsdsp_rashift_acc() argument
525 tempB = env->active_tc.HI[ac]; in mipsdsp_rashift_acc()
526 tempA = env->active_tc.LO[ac]; in mipsdsp_rashift_acc()
540 uint32_t ac, in mipsdsp_rndrashift_acc() argument
546 tempB = env->active_tc.HI[ac]; in mipsdsp_rndrashift_acc()
547 tempA = env->active_tc.LO[ac]; in mipsdsp_rndrashift_acc()
566 static inline int32_t mipsdsp_mul_q15_q15(int32_t ac, uint16_t a, uint16_t b, in mipsdsp_mul_q15_q15() argument
573 set_DSPControl_overflow_flag(1, 16 + ac, env); in mipsdsp_mul_q15_q15()
581 static inline int64_t mipsdsp_mul_q31_q31(int32_t ac, uint32_t a, uint32_t b, in mipsdsp_mul_q31_q31() argument
588 set_DSPControl_overflow_flag(1, 16 + ac, env); in mipsdsp_mul_q31_q31()
2038 void helper_##name(uint32_t ac, target_ulong rs, target_ulong rt, \
2049 tempB = mipsdsp_mul_q15_q15(ac, rsh, rth, env); \
2050 tempA = mipsdsp_mul_q15_q15(ac, rsl, rtl, env); \
2057 acc = ((uint64_t)env->active_tc.HI[ac] << 32) | \
2058 ((uint64_t)env->active_tc.LO[ac] & MIPSDSP_LLO); \
2060 env->active_tc.HI[ac] = (target_long)(int32_t) \
2062 env->active_tc.LO[ac] = (target_long)(int32_t)(dotp & MIPSDSP_LLO); \
2136 void helper_mulsaq_s_w_qh(target_ulong rs, target_ulong rt, uint32_t ac, in helper_mulsaq_s_w_qh() argument
2149 tempD = mipsdsp_mul_q15_q15(ac, rs3, rt3, env); in helper_mulsaq_s_w_qh()
2150 tempC = mipsdsp_mul_q15_q15(ac, rs2, rt2, env); in helper_mulsaq_s_w_qh()
2151 tempB = mipsdsp_mul_q15_q15(ac, rs1, rt1, env); in helper_mulsaq_s_w_qh()
2152 tempA = mipsdsp_mul_q15_q15(ac, rs0, rt0, env); in helper_mulsaq_s_w_qh()
2163 acc[0] = env->active_tc.LO[ac]; in helper_mulsaq_s_w_qh()
2164 acc[1] = env->active_tc.HI[ac]; in helper_mulsaq_s_w_qh()
2174 env->active_tc.HI[ac] = acc[1]; in helper_mulsaq_s_w_qh()
2175 env->active_tc.LO[ac] = acc[0]; in helper_mulsaq_s_w_qh()
2180 void helper_##name(uint32_t ac, target_ulong rs, target_ulong rt, \
2196 tempC = (((uint64_t)env->active_tc.HI[ac] << 32) | \
2197 ((uint64_t)env->active_tc.LO[ac] & MIPSDSP_LLO)) \
2200 tempC = (((uint64_t)env->active_tc.HI[ac] << 32) | \
2201 ((uint64_t)env->active_tc.LO[ac] & MIPSDSP_LLO)) \
2205 env->active_tc.HI[ac] = (target_long)(int32_t) \
2207 env->active_tc.LO[ac] = (target_long)(int32_t)(tempC & MIPSDSP_LLO); \
2221 void helper_##name(target_ulong rs, target_ulong rt, uint32_t ac, \
2251 acc[0] = env->active_tc.LO[ac]; \
2252 acc[1] = env->active_tc.HI[ac]; \
2271 env->active_tc.HI[ac] = temp[1]; \
2272 env->active_tc.LO[ac] = temp[0]; \
2284 void helper_##name(uint32_t ac, target_ulong rs, target_ulong rt, \
2299 acc = ((uint64_t)env->active_tc.HI[ac] << 32) | \
2300 ((uint64_t)env->active_tc.LO[ac] & MIPSDSP_LLO); \
2308 env->active_tc.HI[ac] = (target_long)(int32_t)((acc & MIPSDSP_LHI) >> 32); \
2309 env->active_tc.LO[ac] = (target_long)(int32_t)(acc & MIPSDSP_LLO); \
2319 void helper_##name(uint32_t ac, target_ulong rs, target_ulong rt, \
2331 tempB = mipsdsp_mul_q15_q15(ac, rsB, rtB, env); \
2332 tempA = mipsdsp_mul_q15_q15(ac, rsA, rtA, env); \
2335 acc = ((uint64_t)env->active_tc.HI[ac] << 32) | \
2336 ((uint64_t)env->active_tc.LO[ac] & MIPSDSP_LLO); \
2344 env->active_tc.HI[ac] = (target_long)(int32_t) \
2346 env->active_tc.LO[ac] = (target_long)(int32_t) \
2358 void helper_##name(uint32_t ac, target_ulong rs, target_ulong rt, \
2368 tempB = mipsdsp_mul_q15_q15(ac, rsh, rtl, env); \
2369 tempA = mipsdsp_mul_q15_q15(ac, rsl, rth, env); \
2372 acc = ((uint64_t)env->active_tc.HI[ac] << 32) | \
2373 ((uint64_t)env->active_tc.LO[ac] & MIPSDSP_LLO); \
2384 set_DSPControl_overflow_flag(1, 16 + ac, env); \
2389 set_DSPControl_overflow_flag(1, 16 + ac, env); \
2392 env->active_tc.HI[ac] = (target_long)(int32_t) \
2394 env->active_tc.LO[ac] = (target_long)(int32_t) \
2405 void helper_##name(target_ulong rs, target_ulong rt, uint32_t ac, \
2419 tempD = mipsdsp_mul_q15_q15(ac, rs3, rt3, env); \
2420 tempC = mipsdsp_mul_q15_q15(ac, rs2, rt2, env); \
2421 tempB = mipsdsp_mul_q15_q15(ac, rs1, rt1, env); \
2422 tempA = mipsdsp_mul_q15_q15(ac, rs0, rt0, env); \
2439 acc[1] = env->active_tc.HI[ac]; \
2440 acc[0] = env->active_tc.LO[ac]; \
2459 env->active_tc.HI[ac] = temp[1]; \
2460 env->active_tc.LO[ac] = temp[0]; \
2473 void helper_##name(uint32_t ac, target_ulong rs, target_ulong rt, \
2481 dotp = mipsdsp_mul_q31_q31(ac, rs, rt, env); \
2482 acc = ((uint64_t)env->active_tc.HI[ac] << 32) | \
2483 ((uint64_t)env->active_tc.LO[ac] & MIPSDSP_LLO); \
2502 set_DSPControl_overflow_flag(1, 16 + ac, env); \
2505 env->active_tc.HI[ac] = (target_long)(int32_t) \
2507 env->active_tc.LO[ac] = (target_long)(int32_t) \
2518 void helper_##name(target_ulong rs, target_ulong rt, uint32_t ac, \
2534 tempB[0] = mipsdsp_mul_q31_q31(ac, rs1, rt1, env); \
2535 tempA[0] = mipsdsp_mul_q31_q31(ac, rs0, rt0, env); \
2557 mipsdsp_##func(acc, ac, temp, env); \
2559 env->active_tc.HI[ac] = acc[1]; \
2560 env->active_tc.LO[ac] = acc[0]; \
2568 void helper_mulsaq_s_l_pw(target_ulong rs, target_ulong rt, uint32_t ac, in helper_mulsaq_s_l_pw() argument
2583 tempB[0] = mipsdsp_mul_q31_q31(ac, rs1, rt1, env); in helper_mulsaq_s_l_pw()
2584 tempA[0] = mipsdsp_mul_q31_q31(ac, rs0, rt0, env); in helper_mulsaq_s_l_pw()
2598 acc[0] = env->active_tc.LO[ac]; in helper_mulsaq_s_l_pw()
2599 acc[1] = env->active_tc.HI[ac]; in helper_mulsaq_s_l_pw()
2622 env->active_tc.HI[ac] = acc[1]; in helper_mulsaq_s_l_pw()
2623 env->active_tc.LO[ac] = acc[0]; in helper_mulsaq_s_l_pw()
2628 void helper_##name(uint32_t ac, target_ulong rs, target_ulong rt, \
2637 tempA = mipsdsp_mul_q15_q15(ac, rsh, rth, env); \
2638 acc = ((uint64_t)env->active_tc.HI[ac] << 32) | \
2639 ((uint64_t)env->active_tc.LO[ac] & MIPSDSP_LLO); \
2641 env->active_tc.HI[ac] = (target_long)(int32_t) \
2643 env->active_tc.LO[ac] = (target_long)(int32_t) \
2653 void helper_##name(uint32_t ac, target_ulong rs, target_ulong rt, \
2661 tempA = mipsdsp_mul_q15_q15(ac, rsh, rth, env); \
2662 tempA = mipsdsp_sat32_acc_q31(ac, tempA, env); \
2664 env->active_tc.HI[ac] = (target_long)(int32_t)(((int64_t)tempA & \
2666 env->active_tc.LO[ac] = (target_long)(int32_t)((int64_t)tempA & \
2706 void helper_##name(target_ulong rs, target_ulong rt, uint32_t ac, \
2720 temp_mul = mipsdsp_mul_q15_q15(ac, rs_t, rt_t, env); \
2729 acc[0] = env->active_tc.LO[ac]; \
2730 acc[1] = env->active_tc.HI[ac]; \
2740 env->active_tc.HI[ac] = acc[1]; \
2741 env->active_tc.LO[ac] = acc[0]; \
2752 void helper_##name(target_ulong rs, target_ulong rt, uint32_t ac, \
2761 temp = mipsdsp_mul_q15_q15(ac, rs_t, rt_t, env); \
2762 temp = mipsdsp_sat32_acc_q31(ac, temp, env); \
2771 env->active_tc.HI[ac] = acc[1]; \
2772 env->active_tc.LO[ac] = acc[0]; \
2783 void helper_##name(target_ulong rs, target_ulong rt, uint32_t ac, \
2797 temp[0] = mipsdsp_mul_q31_q31(ac, rs_t, rt_t, env); \
2804 acc[0] = env->active_tc.LO[ac]; \
2805 acc[1] = env->active_tc.HI[ac]; \
2815 env->active_tc.HI[ac] = acc[1]; \
2816 env->active_tc.LO[ac] = acc[0]; \
2825 void helper_##name(target_ulong rs, target_ulong rt, uint32_t ac, \
2863 acc[1] = env->active_tc.HI[ac]; \
2864 acc[0] = env->active_tc.LO[ac]; \
2891 env->active_tc.HI[ac] = temp[1]; \
2892 env->active_tc.LO[ac] = temp[0]; \
3120 target_ulong helper_extr_w(target_ulong ac, target_ulong shift, in helper_extr_w() argument
3128 mipsdsp_rndrashift_short_acc(tempDL, ac, shift, env); in helper_extr_w()
3149 target_ulong helper_extr_r_w(target_ulong ac, target_ulong shift, in helper_extr_r_w() argument
3156 mipsdsp_rndrashift_short_acc(tempDL, ac, shift, env); in helper_extr_r_w()
3175 target_ulong helper_extr_rs_w(target_ulong ac, target_ulong shift, in helper_extr_rs_w() argument
3183 mipsdsp_rndrashift_short_acc(tempDL, ac, shift, env); in helper_extr_rs_w()
3209 target_ulong helper_dextr_w(target_ulong ac, target_ulong shift, in helper_dextr_w() argument
3216 mipsdsp_rndrashift_acc(temp, ac, shift, env); in helper_dextr_w()
3221 target_ulong helper_dextr_r_w(target_ulong ac, target_ulong shift, in helper_dextr_r_w() argument
3228 mipsdsp_rndrashift_acc(temp, ac, shift, env); in helper_dextr_r_w()
3248 target_ulong helper_dextr_rs_w(target_ulong ac, target_ulong shift, in helper_dextr_rs_w() argument
3255 mipsdsp_rndrashift_acc(temp, ac, shift, env); in helper_dextr_rs_w()
3280 target_ulong helper_dextr_l(target_ulong ac, target_ulong shift, in helper_dextr_l() argument
3287 mipsdsp_rndrashift_acc(temp, ac, shift, env); in helper_dextr_l()
3292 target_ulong helper_dextr_r_l(target_ulong ac, target_ulong shift, in helper_dextr_r_l() argument
3299 mipsdsp_rndrashift_acc(temp, ac, shift, env); in helper_dextr_r_l()
3319 target_ulong helper_dextr_rs_l(target_ulong ac, target_ulong shift, in helper_dextr_rs_l() argument
3326 mipsdsp_rndrashift_acc(temp, ac, shift, env); in helper_dextr_rs_l()
3354 target_ulong helper_extr_s_h(target_ulong ac, target_ulong shift, in helper_extr_s_h() argument
3361 acc = ((int64_t)env->active_tc.HI[ac] << 32) | in helper_extr_s_h()
3362 ((int64_t)env->active_tc.LO[ac] & 0xFFFFFFFF); in helper_extr_s_h()
3379 target_ulong helper_dextr_s_h(target_ulong ac, target_ulong shift, in helper_dextr_s_h() argument
3387 mipsdsp_rashift_acc((uint64_t *)temp, ac, shift, env); in helper_dextr_s_h()
3408 target_ulong helper_extp(target_ulong ac, target_ulong size, CPUMIPSState *env) in helper_extp() argument
3421 acc = ((uint64_t)env->active_tc.HI[ac] << 32) | in helper_extp()
3422 ((uint64_t)env->active_tc.LO[ac] & MIPSDSP_LLO); in helper_extp()
3432 target_ulong helper_extpdp(target_ulong ac, target_ulong size, in helper_extpdp() argument
3445 acc = ((uint64_t)env->active_tc.HI[ac] << 32) | in helper_extpdp()
3446 ((uint64_t)env->active_tc.LO[ac] & MIPSDSP_LLO); in helper_extpdp()
3460 target_ulong helper_dextp(target_ulong ac, target_ulong size, CPUMIPSState *env) in helper_dextp() argument
3473 tempB = env->active_tc.HI[ac]; in helper_dextp()
3474 tempA = env->active_tc.LO[ac]; in helper_dextp()
3489 target_ulong helper_dextpdp(target_ulong ac, target_ulong size, in helper_dextpdp() argument
3502 tempB = env->active_tc.HI[ac]; in helper_dextpdp()
3503 tempA = env->active_tc.LO[ac]; in helper_dextpdp()
3521 void helper_shilo(target_ulong ac, target_ulong rs, CPUMIPSState *env) in helper_shilo() argument
3533 acc = (((uint64_t)env->active_tc.HI[ac] << 32) & MIPSDSP_LHI) | in helper_shilo()
3534 ((uint64_t)env->active_tc.LO[ac] & MIPSDSP_LLO); in helper_shilo()
3542 env->active_tc.HI[ac] = (target_ulong)(int32_t)((temp & MIPSDSP_LHI) >> 32); in helper_shilo()
3543 env->active_tc.LO[ac] = (target_ulong)(int32_t)(temp & MIPSDSP_LLO); in helper_shilo()
3547 void helper_dshilo(target_ulong shift, target_ulong ac, CPUMIPSState *env) in helper_dshilo() argument
3554 tempB = env->active_tc.HI[ac]; in helper_dshilo()
3555 tempA = env->active_tc.LO[ac]; in helper_dshilo()
3568 env->active_tc.HI[ac] = tempB; in helper_dshilo()
3569 env->active_tc.LO[ac] = tempA; in helper_dshilo()
3573 void helper_mthlip(target_ulong ac, target_ulong rs, CPUMIPSState *env) in helper_mthlip() argument
3578 tempB = env->active_tc.LO[ac]; in helper_mthlip()
3579 env->active_tc.HI[ac] = (target_long)tempB; in helper_mthlip()
3580 env->active_tc.LO[ac] = (target_long)tempA; in helper_mthlip()
3591 void helper_dmthlip(target_ulong rs, target_ulong ac, CPUMIPSState *env) in helper_dmthlip() argument
3597 ac_t = ac & 0x3; in helper_dmthlip()