Memory management

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
ASHLEY4

Re:Memory management

Post by ASHLEY4 »

Tim Robinson wrote:
You don't think they look up the page directory and page table for every memory access, do you?
Yes i did,I see the point now.
Thanks

ASHLEY4.
mr. xsism

Re:Memory management

Post by mr. xsism »

i use paging for memory protection more than anything. I dont like the idea of swap files very much. I think it should be an option that the user has to turn on. It can slow down the system a lot.

virtual addressing is the 2nd reason i use paging. So i can create how apps see memory. i can fool them into thinking they are alone and located at 0x500 when they are really at 0xD31000.
Tim

Re:Memory management

Post by Tim »

What would you prefer users to see: a slow system or an "Out of memory message"? You don't have to page to disk while there's still physical memory free.
ASHLEY4

Re:Memory management

Post by ASHLEY4 »

I f i was making a 1GB desktop OS ,There is noway i would not use's paging.
But as im making a OS for, games,mp3,demos,etc.
That is is pmode,single tasking,has no memory protection,
then nopaging is best.
eg: If paging is just as fast as nopaging Y does MS have none in its xbox ::).
( This is from a letter to xbox game makers)
Services from Windows 2000 not available in the Xbox system software include:
* Services?
* Plug and play?
* Additional hardware enumeration?
* Hot docking?
* All unsupported drivers?
* Power management?
* Virtual memory (paging)?
* Multiple-process support?
* Multiple-processor support?
* Windows NT File System (NTFS)?


ASHLEY4.
kiv

Re:Memory management

Post by kiv »

what is memory protection ?
Tim

Re:Memory management

Post by Tim »

ASHLEY4: You're confusing virtual memory/paging in the marketing sense, with virtual memory/paging in the technical sense.

In the OS development world, virtual memory means the ability to define one or multiple address spaces inside the CPU, each of which has its own virtual to physical address mapping. You could add the ability to page data to and from a disk under such as scheme, but you don't have to.

For example, Linux and Windows are hard-coded to use paging in the CPU, but an actual pagefile/swapfile is optional.
Solar (on the run)

Re:Memory management

Post by Solar (on the run) »

kiv wrote: what is memory protection ?
Giving each process it's own virtual-to-physical mapping (address space), isolating them from each other so that process A does not have a chance to damage / corrupt process B.
Post Reply