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

Comparing BasiliskII/src/uae_cpu/fpu/impl.h (file contents):
Revision 1.1 by gbeauche, 2002-09-13T12:50:40Z vs.
Revision 1.3 by cebix, 2004-01-12T15:29:31Z

# Line 1 | Line 1
1   /*
2   *  fpu/impl.h - extra functions and inline implementations
3   *
4 < *  Basilisk II (C) 1997-1999 Christian Bauer
4 > *  Basilisk II (C) 1997-2004 Christian Bauer
5   *
6   *  MC68881/68040 fpu emulation
7   *  
# Line 48 | Line 48
48   #ifdef FPU_X86
49  
50   /* Return the floating-point status register in m68k format */
51 < PUBLIC inline uae_u32 FFPU get_fpsr(void)
51 > static inline uae_u32 FFPU get_fpsr(void)
52   {
53          return  to_m68k_fpcond[(x86_status_word & 0x4700) >> 8]
54                  |       FPU fpsr.quotient
# Line 58 | Line 58 | PUBLIC inline uae_u32 FFPU get_fpsr(void
58   }
59  
60   /* Set the floating-point status register from an m68k format */
61 < PUBLIC inline void FFPU set_fpsr(uae_u32 new_fpsr)
61 > static inline void FFPU set_fpsr(uae_u32 new_fpsr)
62   {
63          x86_status_word = to_host_fpcond[(new_fpsr & FPSR_CCB) >> 24 ]
64                  | exception_mac2host[(new_fpsr & FPSR_EXCEPTION_STATUS) >> 8];
# Line 74 | Line 74 | PUBLIC inline void FFPU set_fpsr(uae_u32
74   #ifndef FPU_X86
75  
76   /* Return the floating-point status register in m68k format */
77 < PUBLIC inline uae_u32 FFPU get_fpsr(void)
77 > static inline uae_u32 FFPU get_fpsr(void)
78   {
79          uae_u32 condition_codes         = get_fpccr();
80          uae_u32 exception_status        = get_exception_status();
# Line 84 | Line 84 | PUBLIC inline uae_u32 FFPU get_fpsr(void
84   }
85  
86   /* Set the floating-point status register from an m68k format */
87 < PUBLIC inline void FFPU set_fpsr(uae_u32 new_fpsr)
87 > static inline void FFPU set_fpsr(uae_u32 new_fpsr)
88   {
89          set_fpccr                                       ( new_fpsr & FPSR_CCB                           );
90          set_exception_status            ( new_fpsr & FPSR_EXCEPTION_STATUS      );
# Line 99 | Line 99 | PUBLIC inline void FFPU set_fpsr(uae_u32
99   /* -------------------------------------------------------------------------- */
100  
101   /* Return the floating-point control register in m68k format */
102 < PUBLIC inline uae_u32 FFPU get_fpcr(void)
102 > static inline uae_u32 FFPU get_fpcr(void)
103   {
104          uae_u32 rounding_precision      = get_rounding_precision();
105          uae_u32 rounding_mode           = get_rounding_mode();
# Line 107 | Line 107 | PUBLIC inline uae_u32 FFPU get_fpcr(void
107   }
108  
109   /* Set the floating-point control register from an m68k format */
110 < PUBLIC inline void FFPU set_fpcr(uae_u32 new_fpcr)
110 > static inline void FFPU set_fpcr(uae_u32 new_fpcr)
111   {
112          set_rounding_precision          ( new_fpcr & FPCR_ROUNDING_PRECISION);
113          set_rounding_mode                       ( new_fpcr & FPCR_ROUNDING_MODE         );
# Line 121 | Line 121 | PUBLIC inline void FFPU set_fpcr(uae_u32
121   #ifdef FPU_X86
122  
123   /* Retrieve a floating-point register value and convert it to double precision */
124 < PUBLIC inline double FFPU fpu_get_register(int r)
124 > static inline double FFPU fpu_get_register(int r)
125   {
126          double f;
127          __asm__ __volatile__("fldt %1\n\tfstpl %0" : "=m" (f) : "m" (FPU registers[r]));
# Line 137 | Line 137 | PUBLIC inline double FFPU fpu_get_regist
137   #if defined(FPU_UAE) || defined(FPU_IEEE)
138  
139   /* Retrieve a floating-point register value and convert it to double precision */
140 < PUBLIC inline double FFPU fpu_get_register(int r)
140 > static inline double FFPU fpu_get_register(int r)
141   {
142          return FPU registers[r];
143   }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines