Method and apparatus for memory-mapped input/output
First Claim
1. A method of reading a block of data at a location in a memory-mapped file, comprising the steps of:
- receiving a reference indicating the location in the memory-mapped file;
extracting a page number and a page offset from respective portions of the reference;
computing a shared memory address in main memory based on the page number and the page offset; and
reading the block of data from a paged memory indicated at the shared memory address.
1 Assignment
0 Petitions
Accused Products
Abstract
A method of managing memory mapped input/output (I/O) for a run-time environment is disclosed, in which opaque references are used for accessing information blocks included in files used in a dynamic run-time environment. The information block is stored in a shared memory space of pages that are each aligned on respective boundaries having addresses that are each some multiple of two raised to an integer power. The opaque reference used for the dynamic run-time environment includes at least an index, or page number reference into a page map of references to the pages of the shared memory space, and an offset value indicating an offset into the referenced page for the beginning of the storage of the information block. Control bits of the opaque reference indicate information such as the mapping mode, e.g., read-only, read-write, or private. Pages which are modified by a process may be written back to a backing store of the file based on control bits which indicate that a page has been modified.
-
Citations
24 Claims
-
1. A method of reading a block of data at a location in a memory-mapped file, comprising the steps of:
-
receiving a reference indicating the location in the memory-mapped file;
extracting a page number and a page offset from respective portions of the reference;
computing a shared memory address in main memory based on the page number and the page offset; and
reading the block of data from a paged memory indicated at the shared memory address. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8)
-
-
9. A method of writing a number of bytes to a location in a memory-mapped file, comprising the steps of:
-
receiving a reference indicating the location in the memory-mapped file;
extracting a page number and a page offset from respective portions of the reference;
computing a shared memory address based on the page number and the page offset; and
writing the number of bytes to a shared memory indicated at the shared memory address. - View Dependent Claims (10, 11, 12, 13, 14, 15, 16)
-
-
17. A method of memory-mapping a file, the method comprising the steps of:
-
determining an available page in a shared memory space for storing at least a portion of the file;
computing a shared page reference to the available page based on a memory address of the available page and control information associated with the available page;
storing the shared page reference in a page map;
storing the at least a portion of the file in the available page; and
computing an opaque reference to the available page indicating a page map index for the location of the shared page reference and an offset value. - View Dependent Claims (18, 19, 20, 21, 22, 23, 24)
-
Specification