Skip to content
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

Add support for +RTS/-RTS flags from GHC #65

Merged
merged 1 commit into from
Feb 13, 2018
Merged

Conversation

antew
Copy link
Contributor

@antew antew commented Feb 13, 2018

Enabling these flags allows for tuning the GHC runtime and can dramatically improve build times when a lot of files have to be recompiled, as well as improving performance on large case statements, the main benefit is reducing the time spent in the garbage collector.

This does require a version of elm-make compiled with the -rtsopts option to allow runtime control, if you try to run it on a version without that enabled you'll get the message:

$ elm-make src/elm/Main.elm +RTS -A128M -N128M -n8m -RTS
elm-make.exe: Most RTS options are disabled. Link with -rtsopts to enable them.

Some further information and related issues here:

The current version of elm-make does allow limited RTS options, for instance, you can use +RTS -s -RTS to profile a run.

@rtfeldman
Copy link
Owner

Cool, thanks @antew!

@rtfeldman rtfeldman merged commit 127e3bb into rtfeldman:master Feb 13, 2018
@rtfeldman
Copy link
Owner

Published as 4.5.0

@antew
Copy link
Contributor Author

antew commented Feb 13, 2018

Thank you @rtfeldman 🎉 🎈 !!

@andys8
Copy link

andys8 commented Mar 7, 2018

@antew @rtfeldman This will only work for self compiled elm compilers, right? Can we somehow enable the flag in the next version of the compiler? Otherwise the added argument in node-elm-compiler will not work for most of the users, right?

elm-lang/elm-make#164 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants