-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Hash tables are large and must be persisted in memory. Further, all these tables are computed at runtime on the heap. This won't scale as more languages are added. Ideally as much is done in the stack as possible.
A naive linear search should be implemented that does not split by whitespace.
An alternative, a build script to format the words file as a static Rust file with a hardcoded lookup table, was considered, but this will still take up more memory compared to a string. Considering this lookup needs to happen rarely, while the table will be in-memory for the duration of the program, it's best to optimize for space at the cost of time in this case.
Metadata
Metadata
Assignees
Labels
No labels