English
Language : 

MC68030 Datasheet, PDF (352/602 Pages) Motorola, Inc – ENHANCED 32-BIT MICROPROCESSOR
Memory Management Unit
In a typical computer system, with 64K bytes of boot and diagnostics ROM, a 64K I/O area,
and 1 Mbyte of RAM, the physical mapping appears as follows:
(UNABLE TO LOCATE ART)
The operating system must control memory allocation for physical memory (page frames)
to hold the pages of virtual memory. All available physical memory is divided into page
frames, each of which can hold a page of virtual memory. A system with 4 Mbytes of actual
memory is divided into 512 8K-byte frames that can theoretically hold 512 pages of active
virtual memory at any one time. Usually, operating system components (exception handlers,
the kernel, private memory pool) permanently reside in some of the memory. Only the
remaining page frames are available for virtual memory pages.
The operating system maintains a linked list of all unallocated page frames. One simple way
to do this is for each unallocated frame to contain a pointer to the next frame. The operating
system takes the first page frame on the list when a frame is required. An operating system
primitive called GetFrame performs this function and returns the physical address of an
available frame. When all frames are allocated, GetFrame steals a frame from another task.
GetFrame first looks for an unmodified frame to steal. An unmodified frame could be stolen
without waiting for the page to be copied back to the external storage device that stores
virtual page images. (This device is called the paging device or the backing store.) If no
unmodified page frame is available, GetFrame must wait while the system copies a modified
page to the paging device, then steals the page frame and returns to the caller with the
physical address.
Next, the operating system needs physical memory management routines to allocate and
free supervisor work memory. The routine must allocate pieces of memory on boundaries
of at least modulo 16, the requirement for address translation tables. Typically, this type of
routine allocates pieces of certain sizes. GetReal is the allocation routine; ReturnReal is the
return routine. They use physical addresses.
With physical memory allocation provided for, the operating system must be able to manage
virtual memory for all tasks. To do this, the system must be aware of the virtual memory map.
It must know the total amount of virtual memory space, how much is allocated, and which
areas are available to be assigned to tasks. The virtual memory map looks like this:
(UNABLE TO LOCATE ART)
Virtual addresses for this virtual memory are subdivided:
(UNABLE TO LOCATE ART)
9-64
MC68030 USER’S MANUAL
MOTOROLA