Revision a7cfbba0
b/target-cris/translate.c | ||
---|---|---|
735 | 735 |
else |
736 | 736 |
tcg_gen_andi_tl(cpu_PR[PR_CCS], |
737 | 737 |
cpu_PR[PR_CCS], ~X_FLAG); |
738 |
} |
|
738 |
}
|
|
739 | 739 |
|
740 | 740 |
dc->flags_uptodate = 1; |
741 | 741 |
} |
... | ... | |
1530 | 1530 |
|
1531 | 1531 |
cris_cc_mask(dc, CC_MASK_NZ); |
1532 | 1532 |
|
1533 |
t_gen_mov_TN_reg(cpu_T[0], dc->op2); |
|
1534 | 1533 |
cris_alu(dc, CC_OP_BTST, |
1535 | 1534 |
cpu_T[0], cpu_R[dc->op2], tcg_const_tl(dc->op1), 4); |
1536 | 1535 |
cris_update_cc_op(dc, CC_OP_FLAGS, 4); |
... | ... | |
1968 | 1967 |
dc->op1, dc->op2)); |
1969 | 1968 |
|
1970 | 1969 |
cris_cc_mask(dc, CC_MASK_NZ); |
1971 |
t_gen_mov_TN_reg(cpu_T[0], dc->op1); |
|
1972 | 1970 |
/* Size can only be qi or hi. */ |
1973 | 1971 |
t_gen_sext(cpu_T[1], cpu_R[dc->op1], size); |
1974 | 1972 |
cris_alu(dc, CC_OP_MOVE, |
1975 |
cpu_R[dc->op2], cpu_T[0], cpu_T[1], 4);
|
|
1973 |
cpu_R[dc->op2], cpu_R[dc->op1], cpu_T[1], 4);
|
|
1976 | 1974 |
return 2; |
1977 | 1975 |
} |
1978 | 1976 |
|
... | ... | |
2788 | 2786 |
break; |
2789 | 2787 |
case 5: |
2790 | 2788 |
/* rfn. */ |
2791 |
BUG(); |
|
2789 |
cris_evaluate_flags(dc); |
|
2790 |
tcg_gen_helper_0_0(helper_rfn); |
|
2791 |
dc->is_jmp = DISAS_UPDATE; |
|
2792 | 2792 |
break; |
2793 | 2793 |
case 6: |
2794 | 2794 |
/* break. */ |
... | ... | |
3271 | 3271 |
CPUCRISState *cpu_cris_init (const char *cpu_model) |
3272 | 3272 |
{ |
3273 | 3273 |
CPUCRISState *env; |
3274 |
static int tcg_initialized = 0; |
|
3274 | 3275 |
int i; |
3275 | 3276 |
|
3276 | 3277 |
env = qemu_mallocz(sizeof(CPUCRISState)); |
3277 | 3278 |
if (!env) |
3278 | 3279 |
return NULL; |
3280 |
|
|
3279 | 3281 |
cpu_exec_init(env); |
3282 |
cpu_reset(env); |
|
3283 |
|
|
3284 |
if (tcg_initialized) |
|
3285 |
return env; |
|
3286 |
|
|
3287 |
tcg_initialized = 1; |
|
3280 | 3288 |
|
3281 | 3289 |
cpu_env = tcg_global_reg_new(TCG_TYPE_PTR, TCG_AREG0, "env"); |
3282 | 3290 |
#if TARGET_LONG_BITS > HOST_LONG_BITS |
... | ... | |
3337 | 3345 |
TCG_HELPER(helper_movl_sreg_reg); |
3338 | 3346 |
TCG_HELPER(helper_movl_reg_sreg); |
3339 | 3347 |
TCG_HELPER(helper_rfe); |
3348 |
TCG_HELPER(helper_rfn); |
|
3340 | 3349 |
|
3341 | 3350 |
TCG_HELPER(helper_evaluate_flags_muls); |
3342 | 3351 |
TCG_HELPER(helper_evaluate_flags_mulu); |
... | ... | |
3346 | 3355 |
TCG_HELPER(helper_evaluate_flags_move_2); |
3347 | 3356 |
TCG_HELPER(helper_evaluate_flags); |
3348 | 3357 |
TCG_HELPER(helper_top_evaluate_flags); |
3349 |
|
|
3350 |
cpu_reset(env); |
|
3351 | 3358 |
return env; |
3352 | 3359 |
} |
3353 | 3360 |
|
Also available in: Unified diff