diff options
Diffstat (limited to 'target-sparc/op.c')
-rw-r--r-- | target-sparc/op.c | 262 |
1 files changed, 0 insertions, 262 deletions
diff --git a/target-sparc/op.c b/target-sparc/op.c index ce4c87885f..7042047107 100644 --- a/target-sparc/op.c +++ b/target-sparc/op.c @@ -169,10 +169,6 @@ #include "fop_template.h" #endif -#ifdef TARGET_SPARC64 -#define XFLAG_SET(x) ((env->xcc&x)?1:0) -#endif - #define FLAG_SET(x) ((env->psr&x)?1:0) void OPPROTO op_add_T1_T0_cc(void) @@ -857,249 +853,11 @@ void OPPROTO op_restore(void) } #endif -void OPPROTO op_eval_ba(void) -{ - T2 = 1; -} - -void OPPROTO op_eval_be(void) -{ - T2 = FLAG_SET(PSR_ZERO); -} - -void OPPROTO op_eval_ble(void) -{ - target_ulong Z = FLAG_SET(PSR_ZERO), N = FLAG_SET(PSR_NEG), V = FLAG_SET(PSR_OVF); - - T2 = Z | (N ^ V); -} - -void OPPROTO op_eval_bl(void) -{ - target_ulong N = FLAG_SET(PSR_NEG), V = FLAG_SET(PSR_OVF); - - T2 = N ^ V; -} - -void OPPROTO op_eval_bleu(void) -{ - target_ulong Z = FLAG_SET(PSR_ZERO), C = FLAG_SET(PSR_CARRY); - - T2 = C | Z; -} - -void OPPROTO op_eval_bcs(void) -{ - T2 = FLAG_SET(PSR_CARRY); -} - -void OPPROTO op_eval_bvs(void) -{ - T2 = FLAG_SET(PSR_OVF); -} - -void OPPROTO op_eval_bn(void) -{ - T2 = 0; -} - -void OPPROTO op_eval_bneg(void) -{ - T2 = FLAG_SET(PSR_NEG); -} - -void OPPROTO op_eval_bne(void) -{ - T2 = !FLAG_SET(PSR_ZERO); -} - -void OPPROTO op_eval_bg(void) -{ - target_ulong Z = FLAG_SET(PSR_ZERO), N = FLAG_SET(PSR_NEG), V = FLAG_SET(PSR_OVF); - - T2 = !(Z | (N ^ V)); -} - -void OPPROTO op_eval_bge(void) -{ - target_ulong N = FLAG_SET(PSR_NEG), V = FLAG_SET(PSR_OVF); - - T2 = !(N ^ V); -} - -void OPPROTO op_eval_bgu(void) -{ - target_ulong Z = FLAG_SET(PSR_ZERO), C = FLAG_SET(PSR_CARRY); - - T2 = !(C | Z); -} - -void OPPROTO op_eval_bcc(void) -{ - T2 = !FLAG_SET(PSR_CARRY); -} - -void OPPROTO op_eval_bpos(void) -{ - T2 = !FLAG_SET(PSR_NEG); -} - -void OPPROTO op_eval_bvc(void) -{ - T2 = !FLAG_SET(PSR_OVF); -} - -#ifdef TARGET_SPARC64 -void OPPROTO op_eval_xbe(void) -{ - T2 = XFLAG_SET(PSR_ZERO); -} - -void OPPROTO op_eval_xble(void) -{ - target_ulong Z = XFLAG_SET(PSR_ZERO), N = XFLAG_SET(PSR_NEG), V = XFLAG_SET(PSR_OVF); - - T2 = Z | (N ^ V); -} - -void OPPROTO op_eval_xbl(void) -{ - target_ulong N = XFLAG_SET(PSR_NEG), V = XFLAG_SET(PSR_OVF); - - T2 = N ^ V; -} - -void OPPROTO op_eval_xbleu(void) -{ - target_ulong Z = XFLAG_SET(PSR_ZERO), C = XFLAG_SET(PSR_CARRY); - - T2 = C | Z; -} - -void OPPROTO op_eval_xbcs(void) -{ - T2 = XFLAG_SET(PSR_CARRY); -} - -void OPPROTO op_eval_xbvs(void) -{ - T2 = XFLAG_SET(PSR_OVF); -} - -void OPPROTO op_eval_xbneg(void) -{ - T2 = XFLAG_SET(PSR_NEG); -} - -void OPPROTO op_eval_xbne(void) -{ - T2 = !XFLAG_SET(PSR_ZERO); -} - -void OPPROTO op_eval_xbg(void) -{ - target_ulong Z = XFLAG_SET(PSR_ZERO), N = XFLAG_SET(PSR_NEG), V = XFLAG_SET(PSR_OVF); - - T2 = !(Z | (N ^ V)); -} - -void OPPROTO op_eval_xbge(void) -{ - target_ulong N = XFLAG_SET(PSR_NEG), V = XFLAG_SET(PSR_OVF); - - T2 = !(N ^ V); -} - -void OPPROTO op_eval_xbgu(void) -{ - target_ulong Z = XFLAG_SET(PSR_ZERO), C = XFLAG_SET(PSR_CARRY); - - T2 = !(C | Z); -} - -void OPPROTO op_eval_xbcc(void) -{ - T2 = !XFLAG_SET(PSR_CARRY); -} - -void OPPROTO op_eval_xbpos(void) -{ - T2 = !XFLAG_SET(PSR_NEG); -} - -void OPPROTO op_eval_xbvc(void) -{ - T2 = !XFLAG_SET(PSR_OVF); -} -#endif - -#define FCC -#define FFLAG_SET(x) (env->fsr & x? 1: 0) -#include "fbranch_template.h" - -#ifdef TARGET_SPARC64 -#define FCC _fcc1 -#define FFLAG_SET(x) ((env->fsr & ((uint64_t)x >> 32))? 1: 0) -#include "fbranch_template.h" -#define FCC _fcc2 -#define FFLAG_SET(x) ((env->fsr & ((uint64_t)x >> 34))? 1: 0) -#include "fbranch_template.h" -#define FCC _fcc3 -#define FFLAG_SET(x) ((env->fsr & ((uint64_t)x >> 36))? 1: 0) -#include "fbranch_template.h" -#endif - -#ifdef TARGET_SPARC64 -void OPPROTO op_eval_brz(void) -{ - T2 = (T0 == 0); -} - -void OPPROTO op_eval_brnz(void) -{ - T2 = (T0 != 0); -} - -void OPPROTO op_eval_brlz(void) -{ - T2 = ((int64_t)T0 < 0); -} - -void OPPROTO op_eval_brlez(void) -{ - T2 = ((int64_t)T0 <= 0); -} - -void OPPROTO op_eval_brgz(void) -{ - T2 = ((int64_t)T0 > 0); -} - -void OPPROTO op_eval_brgez(void) -{ - T2 = ((int64_t)T0 >= 0); -} -#endif - void OPPROTO op_jmp_label(void) { GOTO_LABEL_PARAM(1); } -void OPPROTO op_jnz_T2_label(void) -{ - if (T2) - GOTO_LABEL_PARAM(1); - FORCE_RET(); -} - -void OPPROTO op_jz_T2_label(void) -{ - if (!T2) - GOTO_LABEL_PARAM(1); - FORCE_RET(); -} - #define F_OP(name, p) void OPPROTO op_f##name##p(void) #if defined(CONFIG_USER_ONLY) @@ -1310,26 +1068,6 @@ void OPPROTO op_fqtox(void) } #endif -void OPPROTO op_fmovs_cc(void) -{ - if (T2) - FT0 = FT1; -} - -void OPPROTO op_fmovd_cc(void) -{ - if (T2) - DT0 = DT1; -} - -#if defined(CONFIG_USER_ONLY) -void OPPROTO op_fmovq_cc(void) -{ - if (T2) - QT0 = QT1; -} -#endif - void OPPROTO op_flushw(void) { if (env->cansave != NWINDOWS - 2) { |