Chemistry Reference and  Research
           
 
Periodic Table
- standard table
- large table
 
Chemical Elements
- by name
- by symbol
- by atomic number
 
Chemical Properties
 
Chemical Reactions
 
Organic Chemistry
 
Branches of Chemistry
Analytical chemistry
Biochemistry
Computational Chemistry
Electrochemistry
Environmental chemistry
Geochemistry
Inorganic chemistry
Materials science
Medicinal chemistry
Nuclear chemistry
Organic chemistry
Pharmacology
Physical chemistry
Polymer chemistry
Supramolecular Chemistry
Thermochemistry

Cache algorithms

Cache algorithms are optimizing instructions that a computer program can follow to manage a cache of information stored on the computer. Cache size is usually limited, and if the cache is full, the computer (that is, the programmer) must decide which items to keep and which to discard to make room for new items.

Examples of caching algorithms are:

  • LRU (least recently used) discards the least recently used items first. Obviously, this requires keeping track of what was used when.
  • LFU (least frequently used) counts, how often an item is needed. Those that are used least often are discarded first.


Other things to consider:

  • Price: keep those items that are expensive to obtain, e.g. those that take a long time to get.
  • Size: If items have different sizes, you may want to discard a large one to store several smaller ones.
  • Time: Some caches keep information that expires (e.g. a news cache, a DNS cache, or a web browser cache). The computer may discard items because they are expired. Depending on the size of the cache no further caching algorithm to discard items may be necessary.

External Links

01-04-2007 01:16:19
The contents of this article are licensed from Wikipedia.org under the GNU Free Documentation License. How to see transparent copy