[Select]

Memory


Index

 

Memory Map

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.

   Address    Function                           Size            Type
  000 00000
             Reserved                           8M              Private
  FF8 00000
             Dynamic areas [8]                  1.75G-8M        Public [5]
  900 00000
             Copy of physical space             256M            Private
  800 00000
             Dynamic areas                      2G-136M         Public [5]
  088 00000
             Reserved                           3M              Private
  085 00000
             OS page tables (SoftCAM) [9]       1M-16k          Private
  084 04000
             UNDEF stack [9]                    8k              Private
  084 00000
             Level 2 page tables                4M              Private
  080 00000
             Dynamic areas                      64M             Public [5]
  040 00000
             ROM                                8M              Private
  038 00000
             Reserved for 2nd processor         1M              Private
  037 00000
             Reserved                           1M              Private
  036 00000
             VIDC20                             1M              Private
  035 00000
             Reserved for VIDC1 emulation       1M              Private
  034 00000
             I/O space                          4M              Private [4]
  030 00000
             RMA                                15M             Public [3]
  021 00000
             Kernel buffers                     544k            Private
  020 78000
             Reserved for fake screen           960k            Private
  01F 88000
             Reserved                           448k            Private
  01F 18000
             Reserved                           32k             Private
  01F 10000
             Reserved                           24k             Private
  01F 0A000
             "Nowhere" (2 pages)                8k              Private
  01F 08000
             SWI dispatch / IRQ tables [7]      16k             Private
  01F 04000
             Reserved [7]                       16k             Private
  01F 00000
             Reserved                           1M-16k          Private
  01E 04000
             IRQ stack [7]                      16k             Public [2]
  01E 00000
             System heap [6]                    2M-36k          Private
  01C 09000
             Reserved [6]                       4k              Private
  01C 08000
             SVC stack                          32k             Public [2]
  01C 00000
             Application space                  28M-32k         Public
  000 08000
             Scratch space [10]                 16k             Public [1]
  000 04000
             System workspace [10]              16k             Private
  000 00000
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
    - 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 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.


This documentation is copyright 3QD Developments Ltd 2013 and may not be reproduced or published in any form without the copyright holders permission. RISC OS is subject to continuous development and improvement as such all information is reproduced by 3QD Developments Ltd in good faith and is believed to be correct at the time of publication E&OE. 3QD Developments Ltd cannot accept any liability for any loss or damage arising from the use of any information provided as part of the RISC OS Documentation.

HTML document version 1.03 3rd November 2015