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

Switch immutables.Map and pyrsistent.PMap to constantdict #832

Draft
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

matthiasdiener
Copy link
Collaborator

@matthiasdiener matthiasdiener commented Mar 6, 2024

This currently a proof-of-concept.

Edit: I removed the previous performance results, they were likely caused by some kind of caching of kernels.

TODOs:

  • add mutate support to constantdict (and perhaps immutabledict) (or change the single mutate call)
  • Change from constantdict import constantdict as Map => from constantdict import constantdict
  • Perhaps remove sorted calls (likely in a separate PR)
  • This needs a new pytools release
  • Benchmark this

Please squash

@matthiasdiener
Copy link
Collaborator Author

This is ready for a first look @inducer. It will need a new pytools release for the CI.

Copy link
Owner

@inducer inducer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this generally looks OK. Flagged some minor wrinkles.

loopy/codegen/__init__.py Show resolved Hide resolved
t.py Outdated Show resolved Hide resolved
@inducer
Copy link
Owner

inducer commented Mar 25, 2024

Please don't remove the sorted() calls, FWIW.

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.

2 participants