/***************************************************************
 *  Alcuin: A HP48 emulator for Amiga Computers
 * 
 *  (C) 1995 Stephan Schupfer (schupfer@sbox.tu-graz.ac.at)
 *
 */

static inline void bf_illegal()
{
enter_debugger |= ILLEGAL_INSTRUCTION;
}

static inline void bf_rtnsxm()
{
saturn_HST |= XM;
saturn_PC = pop ();
}

static inline void bf_rtn()
{
saturn_PC = pop ();
}

static inline void bf_rtnsc()
{
saturn_CARRY = 1;
saturn_PC = pop ();
}

static inline void bf_rtncc ()
{
saturn_CARRY = 0;
saturn_PC = pop ();
}

static inline void bf_sethex ()
{
saturn_hexmode = 1;
saturn_PC += 2;
}

static inline void bf_setdec ()
{
saturn_hexmode = 0;
saturn_PC += 2;
}

static inline void bf_push ()
{
push (reg_addr (saturn_C));
saturn_PC += 2;
}

static inline void bf_pop ()
{
addr_reg (pop (), saturn_C);
saturn_PC += 2;
}

static inline void bf_clr_st ()
{
clr_st ();
saturn_PC += 2;
}

static inline void bf_move_st_c ()
{
move_st_c ();
saturn_PC += 2;
}

static inline void bf_move_c_st ()
{
move_c_st ();
saturn_PC += 2;
}

static inline void bf_exg_c_st ()
{
exg_st_c ();
saturn_PC += 2;
}

static inline void bf_inc_reg_p ()
{
inc_reg_p ();
saturn_PC += 2;
}

static inline void bf_dec_reg_p ()
{
dec_reg_p ();
saturn_PC += 2;
}

static inline void bf_and_p ()
{
and_p (op->cpu_src, op->cpu_dst,saturn_P);
saturn_PC += 4;
}

static inline void bf_and_wp ()
{
and_wp (op->cpu_src, op->cpu_dst);
saturn_PC += 4;
}

static inline void bf_and_xs ()
{
and_p (op->cpu_src, op->cpu_dst,2);
saturn_PC += 4;
}

static inline void bf_and_x ()
{
and_x (op->cpu_src, op->cpu_dst);
saturn_PC += 4;
}

static inline void bf_and_s ()
{
and_p (op->cpu_src, op->cpu_dst,15);
saturn_PC += 4;
}

static inline void bf_and_m ()
{
and_m (op->cpu_src, op->cpu_dst);
saturn_PC += 4;
}

static inline void bf_and_b ()
{
and_b (op->cpu_src, op->cpu_dst);
saturn_PC += 4;
}

static inline void bf_and_w ()
{
and_w (op->cpu_src, op->cpu_dst);
saturn_PC += 4;
}

static inline void bf_and_a()
{
and_a (op->cpu_src, op->cpu_dst);
saturn_PC += 4;
}

static inline void bf_or_p ()
{
or_p (op->cpu_src, op->cpu_dst,saturn_P);
saturn_PC += 4;
}

static inline void bf_or_wp ()
{
or_wp (op->cpu_src, op->cpu_dst);
saturn_PC += 4;
}

static inline void bf_or_xs ()
{
or_p (op->cpu_src, op->cpu_dst,2);
saturn_PC += 4;
}

static inline void bf_or_x ()
{
or_x (op->cpu_src, op->cpu_dst);
saturn_PC += 4;
}

static inline void bf_or_s ()
{
or_p (op->cpu_src, op->cpu_dst,15);
saturn_PC += 4;
}

static inline void bf_or_m ()
{
or_m (op->cpu_src, op->cpu_dst);
saturn_PC += 4;
}

static inline void bf_or_b ()
{
or_b (op->cpu_src, op->cpu_dst);
saturn_PC += 4;
}

static inline void bf_or_w ()
{
or_w (op->cpu_src, op->cpu_dst);
saturn_PC += 4;
}

static inline void bf_or_a ()
{
or_a (op->cpu_src, op->cpu_dst);
saturn_PC += 4;
}

static inline void bf_rti ()
{
rti ();
}

static inline void bf_move_p ()
{
move_p (op->cpu_src, op->cpu_dst,saturn_P);
saturn_PC += ++opcount;
}

static inline void bf_move_wp ()
{
move_wp (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_move_xs ()
{
move_p (op->cpu_src, op->cpu_dst,2);
saturn_PC += ++opcount;
}

static inline void bf_move_x ()
{
move_x (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_move_s ()
{
move_p (op->cpu_src, op->cpu_dst,15);
saturn_PC += ++opcount;
}

static inline void bf_move_m ()
{
move_m (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_move_b ()
{
move_b (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_move_w ()
{
move_w (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_move_a ()
{
move_a (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_exg_p ()
{
exg_p (op->cpu_src, op->cpu_dst,saturn_P);
saturn_PC += ++opcount;
}

static inline void bf_exg_wp ()
{
exg_wp (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_exg_xs ()
{
exg_p (op->cpu_src, op->cpu_dst,2);
saturn_PC += ++opcount;
}

static inline void bf_exg_x ()
{
exg_x (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_exg_s ()
{
exg_p (op->cpu_src, op->cpu_dst,15);
saturn_PC += ++opcount;
}

static inline void bf_exg_m ()
{
exg_m (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_exg_b ()
{
exg_b (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_exg_w ()
{
exg_w (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_exg_a ()
{
exg_a (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_move_dp_4 ()
{
move_dp_4 (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_move_dp_5 ()
{
move_dp_5 (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_exg_dp_4 ()
{
exg_dp_4 (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_exg_dp_5()
{
exg_dp_5 (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_load_p()
{
load_p (op->cpu_src, op->cpu_dst,saturn_P);
saturn_PC += ++opcount;
}

static inline void bf_load_wp()
{
load_wp (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_load_xs()
{
load_p (op->cpu_src, op->cpu_dst,2);
saturn_PC += ++opcount;
}

static inline void bf_load_x()
{
load_x (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_load_s()
{
load_p (op->cpu_src, op->cpu_dst,15);
saturn_PC += ++opcount;
}

static inline void bf_load_m()
{
load_m (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_load_b()
{
load_b (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_load_w()
{
load_w (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_load_a()
{
load_a (op->cpu_src, op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_store_p()
{
store_p (op->cpu_dst, op->cpu_src,saturn_P);
saturn_PC += ++opcount;
}

static inline void bf_store_wp()
{
store_wp (op->cpu_dst, op->cpu_src);
saturn_PC += ++opcount;
}

static inline void bf_store_xs()
{
store_p (op->cpu_dst, op->cpu_src,2);
saturn_PC += ++opcount;
}

static inline void bf_store_x()
{
store_x (op->cpu_dst, op->cpu_src);
saturn_PC += ++opcount;
}

static inline void bf_store_s()
{
store_p (op->cpu_dst, op->cpu_src,15);
saturn_PC += ++opcount;
}

static inline void bf_store_m()
{
store_m (op->cpu_dst, op->cpu_src);
saturn_PC += ++opcount;
}

static inline void bf_store_b()
{
store_b (op->cpu_dst, op->cpu_src);
saturn_PC += ++opcount;
}

static inline void bf_store_w()
{
store_w (op->cpu_dst, op->cpu_src);
saturn_PC += ++opcount;
}

static inline void bf_store_a()
{
store_a (op->cpu_dst, op->cpu_src);
saturn_PC += ++opcount;
}

static inline void bf_load_n()
{
load_n (op->cpu_src, op->cpu_dst, op->cpu_field);
saturn_PC += 4;
}

static inline void bf_store_n()
{
store_n (op->cpu_dst, op->cpu_src, op->cpu_field);
saturn_PC += 4;
}

static inline void bf_add_con_dp()
{
add_con_dp (op->cpu_dst, read_pimm_1());
saturn_PC += 3;
}

static inline void bf_sub_con_dp()
{
sub_con_dp (op->cpu_dst, read_pimm_1());
saturn_PC += 3;
}

static inline void bf_move_con_dp_2()
{
move_con_dp_2 (op->cpu_dst, read_simm_2());
saturn_PC += 4;
}

static inline void bf_move_con_dp_4()
{
move_con_dp_4 (op->cpu_dst, read_simm_4());
saturn_PC += 6;
}

static inline void bf_move_con_dp_5()
{
move_con_dp_5 (op->cpu_dst, read_simm_5());
saturn_PC += 7;
}

static inline void bf_move_con_reg_p()
{
move_con_reg_p (read_simm_1());
saturn_PC += 2;
}

static inline void bf_move_con_1()
{
read_limm_1(code);
move_con_1 (op->cpu_dst, code->con64);
saturn_PC += ++opcount;
}

static inline void bf_move_con_2()
{
read_limm_2(code);
move_con_2 (op->cpu_dst, code->con64);
saturn_PC += ++opcount;
}

static inline void bf_move_con_3()
{
read_limm_3(code);
move_con (op->cpu_dst, code->con64,3);
saturn_PC += ++opcount;
}

static inline void bf_move_con_4()
{
read_limm_4(code);
move_con (op->cpu_dst, code->con64,4);
saturn_PC += ++opcount;
}

static inline void bf_move_con_5()
{
read_limm_5(code);
move_con (op->cpu_dst, code->con64,5);
saturn_PC += ++opcount;
}

static inline void bf_move_con_6()
{
read_limm_6(code);
move_con (op->cpu_dst, code->con64,6);
saturn_PC += ++opcount;
}

static inline void bf_move_con_7()
{
read_limm_7(code);
move_con (op->cpu_dst, code->con64,7);
saturn_PC += ++opcount;
}

static inline void bf_move_con_8()
{
read_limm_8(code);
move_con (op->cpu_dst, code->con64,8);
saturn_PC += ++opcount;
}

static inline void bf_move_con_9()
{
read_limm_9(code);
move_con (op->cpu_dst, code->con64,9);
saturn_PC += ++opcount;
}

static inline void bf_move_con_10()
{
read_limm_10(code);
move_con (op->cpu_dst, code->con64,10);
saturn_PC += ++opcount;
}

static inline void bf_move_con_11()
{
read_limm_11(code);
move_con (op->cpu_dst, code->con64,11);
saturn_PC += ++opcount;
}

static inline void bf_move_con_12()
{
read_limm_12(code);
move_con (op->cpu_dst, code->con64,12);
saturn_PC += ++opcount;
}

static inline void bf_move_con_13()
{
read_limm_13(code);
move_con (op->cpu_dst, code->con64,13);
saturn_PC += ++opcount;
}

static inline void bf_move_con_14()
{
read_limm_14(code);
move_con (op->cpu_dst, code->con64,14);
saturn_PC += ++opcount;
}

static inline void bf_move_con_15()
{
read_limm_15(code);
move_con (op->cpu_dst, code->con64,15);
saturn_PC += ++opcount;
}

static inline void bf_move_con_16()
{
read_limm_16(code);
move_con (op->cpu_dst, code->con64,16);
saturn_PC += ++opcount;
}

static inline void bf_bcs()
{
if (saturn_CARRY) read_bra_2();
else saturn_PC += 3;
}

static inline void bf_bcc()
{
if (!saturn_CARRY) read_bra_2();
else saturn_PC += 3;
}

static inline void bf_bra_3()
{
read_bra_3(code);
if (code->emucall) {
    enter_debugger |= code->emucall;
    saturn_PC += ++opcount;
	}
else saturn_PC = code->jmp_addr;
}

static inline void bf_bra_4()
{
read_bra_4(code);
if (code->emucall) {
    enter_debugger |= code->emucall;
    saturn_PC += ++opcount;
	}
else saturn_PC = code->jmp_addr;
}

static inline void bf_bsr_3()
{
push (saturn_PC + 4);
read_bsr_3();
}

static inline void bf_bsr_4()
{
push (saturn_PC + 6);
read_bsr_4();
}

static inline void bf_move_out_1()
{
move_out_1 ();
saturn_PC += 3;
check_out_register();
}

static inline void bf_move_out_3()
{
move_out_3 ();
saturn_PC += 3;
check_out_register();
}

static inline void bf_move_in()
{
kbd_read ();
move_in (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_uncnfg()
{
do_unconfigure ();
saturn_PC += 3;
}

static inline void bf_config()
{
config ();
saturn_PC += 3;
}

static inline void bf_c_id()
{
get_identification ();
saturn_PC += 3;
}

static inline void bf_shutdn()
{
saturn_PC += 3;
do_shutdown ();
}

static inline void bf_inton()
{
inton ();
saturn_PC += 4;
}

static inline void bf_rsi()
{
saturn_PC += 5;
do_reset_interupt_system ();
}

static inline void bf_buscb()
{
buscb ();
saturn_PC += 4;
}

static inline void	 bf_bclr()
{
bclr (op->cpu_dst, read_simm_1());
saturn_PC += 5;
}

static inline void bf_bset()
{
bset (op->cpu_dst, read_simm_1());
saturn_PC += 5;
}

static inline void bf_bbc()
{
saturn_CARRY = b_is_clr (op->cpu_dst, read_simm_1());
if (saturn_CARRY) read_bra_2();
else saturn_PC += 7;
}

static inline void bf_bbs()
{
saturn_CARRY = b_is_set (op->cpu_dst, read_simm_1());
if (saturn_CARRY) read_bra_2();
else saturn_PC += 7;
}

static inline void bf_jmp_reg_ind()
{
mmu_read_con20 (reg_addr (op->cpu_dst), 5, &saturn_PC);
}

static inline void bf_buscc()
{
buscc ();
saturn_PC += 3;
}

static inline void bf_intoff()
{
intoff ();
saturn_PC += 4;
}

static inline void bf_add_c_p_1()
{
add_c_p_1 ();
saturn_PC += 3;
}

static inline void bf_reset()
{
do_reset ();
saturn_PC += 3;
}

static inline void bf_buscd()
{
buscd ();
saturn_PC += 4;
}

static inline void bf_move_p_c()
{
move_p_c (op->cpu_field);
saturn_PC += 4;
}

static inline void bf_move_c_p()
{
move_c_p (op->cpu_field);
saturn_PC += 4;
}

static inline void bf_sreq()
{
sreq ();
saturn_PC += 3;
}

static inline void bf_exg_p_c()
{
exg_p_c (op->cpu_field);
saturn_PC += 4;
}

static inline void bf_rol_w()
{
rol_reg (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_ror_w()
{
ror_reg (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_add_con_p()
{
add_con_p (op->cpu_dst, read_pimm_1(),saturn_P);
saturn_PC += ++opcount;
}

static inline void bf_add_con_wp()
{
add_con_wp (op->cpu_dst, read_pimm_1());
saturn_PC += ++opcount;
}

static inline void bf_add_con_xs()
{
add_con_p (op->cpu_dst, read_pimm_1(),2);
saturn_PC += ++opcount;
}

static inline void bf_add_con_x()
{
add_con_x (op->cpu_dst, read_pimm_1());
saturn_PC += ++opcount;
}

static inline void bf_add_con_s()
{
add_con_p (op->cpu_dst, read_pimm_1(),15);
saturn_PC += ++opcount;
}

static inline void bf_add_con_m()
{
add_con_m (op->cpu_dst, read_pimm_1());
saturn_PC += ++opcount;
}

static inline void bf_add_con_b()
{
add_con_b (op->cpu_dst, read_pimm_1());
saturn_PC += ++opcount;
}

static inline void bf_add_con_w()
{
add_con_w (op->cpu_dst, read_pimm_1());
saturn_PC += 6;
}

static inline void bf_add_con_a()
{
add_con_a (op->cpu_dst, read_pimm_1());
saturn_PC += 6;
}

static inline void bf_sub_con_p()
{
sub_con_p (op->cpu_dst, read_pimm_1(),saturn_P);
saturn_PC += ++opcount;
}

static inline void bf_sub_con_wp()
{
sub_con_wp (op->cpu_dst, read_pimm_1());
saturn_PC += ++opcount;
}

static inline void bf_sub_con_xs()
{
sub_con_p (op->cpu_dst, read_pimm_1(),2);
saturn_PC += ++opcount;
}

static inline void bf_sub_con_x()
{
sub_con_x (op->cpu_dst, read_pimm_1());
saturn_PC += ++opcount;
}

static inline void bf_sub_con_s()
{
sub_con_p (op->cpu_dst, read_pimm_1(),15);
saturn_PC += ++opcount;
}

static inline void bf_sub_con_m()
{
sub_con_m (op->cpu_dst, read_pimm_1());
saturn_PC += ++opcount;
}

static inline void bf_sub_con_b()
{
sub_con_b (op->cpu_dst, read_pimm_1());
saturn_PC += ++opcount;
}

static inline void bf_sub_con_w()
{
sub_con_w (op->cpu_dst, read_pimm_1());
saturn_PC += 6;
}

static inline void bf_sub_con_a()
{
sub_con_a (op->cpu_dst, read_pimm_1());
saturn_PC += 6;
}

static inline void bf_lsr_1_p()
{
lsr_1_p (op->cpu_dst,saturn_P);
saturn_PC += 5;
}

static inline void bf_lsr_1_wp()
{
lsr_1_wp (op->cpu_dst);
saturn_PC += 5;
}

static inline void bf_lsr_1_xs()
{
lsr_1_p (op->cpu_dst,2);
saturn_PC += 5;
}

static inline void bf_lsr_1_x()
{
lsr_1_x (op->cpu_dst);
saturn_PC += 5;
}

static inline void bf_lsr_1_s()
{
lsr_1_p (op->cpu_dst,15);
saturn_PC += 5;
}

static inline void bf_lsr_1_m()
{
lsr_1_m (op->cpu_dst);
saturn_PC += 5;
}

static inline void bf_lsr_1_b()
{
lsr_1_b (op->cpu_dst);
saturn_PC += 5;
}

static inline void bf_lsr_1_w()
{
lsr_1_w (op->cpu_dst);
saturn_PC += ++opcount;
}

static inline void bf_lsr_1_a()
{
lsr_1_a (op->cpu_dst);
saturn_PC += 5;
}

static inline void bf_jmp_reg()
{
saturn_PC = reg_addr (op->cpu_dst);
}

static inline void bf_move_pc()
{
move_pc (op->cpu_dst);
saturn_PC += 4;
}

static inline void bf_exg_pc()
{
saturn_PC = exg_pc (op->cpu_dst);
}

static inline void bf_clr_hst()
{
clr_hst (read_simm_1());
saturn_PC += 3;
}

static inline void bf_beq_hst()
{
saturn_CARRY = is_clr_hst (read_simm_1());
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bclr_st()
{
bclr_st (read_simm_1());
saturn_PC += 3;
}

static inline void bf_bset_st()
{
bset_st (read_simm_1());
saturn_PC += 3;
}

static inline void bf_bbc_st()
{
saturn_CARRY = b_is_clr_st (read_simm_1());
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bbs_st()
{
saturn_CARRY = b_is_set_st (read_simm_1());
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_reg_p()
{
saturn_CARRY = ne_reg_p (read_simm_1());
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_reg_p()
{
saturn_CARRY = eq_reg_p (read_simm_1());
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_p()
{
saturn_CARRY = eq_p (op->cpu_src, op->cpu_dst,saturn_P);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_wp()
{
saturn_CARRY = eq_wp (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_xs()
{
saturn_CARRY = eq_p (op->cpu_src, op->cpu_dst,2);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_x()
{
saturn_CARRY = eq_x (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_s()
{
saturn_CARRY = eq_p (op->cpu_src, op->cpu_dst,15);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_m()
{
saturn_CARRY = eq_m (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_b()
{
saturn_CARRY = eq_b (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_w()
{
saturn_CARRY = eq_w (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_a()
{
saturn_CARRY = eq_a (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_p()
{
saturn_CARRY = ne_p (op->cpu_src, op->cpu_dst,saturn_P);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_wp()
{
saturn_CARRY = ne_wp (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_xs()
{
saturn_CARRY = ne_p (op->cpu_src, op->cpu_dst,2);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_x()
{
saturn_CARRY = ne_x (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_s()
{
saturn_CARRY = ne_p (op->cpu_src, op->cpu_dst,15);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_m()
{
saturn_CARRY = ne_m (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_b()
{
saturn_CARRY = ne_b (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_w()
{
saturn_CARRY = ne_w (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_a()
{
saturn_CARRY = ne_a (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_zero_p()
{
saturn_CARRY = eqz_p (op->cpu_src,saturn_P);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_zero_wp()
{
saturn_CARRY = eqz_wp (op->cpu_src);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_zero_xs()
{
saturn_CARRY = eqz_p (op->cpu_src,2);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_zero_x()
{
saturn_CARRY = eqz_x (op->cpu_src);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_zero_s()
{
saturn_CARRY = eqz_p (op->cpu_src,15);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_zero_m()
{
saturn_CARRY = eqz_m (op->cpu_src);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_zero_b()
{
saturn_CARRY = eqz_b (op->cpu_src);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_zero_w()
{
saturn_CARRY = eqz_w (op->cpu_src);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_beq_zero_a()
{
saturn_CARRY = eqz_a (op->cpu_src);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_zero_p()
{
saturn_CARRY = nez_p (op->cpu_src,saturn_P);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_zero_wp()
{
saturn_CARRY = nez_wp (op->cpu_src);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_zero_xs()
{
saturn_CARRY = nez_p (op->cpu_src,2);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_zero_x()
{
saturn_CARRY = nez_x (op->cpu_src);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_zero_s()
{
saturn_CARRY = nez_p (op->cpu_src,15);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_zero_m()
{
saturn_CARRY = nez_m (op->cpu_src);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_zero_b()
{
saturn_CARRY = nez_b (op->cpu_src);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_zero_w()
{
saturn_CARRY = nez_w (op->cpu_src);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bne_zero_a()
{
saturn_CARRY = nez_a (op->cpu_src);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bgt_p()
{
saturn_CARRY = gt_p (op->cpu_src, op->cpu_dst,saturn_P);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bgt_wp()
{
saturn_CARRY = gt_wp (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bgt_xs()
{
saturn_CARRY = gt_p (op->cpu_src, op->cpu_dst,2);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bgt_x()
{
saturn_CARRY = gt_x (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bgt_s()
{
saturn_CARRY = gt_p (op->cpu_src, op->cpu_dst,15);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bgt_m()
{
saturn_CARRY = gt_m (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bgt_b()
{
saturn_CARRY = gt_b (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bgt_w()
{
saturn_CARRY = gt_w (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bgt_a()
{
saturn_CARRY = gt_a (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_blt_p()
{
saturn_CARRY = lt_p (op->cpu_src, op->cpu_dst,saturn_P);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_blt_wp()
{
saturn_CARRY = lt_wp (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_blt_xs()
{
saturn_CARRY = lt_p (op->cpu_src, op->cpu_dst,2);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_blt_x()
{
saturn_CARRY = lt_x (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_blt_s()
{
saturn_CARRY = lt_p (op->cpu_src, op->cpu_dst,15);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_blt_m()
{
saturn_CARRY = lt_m (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_blt_b()
{
saturn_CARRY = lt_b (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_blt_w()
{
saturn_CARRY = lt_w (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_blt_a()
{
saturn_CARRY = lt_a (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bge_p()
{
saturn_CARRY = ge_p (op->cpu_src, op->cpu_dst,saturn_P);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bge_wp()
{
saturn_CARRY = ge_wp (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bge_xs()
{
saturn_CARRY = ge_p (op->cpu_src, op->cpu_dst,2);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bge_x()
{
saturn_CARRY = ge_x (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bge_s()
{
saturn_CARRY = ge_p (op->cpu_src, op->cpu_dst,15);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bge_m()
{
saturn_CARRY = ge_m (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bge_b()
{
saturn_CARRY = ge_b (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bge_w()
{
saturn_CARRY = ge_w (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_bge_a()
{
saturn_CARRY = ge_a (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_ble_p()
{
saturn_CARRY = le_p (op->cpu_src, op->cpu_dst,saturn_P);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_ble_wp()
{
saturn_CARRY = le_wp (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_ble_xs()
{
saturn_CARRY = le_p (op->cpu_src, op->cpu_dst,2);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_ble_x()
{
saturn_CARRY = le_x (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_ble_s()
{
saturn_CARRY = le_p (op->cpu_src, op->cpu_dst,15);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_ble_m()
{
saturn_CARRY = le_m (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_ble_b()
{
saturn_CARRY = le_b (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_ble_w()
{
saturn_CARRY = le_w (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_ble_a()
{
saturn_CARRY = le_a (op->cpu_src, op->cpu_dst);
if (saturn_CARRY) read_bra_2();
else saturn_PC += 5;
}

static inline void bf_jmp()
{
read_abs_5();
}

static inline void bf_jsr()
{
push (saturn_PC + 7);
read_abs_5();
}

static inline void bf_add_p()
{
add_p (op->cpu_src, op->cpu_dst,saturn_P);
saturn_PC += 3;
}

static inline void bf_add_wp()
{
add_wp (op->cpu_src, op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_add_xs()
{
add_p (op->cpu_src, op->cpu_dst,2);
saturn_PC += 3;
}

static inline void bf_add_x()
{
add_x (op->cpu_src, op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_add_s()
{
add_p (op->cpu_src, op->cpu_dst,15);
saturn_PC += 3;
}

static inline void bf_add_m()
{
add_m (op->cpu_src, op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_add_b()
{
add_b (op->cpu_src, op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_add_w()
{
add_w (op->cpu_src, op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_add_a()
{
add_a (op->cpu_src, op->cpu_dst);
saturn_PC += 2;
}

static inline void bf_lsl_1_p()
{
lsl_1_p (op->cpu_dst,saturn_P);
saturn_PC += 3;
}

static inline void bf_lsl_1_wp()
{
lsl_1_wp (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_lsl_1_xs()
{
lsl_1_p (op->cpu_dst,2);
saturn_PC += 3;
}

static inline void bf_lsl_1_x()
{
lsl_1_x (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_lsl_1_s()
{
lsl_1_p (op->cpu_dst,15);
saturn_PC += 3;
}

static inline void bf_lsl_1_m()
{
lsl_1_m (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_lsl_1_b()
{
lsl_1_b (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_lsl_1_w()
{
lsl_1_w (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_lsl_1_a()
{
lsl_1_a (op->cpu_dst);
saturn_PC += 2;
}

static inline void bf_dec_p()
{
dec_p (op->cpu_dst,saturn_P);
saturn_PC += 3;
}

static inline void bf_dec_wp()
{
dec_wp (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_dec_xs()
{
dec_p (op->cpu_dst,2);
saturn_PC += 3;
}

static inline void bf_dec_x()
{
dec_x (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_dec_s()
{
dec_p (op->cpu_dst,15);
saturn_PC += 3;
}

static inline void bf_dec_m()
{
dec_m (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_dec_b()
{
dec_b (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_dec_w()
{
dec_w (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_dec_a()
{
dec_a (op->cpu_dst);
saturn_PC += 2;
}

static inline void bf_clr_p()
{
clr_p (op->cpu_dst,saturn_P);
saturn_PC += 3;
}

static inline void bf_clr_wp()
{
clr_wp (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_clr_xs()
{
clr_p (op->cpu_dst,2);
saturn_PC += 3;
}

static inline void bf_clr_x()
{
clr_x (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_clr_s()
{
clr_p (op->cpu_dst,15);
saturn_PC += 3;
}

static inline void bf_clr_m()
{
clr_m (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_clr_b()
{
clr_b (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_clr_w()
{
clr_w (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_clr_a()
{
clr_a (op->cpu_dst);
saturn_PC += 2;
}

static inline void bf_sub_p()
{
sub_p (op->cpu_src, op->cpu_dst,saturn_P);
saturn_PC += 3;
}

static inline void bf_sub_wp()
{
sub_wp (op->cpu_src, op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_sub_xs()
{
sub_p (op->cpu_src, op->cpu_dst,2);
saturn_PC += 3;
}

static inline void bf_sub_x()
{
sub_x (op->cpu_src, op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_sub_s()
{
sub_p (op->cpu_src, op->cpu_dst,15);
saturn_PC += 3;
}

static inline void bf_sub_m()
{
sub_m (op->cpu_src, op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_sub_b()
{
sub_b (op->cpu_src, op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_sub_w()
{
sub_w (op->cpu_src, op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_sub_a()
{
sub_a (op->cpu_src, op->cpu_dst);
saturn_PC += 2;
}

static inline void bf_inc_p()
{
inc_p (op->cpu_dst,saturn_P);
saturn_PC += 3;
}

static inline void bf_inc_wp()
{
inc_wp (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_inc_xs()
{
inc_p (op->cpu_dst,2);
saturn_PC += 3;
}

static inline void bf_inc_x()
{
inc_x (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_inc_s()
{
inc_p (op->cpu_dst,15);
saturn_PC += 3;
}

static inline void bf_inc_m()
{
inc_m (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_inc_b()
{
inc_b (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_inc_w()
{
inc_w (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_inc_a()
{
inc_a (op->cpu_dst);
saturn_PC += 2;
}

static inline void bf_subr_p()
{
subr_p (op->cpu_src, op->cpu_dst,saturn_P);
saturn_PC += 3;
}

static inline void bf_subr_wp()
{
subr_wp (op->cpu_src, op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_subr_xs()
{
subr_p (op->cpu_src, op->cpu_dst,2);
saturn_PC += 3;
}

static inline void bf_subr_x()
{
subr_x (op->cpu_src, op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_subr_s()
{
subr_p (op->cpu_src, op->cpu_dst,15);
saturn_PC += 3;
}

static inline void bf_subr_m()
{
subr_m (op->cpu_src, op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_subr_b()
{
subr_b (op->cpu_src, op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_subr_w()
{
subr_w (op->cpu_src, op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_subr_a()
{
subr_a (op->cpu_src, op->cpu_dst);
saturn_PC += 2;
}

static inline void bf_lsl_4_p()
{
lsl_p (op->cpu_dst,saturn_P);
saturn_PC += 3;
}

static inline void bf_lsl_4_wp()
{
lsl_wp (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_lsl_4_xs()
{
lsl_p (op->cpu_dst,2);
saturn_PC += 3;
}

static inline void bf_lsl_4_x()
{
lsl_x (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_lsl_4_s()
{
lsl_p (op->cpu_dst,15);
saturn_PC += 3;
}

static inline void bf_lsl_4_m()
{
lsl_m (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_lsl_4_b()
{
lsl_b (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_lsl_4_w()
{
lsl_w (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_lsl_4_a()
{
lsl_a (op->cpu_dst);
saturn_PC += 2;
}

static inline void bf_lsr_4_p()
{
lsr_p (op->cpu_dst,saturn_P);
saturn_PC += 3;
}

static inline void bf_lsr_4_wp()
{
lsr_wp (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_lsr_4_xs()
{
lsr_p (op->cpu_dst,2);
saturn_PC += 3;
}

static inline void bf_lsr_4_x()
{
lsr_x (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_lsr_4_s()
{
lsr_p (op->cpu_dst,15);
saturn_PC += 3;
}

static inline void bf_lsr_4_m()
{
lsr_m (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_lsr_4_b()
{
lsr_b (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_lsr_4_w()
{
lsr_w (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_lsr_4_a()
{
lsr_a (op->cpu_dst);
saturn_PC += 2;
}

static inline void bf_neg_p()
{
neg_p (op->cpu_dst,saturn_P);
saturn_PC += 3;
}

static inline void bf_neg_wp()
{
neg_wp (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_neg_xs()
{
neg_p (op->cpu_dst,2);
saturn_PC += 3;
}

static inline void bf_neg_x()
{
neg_x (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_neg_s()
{
neg_p (op->cpu_dst,15);
saturn_PC += 3;
}

static inline void bf_neg_m()
{
neg_m (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_neg_b()
{
neg_b (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_neg_w()
{
neg_w (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_neg_a()
{
neg_a (op->cpu_dst);
saturn_PC += 2;
}

static inline void bf_not_p()
{
not_p (op->cpu_dst,saturn_P);
saturn_PC += 3;
}

static inline void bf_not_wp()
{
not_wp (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_not_xs()
{
not_p (op->cpu_dst,2);
saturn_PC += 3;
}

static inline void bf_not_x()
{
not_x(op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_not_s()
{
not_p (op->cpu_dst,15);
saturn_PC += 3;
}

static inline void bf_not_m()
{
not_m (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_not_b()
{
not_b (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_not_w()
{
not_w (op->cpu_dst);
saturn_PC += 3;
}

static inline void bf_not_a()
{
not_a (op->cpu_dst);
saturn_PC += 2;
}
