ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/cebix/BasiliskII/src/uae_cpu/newcpu.cpp
(Generate patch)

Comparing BasiliskII/src/uae_cpu/newcpu.cpp (file contents):
Revision 1.5 by cebix, 1999-11-03T10:56:43Z vs.
Revision 1.8 by gbeauche, 2001-03-20T17:35:46Z

# Line 22 | Line 22 | extern int intlev(void);       // From baisili
22   #include "memory.h"
23   #include "readcpu.h"
24   #include "newcpu.h"
25 #include "compiler.h"
25  
26   int quit_program = 0;
27   int debugging = 0;
# Line 207 | Line 206 | void init_m68k (void)
206      do_merges ();
207  
208      build_cpufunctbl ();
209 +    
210 +    fpu_init ();
211 +    fpu_set_integral_fpu (CPUType == 4);
212 + }
213 +
214 + void exit_m68k (void)
215 + {
216 +        fpu_exit ();
217   }
218  
219   struct regstruct regs, lastint_regs;
# Line 215 | Line 222 | static int backup_pointer = 0;
222   static long int m68kpc_offset;
223   int lastint_no;
224  
225 + #if REAL_ADDRESSING || DIRECT_ADDRESSING
226 + #define get_ibyte_1(o) get_byte(get_virtual_address(regs.pc_p) + (o) + 1)
227 + #define get_iword_1(o) get_word(get_virtual_address(regs.pc_p) + (o))
228 + #define get_ilong_1(o) get_long(get_virtual_address(regs.pc_p) + (o))
229 + #else
230   #define get_ibyte_1(o) get_byte(regs.pc + (regs.pc_p - regs.pc_oldp) + (o) + 1)
231   #define get_iword_1(o) get_word(regs.pc + (regs.pc_p - regs.pc_oldp) + (o))
232   #define get_ilong_1(o) get_long(regs.pc + (regs.pc_p - regs.pc_oldp) + (o))
233 + #endif
234  
235   uae_s32 ShowEA (int reg, amodes mode, wordsizes size, char *buf)
236   {
# Line 645 | Line 658 | void MakeFromSR (void)
658  
659   void Exception(int nr, uaecptr oldpc)
660   {
648    compiler_flush_jsr_stack();
661      MakeSR();
662      if (!regs.s) {
663          regs.usp = m68k_areg(regs, 7);
# Line 1047 | Line 1059 | void m68k_reset (void)
1059      regs.spcflags = 0;
1060      regs.intmask = 7;
1061      regs.vbr = regs.sfc = regs.dfc = 0;
1062 <    regs.fpcr = regs.fpsr = regs.fpiar = 0;
1062 >    /* gb-- moved into {fpp,fpu_x86}.cpp::fpu_init()
1063 >    regs.fpcr = regs.fpsr = regs.fpiar = 0; */
1064 >    fpu_reset();
1065   }
1066  
1067   void REGPARAM2 op_illg (uae_u32 opcode)
1068   {
1069      uaecptr pc = m68k_getpc ();
1070  
1057    compiler_flush_jsr_stack ();
1058
1071          if ((opcode & 0xFF00) == 0x7100) {
1072                  struct M68kRegisters r;
1073                  int i;
# Line 1156 | Line 1168 | static void do_trace (void)
1168   static int do_specialties (void)
1169   {
1170      /*n_spcinsns++;*/
1159    run_compiled_code();
1171      if (regs.spcflags & SPCFLAG_DOTRACE) {
1172          Exception (9,last_trace_ad);
1173      }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines