k_data 3.97 KB
Newer Older
Neil Turton's avatar
Neil Turton committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26
; Copyright 1996 Acorn Computers Ltd
;
; Licensed under the Apache License, Version 2.0 (the "License");
; you may not use this file except in compliance with the License.
; You may obtain a copy of the License at
;
;     http://www.apache.org/licenses/LICENSE-2.0
;
; Unless required by applicable law or agreed to in writing, software
; distributed under the License is distributed on an "AS IS" BASIS,
; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
; See the License for the specific language governing permissions and
; limitations under the License.
;
; -*- Mode: Assembler -*-
;* Shared library kernel for Arthur/Brazil: static data layout
;* Lastedit: 09 Apr 90 10:25:45 by Harry Meekings *
;
; Copyright (C) Acorn Computers Ltd., 1988.
;

StaticData
imageBase               Variable
rtsDataBase             Variable
rtsDataLimit            Variable

27 28 29 30 31 32 33 34
IIHandlerInData         Variable        4
PAHandlerInData         Variable        4
DAHandlerInData         Variable        4
AEHandlerInData         Variable        4

undStack                Variable
svcStack                Variable
unused4                 Variable        9
Neil Turton's avatar
Neil Turton committed
35

36
registerDump            Variable        17      ; PSR in 17th entry
Neil Turton's avatar
Neil Turton committed
37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67

; Handler values on entry, to be restored on exit
oldAbortHandlers        Variable        4

oldExitHandler          Variable        2       ; handler, r12
oldMemoryLimit          Variable

oldErrorHandler         Variable                ; handler, r0, buffer
oldErrorR0              Variable
oldErrorBuffer          Variable

oldCallBackHandler      Variable        3       ; handler, r12, buffer
oldEscapeHandler        Variable        2       ; handler, r12
oldEventHandler         Variable        2       ; handler, r12

oldUpCallHandler        Variable        2       ; handler, r12

; Stuff used for _kernel_system
languageEnvSave         Variable        3       ; (fp, sp, sl over _system)

hadEscape               VariableByte
;******************* beware : position of this byte is fixed ***************
;                             (used in stubs)
kallocExtendsWS         VariableByte
inTrapHandler           VariableByte
beingDebugged           VariableByte
fpPresent               VariableByte    ; zero if not
initialised             InitByte 1
callbackInactive        VariableByte
unused_byte_2           VariableByte

68 69 70 71 72 73
errorBuffer             Variable
errorNumber             Variable
errorString             Variable        63

; Fatal error needs an error buffer - just splat from here on
FatalErrorBuffer        Variable        0
Neil Turton's avatar
Neil Turton committed
74 75 76 77

eventCode               Variable
eventUserR13            Variable
eventRegisters          Variable        12      ; r0-r10 and r13
78

79
unused2                 Variable        11
Neil Turton's avatar
Neil Turton committed
80 81 82 83 84 85 86 87 88 89 90

heapTop                 Variable
heapLimit               Variable

allocProc               Variable
freeProc                Variable

returnCode              Variable

moduleDataWord          Variable

91 92 93
;********** beware : position of this byte relative to end is fixed ********
;                         (used in s.initmodule)
ClientFlags             VariableByte    ; formerly APCS_A_Client
Neil Turton's avatar
Neil Turton committed
94 95 96 97 98 99 100 101 102 103 104 105 106
escapeSeen              VariableByte
unwinding               VariableByte
underDesktop            VariableByte

heapBase                Variable

ArgString               Variable
heapExtender            Variable
knownSlotSize           Variable
initSlotSize            Variable

lk_RestoreOSHandlers    Variable
extendChunk             Variable
107 108
extendChunkNotInUse     Variable
_swp_available          ExportedVariable
Neil Turton's avatar
Neil Turton committed
109 110 111 112 113 114 115 116 117 118 119 120 121
rootStackChunk          Variable

; Tmp space for expanding PC value in fatal error handler
; 3 words overlaid with returnCodeLimit
pc_hex_buff             Variable        0
; Tmp space for reading RC Limit in _kernel_exit - Reuse.
returnCodeLimit         Variable        3

; Tmp space for expanding reg. dump address in fatal error handler - Reuse
reg_hex_buff            Variable        3

disable_stack_extension ExportedVariable 1

122
unused                  Variable        14
Neil Turton's avatar
Neil Turton committed
123 124

        END