blob: cecfea3dee1c7c276eab925979062dba4fa4725a (
plain)
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
27
28
29
30
31
32
33
34
35
36
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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
|
Systems Programming framework memory layout
Version: @(#)Memory.txt 2.2a
Date: 3/23/25
---------------------------------------------------------------------------
This diagram shows important areas in the first 1MB of memory as seen
by the standalone framework code.
Each row in the diagram represents 0x100 (256) bytes of memory, except in
"elided" areas (< ... >). The starting address is indicated for each
region in hex; if a CPP #define exists for that region in either
bootstrap.h or x86/bios.h, its name is also given.
-----------------------
| Interrupt Vector | 0x00000
| 256 x 4 bytes |
| (1024, 0x400) |
| |
-----------------------
| BIOS Data Area (BDA)| 0x00400 BIOS_BDA
-----------------------
| GDT | 0x00500 GDT_ADDR
| 1024 x 8 bytes |
| (8192, 0x2000) |
| |
< . . . >
| |
-----------------------
| IDT | 0x02500 IDT_ADDR
| 256 x 8 bytes |
| (2048, 0x800) |
| |
| |
| |
| |
| |
-----------------------
| Mmap data | 0x02D00 MMAP_ADDR
| |
| |
| |
| |
< . . . >
| |
-----------------------
| Bootstrap sector 1 | 0x07c00 BOOT_ADDR
| |
-----------------------
| Bootstrap sector 2 | 0x07e00 PART2_ADDR
| |
-----------------------
| | 0x08000
| |
< . . . >
| ^ |
| Bootstrap stack | |
-----------------------
| | 0x0bc00 BOOT_SP_ADDR
| |
| |
< . . . >
| OS stack |
-----------------------
| Operating System | 0x10000 TARGET_ADDR, TARGET_STACK
| (size varies) |
| |
< . . . >
| |
-----------------------
| User Code Blob | 0x30000
| (size varies) |
| |
< . . . >
| |
-----------------------
| Extended BIOS Data | 0x9fc00
| Area (EBDA) |
| |
< . . . >
| |
-----------------------
| Video memory | 0xb8000 VID_BASE_ADDR
| |
< . . . >
| |
-----------------------
| The BIOS | 0xf0000
| |
< . . . >
| |
----------------------- 0xfffff
|