# US 7,610,523 B1 · Method and template for physical-memory allocation for implementing an in-system memory test

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 7,610,523 B1
- Document ID: US7610523B1
- Status: Granted
- Kind: B1
- Application number: 11/352,085
- Filed: 2006-02-09
- Granted: 2009-10-27
- Earliest claimed: 2006-02-09
- Assignees: Sun Microsystems, Inc.
- Inventors: Amandeep Singh
- Web page: https://patentgrep.com/patent/US7610523B1

## CPC

- G11C 29/52: Protection of memory contents; Detection of errors in memory contents
- G11C 29/42: using error correcting codes [ECC] or parity check
- G11C 2029/0409: {Online test}
- G11C: STATIC STORES (semiconductor memory devices H10B)

## Abstract

An in-system memory testing method includes transparently selecting and “stealing” a portion of memory from the memory system for running memory tests, then running one or more of the numerous known memory system tests on the selected portion of memory, and then inserting the selected, and now tested, portion of memory back into the system for normal application use. The disclosed in-system memory testing method is capable of testing system memory in both offline and online environments, without imposing any additional hardware requirements or significantly affecting system performance. The disclosed in-system memory testing method is compatible with any conventional prior art functional test algorithm for in-system memory testing and can be performed under real life system environmental conditions. Therefore, the disclosed in-system memory testing method complements other test techniques like BIST/POST that are conventionally used only at the time of system boot up.

## Claims

### Claim 1

A method for in-system memory testing comprising:
probing a physical memory to determine the physical memory configuration including a base address of the physical memory the size of the entire physical memory;
determining a size of a portion of physical memory to be tested in each iteration of testing of one or more iterations of testing to be performed to test the entire physical memory, the size of a portion of physical memory to be tested in each iteration of testing being determined by dividing the size of the entire physical memory by a total number of iterations to be performed to test the entire physical memory;
selecting a first portion of physical memory for testing, thereby defining a selected first portion of physical memory, the selected first portion of physical memory being selected based on the iteration number associated with the testing of the selected first portion of physical memory, the size of a portion of physical memory to be tested in each iteration of testing and an allocated start address for the selected first portion of physical memory, the allocated start address for the selected first portion of physical memory being determined by adding the product of the size of a portion of physical memory to be tested in each iteration of testing and the iteration number associated with the testing of the selected first portion of physical memory to the base address of the physical memory;
allocating a portion of virtual memory for testing, thereby defining an allocated portion of virtual memory;
mapping the selected first portion of physical memory from the physical memory to the allocated portion of virtual memory; and
executing a memory test algorithm on the selected first portion of physical memory mapped to the allocated portion of virtual memory, in the allocated portion of virtual memory.

### Claim 2 (depends on 1)

The method for in-system memory testing of claim 1, further comprising:
selecting a second portion of physical memory for testing, thereby defining a selected second portion of physical memory, the selected second portion of physical memory being selected based on the iteration number associated with the testing of the selected second portion of physical memory, the size of a portion of physical memory to be tested in each iteration of testing, and an allocated start address for the selected second portion of physical memory, the allocated start address for the selected second portion of physical memory being determined by adding the product of the size of a portion of physical memory to be tested in each iteration of testing and the iteration number associated with the testing of the selected second portion of physical memory to the base address of the physical memory;
mapping the selected second portion of physical memory from the physical memory to the allocated portion of virtual memory; and
executing a memory test algorithm on the selected second portion of physical memory mapped to the allocated portion of virtual memory, in the allocated portion of virtual memory.

### Claim 3 (depends on 2)

The method for in-system memory testing of claim 2, further comprising:
repeating:
selecting a portion of physical memory for testing, thereby defining a selected portion of physical memory, the selected portion of physical memory being selected based on the iteration number associated with the testing of the selected portion of physical memory, the size of a portion of physical memory to be tested in each iteration of testing, and an allocated start address for the selected portion of physical memory, the allocated start address for the selected portion of physical memory being determined by adding the product of the size of a portion of physical memory to be tested in each iteration of testing and the iteration number associated with the testing of the selected portion of physical memory to the base address of the physical memory;
mapping the selected portion of physical memory from the physical memory to the allocated portion of virtual memory, thereby defining an allocated portion of virtual memory; and
executing a memory test algorithm on the selected portion of physical memory mapped to the allocated portion of virtual memory, in the allocated portion of virtual memory until the entire physical memory has been tested.

### Claim 4 (depends on 1)

The method for in-system memory testing of claim 1, wherein:
selecting a first portion of physical memory for testing, thereby defining a selected first portion of physical memory;
mapping the selected first portion of physical memory from the physical memory to the allocated portion of virtual memory; and
executing a memory test algorithm on the selected first portion of physical memory in the allocated portion of virtual memory are performed in an offline environment.

### Claim 5 (depends on 1)

The method for in-system memory testing of claim 1, wherein:
selecting a first portion of physical memory for testing, thereby defining a selected first portion of physical memory;
mapping the selected first portion of physical memory from the physical memory to the allocated portion of virtual memory; and
executing a memory test algorithm on the selected first portion of physical memory in the allocated portion of virtual memory are performed in an online environment.

### Claim 6 (depends on 5)

The method for in-system memory testing of claim 5, wherein:
selecting a first portion of physical memory for testing, thereby defining a selected first portion of physical memory;
mapping the selected first portion of physical memory from the physical memory to the allocated portion of virtual memory; and
executing a memory test algorithm on the selected first portion of physical memory in the allocated portion of virtual memory are scheduled to be performed during system idle periods.

### Claim 7 (depends on 1)

The method for in-system memory testing of claim 1, further comprising:
preventing an Operating System of a computer system using the physical memory being tested from paging-out the selected first portion of physical memory while the test algorithm is being executed on the selected first portion of physical memory.

### Claim 8

A system for in-system memory testing comprising:
means for probing a physical memory to determine the physical memory configuration including a base address of the physical memory the size of the entire physical memory;
determining a size of a portion of physical memory to be tested in each iteration of testing of one or more iterations of testing to be performed to test the entire physical memory, the size of a portion of physical memory to be tested in each iteration of testing being determined by dividing the size of the entire physical memory by a total number of iterations to be performed to test the entire physical memory;
means for selecting a first portion of physical memory for testing, thereby defining a selected first portion of physical memory, the selected portion of physical memory being selected based on the iteration number associated with the testing of the selected first portion of physical memory, the size of a portion of physical memory to be tested in each iteration of testing and an allocated start address for the selected first portion of physical memory, the allocated start address for the selected first portion of physical memory being determined by adding the product of the size of a portion of physical memory to be tested in each iteration of testing and the iteration number associated with the testing of the selected first portion of physical memory to the base address of the physical memory;
means for allocating a portion of virtual memory for testing, thereby defining an allocated portion of virtual memory;
means for mapping the selected first portion of physical memory from the physical memory to the allocated portion of virtual memory; and
means for executing a memory test algorithm on the selected first portion of physical memory mapped to the allocated portion of virtual memory, in the allocated portion of virtual memory.

### Claim 9 (depends on 8)

The system for in-system memory testing of claim 8, further comprising:
means for selecting a second portion of physical memory for testing, thereby defining a selected second portion of physical memory, the selected second portion of physical memory being selected based on the iteration number associated with the testing of the selected second portion of physical memory, the size of a portion of physical memory to be tested in each iteration of testing, and an allocated start address for the selected second portion of physical memory, the allocated start address for the selected second portion of physical memory being determined by adding the product of the size of a portion of physical memory to be tested in each iteration of testing and the iteration number associated with the testing of the selected second portion of physical memory to the base address of the physical memory;
means for mapping the selected second portion of physical memory from the physical memory to the allocated portion of virtual memory; and
means for executing a memory test algorithm on the selected second portion of physical memory mapped to the allocated portion of virtual memory, in the allocated portion of virtual memory.

### Claim 10 (depends on 9)

The system for in-system memory testing of claim 9, further comprising:
means for repeating:
selecting a portion of physical memory for testing, thereby defining a selected portion of physical memory, the selected portion of physical memory being selected based on the iteration number associated with the testing of the selected portion of physical memory, the size of a portion of physical memory to be tested in each iteration of testing, and an allocated start address for the selected portion of physical memory, the allocated start address for the selected portion of physical memory being determined by adding the product of the size of a portion of physical memory to be tested in each iteration of testing and the iteration number associated with the testing of the selected portion of physical memory to the base address of the physical memory;
mapping the selected portion of physical memory from the physical memory to the allocated portion of virtual memory, thereby defining an allocated portion of virtual memory; and
executing a memory test algorithm on the selected portion of physical memory mapped to the allocated portion of virtual memory, in the allocated portion of virtual memory until the entire physical memory has been tested.

### Claim 11 (depends on 8)

The system for in-system memory testing of claim 8, further comprising:
means for preventing an Operating System of a computer system using the physical memory being tested from paging-out the selected first portion of physical memory while the test algorithm is being executed on the selected first portion of physical memory.

### Claim 12

A computer program product comprising:
instructions for directing an in-system memory test, the in-system memory test comprising:
probing a physical memory to determine the physical memory configuration including a base address of the physical memory the size of the entire physical memory;
determining a size of a portion of physical memory to be tested in each iteration of testing of one or more iterations of testing to be performed to test the entire physical memory, the size of a portion of physical memory to be tested in each iteration of testing being determined by dividing the size of the entire physical memory by a total number of iterations to be performed to test the entire physical memory;
selecting a first portion of physical memory for testing, thereby defining a selected first portion of physical memory, the iteration number associated with the testing of the selected first portion of physical memory, the size of a portion of physical memory to be tested in each iteration of testing and an allocated start address for the selected first portion of physical memory, the allocated start address for the selected first portion of physical memory being determined by adding the product of the size of a portion of physical memory to be tested in each iteration of testing and the iteration number associated with the testing of the selected first portion of physical memory to the base address of the physical memory
allocating a portion of virtual memory for testing, thereby defining an allocated portion of virtual memory;
mapping the selected first portion of physical memory from the physical memory to the allocated portion of virtual memory;
executing a memory test algorithm on the selected first portion of physical memory mapped to the allocated portion of virtual memory, in the allocated portion of virtual memory; and
a computing system using the selected first portion of physical memory.

### Claim 13 (depends on 12)

The computer program product of claim 12, wherein, the in-system memory test further comprises:
selecting a second portion of physical memory for testing, thereby defining a selected second portion of physical memory, the selected second portion of physical memory being selected based on the iteration number associated with the testing of the selected second portion of physical memory, the size of a portion of physical memory to be tested in each iteration of testing, and an allocated start address for the selected second portion of physical memory, the allocated start address for the selected second portion of physical memory being determined by adding the product of the size of a portion of physical memory to be tested in each iteration of testing and the iteration number associated with the testing of the selected second portion of physical memory to the base address of the physical memory;
mapping the selected second portion of physical memory from the physical memory to the allocated portion of virtual memory; and
executing a memory test algorithm on the selected second portion of physical memory mapped to the allocated portion of virtual memory, in the allocated portion of virtual memory.

### Claim 14 (depends on 13)

The computer program product of claim 13, wherein, the in-system memory test further comprises:
repeating:
selecting a portion of physical memory for testing, thereby defining a selected portion of physical memory, the selected portion of physical memory being selected based on the iteration number associated with the testing of the selected portion of physical memory, the size of a portion of physical memory to be tested in each iteration of testing, and an allocated start address for the selected portion of physical memory, the allocated start address for the selected portion of physical memory being determined by adding the product of the size of a portion of physical memory to be tested in each iteration of testing and the iteration number associated with the testing of the selected portion of physical memory to the base address of the physical memory;
mapping the selected portion of physical memory from the physical memory to the allocated portion of virtual memory, thereby defining an allocated portion of virtual memory; and
executing a memory test algorithm on the selected portion of physical memory mapped to the allocated portion of virtual memory, in the allocated portion of virtual memory until the entire physical memory has been tested.

### Claim 15 (depends on 12)

The computer program product of claim 12, wherein, the in-system memory test further comprises:
selecting a first portion of physical memory for testing, thereby defining a selected first portion of physical memory;
mapping the selected first portion of physical memory from the physical memory to the allocated portion of virtual memory; and
executing a memory test algorithm on the selected first portion of physical memory in the allocated portion of virtual memory are performed in an offline environment.

### Claim 16 (depends on 12)

The computer program product of claim 12, wherein, the in-system memory test further comprises:
selecting a first portion of physical memory for testing, thereby defining a selected first portion of physical memory;
mapping the selected first portion of physical memory from the physical memory to the allocated portion of virtual memory; and
executing a memory test algorithm on the selected first portion of physical memory in the allocated portion of virtual memory are performed in an online environment.

### Claim 17 (depends on 12)

The computer program product of claim 12, wherein, the in-system memory test further comprises:
selecting a first portion of physical memory for testing, thereby defining a selected first portion of physical memory;
mapping the selected first portion of physical memory from the physical memory to the allocated portion of virtual memory; and
executing a memory test algorithm on the selected first portion of physical memory in the allocated portion of virtual memory are scheduled to be performed during system idle periods.

### Claim 18 (depends on 12)

The computer program product of claim 12, wherein, the in-system memory test further comprises:
preventing an Operating System of a computer system using the physical memory being tested from paging-out the selected first portion of physical memory while the test algorithm is being executed on the selected first portion of physical memory.
