System and method for managing compression and decompression of system memory in a computer system
First Claim
1. A method for managing compression of pages of memory in a system comprising physical memory, wherein the physical memory comprises system memory, the method comprising:
- receiving a system memory access;
locating a page translation entry for the system memory access in a page translation table;
determining if a page in the physical memory and referenced by the page translation entry is compressed or uncompressed;
if said determining indicates the page is compressed;
decompressing the compressed page to produce a decompressed page;
writing the decompressed page to the physical memory; and
providing a first physical memory address of the decompressed page in the physical memory to fulfill the system memory access.
4 Assignments
0 Petitions
Accused Products
Abstract
A method and system for allowing a processor or I/O master to address more system memory than physically exists are described. A Compressed Memory Management Unit (CMMU) may keep least recently used pages compressed, and most recently and/or frequently used pages uncompressed in physical memory. The CMMU translates system addresses into physical addresses, and may manage the compression and/or decompression of data at the physical addresses as required. The CMMU may provide data to be compressed or decompressed to a compression/decompression engine. In some embodiments, the data to be compressed or decompressed may be provided to a plurality of compression/decompression engines that may be configured to operate in parallel. The CMMU may pass the resulting physical address to the system memory controller to access the physical memory. A CMMU may be integrated in a processor, a system memory controller or elsewhere within the system.
-
Citations
134 Claims
-
1. A method for managing compression of pages of memory in a system comprising physical memory, wherein the physical memory comprises system memory, the method comprising:
-
receiving a system memory access;
locating a page translation entry for the system memory access in a page translation table;
determining if a page in the physical memory and referenced by the page translation entry is compressed or uncompressed;
if said determining indicates the page is compressed;
decompressing the compressed page to produce a decompressed page;
writing the decompressed page to the physical memory; and
providing a first physical memory address of the decompressed page in the physical memory to fulfill the system memory access. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 66, 68, 69, 70, 71, 72)
-
-
41. A method for managing compression of pages of memory in a system comprising an operating system and physical memory, wherein the physical memory comprises system memory, the method comprising:
-
locating a page translation entry in a page translation table, wherein the page translation entry references an uncompressed page in the physical memory;
determining if the uncompressed page is to be compressed;
if said determining indicates the page is to be compressed;
compressing the uncompressed page to produce a compressed page; and
writing the compressed page to the physical memory. wherein the compression of pages of the memory in the system is operable to increase the effective size of the system memory by keeping least recently used data as compressed data in the physical memory and most recently and frequently used data as uncompressed data in the physical memory; and
wherein the operating system is not aware of the increased effective size of the system memory. - View Dependent Claims (42, 43, 44, 45, 46, 47, 48, 49)
-
-
50. A method for compressing memory in a system comprising a plurality of compression engines and a physical memory, wherein the physical memory comprises system memory, the method comprising:
-
locating a page translation entry in a page translation table, wherein the page translation entry references an uncompressed page in the physical memory;
providing the referenced uncompressed page to the plurality of compression engines, wherein each of the plurality of compression engines implements a different compression algorithm;
the plurality of compression engines each compressing the uncompressed page using the compression algorithm implemented by the particular compression engine to produce a plurality of compressed pages each compressed by a different compression algorithm;
selecting the compressed page with the highest compression ratio of the plurality of compressed pages; and
writing the selected compressed page to the physical memory. - View Dependent Claims (51, 52, 53, 54)
-
-
55. A method comprising:
-
determining a compression ratio for system memory in a system comprising physical memory, wherein the physical memory comprises the system memory;
determining if the compression ratio is below a compression ratio threshold;
if the compression ratio is below the compression ratio threshold;
locating a page translation entry in a page translation table referencing an uncompressed page in the system memory to be highly compressed;
setting a highly compressed attribute in the page translation entry to indicate that the page is highly compressed; and
freeing a first portion of the physical memory allocated to the page in the system memory;
wherein highly compressing the page of the memory in the system is operable to increase the compression ratio for the system memory. - View Dependent Claims (56, 57, 58, 59, 60)
-
-
61. A system comprising:
-
one or more processors;
a physical memory comprising a system memory;
a system memory controller; and
a compressed memory management unit (CMMU), configured to;
receive from a first processor of the one or more processors a system memory access comprising a system memory address;
translate the system memory address into a first physical memory address;
cause the decompression of the compressed data at the first physical memory address in the physical memory;
write the decompressed data to a second physical memory address; and
pass the second physical memory address to the system memory controller;
wherein the system memory controller is configured to fulfill the system memory access from the decompressed data at the second physical memory address; and
wherein the CMMU is operable to increase the effective size of the system memory by keeping least recently used data as compressed data in the physical memory and most recently and frequently used data as uncompressed data in the physical memory. - View Dependent Claims (62, 63, 64, 65, 67, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97)
-
-
98. A system comprising:
-
one or more processors;
a system memory controller;
a physical memory comprising a system memory; and
a compressed memory management unit (CMMU), configured to;
translate a system memory address into a first physical memory address;
cause the compression of the uncompressed data at the first physical memory address to produce compressed data; and
write the compressed data to a second physical memory address;
wherein the system is operable to increase the effective size of system memory by keeping least recently used pages compressed in the physical memory and most recently and frequently used pages uncompressed in the physical memory. - View Dependent Claims (99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, 130, 131, 132, 133, 134)
-
-
129. A system comprising:
-
one or more processors;
a system memory controller;
a physical memory comprising a system memory; and
a compressed memory management unit (CMMU), configured to;
maintain a threshold compression ratio, wherein the threshold compression ratio is a desired minimum ratio between compressed pages and uncompressed pages of the system memory;
dynamically monitor a current compression ratio for the system memory, wherein the current compression ratio is an actual ratio between compressed pages and uncompressed pages of the system memory, and wherein the compression ratio determines an amount by which system memory address space can be increased;
dynamically determine if the current compression ratio is below the threshold compression ratio;
if the current compression ratio is below the threshold compression ratio, cause the compression of one or more uncompressed pages to generate one or more compressed pages; and
wherein the CMMU is operable to increase the effective size of the system memory by keeping least recently used pages compressed in the physical memory and most recently and frequently used pages uncompressed in the physical memory; and
wherein compressing the one or more uncompressed page is operable to increase the current compression ratio for the system memory.
-
Specification