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

Replace memory writes with mask in sse4.1 aom/vpx parsing, fix edge case #588

Merged
merged 1 commit into from
Mar 11, 2022

Conversation

redzic
Copy link
Collaborator

@redzic redzic commented Mar 11, 2022

If a single chunk had >=10,000 frames, there would be a singular line of text causing the sse4.1 code to report a garbage value, which happened because of an invalid assumption that the number of digits of the buffered frames and encoded frames is always the same. This also affected the fallback function but in a non-obnoxious way, causing it to just return None in this edge case instead of a garbage value.

This PR fixes that issue, along with replacing the very suboptimal writes back to main memory (which caused parse_encoded_frames to be marked as unsafe) in the sse4.1 code with significantly more sensible masking of xmm registers based on the number of digits found.

@mergify mergify bot merged commit 9242b03 into master-of-zen:master Mar 11, 2022
@redzic redzic deleted the fix-parsing branch March 12, 2022 05:12
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

Successfully merging this pull request may close these issues.

None yet

2 participants