-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
struct Rav1dFrameData::{cur,prev}_segmap
: Arc
ify with an `Option<…
…DisjointMutArcSlice<u8>>` (#971) * Fixes `{cur,prev}_segmap{,_ref}` fields of #713. * Fixes `segmap{,_pool}` fields of #641. To do this, I first added a few things to `DisjointMut`: * e495e00: Allowing `T: ?Sized` so `DisjointMut<[_]>` is possible. This didn't really require any changes other than expanding the bounds. * e495e00: `impl AsMutPtr for [_]` * 631ce49: `impl AsMutPtr for Box<[_]>` * 704fe93: add `fn DisjointMut::new` to create a non-`default()` `DisjointMut` from a pre-existing `T` * 712c759: Add `DisjointMutArcSlice`, which is an `Arc<DisjointMut<[_]>>` in release mode, and an `Arc<DisjointMut<Box<[_]>>>` in debug mode. In release mode, `DisjointMut` is `#[repr(transparent)]`, so we can do this and safe allocations and indirections. And in debug mode, the overhead is fine. Then this `Arc`ifies the `segmap`s with the above `DisjointMutArcSlice<u8>`.
- Loading branch information
Showing
6 changed files
with
201 additions
and
138 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
Oops, something went wrong.