# US 2008/0303839 A1 · Facilitating caching in an image-processing system

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

- Number: US 2008/0303839 A1
- Document ID: US20080303839A1
- Status: Published application
- Kind: A1
- Application number: 11/811,116
- Filed: 2007-06-08
- Published: 2008-12-11
- Earliest claimed: 2007-06-08
- Assignees: Apple Inc.
- Inventors: Kevin Quennesson; Pierre-Olivier Latour
- Web page: https://patentgrep.com/patent/US20080303839A1

## CPC

- G06F 12/0875: with dedicated cache, e.g. instruction or stack
- G06T 1/60: Memory management
- G09G 5/06: using colour palettes, e.g. look-up tables
- G09G 5/12: Synchronisation between the display unit and other units, e.g. other display units, video-disc players
- G09G 2360/121: using a cache memory
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- G06T: IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G09G: ARRANGEMENTS OR CIRCUITS FOR CONTROL OF INDICATING DEVICES USING STATIC MEANS TO PRESENT VARIABLE INFORMATION (arrangements for transferring data between digital computers and displays G06F3/14; static indicating arrangements comprising an association of a number of separate sources or light control cells G09F9/00; static indicating arrangements comprising integral associations of a number of light sources H01J, H01K, H10H, H05B33/12; scanning, transmission or reproduction of documents or the like, e.g. facsimile transmission, details thereof H04N1/00)

## Abstract

Embodiments of the present invention provide a system for performing caching in an image-processing system. The system starts by receiving a filtering query for resources in a cache. The system then returning a subcache in response to the filtering query. Upon receiving a resource query for resources in the subcache, the system performs the filtering query on the cache, populates the subcache with addresses of resources returned by the filtering query until the resource query is satisfied, and returns available resources from the subcache in response to the resource query.

## Claims

### Claim 1

A method for performing caching in an image-processing system, comprising:
receiving a filtering query for resources in a cache;
returning a subcache in response to the filtering query; and
upon receiving a resource query for resources in the subcache,
performing the filtering query on the cache,
populating the subcache with addresses of resources returned by the filtering query until the resource query is satisfied, and
returning available resources from the subcache in response to the resource query.

### Claim 2 (depends on 1)

The method of claim 1, wherein the method further comprises:
receiving a second filtering query for resources in the subcache;
returning a second subcache in response to the second filtering query; and
upon receiving a second resource query for resources from the second subcache,
performing the second filtering query on the subcache,
populating the second subcache with resources returned from the second filtering query until the resource query is satisfied, and
returning available resources from the second subcache in response to the second resource query.

### Claim 3 (depends on 2)

The method of claim 2, wherein if the filtering query has not already been performed on the cache, performing the second filtering query on the subcache involves first performing the filtering query on the cache until the resource query is satisfied and populating the subcache with resources returned from the filtering query.

### Claim 4 (depends on 1)

The method of claim 1, wherein the resources are identifiers for images, wherein the identifiers include:
addresses of a location in a memory or on a disk where the images are stored;
MD5 tags,
a size value, and/or
an age value.

### Claim 5 (depends on 4)

The method of claim 4, wherein receiving the resource query or the filtering query involves receiving a request for a list of addresses of images, wherein the images have at least one property in common, and wherein the property in common can be determined by comparing one or more MD5 tags.

### Claim 6 (depends on 5)

The method of claim 5, wherein the property in common can include:
being stored in a given location;
being stored in a given format;
having undergone a format change, a color-space change, a conversion, and/or a transformation;
exceeding or not exceeding a given bound; and/or
exceeding or not exceeding a given size in memory.

### Claim 7 (depends on 4)

The method of claim 4, wherein returning the subcache in response to the filtering query involves indicating a maximum size allowed for the subcache and indicting a maximum age and a purgeable age for identifiers for images in the subcache.

### Claim 8 (depends on 7)

The method of claim 7, wherein each subcache includes a maximum age and purgeable age limit, wherein the method further comprises:
removing an identifier for an image from the cache if the identifier for the image is older than the maximum age limit, wherein removing the identifier for the image involves removing the underlying image from the location in memory or on disk;
marking the identifier for the image as purgeable if the identifier for the image is older than the purgeable age; and
wherein when an identifier for an image is marked as purgeable, the method further comprises removing the associated image from the location in memory if the location in memory is required for another purpose.

### Claim 9 (depends on 8)

The method of claim 8, wherein the method further comprises:
computing a statistical profile for the ages of resources returned from a given subcache in response to a resource query or filtering query
using the statistical profile to compute a purgeable age; and
updating the purgeable age with the computed purgeable age.

### Claim 10 (depends on 1)

The method of claim 1, wherein upon receiving a command to add a resource to the cache, the method further comprises adding the resource to the cache.

### Claim 11 (depends on 10)

The method of claim 10, wherein the method further comprises performing a garbage-collection operation to remove excess or unused resources from the cache or set resources as purgeable if those resources are over the purgeable age.

### Claim 12 (depends on 11)

The method of claim 11, wherein upon receiving a resource query for resources in a given subcache after the resource has been added to the cache or removed from the cache, the method further comprises performing a corresponding filtering query on the cache and a corresponding filtering query on any intervening subcaches to update the given subcache to account for the added or removed resource.

### Claim 13

An apparatus for performing caching in an image-processing system, comprising:
a processor;
an execution mechanism on the processor;
wherein the execution mechanism is configured to:
receive a filtering query for resources in a cache;
return a subcache in response to the filtering query; and
upon receiving a resource query for resources in the subcache,
perform the filtering query on the cache,
populate the subcache with addresses of resources returned by the filtering query until the resource query is satisfied, and
return available resources from the subcache in response to the resource query.

### Claim 14 (depends on 13)

The apparatus of claim 13, wherein the execution mechanism is configured to:
receive a second filtering query for resources in the subcache;
return a second subcache in response to the second filtering query; and
upon receiving a second resource query for resources from the second subcache,
perform the second filtering query on the subcache,
populate the second subcache with resources returned from the second filtering query until the resource query is satisfied, and
return available resources from the second subcache in response to the second resource query.

### Claim 15 (depends on 14)

The apparatus of claim 14, wherein if the filtering query has not already been performed on the cache, the execution mechanism is configured to perform the second filtering query on the subcache by first performing the filtering query on the cache until the resource query is satisfied and populating the subcache with resources returned from the filtering query.

### Claim 16 (depends on 13)

The apparatus of claim 13, wherein the resources are identifiers for images, wherein the identifiers include:
addresses of a location in a memory or on a disk where the images are stored;
MD5 tags,
a size value, and/or
an age value.

### Claim 17 (depends on 16)

The apparatus of claim 16, when wherein receiving the resource query or the filtering query, wherein the execution mechanism is configured to receive a request for a list of addresses of images, wherein the images have at least one property in common, and wherein the property in common can be determined by comparing one or more MD5 tags.

### Claim 18 (depends on 17)

The apparatus of claim 17, wherein the property in common can include:
being stored in a given location;
being stored in a given format;
having undergone a format change, a color-space change, a conversion, and/or a transformation;
exceeding or not exceeding a given bound; and/or
exceeding or not exceeding a given size in memory.

### Claim 19 (depends on 16)

The apparatus of claim 16, wherein when returning the subcache in response to the filtering query, wherein the execution mechanism is configured to indicate a maximum size allowed for the subcache and indicate a maximum age and a purgeable age for identifiers for images in the subcache.

### Claim 20 (depends on 19)

The apparatus of claim 19, wherein each subcache includes a maximum age and purgeable age limit, wherein the execution mechanism is configured to:
remove an identifier for an image from the cache if the identifier for the image is older than the maximum age limit, wherein when removing the identifier for the image, the execution mechanism is configured to removing the underlying image from the location in memory or on disk;
mark the identifier for the image as purgeable if the identifier for the image is older than the purgeable age; and
wherein when an identifier for an image is marked as purgeable, the wherein the execution mechanism is configured to remove the associated image from the location in memory if wherein the execution mechanism requires the location in memory for another purpose.

### Claim 21 (depends on 20)

The apparatus of claim 20, wherein the execution mechanism is configured to:
compute a statistical profile for the ages of resources returned from a given subcache in response to a resource query or filtering query
use the statistical profile to compute a purgeable age; and
update the purgeable age with the computed purgeable age.

### Claim 22 (depends on 13)

The apparatus of claim 13, wherein upon receiving a command to add a resource to the cache, the execution mechanism is configured to add the resource to the cache.

### Claim 23 (depends on 22)

The apparatus of claim 22, wherein the execution mechanism is configured to perform a garbage-collection operation to remove excess or unused resources from the cache or set resources as purgeable if those resources are over the purgeable age.

### Claim 24 (depends on 23)

The apparatus of claim 23, wherein upon receiving a resource query for resources in a given subcache after the resource has been added to the cache or removed from the cache, the execution mechanism is configured to perform a corresponding filtering query on the cache and a corresponding filtering query on any intervening subcaches to update the given subcache to account for the added or removed resource.

### Claim 25

A computer-readable storage medium containing instructions that when executed by a computer cause the computer to perform a method for performing caching in an image-processing system, the method comprising:
receiving a filtering query for resources in a cache;
returning a subcache in response to the filtering query; and
upon receiving a resource query for resources in the subcache,
performing the filtering query on the cache,
populating the subcache with addresses of resources returned by the filtering query until the resource query is satisfied, and
returning available resources from the subcache in response to the resource query.

### Claim 26 (depends on 25)

The computer-readable storage medium of claim 25, wherein the method further comprises:
receiving a second filtering query for resources in the subcache;
returning a second subcache in response to the second filtering query; and
upon receiving a second resource query for resources from the second subcache,
performing the second filtering query on the subcache,
populating the second subcache with resources returned from the second filtering query until the resource query is satisfied, and
returning available resources from the second subcache in response to the second resource query.

### Claim 27 (depends on 26)

The computer-readable storage medium of claim 26, wherein if the filtering query has not already been performed on the cache, performing the second filtering query on the subcache involves first performing the filtering query on the cache until the resource query is satisfied and populating the subcache with resources returned from the filtering query.

### Claim 28 (depends on 25)

The computer-readable storage medium of claim 25, wherein the resources are identifiers for images, wherein the identifiers include:
addresses of a location in a memory or on a disk where the images are stored;
MD5 tags,
a size value, and/or
an age value.

### Claim 29 (depends on 28)

The computer-readable storage medium of claim 28, wherein receiving the resource query or the filtering query involves receiving a request for a list of addresses of images, wherein the images have at least one property in common, and wherein the property in common can be determined by comparing one or more MD5 tags.

### Claim 30 (depends on 29)

The computer-readable storage medium of claim 29, wherein the property in common can include:
being stored in a given location;
being stored in a given format;
having undergone a format change, a color-space change, a conversion, and/or a transformation;
exceeding or not exceeding a given bound; and/or
exceeding or not exceeding a given size in memory.

### Claim 31 (depends on 28)

The computer-readable storage medium of claim 28, wherein returning the subcache in response to the filtering query involves indicating a maximum size allowed for the subcache and indicting a maximum age and a purgeable age for identifiers for images in the subcache.

### Claim 32 (depends on 31)

The computer-readable storage medium of claim 31, wherein each subcache includes a maximum age and purgeable age limit, wherein the method further comprises:
removing an identifier for an image from the cache if the identifier for the image is older than the maximum age limit, wherein removing the identifier for the image involves removing the underlying image from the location in memory or on disk;
marking the identifier for the image as purgeable if the identifier for the image is older than the purgeable age; and
wherein when an identifier for an image is marked as purgeable, the method further comprises removing the associated image from the location in memory if the location in memory is required for another purpose.

### Claim 33 (depends on 32)

The computer-readable storage medium of claim 32, wherein the method further comprises:
computing a statistical profile for the ages of resources returned from a given subcache in response to a resource query or filtering query
using the statistical profile to compute a purgeable age; and
updating the purgeable age with the computed purgeable age.

### Claim 34 (depends on 25)

The computer-readable storage medium of claim 25, wherein upon receiving a command to add a resource to the cache, the method further comprises adding the resource to the cache.

### Claim 35 (depends on 34)

The computer-readable storage medium of claim 34, wherein the method further comprises performing a garbage-collection operation to remove excess or unused resources from the cache or set resources as purgeable if those resources are over the purgeable age.

### Claim 36 (depends on 35)

The computer-readable storage medium of claim 35, wherein upon receiving a resource query for resources in a given subcache after the resource has been added to the cache or removed from the cache, the method further comprises performing a corresponding filtering query on the cache and a corresponding filtering query on any intervening subcaches to update the given subcache to account for the added or removed resource.
