libavc: reset i4_error_code to prevent early worker thread abort - #145
Merged
Merged
Conversation
The recon and deblocking worker threads abort when ps_dec->i4_error_code
is non-zero, a check added to fix a worker thread hang. The following
cases could cause them to abort early:
- ps_dec->i4_error_code was not cleared at the start of
ih264d_video_decode(), so an error set during a previous decode call
persisted across subsequent frames.
- ih264d_process_intra_mb() sets ERROR_INTRAPRED when an intra
prediction mode needs unavailable neighbors, although the mode is
already replaced with mode 0 (vertical). Before that check, this error
code was not read during decoding.
Reset ps_dec->i4_error_code to 0 at the start of ih264d_video_decode()
alongside ps_dec_op->u4_error_code, and stop setting ERROR_INTRAPRED.
Bug: 548241521
Bug: 565823098
Flag: EXEMPT BUGFIX
Test: atest CtsMediaV2TestCases:android.mediav2.cts.EncodeDecodeAccuracyTest#testEncodeDecodeAccuracyRGB
atest MctsMediaV2TestCases
atest MctsMediaDecoderTestCases
atest MctsMediaCodecTestCases
atest VtsHalMediaC2V1_0TargetVideoDecTest
Change-Id: I191ea7a6f6bd027fd3719db6581703c790eb40f2
(cherry picked from commit cfc33cb8eb9394274d1ca7a1c3193800d9356faa)
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The recon and deblocking worker threads abort when ps_dec->i4_error_code is non-zero, a check added to fix a worker thread hang. The following cases could cause them to abort early:
Reset ps_dec->i4_error_code to 0 at the start of ih264d_video_decode() alongside ps_dec_op->u4_error_code, and stop setting ERROR_INTRAPRED.
Bug: 548241521
Bug: 565823098
Flag: EXEMPT BUGFIX
Test: atest CtsMediaV2TestCases:android.mediav2.cts.EncodeDecodeAccuracyTest#testEncodeDecodeAccuracyRGB
atest MctsMediaV2TestCases
atest MctsMediaDecoderTestCases
atest MctsMediaCodecTestCases
atest VtsHalMediaC2V1_0TargetVideoDecTest
Change-Id: I191ea7a6f6bd027fd3719db6581703c790eb40f2 (cherry picked from commit cfc33cb8eb9394274d1ca7a1c3193800d9356faa)