Lines Matching defs:cache

253         PyObject *cache =
257 // cache, so we'll return a "borrowed reference".
258 Py_XDECREF(cache);
259 return cache;
435 // Remove from strong cache
441 // Remove from weak cache
651 * was constructed from the cache, because from-cache objects will hit the
652 * unpickling process's cache, whereas no-cache objects will bypass it.
719 * integer number of hours, etc. We will keep a cache so that we construct
722 * Possibly this should be replaced with an LRU cache so that it's not possible
726 * fills the cache with ~450 timedeltas for a total size of ~12kB.
2265 // Functions for cache handling
2297 /* Frees all nodes at or after a specified root in the strong cache.
2299 * This can be used on the root node to free the entire cache or it can be used
2316 /* Removes a node from the cache and update its neighbors.
2318 * This is used both when ejecting a node from the cache and when moving it to
2319 * the front of the cache.
2342 * This traverses the strong cache until it finds a matching key and returns a
2345 * root may be NULL, indicating an empty cache.
2366 /* Ejects a given key from the class's strong cache, if applicable.
2389 /* Moves a node to the front of the LRU cache.
2391 * The strong cache is an LRU cache, so whenever a given node is accessed, if
2392 * it is not at the front of the cache, it needs to be moved there.
2414 /* Retrieves a ZoneInfo from the strong cache if it's present.
2417 * the front of the LRU cache and return a new reference to it. It returns NULL
2418 * if the key is not in the cache.
2420 * The strong cache is currently only implemented for the base class, so this
2421 * always returns a cache miss for subclasses.
2427 return NULL; // Strong cache currently only implemented for base class
2441 /* Inserts a new key into the strong LRU cache.
2443 * This function is only to be used after a cache miss — it creates a new node
2444 * at the front of the cache and ejects any stale entries (keeping the size of
2445 * the cache to at most ZONEINFO_STRONG_CACHE_MAX_SIZE).
2476 /* Clears all entries into a type's strong cache.
2478 * Because the strong cache is not implemented for subclasses, this is a no-op
2557 PyDoc_STR("Clear the ZoneInfo cache.")},
2560 PyDoc_STR("Get a new instance of ZoneInfo, bypassing the cache.")},