EP0526114A1 - A method and apparatus for performing address translation in a data processor using masked protection indirection page descriptors - Google Patents
A method and apparatus for performing address translation in a data processor using masked protection indirection page descriptors Download PDFInfo
- Publication number
- EP0526114A1 EP0526114A1 EP92306769A EP92306769A EP0526114A1 EP 0526114 A1 EP0526114 A1 EP 0526114A1 EP 92306769 A EP92306769 A EP 92306769A EP 92306769 A EP92306769 A EP 92306769A EP 0526114 A1 EP0526114 A1 EP 0526114A1
- Authority
- EP
- European Patent Office
- Prior art keywords
- descriptor
- address
- translation
- memory
- control
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Withdrawn
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F12/00—Accessing, addressing or allocating within memory systems or architectures
- G06F12/14—Protection against unauthorised use of memory or access to memory
- G06F12/1458—Protection against unauthorised use of memory or access to memory by checking the subject access rights
- G06F12/1466—Key-lock mechanism
- G06F12/1475—Key-lock mechanism in a virtual system, e.g. with translation means
Definitions
- This invention relates generally to data processors, and more particularly to data processors which perform address translation.
- ATC address translation caches
- the address translation caches (e.g. data and instruction) store the results of the most recent traversals of the memory based translation tables, which are stored in a main memory.
- ATC address translation caches
- ATC hardware state machine
- a software routine is invoked to walk the appropriate memory based translation tables to retrieve the logical to physical mapping.
- the translation tables are organized in a multi-level hierarchy (e.g. segment table, page table), in order to minimize the size of the translation tables, and the memory management system accesses the translation tables via address translation descriptors.
- the address translation descriptors are comprised generally of three basic components: 1) an address which is either a pointer to the next lower level in the table hierarchy or, at the very end of the chain, the physical memory address of the page being mapped, 2) a set of access privilege rights (e.g. read/write or read only) to all pages below this level of the table hierarchy, and 3) status bits for maintaining state information for the page (e.g. used, modified).
- the status information for physical pages is maintained in page descriptors, which are stored in the lowest level table (i.e. page table). Since this status information is used for physical page maintenance, it is most efficient to use a single page descriptor to store the status information. In the prior art systems, however, using a single page descriptor to store the status information is only possible when all mappings to a given physical page have identical access rights. Consequently, in the prior art systems, it is not possible to efficiently allow different processes to have different access rights to the same physical page, without using multiple page descriptors to distinguish the differing permissions (read/write versus read-only).
- the data processing system includes a main memory for storing a set of address translation tables and a memory management unit (MMU) for using the set of address translation tables to obtain a logical to physical address translation.
- MMU memory management unit
- the MMU maps a plurality of logical pages to a common page descriptor, while permitting different memory accesses to have different access right to a physical memory page without using multiple page descriptors to distinguish the differing permissions.
- a translation controller When an address translation cache (ATC) in the MMU does not contain a required logical to physical address translation, a translation controller performs a tablewalk to retrieve a memory page descriptor from the set of address translation tables in main memory. During the tablewalk, the translation controller uses an area descriptor to traverse a segment translation table, and a segment descriptor to traverse a page translation table to thereby access the memory page descriptor.
- the memory page descriptor comprises a page descriptor address and a descriptor type information field.
- Control logic circuitry in the translation controller reads the descriptor type information field of the memory page descriptor, and uses the page descriptor address as a pointer to the common memory page descriptor, when the descriptor type field contains a certain logic value.
- the common memory page descriptor includes an intermediate set of control and protection bits.
- control logic circuitry When the descriptor type contains the certain logic value, the control logic circuitry masks the intermediate set of control and write protection bits of the common memory page descriptor. The control logic circuitry determines the final control and write protection bits for the memory page by logically ORing the control and write protection bits for the corresponding area and segment descriptors.
- FIG. 1 is a block diagram of a preferred embodiment of a data processing system for utilizing the present invention.
- FIG. 2 is a block diagram of the memory management unit (MMU) of FIG. 1, in accordance with a preferred embodiment of the present invention.
- MMU memory management unit
- FIG. 3 is an illustration of the format of a set of address translation descriptors for use in the preferred embodiment of the present invention.
- FIG. 4 is a block diagram illustrating a hardware tablewalk sequence, used in the preferred embodiment of the present invention.
- FIG. 5 is a partial schematic diagram of the control logic circuitry of the MMU of FIG. 2, in accordance with a preferred embodiment of the present invention.
- FIG. 1 Shown in FIG. 1 is a block diagram illustrated an integrated circuit data processing system 10 for implementing the present invention.
- data processing system 10 comprises an instruction sequencer 12, load/store units 14, register files 16, and integer execution units 18.
- the instruction sequencer 12 provides control over the data flow amount to the execution units 18, and the register files 16. Accordingly, the instruction sequencer 12 implements a 4-stage (fetch-decode-execute-writeback) master instruction pipeline, enforces data interlocks, dispatches (issues) instructions to available execution units 18, directs data from the register files 16 onto and off of the busses 28 and 30, and maintains a state history so it can back the system 10 up in the event of an exception.
- 4-stage (fetch-decode-execute-writeback) master instruction pipeline enforces data interlocks, dispatches (issues) instructions to available execution units 18, directs data from the register files 16 onto and off of the busses 28 and 30, and maintains a state history so it can back the system 10 up in the event of an exception.
- data processing system 10 uses a Harvard architecture with separate paths for the instruction stream and the data stream. Separate caches 20, and 22 are used to supply the two streams.
- the sequencer 12 is responsible for instruction flow in system 10. Sequencer 12 retrieves instructions from an instruction cache 22, and dispatches the instructions to one of the execution units 18 based on availability and inter-instruction data dependencies. When an instruction "issues", the source data for that instruction is transferred from a source register in the general register file 16 onto the source operand busses 28, and the associated destination register is marked “busy”. A hardware scoreboard maintains a record of all busy registers. The execution unit 18, to which the instruction issues, then reads data off the appropriate source bus 30.
- Data processing system 10 employs separate instruction and data memory management units (MMUs) 24 and 26, respectively .
- each unit provides two 4G Byte (User/Supervisor) logical address spaces and enforces access privileges on segment and page levels for both of these spaces.
- the internal structure of MMUs 24 and 26 is the same.
- FIG. 2 illustrates a block diagram for the data MMU 26; however, each of the MMUs 24 and 26 comprise an address translation cache (ATC) 42 and a translation controller 44. On each memory reference, a logical address is looked up in one of the appropriate ATCs 42 in parallel with the caches 20 and 22 (FIG. 1) being checked for the data/instruction, respectively.
- ATC address translation cache
- Each ATC 42 implements a fully associative look-up.
- the referenced logical address is compared against all entries in the appropriate ATC 42 (instruction or data). If the upper bits of the referenced logical address match a logical address tag in one of the ATCs 42 a "hit" occurs, and the matching entry is used to map the referenced logical address to the physical memory address.
- the physical address is then sent to the data (or instruction) cache, and the data (or instruction) is provided to the load store unit 14, or instruction sequencer 12, respectively, In the case where the physical memory address is not stored in the data (or instruction) cache 20 or 22, the physical address to sent to memory 40. Accordingly, the physical address is transferred via bus 17 to a bus interface unit 32 (FIG. 1) and via the BIU 32 (FIG. 1), which sends the physical address to memory 40, via the system bus 38.
- a hardware state machine (or a software routine) is invoked to walk the appropriate memory based tables to retrieve the logical to physical address mapping.
- a set of memory mapping (translation) tables are stored in memory 40. These translation tables describe the mapping of the logical program addresses (virtual) address to physical memory addresses.
- the ATCs 42 store the results of recent traversals of the memory based tables.
- the translation controller comprises a set of registers 46 and control logic 48 for reading and manipulating information stored in the registers 46.
- the memory based address translation tables 50 and 52 (FIG. 4) are defined and accessed via address translation descriptors, shown in FIG. 3. These descriptors have three basic components: 1) an address which is either a pointer to a next lower level in the table hierarchy or, at the very end of the chain, a pointer to a physical memory address of the page being mapped, 2) a set of access privilege rights to all pages below this level of the table hierarchy, and 3) some status bits for maintaining state information for the page.
- each segment table 50 contains 1024 segment descriptors 56, each of which points to page tables 52 in memory 40.
- Each segment descriptor 56 contains the base address of a page table, and segment-level status and protection (P) information.
- each page table 52 contains 1024 page descriptors.
- Each page descriptor 60 contains the address of a physical page frame into which the logical page address is mapped.
- each page descriptor 60 contains the page-level status and protection (P) information bit, and a descriptor type (DT) field. Table I below illustrates the encoding for the DT field. Accordingly, if the DT field in a page descriptor is equal to 11 or 10, then the descriptor is actually a pointer to the actual page descriptor. In the present invention, such a pointer is referred to as an Indirect Page Descriptor 58, and its format is shown in FIG. 4.
- a page descriptor may be a direct page descriptor 60 which describes the actual mapping and status information for a memory page, or an indirect descriptor 58 which points to an actual (final) page descriptor.
- the appropriate MMU 24 or 26 selects an ATC entry for replacement using a FIFO algorithm, and then performs a two level tablewalk, to retrieve the page descriptor for the referenced logical address 53.
- the tablewalk begins at a Segment Table Base Address which is found in an Area Descriptor 54.
- the Segment Table Base Address is concatenated with the most significant bits ⁇ 31:22 ⁇ of the referenced logical address 53, and the result is zero extended to form a first translation descriptor address, which is temporarily stored in a first register 64.
- the segment table 50 is indexed by the most significant bits ⁇ 31:22 ⁇ of logical address 53 to retrieve the Page Table Base Address from a segment descriptor 56.
- the Page Table Base Address is concatenated with the next 10 lessor significant bits ⁇ 21:12 ⁇ of the referenced logical address 53 to form a second translation descriptor address, which is then stored in a second register 66.
- the page table 52 is indexed by ⁇ LA 21: 12 ⁇ to retrieve a selected page descriptor.
- the control logic 48 reads the DT field of the selected page descriptor 58. As previously indicated, when the DT field in the selected page descriptor is equal to 11 or 10, the selected page descriptor is an Indirect Page Descriptor 58 and is, therefore, actually a pointer to a final page descriptor 60.
- the translation controller 44 uses the selected (indirect) page descriptor 58 to retrieve the final page descriptor 60 from the page translation table 52.
- the MMU 24 uses the accessed indirect (common) page descriptor (not shown) as an address to the actual (final) page descriptor 60.
- the control logic circuitry 48 determines the protection and control information for the accessed memory page by logically ORing all control (status) and protection bits found in the corresponding area, segment and page descriptors.
- the translation controller 44 Upon completing the tablewalk, the translation controller 44 loads the 20 most significant bits of the missed (referenced) logical address 53 into the logical page address TAG (LOGICAL ADDRESS) of the ATC entry selected for replacement, via logical address bus 43. The translation controller 44 also loads the 20-bit Page Frame Address from the final page descriptor 60 into the lower half of the ATC 42 entry (PHYSICAL ADDRESS), via physical address bus 45. Furthermore, the translation controller 44 loads the results obtained from the logical OR of the protection bits found in the area, and segment descriptors into the lower half of the ATC entry.
- FIG. 5 Shown in FIG. 5 is partial schematic diagram of the control logic 48, in accordance with a preferred embodiment of the present invention.
- decoder logic 70 receives a two bit input, representative of the descriptor type, and provides an output signal MASKPROT* indicative of whether or not the page descriptor is a masked protection indirection descriptor.
- decoder 70 indicates that the selected page descriptor is a masked indirection descriptor by providing a logic low MASKPROT* output signal.
- An AND gate 72 is coupled to the output of decoder logic 70, and register 68.
- AND gate 70 has a first input for receiving the MASKPROT* signal, a second input for receiving a page protection bit of the actual (final) page descriptor, and an output.
- the MASKPROT* signal is a logic low
- AND gate 72 provides a logic low signal.
- the logic low MASKPROT* signal is ORed with a segment protection bit from the corresponding segment descriptor 56, and an area protection bit from the corresponding area descriptor 54.
- the output of OR gate 74 determines the final page protection for the memory page selected by the page descriptor 60.
- an OR gate 76 is coupled to each of the bit positions of each of the corresponding area, segment and page descriptors, 54, 56, and 60, respectively.
- Each OR gate 76 has a first input for receiving an area status bit, a second input for receiving a segment status bit, and a third input for receiving a page status bit for each of the corresponding descriptors.
- the collective outputs of the OR gates 76 determines the final page status information for the memory page selected by the page descriptor 60.
- control logic 48 operates to determine when a selected page descriptor is a selected type (i.e. masked indirection descriptor).
- the control logic 48 then logically combines the information provided in the corresponding area, and segment descriptors to determine the final page protection. Similarly, the information provided in the corresponding area, segment, and final page descriptors is logically combined to provide the final page status information.
- the translation controller 44 uses the accessed indirect (common) page descriptor 58 as the address to the actual (final) page descriptor 60; however, the protection and control bits for actual (final) page descriptor 60 are ignored by the control logic circuitry 48.
- the ATCs 42 may include a block address translation cache (BATC), to map large areas of the system and user memory (i.e. 512K to 64Mbytes) without usurping a large number of ATC entries, and a page address translation cache (PATC) for mapping pages of 4K bytes each, for example.
- BATC block address translation cache
- PATC page address translation cache
- the index bits derived from the referenced logical address may vary based upon the number of descriptors stored in the segment and page translation tables. Accordingly, it is intended by the appended claims to cover all modifications of the invention which fall within the true spirit and scope of the invention.
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computer Security & Cryptography (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Memory System Of A Hierarchy Structure (AREA)
Abstract
Description
- This invention relates generally to data processors, and more particularly to data processors which perform address translation.
- Today's high performance data processing systems rely upon sophisticated memory management systems to translate logical program addresses into real (physical) addresses. Many of these memory management systems employ address translation caches (ATC's) to perform high speed address translation, thereby enhancing the performance of the data processing system. Generally, the address translation caches (e.g. data and instruction) store the results of the most recent traversals of the memory based translation tables, which are stored in a main memory. On each memory access, a logical program address is compared to all entries in the appropriate ATC (data or instruction) to locate the requisite logical to physical mapping. When the ATC does not contain the requisite logical to physical mapping, a translation "miss" occurs, and a hardware state machine (or a software routine) is invoked to walk the appropriate memory based translation tables to retrieve the logical to physical mapping.
- Generally, the translation tables are organized in a multi-level hierarchy (e.g. segment table, page table), in order to minimize the size of the translation tables, and the memory management system accesses the translation tables via address translation descriptors. The address translation descriptors are comprised generally of three basic components: 1) an address which is either a pointer to the next lower level in the table hierarchy or, at the very end of the chain, the physical memory address of the page being mapped, 2) a set of access privilege rights (e.g. read/write or read only) to all pages below this level of the table hierarchy, and 3) status bits for maintaining state information for the page (e.g. used, modified). Typically, the status information for physical pages is maintained in page descriptors, which are stored in the lowest level table (i.e. page table). Since this status information is used for physical page maintenance, it is most efficient to use a single page descriptor to store the status information. In the prior art systems, however, using a single page descriptor to store the status information is only possible when all mappings to a given physical page have identical access rights. Consequently, in the prior art systems, it is not possible to efficiently allow different processes to have different access rights to the same physical page, without using multiple page descriptors to distinguish the differing permissions (read/write versus read-only).
- The use of multiple page descriptors to distinguish the differing permissions significantly increases the amount of memory space required for storing the translation tables. Thus, it is desirable to provide a mechanism which accomplishes the foregoing objectives, without using multiple page descriptors to distinguish between the different access rights to the same physical page.
- A method and apparatus for performing address translation using a masked indirection page descriptor in a data processing system is provided. The data processing system includes a main memory for storing a set of address translation tables and a memory management unit (MMU) for using the set of address translation tables to obtain a logical to physical address translation. The MMU maps a plurality of logical pages to a common page descriptor, while permitting different memory accesses to have different access right to a physical memory page without using multiple page descriptors to distinguish the differing permissions.
- When an address translation cache (ATC) in the MMU does not contain a required logical to physical address translation, a translation controller performs a tablewalk to retrieve a memory page descriptor from the set of address translation tables in main memory. During the tablewalk, the translation controller uses an area descriptor to traverse a segment translation table, and a segment descriptor to traverse a page translation table to thereby access the memory page descriptor. The memory page descriptor comprises a page descriptor address and a descriptor type information field. Control logic circuitry in the translation controller reads the descriptor type information field of the memory page descriptor, and uses the page descriptor address as a pointer to the common memory page descriptor, when the descriptor type field contains a certain logic value. The common memory page descriptor includes an intermediate set of control and protection bits.
- When the descriptor type contains the certain logic value, the control logic circuitry masks the intermediate set of control and write protection bits of the common memory page descriptor. The control logic circuitry determines the final control and write protection bits for the memory page by logically ORing the control and write protection bits for the corresponding area and segment descriptors.
- FIG. 1 is a block diagram of a preferred embodiment of a data processing system for utilizing the present invention.
- FIG. 2 is a block diagram of the memory management unit (MMU) of FIG. 1, in accordance with a preferred embodiment of the present invention.
- FIG. 3 is an illustration of the format of a set of address translation descriptors for use in the preferred embodiment of the present invention.
- FIG. 4 is a block diagram illustrating a hardware tablewalk sequence, used in the preferred embodiment of the present invention.
- FIG. 5 is a partial schematic diagram of the control logic circuitry of the MMU of FIG. 2, in accordance with a preferred embodiment of the present invention.
- Shown in FIG. 1 is a block diagram illustrated an integrated circuit
data processing system 10 for implementing the present invention. In a preferred embodiment,data processing system 10 comprises aninstruction sequencer 12, load/store units 14,register files 16, andinteger execution units 18. Theinstruction sequencer 12 provides control over the data flow amount to theexecution units 18, and theregister files 16. Accordingly, theinstruction sequencer 12 implements a 4-stage (fetch-decode-execute-writeback) master instruction pipeline, enforces data interlocks, dispatches (issues) instructions toavailable execution units 18, directs data from theregister files 16 onto and off of thebusses system 10 up in the event of an exception. - In the preferred embodiment,
data processing system 10 uses a Harvard architecture with separate paths for the instruction stream and the data stream.Separate caches 20, and 22 are used to supply the two streams. In accordance with the preferred embodiment, thesequencer 12 is responsible for instruction flow insystem 10. Sequencer 12 retrieves instructions from an instruction cache 22, and dispatches the instructions to one of theexecution units 18 based on availability and inter-instruction data dependencies. When an instruction "issues", the source data for that instruction is transferred from a source register in thegeneral register file 16 onto thesource operand busses 28, and the associated destination register is marked "busy". A hardware scoreboard maintains a record of all busy registers. Theexecution unit 18, to which the instruction issues, then reads data off theappropriate source bus 30. -
Data processing system 10 employs separate instruction and data memory management units (MMUs) 24 and 26, respectively . In the preferred embodiment, each unit provides two 4G Byte (User/Supervisor) logical address spaces and enforces access privileges on segment and page levels for both of these spaces. In accordance with the preferred embodiment, the internal structure ofMMUs data MMU 26; however, each of theMMUs translation controller 44. On each memory reference, a logical address is looked up in one of theappropriate ATCs 42 in parallel with thecaches 20 and 22 (FIG. 1) being checked for the data/instruction, respectively. Each ATC 42 implements a fully associative look-up. The referenced logical address is compared against all entries in the appropriate ATC 42 (instruction or data). If the upper bits of the referenced logical address match a logical address tag in one of the ATCs 42 a "hit" occurs, and the matching entry is used to map the referenced logical address to the physical memory address. The physical address is then sent to the data (or instruction) cache, and the data (or instruction) is provided to theload store unit 14, orinstruction sequencer 12, respectively, In the case where the physical memory address is not stored in the data (or instruction)cache 20 or 22, the physical address to sent tomemory 40. Accordingly, the physical address is transferred viabus 17 to a bus interface unit 32 (FIG. 1) and via the BIU 32 (FIG. 1), which sends the physical address tomemory 40, via thesystem bus 38. - In cases where the requisite logical to physical mapping is not contained in the ATC 42, a hardware state machine (or a software routine) is invoked to walk the appropriate memory based tables to retrieve the logical to physical address mapping. A set of memory mapping (translation) tables, normally maintained by the operating system, are stored in
memory 40. These translation tables describe the mapping of the logical program addresses (virtual) address to physical memory addresses. In the preferred embodiment, the ATCs 42 store the results of recent traversals of the memory based tables. When the upper bits of the referenced logical address 53 (FIG. 4) do not match any entries in the ATC 42 a "miss" occurs, and ATC 42 provides a MISS signal to thetranslation controller 44. In response to receiving the MISS signal, thetranslation controller 44 proceeds to perform a two-level tablewalk to retrieve the requisite mapping. - In a preferred embodiment of the present invention, the translation controller comprises a set of
registers 46 andcontrol logic 48 for reading and manipulating information stored in theregisters 46. In the present invention, the memory based address translation tables 50 and 52 (FIG. 4) are defined and accessed via address translation descriptors, shown in FIG. 3. These descriptors have three basic components: 1) an address which is either a pointer to a next lower level in the table hierarchy or, at the very end of the chain, a pointer to a physical memory address of the page being mapped, 2) a set of access privilege rights to all pages below this level of the table hierarchy, and 3) some status bits for maintaining state information for the page. - As shown in FIG. 3, at the very top of the table hierarchy are
area descriptors 54. In accordance with the preferred embodiment, thearea descriptor 54 is the root of all memory based mapping tables 50 and 52, and are stored inregisters 46. The area descriptors 54 point to segment tables 50 inmemory 40. Eacharea descriptor 54 contains the base address of a segment table and a set of control bits. The area descriptors 54 enable the ATC tablewalk address translation via the translation enable (TE) bit. In the preferred embodiment, each segment table 50 contains 1024segment descriptors 56, each of which points to page tables 52 inmemory 40. Eachsegment descriptor 56 contains the base address of a page table, and segment-level status and protection (P) information. Similarly, each page table 52 contains 1024 page descriptors. Eachpage descriptor 60 contains the address of a physical page frame into which the logical page address is mapped. Furthermore, eachpage descriptor 60 contains the page-level status and protection (P) information bit, and a descriptor type (DT) field. Table I below illustrates the encoding for the DT field.
Accordingly, if the DT field in a page descriptor is equal to 11 or 10, then the descriptor is actually a pointer to the actual page descriptor. In the present invention, such a pointer is referred to as anIndirect Page Descriptor 58, and its format is shown in FIG. 4. Thus, a page descriptor may be adirect page descriptor 60 which describes the actual mapping and status information for a memory page, or anindirect descriptor 58 which points to an actual (final) page descriptor. - Referring again to FIG. 2, when an ATC miss occurs, the
appropriate MMU logical address 53. As shown in FIG. 4, the tablewalk begins at a Segment Table Base Address which is found in anArea Descriptor 54. The Segment Table Base Address is concatenated with the most significant bits {31:22} of the referencedlogical address 53, and the result is zero extended to form a first translation descriptor address, which is temporarily stored in afirst register 64. Using the Segment Table Base Address, the segment table 50 is indexed by the most significant bits {31:22} oflogical address 53 to retrieve the Page Table Base Address from asegment descriptor 56. The Page Table Base Address is concatenated with the next 10 lessor significant bits {21:12} of the referencedlogical address 53 to form a second translation descriptor address, which is then stored in asecond register 66. Using the Page Table Base Address, the page table 52 is indexed by {LA 21: 12} to retrieve a selected page descriptor. - The
control logic 48 reads the DT field of the selectedpage descriptor 58. As previously indicated, when the DT field in the selected page descriptor is equal to 11 or 10, the selected page descriptor is anIndirect Page Descriptor 58 and is, therefore, actually a pointer to afinal page descriptor 60. Thetranslation controller 44 uses the selected (indirect)page descriptor 58 to retrieve thefinal page descriptor 60 from the page translation table 52. In the present invention,MMUs indirect page descriptor 58. A first indirection mode occurs when an accessed page descriptor has the indirection mode set (DT=11). In such cases, theMMU 24 uses the accessed indirect (common) page descriptor (not shown) as an address to the actual (final)page descriptor 60. Thecontrol logic circuitry 48 then determines the protection and control information for the accessed memory page by logically ORing all control (status) and protection bits found in the corresponding area, segment and page descriptors. - In accordance with the preferred embodiment of the present invention, in a second indirection mode, an accessed indirect (common)
page descriptor 58 has the masked protection indirection mode set (DT=10), as shown in FIG. 3. Accordingly, thetranslation controller 44 uses the accessed indirect (common)page descriptor 58 as the address to the actual (final)page descriptor 60; however, the protection and control bits for actual (final)page descriptor 60 are ignored by thecontrol logic circuitry 48. Instead, thecontrol logic 48 determines the final protection and control information of the accessed memory page by logically ORing the protection and control bits from the corresponding area and segment descriptors, 54 and 56, respectively. Thus, using the common page descriptor, a single memory page may be marked as write protected (Read only) to one memory access, and not write protected (Read/Write) to another. - Upon completing the tablewalk, the
translation controller 44 loads the 20 most significant bits of the missed (referenced)logical address 53 into the logical page address TAG (LOGICAL ADDRESS) of the ATC entry selected for replacement, via logical address bus 43. Thetranslation controller 44 also loads the 20-bit Page Frame Address from thefinal page descriptor 60 into the lower half of theATC 42 entry (PHYSICAL ADDRESS), viaphysical address bus 45. Furthermore, thetranslation controller 44 loads the results obtained from the logical OR of the protection bits found in the area, and segment descriptors into the lower half of the ATC entry. - Shown in FIG. 5 is partial schematic diagram of the
control logic 48, in accordance with a preferred embodiment of the present invention. Thedecoder logic 70 is coupled to register 66 to read the descriptor type (DT) information field of a selected page descriptor. As indicated by Table 1, when the descriptor type information field contains a certain logic value (i.e. DT=10) the selected page descriptor is actually a pointer to the actual (final)page descriptor 60. In the preferred embodiment,decoder logic 70 receives a two bit input, representative of the descriptor type, and provides an output signal MASKPROT* indicative of whether or not the page descriptor is a masked protection indirection descriptor. In accordance with the preferred embodiment,decoder 70 indicates that the selected page descriptor is a masked indirection descriptor by providing a logic low MASKPROT* output signal. An ANDgate 72 is coupled to the output ofdecoder logic 70, and register 68. ANDgate 70 has a first input for receiving the MASKPROT* signal, a second input for receiving a page protection bit of the actual (final) page descriptor, and an output. When the MASKPROT* signal is a logic low, ANDgate 72 provides a logic low signal. The logic low MASKPROT* signal is ORed with a segment protection bit from the correspondingsegment descriptor 56, and an area protection bit from the correspondingarea descriptor 54. The output ofOR gate 74 determines the final page protection for the memory page selected by thepage descriptor 60. - In the preferred embodiment, an
OR gate 76 is coupled to each of the bit positions of each of the corresponding area, segment and page descriptors, 54, 56, and 60, respectively. Each ORgate 76 has a first input for receiving an area status bit, a second input for receiving a segment status bit, and a third input for receiving a page status bit for each of the corresponding descriptors. The collective outputs of theOR gates 76 determines the final page status information for the memory page selected by thepage descriptor 60. Thus, in the presentinvention control logic 48 operates to determine when a selected page descriptor is a selected type (i.e. masked indirection descriptor). Thecontrol logic 48 then logically combines the information provided in the corresponding area, and segment descriptors to determine the final page protection. Similarly, the information provided in the corresponding area, segment, and final page descriptors is logically combined to provide the final page status information. Thus, thetranslation controller 44 uses the accessed indirect (common)page descriptor 58 as the address to the actual (final)page descriptor 60; however, the protection and control bits for actual (final)page descriptor 60 are ignored by thecontrol logic circuitry 48. - While the present invention has been described in a preferred embodiment, it will be apparent to those skilled in the art that the disclosed invention may be modified in numerous ways and may assume many embodiments other than that specifically set out and described above. For example, the
ATCs 42 may include a block address translation cache (BATC), to map large areas of the system and user memory (i.e. 512K to 64Mbytes) without usurping a large number of ATC entries, and a page address translation cache (PATC) for mapping pages of 4K bytes each, for example. Accordingly, the index bits derived from the referenced logical address may vary based upon the number of descriptors stored in the segment and page translation tables. Accordingly, it is intended by the appended claims to cover all modifications of the invention which fall within the true spirit and scope of the invention.
Claims (10)
- In a data processing system (10) having a main memory (40) for storing a set of address translation tables (50, 52) and a memory management (24, 26) system for using said set of address translation tables (50, 52) to obtain a logical to physical address translation, a method for performing address translation using a masked protection indirection page descriptor (58) to map a plurality of logical memory pages to a common page descriptor (60) while allowing different memory accesses to have different access rights to each of said plurality of memory pages, said method comprising the steps of:
performing a tablewalk to retrieve a memory page descriptor (58) comprising a page descriptor address and a descriptor type information field from said set of address translation tables (50, 52), said tablewalk using a first descriptor (54) to traverse a first translation table (50), and a second descriptor (56) to traverse a second translation table (52) to thereby access said memory page descriptor (58) stored in said second translation table (52);
reading said descriptor type information field and using said page descriptor address (58) to point to said common memory page descriptor (60) when said descriptor type field contains a first logic value, said common memory page descriptor (60) including an intermediate set of control and access protection bits; and
masking said intermediate set of control and access protection bits of said common memory page descriptor (60), when said descriptor information field contains said first logic value, and using an alternate set of control and access protection bits of said first descriptor (54) and said second descriptor (56) to determine a final access protection mode for a physical memory page accessed using said common memory page descriptor (60). - The method of claim 1 wherein performing said table walk comprises the steps of:
retrieving said first descriptor (54) from a first control register in said memory management system (24, 26), said first descriptor (54) comprising a segment base address and a first set of control and access protection bits, and combining said segment base address with a first set of bits from a referenced logical address (53) to generate a first translation address (62), said first translation address being stored in a second control register;
using said first translation address (62) to traverse said first translation table (50), said first translation address (62) pointing to said second descriptor (56) stored in said first translation table (50) in said main memory (40), said second descriptor (56) comprising a page base address and a second set of control and access protection bits;
retrieving said page base address from said main memory (40), and combining said page base address with a second set of bits from said referenced logical address to generate a second translation address (64), said second translation address (64) being stored in a third control register; and
using said second translation (64) address to traverse a second translation table (52), said second translation address (64) pointing to said memory page descriptor (58) stored in said second translation table (52) in said main memory (40). - The method of claim 2 wherein the step of masking said intermediate set of control and access protection bits comprises the step of logically ORing said first set of control and access protection bits with said second set of control and access protection bits, a logical result thereof determine said final access protection mode for a physical memory page accessed using said common memory page descriptor (60).
- In a data processing system (10) having a main memory (40) for storing a set of address translation tables (50, 52) and a memory management system (24, 26) for using said set of address translation tables (50, 52) to obtain a logical to physical address translation, a method for allowing a plurality of logical memory pages to be mapped through a common memory page descriptor (60) while allowing different memory accesses to have different access rights to each of said plurality of memory pages, said method comprising the steps of:
performing a tablewalk to retrieve a memory page descriptor (58) comprising a page descriptor address and a descriptor type information field from said set of address translation tables (50, 52); said tablewalk using a first descriptor (54) to access a second descriptor (56) stored in a first translation table (50), and using said second descriptor (56) to access said memory page descriptor (58) stored in a second translation table (52), said first descriptor (54) including a first set of control and access protection bits, and said second descriptor (56) including a second set of control and access protection bits;
reading said descriptor type information field and using said page descriptor address to retrieve said common memory page descriptor (60) when said descriptor type field contains a first logic value, said common memory page descriptor (60) including a third set of control and access protection bits; and
masking said third set of control and access protection bits, when said descriptor information field contains said first logic value, and using a set of control and access protection bits of said first descriptor (54) and said second descriptor (56) to determine a final access protection mode for a physical memory page accessed using said common memory page descriptor (60). - The method of claim 4 wherein performing said two level table walk comprises the steps of:
retrieving said first descriptor (54) from a first control register in said memory management system (24, 26), said first descriptor (54) comprising a segment base address and said first set of control and access protection bits, and combining said segment base address with a first set of bits from a referenced logical address (53) to generate a first translation address (62), said first translation address (62) being stored in a second control register;
using said first translation address (62) to traverse said first translation table (50), said first translation address (62) pointing to said second descriptor (56) stored in said first translation table (50) in said main memory (40), said second descriptor (56) comprising a page base address and said second set of control and access protection bits;
retrieving said page base address from said main memory (40), and combining said page base address with a second set of bits from said referenced logical address to generate a second translation address (64), said second translation address (64) being stored in a third control register; and
using said second translation address to traverse (64) a second translation table (52), said second translation address pointing to said memory page descriptor stored in said second translation table in said main memory (40). - The method of claim 5 wherein the step of masking said third set of control and access protection bits comprises the step of logically ORing said first set of control and access protection bits with said second set of control and access protection bits, a logical result thereof determining a final set of control and access protection bits, said final set of control and access protection bits indicating said final access protection mode for said physical memory page accessed using said common memory page descriptor (60).
- A data processor (12, 14-18, 20-22, 24, 26, 28, 30, 32) coupled to an external memory (40) via a system communications bus (38), said data processor having execution means (14) and memory management means (24, 26) for performing logical to physical address translation using a set of address translation tables (50, 52) stored in said external memory (40), said memory management means (24, 26) mapping a plurality of logical memory pages to a common memory page descriptor (60) while allowing different memory accesses to have different access rights to each of said plurality of memory pages, said memory management means (24, 26) comprising:
translation control means (44) for performing a tablewalk to retrieve a logical to physical address translation from said external memory (40), said translation control means using a first descriptor (54) to access a second descriptor (56) stored in a first translation table (50), and using said second descriptor (56) to access a memory page descriptor (58) stored in a second translation table (52), where said memory page descriptor (58) comprises a descriptor type information field and a page descriptor address, said first descriptor (54) includes a first set of control and access protection bits, and said second descriptor (56) includes a second set of control and access protection bits, said translation control means (44) comprising:
storage means (46) for storing said first descriptor (54), said second descriptor (56), and said memory page descriptor (58); and
control means (48) coupled to said storage means (46) for reading said descriptor type information field of said memory page descriptor (58) and using said page descriptor address to point to a common memory page descriptor (60) when said descriptor type field contains a first logic value, said control means (48) masking an intermediate set of control and access protection bits of said common memory page descriptor (60), when said descriptor information field contains said first logic value, and using said first and said second set of control and protection bits to determine a final set of access protection bits for a physical memory page accessed using said common memory page descriptor (60). - The memory management means of claim 7 further comprising address translation means (42) coupled to said translation controller means (44), for receiving a referenced logical program address from said execution means , and for translating said referenced logical program address into a physical address, said address translation (42) means providing a first control signal to said translation controller (44) when said referenced logical program address matches one of a plurality of logical to physical address translation entries stored in said address translation means (42), and providing a second control signal to said translation controller (44) when said referenced logical program address does not match one of said plurality of logical to physical address translation entries.
- The memory management means (24, 26) of claim 8 wherein said control means (48) comprises ORing means (72, 72, 76) coupled to said storage means (46) for logically ORing said first set of control and access protection bits with said second set of control and access bits to determine said final set of access protection bits for said physical memory page accessed using said common memory page descriptor (60).
- A data processor (12, 14-18, 20-22, 24, 26, 28, 30, 32) coupled to an external memory (40) via a system communications bus (38), said data processor having execution means (14) and memory management means (24, 26) for performing logical to physical address translation using a set of address translation tables (50, 52) stored in said external memory (40), said memory management means (24, 26) mapping a plurality of logical pages to a common memory page descriptor (60) while allowing different memory accesses to have different access rights to each of said plurality of memory pages, said memory management means (24, 26) comprising:
address translation means (42) coupled to said translation controller means (44), for receiving a referenced logical program address from said execution means (14), and for translating said referenced logical program address into a physical address, said address translation means (42) providing a first control signal to said translation controller (44) when said referenced logical program address matches one of a plurality of logical to physical address translation entries stored in said address translation means (42), and providing a second control signal to said translation controller (44) when said referenced logical program address does not match one of said plurality of logical to physical address translation entries
translation control means (44) coupled to said address translation means (42) for performing a tablewalk to retrieve a logical to physical address translation from said external memory (40), in response to receiving said second control signal from said address translation means (42), said translation control means, said translation control means (44) comprising:
storage means (46) for storing a first descriptor (54), said first descriptor (54)being used to traverse a first translation table (50) in said external memory (40) to retrieve a second descriptor (56), said said second descriptor (56) being stored in said storage means (46) and used to traverse a second translation table (52) to retrieve said memory page descriptor (58), said memory page descriptor (58) comprising a descriptor type information field and a page descriptor address; and
control means (48) coupled to said storage means (46) for reading said descriptor type information field of said memory page descriptor (58) and using said page descriptor address to point to a common memory page descriptor (60) when said descriptor type field contains a first logic value, said control means (48) masking an intermediate set of control and access protection bits of said common memory page descriptor (60), when said descriptor information field contains said first logic value, and using an alternate set of control and protection bits generated using said first (54) and said second descriptor (56) to determine a final set of access protection bits for a physical memory page accessed using said common memory page descriptor (60).
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
US73699391A | 1991-07-29 | 1991-07-29 | |
US736993 | 1991-07-29 |
Publications (1)
Publication Number | Publication Date |
---|---|
EP0526114A1 true EP0526114A1 (en) | 1993-02-03 |
Family
ID=24962174
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
EP92306769A Withdrawn EP0526114A1 (en) | 1991-07-29 | 1992-07-23 | A method and apparatus for performing address translation in a data processor using masked protection indirection page descriptors |
Country Status (2)
Country | Link |
---|---|
EP (1) | EP0526114A1 (en) |
JP (1) | JPH05250262A (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
DE19709975A1 (en) * | 1997-03-11 | 1998-09-24 | Siemens Ag | Microcomputer |
GB2378277A (en) * | 2001-07-31 | 2003-02-05 | Sun Microsystems Inc | Multiple address translations |
WO2003083665A3 (en) * | 2002-03-22 | 2003-12-18 | Intel Corp | Obtaining data mask mapping information |
Families Citing this family (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US8799620B2 (en) | 2007-06-01 | 2014-08-05 | Intel Corporation | Linear to physical address translation with support for page attributes |
GB2514107B (en) * | 2013-05-13 | 2020-07-29 | Advanced Risc Mach Ltd | Page table data management |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
EP0175398A2 (en) * | 1984-08-17 | 1986-03-26 | Koninklijke Philips Electronics N.V. | Data processing system comprising a memory access controller which is provided for combining descriptor bits of different descriptors associated with virtual addresses |
US4766537A (en) * | 1986-01-02 | 1988-08-23 | Motorola, Inc. | Paged memory management unit having stack change control register |
-
1992
- 1992-07-23 EP EP92306769A patent/EP0526114A1/en not_active Withdrawn
- 1992-07-29 JP JP4220961A patent/JPH05250262A/en active Pending
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
EP0175398A2 (en) * | 1984-08-17 | 1986-03-26 | Koninklijke Philips Electronics N.V. | Data processing system comprising a memory access controller which is provided for combining descriptor bits of different descriptors associated with virtual addresses |
US4766537A (en) * | 1986-01-02 | 1988-08-23 | Motorola, Inc. | Paged memory management unit having stack change control register |
Non-Patent Citations (2)
Title |
---|
ELECTRONIC ENGINEERING vol. 58, no. 715, July 1986, LONDON GB pages 59 - 68 C. GAY 'M68000 family memory management part 2' * |
PATENT ABSTRACTS OF JAPAN vol. 11, no. 68 (P-553)1987 & JP-A-61 231 642 ( HITACHI ) * |
Cited By (12)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
DE19709975A1 (en) * | 1997-03-11 | 1998-09-24 | Siemens Ag | Microcomputer |
DE19709975C2 (en) * | 1997-03-11 | 1999-04-22 | Siemens Ag | Microcomputer |
US6487649B1 (en) | 1997-03-11 | 2002-11-26 | Siemens Aktiengesellschaft | Microcomputer |
GB2378277A (en) * | 2001-07-31 | 2003-02-05 | Sun Microsystems Inc | Multiple address translations |
GB2378277B (en) * | 2001-07-31 | 2003-06-25 | Sun Microsystems Inc | Multiple address translations |
US6732250B2 (en) | 2001-07-31 | 2004-05-04 | Sun Microsystems, Inc. | Multiple address translations |
WO2003083665A3 (en) * | 2002-03-22 | 2003-12-18 | Intel Corp | Obtaining data mask mapping information |
US6801459B2 (en) | 2002-03-22 | 2004-10-05 | Intel Corporation | Obtaining data mask mapping information |
US6925013B2 (en) | 2002-03-22 | 2005-08-02 | Intel Corporation | Obtaining data mask mapping information |
US6952367B2 (en) | 2002-03-22 | 2005-10-04 | Intel Corporation | Obtaining data mask mapping information |
KR100692343B1 (en) * | 2002-03-22 | 2007-03-09 | 인텔 코오퍼레이션 | Acquisition of data mask mapping information |
CN100380351C (en) * | 2002-03-22 | 2008-04-09 | 英特尔公司 | Get data mask mapping information |
Also Published As
Publication number | Publication date |
---|---|
JPH05250262A (en) | 1993-09-28 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US5075848A (en) | Object lifetime control in an object-oriented memory protection mechanism | |
US5075845A (en) | Type management and control in an object oriented memory protection mechanism | |
US5265227A (en) | Parallel protection checking in an address translation look-aside buffer | |
US6532528B1 (en) | Data processor and data processor system having multiple modes of address indexing and operation | |
US5918251A (en) | Method and apparatus for preloading different default address translation attributes | |
JP4295111B2 (en) | Memory management system and memory access security grant method based on linear address | |
EP1096385B1 (en) | A method and apparatus for forming an entry address | |
US6256715B1 (en) | System and method of performing gateway access | |
JP3713312B2 (en) | Data processing device | |
US6189074B1 (en) | Mechanism for storing system level attributes in a translation lookaside buffer | |
US6430670B1 (en) | Apparatus and method for a virtual hashed page table | |
US5752275A (en) | Translation look-aside buffer including a single page size translation unit | |
US5412787A (en) | Two-level TLB having the second level TLB implemented in cache tag RAMs | |
US4800489A (en) | Paged memory management unit capable of selectively supporting multiple address spaces | |
KR100338446B1 (en) | Methods and data processing systems that provide memory access control | |
EP0036110A2 (en) | Cache addressing mechanism | |
EP0911737A1 (en) | Cache memory with reduced access time | |
JPH0628262A (en) | Look-aside buffer and method for high-speed translation of virtual address for physical address | |
EP1490774A1 (en) | System and method providing region-granular, hardware-controlled memory encryption | |
US5682495A (en) | Fully associative address translation buffer having separate segment and page invalidation | |
US5539892A (en) | Address translation lookaside buffer replacement apparatus and method with user override | |
US6651156B1 (en) | Mechanism for extending properties of virtual memory pages by a TLB | |
US5287482A (en) | Input/output cache | |
JPH05210593A (en) | Memory partitioning device for microprocessor and method of loading segment descriptor to segment-register | |
JPH05216766A (en) | Method for maintaining coherence of cache between data cache and segment descriptor and memory device of computer |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PUAI | Public reference made under article 153(3) epc to a published international application that has entered the european phase |
Free format text: ORIGINAL CODE: 0009012 |
|
AK | Designated contracting states |
Kind code of ref document: A1 Designated state(s): DE FR GB IT |
|
17P | Request for examination filed |
Effective date: 19930715 |
|
17Q | First examination report despatched |
Effective date: 19960909 |
|
GRAG | Despatch of communication of intention to grant |
Free format text: ORIGINAL CODE: EPIDOS AGRA |
|
GRAG | Despatch of communication of intention to grant |
Free format text: ORIGINAL CODE: EPIDOS AGRA |
|
GRAG | Despatch of communication of intention to grant |
Free format text: ORIGINAL CODE: EPIDOS AGRA |
|
GRAH | Despatch of communication of intention to grant a patent |
Free format text: ORIGINAL CODE: EPIDOS IGRA |
|
GRAH | Despatch of communication of intention to grant a patent |
Free format text: ORIGINAL CODE: EPIDOS IGRA |
|
STAA | Information on the status of an ep patent application or granted ep patent |
Free format text: STATUS: THE APPLICATION IS DEEMED TO BE WITHDRAWN |
|
ITF | It: translation for a ep patent filed | ||
18D | Application deemed to be withdrawn |
Effective date: 19980515 |