What is the deal with the higher half kernel?
I have read the wiki and found the main advantages:
1. It's easier to set up VM86 processes since the region below 1MB is userspace.
I don't have any intention of running 16bit processes in my OS so this advantage should be useless, right?
2. More generically, user applications are not dependent on how many memory is kernel space (Your application can be linked to 0x400000 regardless of whether kernel is at 0xC0000000, 0x80000000 or 0xE0000000 ...), which makes ABI's nicer.
And yes, if my kernel is C0000000 to FFFFFFFF then an application can be linked in 0x40000000 for example but it can't be linked to 0xC0000000 as far as I understand.Linux, for instance (and many other Unices) reside at the virtual addresses 0xC0000000 - 0xFFFFFFFF of every address space, leaving the range 0x00000000 - 0xBFFFFFFF for user code, data, stacks, libraries, etc.
I don't know what an ABI is and google searches didn't really return anything useful.
But i presume that your normal kernel doesn't change it's memory footprint after the booting sequence. So it will only occupy a set amount of space.
And as long as that is abstracted, I don't see any reason why applications will be dependend of my kernel size. My memory manager should be responsible for loading applications and their data.
3.If your OS is 64-bits, then 32-bit applications will be able to use the full 32-bit address space.
I don't quite understand this. I presume that in 64 bit systems , the first 32bits of memory space are mapped by 32 bit variables, and the higher half (after the higher half kernel) is mapped by using 64bits vars.
If this is the case, then I don't understand why in a 64bit system, you couldn't do exactly the same thing with a lower half kernel.
If it is not the case, then I don't understand it.
4.'mnemonic' invalid pointers such as 0xCAFEBABE, 0xDEADBEEF, 0xDEADC0DE, etc. can be used.
And this completely eludes me.
Thanks in advance for your as always useful answers