Memory Map

Introduction and Overview

The RISC OS logical memory map has not changed significantly from RISC OS 4. In turn, the memory map in RISC OS 4 had not changed significantly from RISC OS 3.7 version. It is very important to note that there are defined mechanisms for reading most of the regions of memory on RISC OS. Where possible, the supported system calls should be used and applications should not rely on the logical mapping of memory being unchanged on future versions of the operating system.

Technical Details

The logical memory map

The map is listed from the top of the address space; each entry is identified by its start address. The numbers in brackets refer to the notes below the table.

Start addressFunctionSize and type
&FF800000Reserved8M, Private
&90000000Dynamic areas [8]1.75G-8M, Public [5]
&80000000Copy of physical space256M, Private
&08800000Dynamic areas2G-136M, Public [5]
&08500000Reserved3M, Private
&08404000OS page tables (SoftCAM) [9]1M-16k, Private
&08400000UNDEF stack [9]8k, Private
&08000000Level 2 page tables4M, Private
&04000000Dynamic areas64M, Public [5]
&03800000ROM8M, Private
&03700000Reserved for 2nd processor1M, Private
&03600000Reserved1M, Private
&03500000VIDC201M, Private
&03400000Reserved for VIDC1 emulation1M, Private
&03000000I/O space4M, Private [4]
&02100000RMA15M, Public [3]
&02078000Kernel buffers544k, Private
&01F88000Reserved for fake screen960k, Private
&01F18000Reserved448k, Private
&01F10000Reserved32k, Private
&01F0A000Reserved24k, Private
&01F08000"Nowhere" (2 pages)8k, Private
&01F04000SWI dispatch / IRQ tables [7]16k, Private
&01F00000Reserved [7]16k, Private
&01E04000Reserved1M-16k, Private
&01E00000IRQ stack [7]16k, Public [2]
&01C09000System heap [6]2M-36k, Private
&01C08000Reserved [6]4k, Private
&01C00000SVC stack32k, Public [2]
&00008000Application space28M-32k, Public
&00004000Scratch space [10]16k, Public [1]
&00000000System workspace [10]16k, Private

Notes about the logical memory map

  • [1] The public [1] area may be used by any module that is not used in an IRQ routine, and not used if you call something else that might also use it. An example client would be FileCore using the scratch space to hold structures while working out how to allocate some free space. Another example would be the Filer using the scratch space to hold structures for OS_HeapSort.
  • [2] The public [2] areas can be assumed to have their lowest address on a 1MB boundary (being descending stacks). An exception will occur if they are accessed beyond this point. The exact location of these stacks should not be assumed.
  • [3] The public [3] area should not assume the location of the RMA or its maximum size. However it will be in the lower 64MB (ie it can execute 26 bit code).
  • [4] The private [4] area is private, and used for I/O except where device drivers export hardware addresses.
  • [5] The public [5] areas can be used by a client to make its own dynamic area.
  • [6] The system heap previously started at &01C08000, but has been moved up by a page such that stack underflow causes an abort, and reduced in size due to the requirement of the IRQ stack to be aligned on a 1MB boundary and to avoid its old allocation.
  • [7] The IRQ stack previously started at &01F00000. The stack has been increased in size. Because of this, it would have covered a region which was reserved for the SWI dispatch table. This table has changed in its internal organisation. Because of these changes, it was decided to move the IRQ stack and SWI dispatch tables such that components attempting to access the dispatch table do not overwrite the IRQ stack. Thus the SWI dispatch area is now higher in memory, and the IRQ stack is lower in memory, with a hole where the IRQ stack was previously.
  • [8] Under RISC OS 4, 256M of PCI space was reserved at &9000000. This is no longer reserved, and is available for dynamic areas.
  • [9] Under RISC OS 4, the UNDEF stack was 8K. In order to simplify some memory arrangement, it has been increased in size to 16K.
  • [10] Under RISC OS 4, the system workspace (also known as 'zero page') and scratch space were only protected against being written to from USR mode for the first 256 bytes. The entire 32K of this region is now only readable in USR mode.