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

Idea: Shrink sign_counts array to fit into a single cache line. #86

Open
Melirius opened this issue May 29, 2024 · 0 comments
Open

Idea: Shrink sign_counts array to fit into a single cache line. #86

Melirius opened this issue May 29, 2024 · 0 comments

Comments

@Melirius
Copy link
Collaborator

Only part of the array is used in VP8 decoding:

  • [0][0] - in 7x7 AC (1 element),
  • [0][calc_sign_index(uncertainty2) + 1] - in DC (3 elements),
  • [calc_sign_index(best_prior as i16)][best_prior_bit_len] - in edge AC (2 * 10 for sign_index=1,2 and best_prior_bit_len in [1,10], 1 additional for sign_index=0: [0][0] for 0 prior, and [0][10] for 0 (prior as i16) but prior != 0)

It gives 25 2-byte branches used instead of 36 in current array.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant