From c15e71cd7c504c038f1c880ad19e8bc181373cf3 Mon Sep 17 00:00:00 2001 From: Astrid Smith Date: Fri, 18 Jun 2010 17:31:31 -0700 Subject: Added more flag stubs --- flags.asm | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'flags.asm') diff --git a/flags.asm b/flags.asm index ac51b01..0dceb2a 100644 --- a/flags.asm +++ b/flags.asm @@ -97,6 +97,11 @@ f_calc_parity: move.w d0,flag_byte-flag_storage(a3) rts + ;; Routine to make both the Carry and Half-Carry flags valid. +f_calc_carries: + ;; XXX do this + rts + ;; Normalize and return Sign bit (loaded into Z bit). ;; Destroys d1 f_norm_sign: @@ -110,8 +115,6 @@ FNsign_ok: rts ;; Routine to turn 68k flags into z80 flags. - ;; Preconditions: - ;; Flags to change are noted in d0 by a 1 bit flags_normalize: move.b f_host_ccr(pc),d1 ; 8/4 ;; .w keeps d1 clean @@ -126,6 +129,12 @@ flags_normalize: or.b d1,flag_byte-flag_storage(a3) rts + ;; Routine to completely fill the flags register +flags_all: + bsr flags_normalize + bsr f_calc_carries + rts + flag_storage: ;; Numbers in comments are offsets from flag_storage, so use ;; offset(a3) to address. -- cgit v1.2.3