-
Notifications
You must be signed in to change notification settings - Fork 188
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Creating toplevels is unbearably slow #818
Comments
Does this refer to compile time of toplevel? Because it has been this slow since I started workig with the toplevel. A usual build of sketch would take about 4 minutes on my machine |
Yes. |
I had a look few weeks ago, I think this has something to do with debug info. |
Here are some timing stat on my machine.
|
With #902 here is the new profile
|
Thanks @hhugo ! I wanted to try your fix to get a feel of the change. But somehow just doing an
|
Ah in fact it's So for me it goes (for a bare toplevel) from 36s to 21s. Much better but still room for improvement ;-) |
How do you build your toplevel ? |
With that |
|
|
Thanks, this is consistent with what I see. I don't think the rest of the slowness is specific to toplevels, but rather a property of compiling large executables. Here is a profile without the
|
|
Ok thanks. So I guess maybe one should try to minimize the deps (also the resulting js file is |
@dbuenzli AFAIK, it won't help much. |
I've added some support for separate compilation of toplevels in #1380. It's not documented yet. I'm waiting for the next release of dune to maybe use it by default in the jsoo repo. |
The simple eval example takes 34s on my machine.
Also when using
--source-map-inline
memory usage on small examples is so big that it leads to SIGSEGVs.The text was updated successfully, but these errors were encountered: