translate.c (151f309b989fd84bec0cbd5bc84dbe83bbe0b2f4) | translate.c (3bbb8e4832b56cea29a61eb32cfb4931e00244c1) |
---|---|
1/* 2 * HPPA emulation cpu translation for qemu. 3 * 4 * Copyright (c) 2016 Richard Henderson <rth@twiddle.net> 5 * 6 * This library is free software; you can redistribute it and/or 7 * modify it under the terms of the GNU Lesser General Public 8 * License as published by the Free Software Foundation; either --- 2795 unchanged lines hidden (view full) --- 2804 dest = dest_gpr(ctx, a->t); 2805 2806 fn(dest, r, a->i); 2807 save_gpr(ctx, a->t, dest); 2808 2809 return nullify_end(ctx); 2810} 2811 | 1/* 2 * HPPA emulation cpu translation for qemu. 3 * 4 * Copyright (c) 2016 Richard Henderson <rth@twiddle.net> 5 * 6 * This library is free software; you can redistribute it and/or 7 * modify it under the terms of the GNU Lesser General Public 8 * License as published by the Free Software Foundation; either --- 2795 unchanged lines hidden (view full) --- 2804 dest = dest_gpr(ctx, a->t); 2805 2806 fn(dest, r, a->i); 2807 save_gpr(ctx, a->t, dest); 2808 2809 return nullify_end(ctx); 2810} 2811 |
2812static bool do_multimedia_shadd(DisasContext *ctx, arg_rrr_sh *a, 2813 void (*fn)(TCGv_i64, TCGv_i64, 2814 TCGv_i64, TCGv_i32)) 2815{ 2816 TCGv_i64 r1, r2, dest; 2817 2818 if (!ctx->is_pa20) { 2819 return false; 2820 } 2821 2822 nullify_over(ctx); 2823 2824 r1 = load_gpr(ctx, a->r1); 2825 r2 = load_gpr(ctx, a->r2); 2826 dest = dest_gpr(ctx, a->t); 2827 2828 fn(dest, r1, r2, tcg_constant_i32(a->sh)); 2829 save_gpr(ctx, a->t, dest); 2830 2831 return nullify_end(ctx); 2832} 2833 |
|
2812static bool trans_hadd(DisasContext *ctx, arg_rrr *a) 2813{ 2814 return do_multimedia(ctx, a, tcg_gen_vec_add16_i64); 2815} 2816 2817static bool trans_hadd_ss(DisasContext *ctx, arg_rrr *a) 2818{ 2819 return do_multimedia(ctx, a, gen_helper_hadd_ss); --- 19 unchanged lines hidden (view full) --- 2839 return do_multimedia_sh(ctx, a, tcg_gen_vec_sar16i_i64); 2840} 2841 2842static bool trans_hshr_u(DisasContext *ctx, arg_rri *a) 2843{ 2844 return do_multimedia_sh(ctx, a, tcg_gen_vec_shr16i_i64); 2845} 2846 | 2834static bool trans_hadd(DisasContext *ctx, arg_rrr *a) 2835{ 2836 return do_multimedia(ctx, a, tcg_gen_vec_add16_i64); 2837} 2838 2839static bool trans_hadd_ss(DisasContext *ctx, arg_rrr *a) 2840{ 2841 return do_multimedia(ctx, a, gen_helper_hadd_ss); --- 19 unchanged lines hidden (view full) --- 2861 return do_multimedia_sh(ctx, a, tcg_gen_vec_sar16i_i64); 2862} 2863 2864static bool trans_hshr_u(DisasContext *ctx, arg_rri *a) 2865{ 2866 return do_multimedia_sh(ctx, a, tcg_gen_vec_shr16i_i64); 2867} 2868 |
2869static bool trans_hshladd(DisasContext *ctx, arg_rrr_sh *a) 2870{ 2871 return do_multimedia_shadd(ctx, a, gen_helper_hshladd); 2872} 2873 2874static bool trans_hshradd(DisasContext *ctx, arg_rrr_sh *a) 2875{ 2876 return do_multimedia_shadd(ctx, a, gen_helper_hshradd); 2877} 2878 |
|
2847static bool trans_hsub(DisasContext *ctx, arg_rrr *a) 2848{ 2849 return do_multimedia(ctx, a, tcg_gen_vec_sub16_i64); 2850} 2851 2852static bool trans_hsub_ss(DisasContext *ctx, arg_rrr *a) 2853{ 2854 return do_multimedia(ctx, a, gen_helper_hsub_ss); --- 1600 unchanged lines hidden --- | 2879static bool trans_hsub(DisasContext *ctx, arg_rrr *a) 2880{ 2881 return do_multimedia(ctx, a, tcg_gen_vec_sub16_i64); 2882} 2883 2884static bool trans_hsub_ss(DisasContext *ctx, arg_rrr *a) 2885{ 2886 return do_multimedia(ctx, a, gen_helper_hsub_ss); --- 1600 unchanged lines hidden --- |