in trying to understand the memory hole and why memory is mapped from 4gb downward instead of just starting at zero (thread about 4gb in videocard forum if you care), it was explained that this is artifact of history dating back to ibm 16bit cpu's.
the point was made that moving the i/o hole when transitioning to 32bit in past or 64bit now would break software compatibility and so things like dos wouldn't run on a modern pc if that were to happen.
but that lead to a follow up question which is essentially this:
why does moving the i/o mapping break software?
i don't understand this because that makes it seem like absolute addresses/references are used. i would have thought that any hardware i/o gets assigned an address as needed, then whenever that hardware is called for the program/driver/os asks the directory (i guess that would be mmu in this case) for the address of the hardware.
sort of like in windows when you open applications, windows assigns ram to apps as you open them. it's not like photoshop has dedicated address from 500mb-600mb, firefox has 600mb-650mb, etc. right? it's dynamically assigned as needed. so if software is mapped this way, why isn't hardware (at boot hardware is queried and mmu assigns addresses as needed into directory, then rest of addresses is given to OS to use).
i imagine something like this:
on first boot it checks if pci1 is occupied, videocard is there so it asks how much is memory is needed, then assign 0mb-256mb. moves on to pci2 which has soundcard, assigns 256mb-284mb, skips pci slots that are empty, etc, etc. then complete directory/table is stored in mobo rom and used by OS. on subsequent boots, if no hardware has changed, the same directory is used to speed up boot process
the point was made that moving the i/o hole when transitioning to 32bit in past or 64bit now would break software compatibility and so things like dos wouldn't run on a modern pc if that were to happen.
but that lead to a follow up question which is essentially this:
why does moving the i/o mapping break software?
i don't understand this because that makes it seem like absolute addresses/references are used. i would have thought that any hardware i/o gets assigned an address as needed, then whenever that hardware is called for the program/driver/os asks the directory (i guess that would be mmu in this case) for the address of the hardware.
sort of like in windows when you open applications, windows assigns ram to apps as you open them. it's not like photoshop has dedicated address from 500mb-600mb, firefox has 600mb-650mb, etc. right? it's dynamically assigned as needed. so if software is mapped this way, why isn't hardware (at boot hardware is queried and mmu assigns addresses as needed into directory, then rest of addresses is given to OS to use).
i imagine something like this:
on first boot it checks if pci1 is occupied, videocard is there so it asks how much is memory is needed, then assign 0mb-256mb. moves on to pci2 which has soundcard, assigns 256mb-284mb, skips pci slots that are empty, etc, etc. then complete directory/table is stored in mobo rom and used by OS. on subsequent boots, if no hardware has changed, the same directory is used to speed up boot process
