-
Notifications
You must be signed in to change notification settings - Fork 570
Description
Description
On our project of 9877 source files (including libs), the IDE quickly consumes so much memory that it becomes hard to work with.
On my 32GB Apple M2, it will be using over 20GB of memory in under a minute. It then starts to slow down until common commands, like looking up a type definition can take over 30 seconds.
To Reproduce
This is not simple as our project is not open source but I believe it would be likely to happen on any sufficiently large project.
Expected behavior
The IDE should limit it's memory usage and commands should execute within a few seconds.
Additional context
From tinkering with the IDE, I have found that the forcing of the result in populateVolatileStateSTM
and possibly populateVolatileStateSync
as well, seems to be responsible. I will make a draft PR to explain in more detail.
I was also wondering if running each command on a new thread and setting allocation limits and/or a timeout for it might help by limiting the resources used by abnormally greedy requests.
PureScript version
0.15.15