-
Notifications
You must be signed in to change notification settings - Fork 1
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
Type-level deletion quite slow #12
Comments
Commit 9c63c7d improves times somewhat (it takes ~ 1 minute to compile now) but I have no idea why. What I did was to pull out a type family invocation that was sitting in a typeclass argument. Instead of that, I evaluate the type family to a result designated with an equality constraint Why should that be faster? I have no idea and I would like to know. |
Commit c896bd2 adds a number of similar changes. The impact in compilation times is minor, but let's include them for consistency anyway. |
Here's the code sample without the insert, with a simple deletion:
It's taking ~ 29 seconds to compile. Removing the deletion ( 20 seconds of compilation time is a steep price to pay for removing a single branch. |
Yet another mystery. If I inline the
Then compilation time drops down to about ~ 8 seconds! For some reason having |
Even more mysterious. When I put
Compilation time goes back to ~ 8 seconds. It seems that having |
SO question and GHC ticket. |
The following core uses type-level deletion and
winnow
:It compiles in about 2 minutes, often more. But removing the
fromPhase2ToPhase3
function makes it compile in about 22 seconds!This seems to indicate that type-level deletion is way slower than insertion.
The text was updated successfully, but these errors were encountered: