-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Calyx-utils] Overhaul
GlobalPositionTable
+ a bunch of CI nonsense (…
…#2377) A quick touch up of the `GlobalPositionTable` to avoid UB without getting too fancy. Main changes are use of `boxcar::Vec` instead of the standard library Vec, so that we can now have lock-free concurrent appends and accesses. This fits our use-case since we never de-allocate files & positions and frees us from all the issues associated with using locks. Since we're not using locks, we also don't need any unsafe to extend lifetimes, and since `boxcar::Vec` doesn't reallocate stored elements, we don't need to box the stored stuff. I also use `LazyLock` instead of `lazy_static!` which is easier to deal with. The end result is a global position table that can be accessed through associated functions on the `GlobalPositionTable` type, rather than methods on an instance. I also changed the `String`s stored by `File` to `Box<str>`, because we don't ever mutate them. --- In the process of this, I ran face first in CI issues. Turns out that because some of the tests run in the docker container, they aren't actually building using the version of rust in `rust-toolchain.toml` and instead were using the version of rust from the container (1.76). This broke things since `LazyLock` was only stabilized in 1.80. I had a real fight with the CI because it turns out that using the standard actions in the docker container is not a straightforward as one would like. I'll skip a recount of the entire ordeal---peruse the commits to witness my pain---but I resolved things and made these tests consistent with the rest of CI by specifically pulling the toolchain file before running the rust install action. The end result is that even the docker container tests do respect the indicated rust version, and we should be able to bump the version of rust used by _EVERYTHING_ (if this isn't true I may scream) by updating the file.
- Loading branch information
1 parent
1505e5d
commit 37d90d9
Showing
10 changed files
with
107 additions
and
104 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.