False advertising?
False advertising?
Hey folks,
Been out on a long, long walk...
And, I came across an odd thought...
That odd thought simply being whether or not 32bit machines can actually use all 4GiB of RAM (should the full 4GiB be installed).
How can the machines access it all? When some hardware is directly patched into the address space, way up in high memory? (high high higgggh memory).
If they are directly patched into the address space, at the physical level - how can we distinguish between pages of memory (that we can yknow, bjork) and pages of the hardware space?
The simple answer is of course, "We cant.".
The other obvious answer is "You can tell the hardware to not map itself there" (Kinda like the VGA Controller - you can kill its mapping in conventional memory or am I mistaken?)
Does anyone have any insights into this?
I find it interesting and, Id love to know the answer.
~Z
Been out on a long, long walk...
And, I came across an odd thought...
That odd thought simply being whether or not 32bit machines can actually use all 4GiB of RAM (should the full 4GiB be installed).
How can the machines access it all? When some hardware is directly patched into the address space, way up in high memory? (high high higgggh memory).
If they are directly patched into the address space, at the physical level - how can we distinguish between pages of memory (that we can yknow, bjork) and pages of the hardware space?
The simple answer is of course, "We cant.".
The other obvious answer is "You can tell the hardware to not map itself there" (Kinda like the VGA Controller - you can kill its mapping in conventional memory or am I mistaken?)
Does anyone have any insights into this?
I find it interesting and, Id love to know the answer.
~Z
Re: False advertising?
That's not the simple answer, that's the dumb answer. There are various ways to check for memory regions being used for memory mapped I/O or not, and the devices themselves (via e.g. PCI enumeration) also give information about the memory they use.zeii wrote:If they are directly patched into the address space, at the physical level - how can we distinguish between pages of memory (that we can yknow, bjork) and pages of the hardware space?
The simple answer is of course, "We cant.".
JAL
But a device allocates a certain physical address range, right? And as soon as that address is put on the memory bus, the device 'takes over' so to speak. So yes, one can map a device above the 4GB memory limit, but it'd still occupy the same (physical) location as some RAM. Wouldn't it be necessary to reprogram the MMU to actually move the RAM to a different physical location?JamesM wrote:PAE/PSE means that a 32 bit system *can* access all 4GiB of RAM. It's just that Windows XP doesn't.
JAL
Yes, all PC motherboards have various RAM address limitations. The CPUs themselves are perfectly capable of accessing 4GB or more, as advertised. If you dig into the tech specs of particular specific machines, they may tell you in the fine print what the true max addressible RAM is for the particular motherboard. And, of course, every time you add a board into your machine, it may use up some RAM address space, but that's your fault for adding in the board.
Oh yeah, d'oh! Mental note: Have coffee *before* posting!jal wrote:But a device allocates a certain physical address range, right? And as soon as that address is put on the memory bus, the device 'takes over' so to speak. So yes, one can map a device above the 4GB memory limit, but it'd still occupy the same (physical) location as some RAM. Wouldn't it be necessary to reprogram the MMU to actually move the RAM to a different physical location?JamesM wrote:PAE/PSE means that a 32 bit system *can* access all 4GiB of RAM. It's just that Windows XP doesn't.
JAL
- zaleschiemilgabriel
- Member
- Posts: 232
- Joined: Mon Feb 04, 2008 3:58 am
I think we all understood what this question was about.
It's about using physical memory at addresses that the CPU maps to other devices.
Simple example: the 0xB8000 address is mapped to video memory for text modes. But there's also physical memory at that address that you can't use unless you remap the video memory to somewhere else, but then the new address you mapped to becomes unusable. That's what he meant by "false advertising": you'll never be able to use all of the physical memory installed on a computer...
EDIT: Can PAE/PSE be used to map all of the installed physical (say 4 GiB) memory PLUS the device memory? In my example this would mean that you could remap the video memory to an address that's not used by physical memory. Is that possible? If so, then the "false advertising" still applies to CPUs that don't support PAE/PSE.
It's about using physical memory at addresses that the CPU maps to other devices.
Simple example: the 0xB8000 address is mapped to video memory for text modes. But there's also physical memory at that address that you can't use unless you remap the video memory to somewhere else, but then the new address you mapped to becomes unusable. That's what he meant by "false advertising": you'll never be able to use all of the physical memory installed on a computer...
EDIT: Can PAE/PSE be used to map all of the installed physical (say 4 GiB) memory PLUS the device memory? In my example this would mean that you could remap the video memory to an address that's not used by physical memory. Is that possible? If so, then the "false advertising" still applies to CPUs that don't support PAE/PSE.
DeviOuS - what a stupid name
At last, people finally click to the question.
Sorry if I worded it in a way that was not clear.
As far as I know, You can disable VGA's 'slice' into memory (what is it? $A0000 - $C7FFF?), effectively making that hole usable. Problem is, If you *did* disable the video mapping (ie: you dont care for video at all...), would physical memory actually take over?
Itd be freaking awesome if we could simply *change* all the regions that the memory mapped hardware used, however, I dont think thats really possible since stuff being directly patched into the physical address space is... really a hardwired thing, No?
~Z
Sorry if I worded it in a way that was not clear.
As far as I know, You can disable VGA's 'slice' into memory (what is it? $A0000 - $C7FFF?), effectively making that hole usable. Problem is, If you *did* disable the video mapping (ie: you dont care for video at all...), would physical memory actually take over?
Itd be freaking awesome if we could simply *change* all the regions that the memory mapped hardware used, however, I dont think thats really possible since stuff being directly patched into the physical address space is... really a hardwired thing, No?
~Z
- Brynet-Inc
- Member
- Posts: 2426
- Joined: Tue Oct 17, 2006 9:29 pm
- Libera.chat IRC: brynet
- Location: Canada
- Contact:
When a device is mapped into physical address space, it doesn't render a portion of RAM unusable (Unless you have ~4GB and aren't using PAE/PSE36).
It makes sense that chipsets are intelligent enough to map installed RAM into available areas.
BIOS int 0x15, AX = 0xe820 should help locate those areas.
It makes sense that chipsets are intelligent enough to map installed RAM into available areas.
BIOS int 0x15, AX = 0xe820 should help locate those areas.
Sure, but if a memory mapping device occupies just a few bytes, the RAM at these locations is not going to be remapped by any chipset. I can imagine some mapping for large areas like video memory, but that's it.Brynet-Inc wrote:It makes sense that chipsets are intelligent enough to map installed RAM into available areas.
JAL
- Brynet-Inc
- Member
- Posts: 2426
- Joined: Tue Oct 17, 2006 9:29 pm
- Libera.chat IRC: brynet
- Location: Canada
- Contact:
I think you're confused... I've always assumed chipsets map devices into physical address space "before" RAM.jal wrote:Sure, but if a memory mapping device occupies just a few bytes, the RAM at these locations is not going to be remapped by any chipset. I can imagine some mapping for large areas like video memory, but that's it.Brynet-Inc wrote:It makes sense that chipsets are intelligent enough to map installed RAM into available areas.
JAL
So.. What RAM is lost?