+++ title = 'FFmpeg development notes' +++ ## Websites * [ffmpeg.org](https://ffmpeg.org/) * [code.ffmpeg.org](https://code.ffmpeg.org/FFmpeg/FFmpeg) - code forge * [trac.ffmpeg.org](https://trac.ffmpeg.org/query?status=!closed&type=defect&order=id&desc=1) - bug tracker, mostly abandoned in favor of forgejo * [ffmpeg-devel mailing list](https://lists.ffmpeg.org/mailman3/lists/ffmpeg-devel.ffmpeg.org/) - development mailing list, mostly abandoned in favor of forgejo * [ffmpeg-devel IRC](https://libera.catirclogs.org/ffmpeg-devel/2026-06) - development chat, very active * [patchwork.ffmpeg.org](https://patchwork.ffmpeg.org/project/ffmpeg/list/) - archive of patches sent to ffmpeg-devel ## Documentation * Command-line tools, filters, etc: https://ffmpeg.org/ffmpeg-all.html * Component libraries: https://ffmpeg.org/doxygen/trunk/index.html ## Building List all compile options: ```sh $ ./configure --help | vim - ``` Quick development build; takes about 90 seconds on an M1 MacBook Air: ```sh $ ./configure --disable-optimizations --disable-asm $ make -j $(nproc) $ make -j $(sysctl -n hw.logicalcpu) ``` Troubleshooting build: ```sh $ ./configure --disable-optimizations --assert-level=2 --toolchain=clang-asan $ ./configure --disable-optimizations --assert-level=2 --toolchain=clang-asan-ubsan ``` `--enable-memory-poisoning` makes `av_malloc` and friends basically just do `memset(ptr, 0x2a, size)`. Does not add any asan-style bounds checking. ## Regression testing FATE documentation: https://ffmpeg.org/fate.html, TLDR: ```sh $ ./configure --disable-optimizations --assert-level=2 --toolchain=clang-asan --samples=$HOME/Proj/FFmpeg-FATE $ make $ make fate-rsync $ make fate ``` ## Benchmarking checkasm docs: https://checkasm.videolan.me/ Build within FFmpeg: ```sh $ make checkasm ``` List tests: ```sh $ ./tests/checkasm/checkasm --list-tests | sort | vim - ``` The easiest way to see what test calls what functions is to check the source code:
[`-> tests/checkasm/checkasm.c`](https://code.ffmpeg.org/FFmpeg/FFmpeg/src/branch/master/tests/checkasm/checkasm.c). Example: ```sh $ ./tests/checkasm/checkasm --bench --test=vf_bwdif ```
Output ``` checkasm: - CPU: Intel(R) Core(TM) i7-7700HQ CPU @ 2.80GHz (000906E9) - Timing source: x86 (rdtsc) - Bench duration: 1000 µs per function (4003730 cycles) - Random seed: 2684063072 C: - vf_bwdif.bwdif8 [OK] - vf_bwdif.bwdif10 [OK] - vf_bwdif.bwdif8.line3 [OK] - vf_bwdif.bwdif8.edge [OK] - vf_bwdif.bwdif8.intra [OK] SSE2: - vf_bwdif.bwdif8 [OK] - vf_bwdif.bwdif10 [OK] SSSE3: - vf_bwdif.bwdif8 [OK] - vf_bwdif.bwdif10 [OK] AVX2: - vf_bwdif.bwdif8 [OK] - vf_bwdif.bwdif10 [OK] checkasm: all 6 tests passed Benchmark results: name cycles (vs ref) bwdif8_c: 28876.2 bwdif8_sse2: 1056.1 (25.12x) bwdif8_ssse3: 870.5 (22.92x) bwdif8_avx2: 550.6 (40.40x) bwdif8.edge.s0.p0_c: 1373.2 bwdif8.edge.s0.p1_c: 1310.2 bwdif8.edge.s1.p0_c: 5368.5 bwdif8.edge.s1.p1_c: 5824.8 bwdif8.intra_c: 584.1 bwdif8.line3.rnd.p0_c: 40020.9 bwdif8.line3.rnd.p1_c: 30286.6 bwdif10_c: 27988.9 bwdif10_sse2: 935.6 (27.51x) bwdif10_ssse3: 864.2 (27.04x) bwdif10_avx2: 594.3 (36.53x) ```