hackclub / putting-the-you-in-cpu

A technical explainer by @kognise of how your computer runs programs, from start to finish.
https://cpu.land
MIT License
4.71k stars 145 forks source link

Kernel space size in virtual memory size #59

Open krzyzanowskim opened 5 months ago

krzyzanowskim commented 5 months ago

Linux's solution is to always allocate the top half of the virtual memory space to the kernel

https://github.com/hackclub/putting-the-you-in-cpu/blame/7550bc67f911795f356c36502bdaa645a0f1400a/src/content/chapters/5-the-translator-in-your-computer.mdx#L63

the wording suggest linux allocate half of the address space for kernel, but to my understanding it allocate in the higher half, not necessary the whole half. more like ¼

image https://elinux.org/images/b/b0/Introduction_to_Memory_Management_in_Linux.pdf