---
name: "Tie::Cache::LRU::Array"
section: "3pm"
platform: "linux"
package: "libtie-cache-lru-perl"
version: "20150301-3"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/Tie::Cache::LRU::Array"
---

# Tie::Cache::LRU::Array(3pm)

Tie::Cache::LRU implemented using arrays

## NAME

Tie::Cache::LRU::Array - Tie::Cache::LRU implemented using arrays

## SYNOPSIS

```
  use Tie::Cache::LRU::Array;
  tie %cache, 'Tie::Cache::LRU::Array', 500;
  ...the rest is as Tie::Cache::LRU...
```

## DESCRIPTION

This is an alternative implementation of Tie::Cache::LRU using Perl arrays and built-in array operations instead of a linked list.  The theory is that even though the algorithm employed is more expensive, it will still be faster for small cache sizes (where small \<= ??)  because the work is done inside perl (ie. higer big O, lower constant).  If nothing else, it should use less memory.

## AUTHOR

Michael G Schwern \<schwern@pobox.com\>

## SEE ALSO

Tie::Cache::LRU, Tie::Cache::LRU::Virtual, Tie::Cache
