Hey everyone. I wrote a blog post on why tsgo uses so much memory. I had a hunch it was related to overhead due to multi-threading (which is true), so I poked around and learned some things: - tsgo creates a typechecker per thread - each .ts file is assigned to one typechecker - each typechecker has its own state (types, symbols, etc.) - this state is not shared because it's expensive to synchronize it across threads - the typechecker allocates memory for types and literally never frees it So the end result is basically that 2 threads can end up doing the same work and allocating memory for the same types.…