PaulF wrote:
The only real way to tell the end of memory from a memory fault is to check the address the test fails at. If it fails at an expected location (e.g. $2000 for an 8k RAM, $8000 for a 32k RAM) then this is likely to be the end of memory. If it fails at some random address, this is probably a fault. Of course, once you have a failure, you know how much memory is available to use - just don't use the address the test fails at or anything above it!
This is something that I am mulling as I close in on bringing POC V2 to fruition. It will have 512KB in a single SRAM, so some means of verifying that all 512KB are there will be required. Yet I don't want to hard-code that specific size into the BIOS, since something may prompt me to add more RAM. Also to be considered, the glue logic will (eventually) allow writes to ROM to bleed through to RAM, as well as allow I/O hardware to be mapped out and replaced with RAM (for what reason I don't know, but I will try it). How would a checkerboard test be done on those RAM ranges?