Skip to content

Un-gate the kernel-cache eviction API from experimental-tune #268

Description

@elibol

The 0.3.1 kernel-cache eviction API (cutile::tile_kernel::{clear_kernel_cache, evict_kernel, retain_kernels}) works as documented for the case it was built for: drop the engine, synchronize, evict, reload, retry. Downstream use shows the same need outside tuning: a long-running serving engine that JITs many specializations (variable sequence lengths, per-request generics) hits the same unbounded L1 growth and needs the same quiesce-then-evict discipline, without opting into the search machinery.

Ask. Un-gate the three eviction functions from experimental-tune. Either make them unconditional or put them behind a narrow feature such as kernel-cache-management, and leave experimental-tune gating only the Objective/Searcher/TrialLog surface (it can imply the narrow feature so existing tuner users see no change).

Keep as is.

  • The functions stay unsafe with the contract as written: the caller quiesces every stream that could still reference a cached kernel before evicting.
  • clear_kernel_cache_for_tests stays #[doc(hidden)].
  • Return counts and the re-entrancy-safe retain_kernels snapshot are unchanged.

Scope. Feature/cfg attributes, the doc paragraph that frames eviction as a tuning-only concern, the book paragraph in the autotuning guide that says the functions are gated, and a changelog entry. Additive; no signature changes.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions