Closed Bug 1298217 Opened 8 years ago Closed 8 years ago

Move some code to the entry actions for MDSM

Categories

(Core :: Audio/Video: Playback, defect, P3)

defect

Tracking

()

RESOLVED FIXED
mozilla51
Tracking Status
firefox51 --- fixed

People

(Reporter: jwwang, Assigned: jwwang)

References

Details

Attachments

(11 files)

58 bytes, text/x-review-board-request
kaku
: review+
Details
58 bytes, text/x-review-board-request
kaku
: review+
Details
58 bytes, text/x-review-board-request
kaku
: review+
Details
58 bytes, text/x-review-board-request
kaku
: review+
Details
58 bytes, text/x-review-board-request
kaku
: review+
Details
58 bytes, text/x-review-board-request
kaku
: review+
Details
58 bytes, text/x-review-board-request
kaku
: review+
Details
58 bytes, text/x-review-board-request
kaku
: review+
Details
58 bytes, text/x-review-board-request
kaku
: review+
Details
58 bytes, text/x-review-board-request
kaku
: review+
Details
58 bytes, text/x-review-board-request
kaku
: review+
Details
A step forward to bug 1295892.

By moving code to the entry actions, it is easier to define the responsibility of each state.
Attachment #8785807 - Flags: review?(kaku)
Attachment #8785808 - Flags: review?(kaku)
Attachment #8785809 - Flags: review?(kaku)
Attachment #8785810 - Flags: review?(kaku)
Attachment #8785811 - Flags: review?(kaku)
Attachment #8785812 - Flags: review?(kaku)
Attachment #8785813 - Flags: review?(kaku)
Attachment #8785814 - Flags: review?(kaku)
Attachment #8785815 - Flags: review?(kaku)
Attachment #8785816 - Flags: review?(kaku)
Attachment #8785817 - Flags: review?(kaku)
Assignee: nobody → jwwang
Blocks: 1295892
Comment on attachment 8785807 [details]
Bug 1298217. Part 1 - Move the code about decoding metadata to the entry action of DECODER_STATE_DECODING_METADATA.

https://reviewboard.mozilla.org/r/74870/#review73000
Attachment #8785807 - Flags: review?(kaku) → review+
Comment on attachment 8785808 [details]
Bug 1298217. Part 2 - Move some code to the entry action of DECODER_STATE_DORMANT.

https://reviewboard.mozilla.org/r/74872/#review73002
Attachment #8785808 - Flags: review?(kaku) → review+
Comment on attachment 8785809 [details]
Bug 1298217. Part 3 - Remove the check for IsShutdown() from CheckIfDecodeComplete() because it is called only when mState is DECODING or BUFFERING.

https://reviewboard.mozilla.org/r/74874/#review73004
Attachment #8785809 - Flags: review?(kaku) → review+
Comment on attachment 8785810 [details]
Bug 1298217. Part 4 - Remove the call to DispatchDecodeTasksIfNeeded() from CheckIfDecodeComplete() because we've decoded all samples.

https://reviewboard.mozilla.org/r/74876/#review73006
Attachment #8785810 - Flags: review?(kaku) → review+
Comment on attachment 8785811 [details]
Bug 1298217. Part 5 - Move the call to |SetState(DECODER_STATE_COMPLETED)| out of CheckIfDecodeComplete() to make it easier to move more code to entry actions.

https://reviewboard.mozilla.org/r/74878/#review73008
Attachment #8785811 - Flags: review?(kaku) → review+
Comment on attachment 8785812 [details]
Bug 1298217. Part 6 - Move some code to the entry action of DECODER_STATE_COMPLETED.

https://reviewboard.mozilla.org/r/74880/#review73010
Attachment #8785812 - Flags: review?(kaku) → review+
Comment on attachment 8785813 [details]
Bug 1298217. Part 7 - Assert |mState != DECODER_STATE_DECODING| in StartDecoding().

https://reviewboard.mozilla.org/r/74882/#review73012
Attachment #8785813 - Flags: review?(kaku) → review+
Comment on attachment 8785814 [details]
Bug 1298217. Part 8 - Move some code to the entry action of DECODER_STATE_DECODING.

https://reviewboard.mozilla.org/r/74884/#review73016
Attachment #8785814 - Flags: review?(kaku) → review+
Comment on attachment 8785815 [details]
Bug 1298217. Part 9 - Assert |mState == DECODER_STATE_DECODING| in MaybeStartBuffering() which is only called in the DECODER_STATE_DECODING case of RunStateMachine().

https://reviewboard.mozilla.org/r/74886/#review73018
Attachment #8785815 - Flags: review?(kaku) → review+
Comment on attachment 8785816 [details]
Bug 1298217. Part 10 - Assert |mState == DECODER_STATE_DECODING| in StartBuffering() which is only called by MaybeStartBuffering() which also asserts that.

https://reviewboard.mozilla.org/r/74888/#review73020
Attachment #8785816 - Flags: review?(kaku) → review+
Comment on attachment 8785817 [details]
Bug 1298217. Part 11 - Move some code to the entry action of DECODER_STATE_BUFFERING.

https://reviewboard.mozilla.org/r/74890/#review73022
Attachment #8785817 - Flags: review?(kaku) → review+
Thanks for the review!
Pushed by jwwang@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/7ec8d889e021
Part 1 - Move the code about decoding metadata to the entry action of DECODER_STATE_DECODING_METADATA. r=kaku
https://hg.mozilla.org/integration/autoland/rev/4e6e02e3ef1a
Part 2 - Move some code to the entry action of DECODER_STATE_DORMANT. r=kaku
https://hg.mozilla.org/integration/autoland/rev/55d0d97dccd1
Part 3 - Remove the check for IsShutdown() from CheckIfDecodeComplete() because it is called only when mState is DECODING or BUFFERING. r=kaku
https://hg.mozilla.org/integration/autoland/rev/495056dc8ed5
Part 4 - Remove the call to DispatchDecodeTasksIfNeeded() from CheckIfDecodeComplete() because we've decoded all samples. r=kaku
https://hg.mozilla.org/integration/autoland/rev/e3989f634b74
Part 5 - Move the call to |SetState(DECODER_STATE_COMPLETED)| out of CheckIfDecodeComplete() to make it easier to move more code to entry actions. r=kaku
https://hg.mozilla.org/integration/autoland/rev/b06577b71a3e
Part 6 - Move some code to the entry action of DECODER_STATE_COMPLETED. r=kaku
https://hg.mozilla.org/integration/autoland/rev/8d191355cb13
Part 7 - Assert |mState != DECODER_STATE_DECODING| in StartDecoding(). r=kaku
https://hg.mozilla.org/integration/autoland/rev/21020a8a6ea7
Part 8 - Move some code to the entry action of DECODER_STATE_DECODING. r=kaku
https://hg.mozilla.org/integration/autoland/rev/a10febe05935
Part 9 - Assert |mState == DECODER_STATE_DECODING| in MaybeStartBuffering() which is only called in the DECODER_STATE_DECODING case of RunStateMachine(). r=kaku
https://hg.mozilla.org/integration/autoland/rev/c48f06ea74fe
Part 10 - Assert |mState == DECODER_STATE_DECODING| in StartBuffering() which is only called by MaybeStartBuffering() which also asserts that. r=kaku
https://hg.mozilla.org/integration/autoland/rev/57a2f1d5bc60
Part 11 - Move some code to the entry action of DECODER_STATE_BUFFERING. r=kaku
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: