mirror of
https://github.com/prirun/p50em.git
synced 2026-01-18 00:42:32 +00:00
emulator seg fault after LPSW near label RXM in CPUT4. CPUT4 activates Ring 3 by loading the ring bits of the program counter. However, it does not enable segmentation, so we're still accessing memory by physical location - no address mapping occurs. mapva used the entire 32-bit program counter as an offset in the MEM array (physical memory), and because of the ring bits, this caused a Unix seg fault. mapva was changed to only use 28 bits of the address when VA mapping is disabled (28 bits matches the size of the MEM array). Technically, a more accurate mask should be applied based on the CPU model. For example, a P750 could only access 8MB of memory.
Description
Prime 50-Series Emulator
Languages
C
97.8%
Roff
1.7%
Python
0.3%
Makefile
0.2%