Expand description
Structs§
- Regular data structures need to be protected by a mutex.
- Atomics can be safely shared between threads.
Functions§
- dfs 🔒Flood fill that explores the connected squares in the grid.
- fill_
row 🔒Compute the knot hash for a row and expand into an array of bytes. - Slightly tweaked version of the code from Day 10 that always performs 64 rounds.
- Parallelize the hashing as each row is independent.
- worker 🔒Each worker thread chooses the next available index then computes the hash and patches the final vec with the result.