Repository navigation
Reversibility data: big writes, temporary directory, clean Ctrl+C - #562
Merged
JeromeMartinez merged 4 commits intoNov 29, 2026
Merged
Conversation
retokromer
approved these changes
Nov 29, 2026
JeromeMartinez
force-pushed
the
reversibility-temp-file
branch
from
November 29, 2026 18:29
4ce1f33 to
e75086b
Compare
Small writes are slow on some network storage, and the reversibility data of each file was written separately and in order, so the analysis of the files was limited by the write latency. Write errors are now reported, also the ones known only when the file is closed.
Default name with the process identifier in the temporary directory of the system: small writes are slow on some network storage, and nothing is left next to the output if the process is killed. Also with --display-command, the displayed command deletes the temporary files after their use. Next to the output if there is no usable temporary directory. The tests set the temporary directory to theirs, get the name of the file from the displayed command, and redirect the input and outputs of all the commands of the displayed command.
The analysis stops after the files being parsed and the encoding after the end of FFmpeg, which also receives Ctrl+C, then the reversibility data file is deleted and the output file is reported as incomplete if it was being written. Ctrl+C again, or when no intermediate file exists, terminates as before. The stop request is in the core, so another user interface can request it.
A write error of the beginning of a decoded file was ignored. The log file was written without checking the result, and a log file which could not be overwritten was not reported.
JeromeMartinez
force-pushed
the
reversibility-temp-file
branch
from
November 29, 2026 21:31
e75086b to
1fc96cb
Compare
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.
On a network share, the analysis of a DPX sequence was about 25 to 50 files/s instead of hundreds: the reversibility data of each file is written in order, and each small write took 15 to 19 ms on the share, so the analysis was limited to about 50 files/s whatever the count of threads.
--display-command: the displayed command now ends with&& rmof the temporary files (reversibility data file, file lists), as it already did with--output-version 2. Next to the output only if there is no usable temporary directory.-r/--rawcooked-file-nameis unchanged.Global.Stop_Requested), so another user interface can use it.--logfile (write and close not checked, and a read-only existing file overwritten with-ywas silently not written).Tests:
helpers.shsets the temporary directory to the one of the test suite (deleted at the end) and gets the name of the reversibility data file from the displayed command; the stale reversibility data file checks ofreversibilityfile.shand the long path test provide the file name with-r;vulkan.shkeeps the temporary files for its second variant.run_ffmpeggroups the displayed command so its redirections are for all the commands (with&& rm, FFmpeg read the standard input, i.e. the file list of the test).