|
|
| version 1.11, 2003/12/08 17:57:29 | version 1.12, 2003/12/09 15:49:14 |
|---|---|
| Line 8 | Line 8 |
| #include "font.h" | #include "font.h" |
| #define USE_HIMEM | #define USE_HIMEM 0x10fff0 |
| #if defined(TRACE) | #if defined(TRACE) |
| #define MEMORY_DEBUG | #define MEMORY_DEBUG |
| #endif | #endif |
| Line 747 static REG8 MEMCALL _i286_memoryread(UIN | Line 748 static REG8 MEMCALL _i286_memoryread(UIN |
| return(mem[address]); | return(mem[address]); |
| } | } |
| #if defined(USE_HIMEM) | #if defined(USE_HIMEM) |
| else if (address >= 0x10fff0) { | else if (address >= USE_HIMEM) { |
| address -= 0x100000; | address -= 0x100000; |
| if (address < CPU_EXTMEMSIZE) { | if (address < CPU_EXTMEMSIZE) { |
| return(CPU_EXTMEM[address]); | return(CPU_EXTMEM[address]); |
| Line 770 static REG16 MEMCALL _i286_memoryread_w( | Line 771 static REG16 MEMCALL _i286_memoryread_w( |
| return(LOADINTELWORD(mem + address)); | return(LOADINTELWORD(mem + address)); |
| } | } |
| #if defined(USE_HIMEM) | #if defined(USE_HIMEM) |
| else if (address >= (0x10fff0 - 1)) { | else if (address >= (USE_HIMEM - 1)) { |
| address -= 0x100000; | address -= 0x100000; |
| if (address == (0x00fff0 - 1)) { | if (address == (USE_HIMEM - 0x100000 - 1)) { |
| ret = mem[0x100000 + address]; | ret = mem[0x100000 + address]; |
| } | } |
| else if (address < CPU_EXTMEMSIZE) { | else if (address < CPU_EXTMEMSIZE) { |
| Line 830 REG8 MEMCALL i286_memoryread(UINT32 addr | Line 831 REG8 MEMCALL i286_memoryread(UINT32 addr |
| return(mem[address]); | return(mem[address]); |
| } | } |
| #if defined(USE_HIMEM) | #if defined(USE_HIMEM) |
| else if (address >= 0x10fff0) { | else if (address >= USE_HIMEM) { |
| address -= 0x100000; | address -= 0x100000; |
| if (address < CPU_EXTMEMSIZE) { | if (address < CPU_EXTMEMSIZE) { |
| return(CPU_EXTMEM[address]); | return(CPU_EXTMEM[address]); |
| Line 853 REG16 MEMCALL i286_memoryread_w(UINT32 a | Line 854 REG16 MEMCALL i286_memoryread_w(UINT32 a |
| return(LOADINTELWORD(mem + address)); | return(LOADINTELWORD(mem + address)); |
| } | } |
| #if defined(USE_HIMEM) | #if defined(USE_HIMEM) |
| else if (address >= (0x10fff0 - 1)) { | else if (address >= (USE_HIMEM - 1)) { |
| address -= 0x100000; | address -= 0x100000; |
| if (address == (0x00fff0 - 1)) { | if (address == (USE_HIMEM - 0x100000 - 1)) { |
| ret = mem[0x100000 + address]; | ret = mem[0x100000 + address]; |
| } | } |
| else if (address < CPU_EXTMEMSIZE) { | else if (address < CPU_EXTMEMSIZE) { |
| Line 892 void MEMCALL i286_memorywrite(UINT32 add | Line 893 void MEMCALL i286_memorywrite(UINT32 add |
| mem[address] = (BYTE)value; | mem[address] = (BYTE)value; |
| } | } |
| #if defined(USE_HIMEM) | #if defined(USE_HIMEM) |
| else if (address >= 0x10fff0) { | else if (address >= USE_HIMEM) { |
| address -= 0x100000; | address -= 0x100000; |
| if (address < CPU_EXTMEMSIZE) { | if (address < CPU_EXTMEMSIZE) { |
| CPU_EXTMEM[address] = (BYTE)value; | CPU_EXTMEM[address] = (BYTE)value; |
| Line 910 void MEMCALL i286_memorywrite_w(UINT32 a | Line 911 void MEMCALL i286_memorywrite_w(UINT32 a |
| STOREINTELWORD(mem + address, value); | STOREINTELWORD(mem + address, value); |
| } | } |
| #if defined(USE_HIMEM) | #if defined(USE_HIMEM) |
| else if (address >= (0x10fff0 - 1)) { | else if (address >= (USE_HIMEM - 1)) { |
| address -= 0x100000; | address -= 0x100000; |
| if (address == (0x00fff0 - 1)) { | if (address == (USE_HIMEM - 0x100000 - 1)) { |
| mem[address] = (BYTE)value; | mem[address] = (BYTE)value; |
| } | } |
| else if (address < CPU_EXTMEMSIZE) { | else if (address < CPU_EXTMEMSIZE) { |