ram
-
Kemp
Re:ram
If you're asking about physical (real) addresses then no, you can't access more memory than you have. If you're talking about what is often referred to as linear memory which is the result of some combination of remapping and/or page swapping then yes, the programs that are using that memory can be told whatever you want as long as you make sure it maps to somewhere within valid physical memory (or you swap the page back into a valid place).
- Pype.Clicker
- Member

- Posts: 5964
- Joined: Wed Oct 18, 2006 2:31 am
- Location: In a galaxy, far, far away
- Contact:
Re:ram
actually, nothing on the processor will never prevent you from accessing a physical address beyond 32MB in that case ... but that will simply act as a black hole: whatever you write, all you'll read back will be 'floating wire' state (e.g. 0xffff is probable, but not even guaranteed)Kemp wrote: If you're asking about physical (real) addresses then no, you can't access more memory than you have.
Now, some devices might have memory mapped above that (e.g. my VBE card here has its LFB somewhere at 0xfa000000 or something), in which case whatever you read/write there will be interpreted by that device and might not react as 'regular' memory.
Re:ram
And depending on your architecture and type of RAM, those 32 MB you have are not necessarily accessable at addresses 0x0000 0000 through 0x0200 0000 either. If you have e.g. two banks with 16 MB each, they might be (physically) mapped at two completely seperate address ranges, with memory-mapped devices strewn in between.
That is why people came up with MMU's and virtual addresses. Physical memory layout is usually a real mess.
That is why people came up with MMU's and virtual addresses. Physical memory layout is usually a real mess.
Every good solution is obvious once you've found it.
Re:ram
And as always in threads like this, let me point out that AmigaOS (up to 3.x at least) does the virtual-to-physical mapping while loading the executable.
Just to show that there is always a different solution to a problem.
Just to show that there is always a different solution to a problem.
Every good solution is obvious once you've found it.
- Pype.Clicker
- Member

- Posts: 5964
- Joined: Wed Oct 18, 2006 2:31 am
- Location: In a galaxy, far, far away
- Contact:
Re:ram
not so sure i got your point, Solar ... What's so great-and-completely-different about it ?Solar wrote: And as always in threads like this, let me point out that AmigaOS (up to 3.x at least) does the virtual-to-physical mapping while loading the executable.
Just to show that there is always a different solution to a problem.![]()
Re:ram
You don't have an MMU employed. Memory references are adjusted in the binary. Actually, binaries are subdivided into "hunks", which are liberally scattered across the available memory however they might fit, so you don't require one large continuous piece of memory for the binary to fit in.
Mind, this is of course horribly inferior to a MMU at work. You get memory fragmentation, you can't do memory protection, and virtual memory (i.e., swapping memory to hard drive) becomes a real headache.
It's just that - a novelty, but one that shows that you can have a system that does not offer you a virtual continuous address space, yet still leaves the developer blissfully ignorant of the details.
Mind, this is of course horribly inferior to a MMU at work. You get memory fragmentation, you can't do memory protection, and virtual memory (i.e., swapping memory to hard drive) becomes a real headache.
It's just that - a novelty, but one that shows that you can have a system that does not offer you a virtual continuous address space, yet still leaves the developer blissfully ignorant of the details.
Every good solution is obvious once you've found it.
Re:ram
You use indexed addressing within an array. Arrays aren't split up between hunks.
(The hunks are defined by the compiler. The Amiga "HUNK" format is a binary format, just as ELF or PE. It doesn't mean binaries are randomly picked apart.)
If you're using indexed addressing in memory areas that haven't been defined as continuous data objects... good luck.
(The hunks are defined by the compiler. The Amiga "HUNK" format is a binary format, just as ELF or PE. It doesn't mean binaries are randomly picked apart.)
If you're using indexed addressing in memory areas that haven't been defined as continuous data objects... good luck.
Every good solution is obvious once you've found it.