starkware-libs / cairo

Cairo is the first Turing-complete language for creating provable programs for general computation.
Apache License 2.0
1.61k stars 501 forks source link

Manage LRU policy in all Salsa queries in LS #6130

Open mkaput opened 3 months ago

mkaput commented 3 months ago

All Salsa queries, used in AnalysisDatabase must have a set sensible LRU policy to keep memory usage limited. Check out how this is done in Rust Analyzer for reference.

https://github.com/salsa-rs/salsa/blob/754eea8b5f8a31b1100ba313d59e41260b494225/book/src/rfcs/RFC0004-LRU.md

This task is spin off #5355

orizi commented 3 months ago

Currently - there's no LRU in salsa - there's a preparation for it. For using LRU - an upgrade to salsa-rust-analyzer is required, or a move to salsa3.