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

Investigate alternate PHF algorithms for detecting keywords #51

Open
DimitrisJim opened this issue May 17, 2023 · 0 comments
Open

Investigate alternate PHF algorithms for detecting keywords #51

DimitrisJim opened this issue May 17, 2023 · 0 comments
Assignees
Labels
optimization Relating to optimizations for the Parser.

Comments

@DimitrisJim
Copy link
Member

This relates to a discussion on discord a while back.

The basic idea is that we can create a custom hash function for our keywords that's based on their structure (see related video in discussion) and possibly gain a good perf boost by replacing rust_phf. It still needs some investigating and bench-marking to actually evaluate if this would result in any significant improvement.

Afaik, this usually results in a bigger table being generated (for a keyword set of 30 odd functions, we might need a table of 1024 or 2048 elements mostly filled with None's) but that's a small price to pay considering this table should only be generated for the keywords and nothing else.

@DimitrisJim DimitrisJim self-assigned this May 17, 2023
@DimitrisJim DimitrisJim added the optimization Relating to optimizations for the Parser. label May 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
optimization Relating to optimizations for the Parser.
Projects
None yet
Development

No branches or pull requests

1 participant