Overview of the Issue
The addition of the ICU regular expression in #13391 has led to a small but nonetheless significant memory increase in components that don't need the evalengine in the end. This applies to things like vtorc, vttablet etc.
Those components do end up importing the evalengine through long dependency chains and also more directly through utility functions like ToInt64 / ToUint64 (https://github.com/vitessio/vitess/blob/main/go/vt/vtgate/evalengine/api_types.go#L60-L96).
But when the evalengine is loaded, we also end up loading the regular expression ICU data files. If we move to lazy loading these files on actual usage, we save additional memory.
Reproduction Steps
The slices.Insert allocation shown here is coming mostly from the icuregex package.
Binary Version
Operating System and Environment details
Log Fragments
No response
Overview of the Issue
The addition of the ICU regular expression in #13391 has led to a small but nonetheless significant memory increase in components that don't need the
evalenginein the end. This applies to things likevtorc,vttabletetc.Those components do end up importing the
evalenginethrough long dependency chains and also more directly through utility functions likeToInt64/ToUint64(https://github.com/vitessio/vitess/blob/main/go/vt/vtgate/evalengine/api_types.go#L60-L96).But when the
evalengineis loaded, we also end up loading the regular expression ICU data files. If we move to lazy loading these files on actual usage, we save additional memory.Reproduction Steps
The
slices.Insertallocation shown here is coming mostly from theicuregexpackage.Binary Version
Operating System and Environment details
Log Fragments
No response