Attempt to gain a little speed on frequently used functions.

This commit is contained in:
Stephen Anthony 2020-06-12 09:24:15 -02:30
parent 9cf4686bc2
commit 2d78f0ee7c
1 changed files with 2 additions and 2 deletions

View File

@ -299,13 +299,13 @@ bool CartridgeEnhanced::bank(uInt16 bank, uInt16 segment)
}
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
uInt16 CartridgeEnhanced::romAddressSegmentOffset(uInt16 address) const
inline uInt16 CartridgeEnhanced::romAddressSegmentOffset(uInt16 address) const
{
return myCurrentSegOffset[((address & ROM_MASK) >> myBankShift) % myBankSegs];
}
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
uInt16 CartridgeEnhanced::ramAddressSegmentOffset(uInt16 address) const
inline uInt16 CartridgeEnhanced::ramAddressSegmentOffset(uInt16 address) const
{
return uInt16(myCurrentSegOffset[((address & ROM_MASK) >> myBankShift) % myBankSegs] - mySize) >> 1;
}