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

Consistent setup for round trip and inverse transform tests #3273

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion src/asm/shared/transform/inverse.rs
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,10 @@ pub mod test {
for sub_h in 0..sub_h_iterations {
let mut src_storage = [T::zero(); 64 * 64];
let src = &mut src_storage[..tx_size.area()];
let mut dst = Plane::from_slice(&[T::zero(); 64 * 64], 64);
let mut dst = Plane::from_slice(
&[T::zero(); 64 * 64][..tx_size.area()],
tx_size.width(),
);
let mut res_storage: Aligned<[MaybeUninit<i16>; 64 * 64]> =
unsafe { Aligned::uninitialized() };
let res = &mut res_storage.data[..tx_size.area()];
Expand Down
6 changes: 2 additions & 4 deletions src/transform/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -461,9 +461,8 @@ mod test {
let coeff_area: usize = av1_get_coded_tx_size(tx_size).area();
let mut src_storage = [T::cast_from(0); 64 * 64];
let src = &mut src_storage[..tx_size.area()];
// dynamic allocation: test
let mut dst = Plane::from_slice(
&vec![T::cast_from(0); tx_size.area()],
&[T::zero(); 64 * 64][..tx_size.area()],
tx_size.width(),
);
let mut res_storage = [0i16; 64 * 64];
Expand Down Expand Up @@ -500,8 +499,7 @@ mod test {

let mut src_storage = [T::cast_from(0); 4 * 4];
let src = &mut src_storage[..];
// dynamic allocation: test
let mut dst = Plane::from_slice(&vec![T::cast_from(0); 4 * 4], 4);
let mut dst = Plane::from_slice(&[T::cast_from(0); 4 * 4], 4);
let mut res_storage = [0i16; 4 * 4];
let res = &mut res_storage[..];
let mut freq_storage = [T::Coeff::cast_from(0); 4 * 4];
Expand Down
Loading