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

improve Dhall.Map.traverseWithKey performance #2589

Merged

Conversation

imuli
Copy link
Contributor

@imuli imuli commented May 24, 2024

traverseWithKey currently calls fromList, which creates a new list of keys (and calls nubOrd on it). this is unnecessary, because a traversal doesn't change the keys.

I haven't done any benchmarking of traverseWithKey specifically, but this change reduces my overall parse+typecheck+inject+normalize+extract time by ~20%.

traverseWithKey currently calls fromList,
which creates a new list of keys (and calls nubOrd on it).
this is unnecessary, because a traversal doesn't change the keys.
@winitzki
Copy link
Collaborator

Currently the macos build seems to be broken. I've been trying randomly poking around to fix it but I don't really know what I'm doing in this build system. #2586 Anyone has any ideas? The failure is around libsodium and has to do with macos architectures (x86 vs arm).

@imuli
Copy link
Contributor Author

imuli commented Jun 3, 2024

Thank you @winitzki!

@Gabriella439 Gabriella439 enabled auto-merge (squash) June 12, 2024 02:48
@Gabriella439 Gabriella439 merged commit 402fedc into dhall-lang:main Jun 12, 2024
7 checks passed
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