type=0;
}
else if(type==MTYPE_1F80) { // scratchpad
- emit_addimm(addr,-0x1f800000,HOST_TEMPREG);
- emit_cmpimm(HOST_TEMPREG,0x1000);
- jaddr=(int)out;
- emit_jc(0);
+ if (psxH == (void *)0x1f800000) {
+ emit_addimm(addr,-0x1f800000,HOST_TEMPREG);
+ emit_cmpimm(HOST_TEMPREG,0x1000);
+ jaddr=(int)out;
+ emit_jc(0);
+ }
+ else {
+ // do usual RAM check, jump will go to the right handler
+ type=0;
+ }
}
#endif
}
psxP = &psxM[0x200000];
- psxH = psxMap(0x1f800000, 0x10000, 1, MAP_TAG_OTHER);
+ psxH = psxMap(0x1f800000, 0x10000, 0, MAP_TAG_OTHER);
psxR = psxMap(0x1fc00000, 0x80000, 0, MAP_TAG_OTHER);
if (psxMemRLUT == NULL || psxMemWLUT == NULL ||
- psxR == NULL || psxP == NULL || psxH != (void *)0x1f800000) {
+ psxR == NULL || psxP == NULL || psxH == NULL) {
SysMessage(_("Error allocating memory!"));
psxMemShutdown();
return -1;