| 1 | A &= 0x1FFF; |
| 2 | |
| 3 | #if defined(__GNUC__cxx . . $ `<built-in>:8:9`!) || defined(__clang__cxx . . $ `<built-in>:3:9`!) || defined(__ICC) || defined(__INTEL_COMPILER) |
| 4 | const void * const IOReadHandlers[0x20] = |
| 5 | { |
| 6 | &&VDC_00, &&VDC_01, &&VDC_02, &&VDC_03, |
| 7 | &&VCE_00, &&VCE_01, &&VCE_02, &&VCE_03, |
| 8 | &&PSG_00, &&PSG_01, &&PSG_02, &&PSG_03, |
| 9 | &&TIMER_00, &&TIMER_01, &&TIMER_02, &&TIMER_03, |
| 10 | &&INPUT_00, &&INPUT_01, &&INPUT_02, &&INPUT_03, |
| 11 | &&IRQ_00, &&IRQ_01, &&IRQ_02, &&IRQ_03, |
| 12 | &&CDROM_00, &&CDROM_01, &&CDROM_02, &&CDROM_03, |
| 13 | &&EXP_00, &&EXP_01, &&EXP_02, &&EXP_03 |
| 14 | }; |
| 15 | |
| 16 | goto *IOReadHandlers[((A & 0x1C00) >> 8) | (A & 0x3)]; |
| 17 | { |
| 18 | #define PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(label, caseval) label |
| 19 | #else |
| 20 | #define PCEF_CASEL(label, caseval) case (caseval) |
| 21 | |
| 22 | switch(((A & 0x1C00) >> 8) | (A & 0x3)) |
| 23 | { |
| 24 | #endif |
| 25 | // |
| 26 | // |
| 27 | // |
| 28 | |
| 29 | |
| 30 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(VDC_00, 0x00): |
| 31 | HuC6280_StealCyclecxx . . $ HuC6280_StealCycle(49f6e7a06ebc5aa8).(); |
| 32 | return(VDC_Readcxx . . $ VDC_Read(caa7d1c0e7e3236b).(0, FALSEcxx . . $ `mednafen/mednafen-types.h:109:9`!)); |
| 33 | |
| 34 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(VDC_01, 0x01): |
| 35 | HuC6280_StealCyclecxx . . $ HuC6280_StealCycle(49f6e7a06ebc5aa8).(); |
| 36 | return(VDC_Readcxx . . $ VDC_Read(caa7d1c0e7e3236b).(1, FALSEcxx . . $ `mednafen/mednafen-types.h:109:9`!)); |
| 37 | |
| 38 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(VDC_02, 0x02): |
| 39 | HuC6280_StealCyclecxx . . $ HuC6280_StealCycle(49f6e7a06ebc5aa8).(); |
| 40 | return(VDC_Readcxx . . $ VDC_Read(caa7d1c0e7e3236b).(2, FALSEcxx . . $ `mednafen/mednafen-types.h:109:9`!)); |
| 41 | |
| 42 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(VDC_03, 0x03): |
| 43 | HuC6280_StealCyclecxx . . $ HuC6280_StealCycle(49f6e7a06ebc5aa8).(); |
| 44 | return(VDC_Readcxx . . $ VDC_Read(caa7d1c0e7e3236b).(3, FALSEcxx . . $ `mednafen/mednafen-types.h:109:9`!)); |
| 45 | |
| 46 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(VCE_00, 0x04): |
| 47 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(VCE_01, 0x05): |
| 48 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(VCE_02, 0x06): |
| 49 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(VCE_03, 0x07): |
| 50 | HuC6280_StealCyclecxx . . $ HuC6280_StealCycle(49f6e7a06ebc5aa8).(); |
| 51 | return(VCE_Readcxx . . $ VCE_Read(32407b39b2dfce37).(A)); |
| 52 | |
| 53 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(PSG_00, 0x08): |
| 54 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(PSG_01, 0x09): |
| 55 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(PSG_02, 0x0A): |
| 56 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(PSG_03, 0x0B): |
| 57 | if(HuCPUcxx . . $ HuCPU..in_block_movecxx . . $ __HuC6280#in_block_move.) |
| 58 | return(0); |
| 59 | return(PCEIODataBuffercxx . . $ PCEIODataBuffer.); |
| 60 | |
| 61 | |
| 62 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(TIMER_00, 0x0C): |
| 63 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(TIMER_01, 0x0D): |
| 64 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(TIMER_02, 0x0E): |
| 65 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(TIMER_03, 0x0F): |
| 66 | if(HuCPUcxx . . $ HuCPU..in_block_movecxx . . $ __HuC6280#in_block_move.) |
| 67 | return(0); |
| 68 | { |
| 69 | uint8cxx . . $ uint8# ret = HuC6280_TimerReadcxx . . $ HuC6280_TimerRead(32407b39b2dfce37).(A); |
| 70 | PCEIODataBuffercxx . . $ PCEIODataBuffer. = ret; |
| 71 | return(ret); |
| 72 | } |
| 73 | |
| 74 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(INPUT_00, 0x10): |
| 75 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(INPUT_01, 0x11): |
| 76 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(INPUT_02, 0x12): |
| 77 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(INPUT_03, 0x13): |
| 78 | if(HuCPUcxx . . $ HuCPU..in_block_movecxx . . $ __HuC6280#in_block_move.) |
| 79 | return(0); |
| 80 | { |
| 81 | uint8cxx . . $ uint8# ret = INPUT_Readcxx . . $ INPUT_Read(32407b39b2dfce37).(A); |
| 82 | PCEIODataBuffercxx . . $ PCEIODataBuffer. = ret; |
| 83 | return(ret); |
| 84 | } |
| 85 | |
| 86 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(IRQ_00, 0x14): |
| 87 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(IRQ_01, 0x15): |
| 88 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(IRQ_02, 0x16): |
| 89 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(IRQ_03, 0x17): |
| 90 | if(HuCPUcxx . . $ HuCPU..in_block_movecxx . . $ __HuC6280#in_block_move.) |
| 91 | return(0); |
| 92 | { |
| 93 | uint8cxx . . $ uint8# ret = HuC6280_IRQStatusReadcxx . . $ HuC6280_IRQStatusRead(32407b39b2dfce37).(A); |
| 94 | PCEIODataBuffercxx . . $ PCEIODataBuffer. = ret; |
| 95 | return(ret); |
| 96 | } |
| 97 | |
| 98 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(CDROM_00, 0x18): |
| 99 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(CDROM_01, 0x19): |
| 100 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(CDROM_02, 0x1A): |
| 101 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(CDROM_03, 0x1B): |
| 102 | if(!PCE_IsCDcxx . . $ PCE_IsCD.) |
| 103 | return(0xFF); |
| 104 | |
| 105 | if((A & 0x1E00) == 0x1A00) |
| 106 | { |
| 107 | if(arcade_cardcxx . . $ arcade_card.) |
| 108 | return(arcade_cardcxx . . $ arcade_card.->Readcxx . . $ ArcadeCard#Read(caa7d1c0e7e3236b).(A & 0x1FFF)); |
| 109 | else |
| 110 | return(0); |
| 111 | } |
| 112 | else |
| 113 | { |
| 114 | return(PCECD_Readcxx . . $ PCECD_Read(e77b674d7ec06db6).(HuCPUcxx . . $ HuCPU..timestampcxx . . $ __HuC6280#timestamp. * 3, A)); |
| 115 | } |
| 116 | |
| 117 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(EXP_00, 0x1C): |
| 118 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(EXP_01, 0x1D): |
| 119 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(EXP_02, 0x1E): |
| 120 | PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`!(EXP_03, 0x1F): |
| 121 | #ifdef HAVE_HES |
| 122 | if(IsHES) |
| 123 | return(ReadIBP(A)); |
| 124 | #endif |
| 125 | return(0xFF); |
| 126 | |
| 127 | } |
| 128 | #undef PCEF_CASELcxx . . $ `mednafen/pce_fast/ioread.inc:18:10`! |
| 129 | //printf("Meow: %08x, %02x:%04x\n", A, A >> 13, A & 0x1FFF); |