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

Comparing BasiliskII/src/uae_cpu/memory.h (file contents):
Revision 1.3 by gbeauche, 2001-06-26T22:35:42Z vs.
Revision 1.5 by cebix, 2001-07-14T15:02:49Z

# Line 114 | Line 114 | extern void byteput(uaecptr addr, uae_u3
114  
115   #if REAL_ADDRESSING
116   const uintptr MEMBaseDiff = 0;
117 < #define do_get_real_address(a)          ((uae_u8 *)(a))
118 < #define do_get_virtual_address(a)       ((uae_u32)(a))
119 < #endif /* REAL_ADDRESSING */
120 <
117 > #endif
118   #if DIRECT_ADDRESSING
119   extern uintptr MEMBaseDiff;
120 < #define do_get_real_address(a)          ((uae_u8 *)(a) + MEMBaseDiff)
124 < #define do_get_virtual_address(a)       ((uae_u32)(a) - MEMBaseDiff)
125 < #endif /* DIRECT_ADDRESSING */
120 > #endif
121  
122   #if REAL_ADDRESSING || DIRECT_ADDRESSING
123 + static __inline__ uae_u8 *do_get_real_address(uaecptr addr)
124 + {
125 +        return (uae_u8 *)MEMBaseDiff + addr;
126 + }
127 + static __inline__ uae_u32 do_get_virtual_address(uae_u8 *addr)
128 + {
129 +        return (uintptr)addr - MEMBaseDiff;
130 + }
131   static __inline__ uae_u32 get_long(uaecptr addr)
132   {
133      uae_u32 * const m = (uae_u32 *)do_get_real_address(addr);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines