current location: Home > download site > Library download > Other libraries > PHP library for caching
PHP library for caching
Classify: Library download / Other libraries | Release time: 2017-12-14 | visits: 1268 |
Download: 60 |
Latest Downloads
Fantasy Aquarium
Girls Frontline
Wings of Stars
Little Flower Fairy Fairy Paradise
Restaurant Cute Story
Shanhe Travel Exploration
Love and Producer
The most powerful brain 3
Odd Dust: Damila
Young Journey to the West 2
24 HoursReading Leaderboard
- 1 How to Extend and Override Django Admin Templates Without Replacing Them?
- 2 How to Combine Two Arrays in JavaScript?
- 3 dynexwcui.exe - What is dynexwcui.exe?
- 4 How to Override Styles in a Shadow-Root Element?
- 5 How to Create a Dynamic Pivot Table in MySQL with Integer User IDs?
- 6 dtvimpex.dll - What is dtvimpex.dll?
- 7 Why does "go module @latest found but does not contain package" Error Occur When Using github.com/mkideal/cli?
- 8 Why Do Lambda Expressions Sometimes Fail to Pass the Correct Parameters When Connecting Slots in PyQt?
- 9 How to Dynamically Create CSS @-keyframes Animations Based on Server Responses?
- 10 How to Select a Label with a Specific 'for' Attribute in CSS?
- 11 Why Can't I Assign to a Struct Field in a Map?
- 12 How to Retrieve the Value of a Submitted Button in a Form with Multiple Buttons?
- 13 When Should You Use Getters/Setters Instead of Public Data Members?
- 14 Who is Running My PHP Script?
- 15 Why Am I Getting "SMTP Error: Could Not Authenticate" When Sending Emails with PHPMailer?
Latest Tutorials
-
- Go language practical GraphQL
- 2011 2024-04-19
-
- 550W fan master learns JavaScript from scratch step by step
- 3430 2024-04-18
-
- Getting Started with MySQL (Teacher mosh)
- 1812 2024-04-07
-
- Mock.js | Axios.js | Json | Ajax--Ten days of quality class
- 2626 2024-03-29
Cache refers to a memory that can perform high-speed data exchange. It exchanges data with the CPU before the memory, so the speed is very fast. L1 Cache (level one cache) is the first level cache of the CPU. The capacity and structure of the built-in L1 cache have a greater impact on the performance of the CPU. However, the cache memory is composed of static RAM and has a complicated structure. When the CPU die area cannot be too large, the capacity of the L1 cache is not sufficient. Probably made too big. Generally, the capacity of L1 cache is usually 32-256KB. L2 Cache (second level cache) is the second level cache of the CPU, which is divided into internal and external chips. The internal on-chip L2 cache runs at the same speed as the main frequency, while the external L2 cache only runs at half the main frequency. The L2 cache capacity will also affect the performance of the CPU. The principle is that the bigger the better. The L2 cache of ordinary desktop CPUs is generally 128KB to 2MB or higher. The L2 cache of CPUs used in notebooks, servers and workstations can be up to 1MB- 3MB.
The cache is only a copy of a small amount of data in the memory, so when the CPU looks for data in the cache, it may not be found (because the data is not copied from the memory to the cache). At this time The CPU will still go to the memory to find data, which will slow down the system, but the CPU will copy the data to the cache so that it does not have to be retrieved from the memory next time. As time changes, the most frequently accessed data is not static. That is to say, the data that was not frequent just now needs to be accessed frequently now. The data that was the most frequently accessed just now is no longer frequent, so It is said that the data in the cache should be frequently replaced according to a certain algorithm, so as to ensure that the data in the cache is accessed most frequently.
<?php namespace Cake\Cache; use Cake\Cache\Engine\NullEngine; use Cake\Core\ObjectRegistry; use Cake\Core\StaticConfigTrait; use InvalidArgumentException; use RuntimeException; class Cache { use StaticConfigTrait; protected static $_dsnClassMap = [ 'apc' => 'Cake\Cache\Engine\ApcEngine', 'file' => 'Cake\Cache\Engine\FileEngine', 'memcached' => 'Cake\Cache\Engine\MemcachedEngine', 'null' => 'Cake\Cache\Engine\NullEngine', 'redis' => 'Cake\Cache\Engine\RedisEngine', 'wincache' => 'Cake\Cache\Engine\WincacheEngine', 'xcache' => 'Cake\Cache\Engine\XcacheEngine', ]; protected static $_enabled = true; protected static $_groups = []; protected static $_registry; public static function getRegistry() { if (!static::$_registry) { static::$_registry = new CacheRegistry(); } return static::$_registry; }