-
Notifications
You must be signed in to change notification settings - Fork 216
Open
Labels
memoryrelated to memory usagerelated to memory usageperformancePotential performance improvementPotential performance improvement
Description
The original motivation why we introduced the infer_expression_type was because we wanted to avoid that ty ever infers the same expression twice and that this is important for performance. astral-sh/ruff#19436 shows that this might not be the case (and it's a very naive approach at removing the query). Most benchmarks are neutral with the exception of sympy (11% regresssion).
Removing the query is motivated by the fact that the cached query results can take up up to 3GB of memory (struct fields + metadata) in large projects (~10% of overall memory usage) and this is without accounting for the Expression ingredients (another 500MB).
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
memoryrelated to memory usagerelated to memory usageperformancePotential performance improvementPotential performance improvement