# videolan/dav2d · xMas Performance Challenge by CodSpeed

> VideoLAN's AV2 decoder, from the team behind dav1d.

A small, portable, open-source decoder for AV2, the royalty-free successor to AV1. It follows dav1d, the AV1 decoder used in VLC, Firefox and Chrome.

AV2 is about five times more complex to decode than AV1, and hardware decoders are years away. Until then, every AV2 video in a browser or player is decoded in software, so dav2d's speed decides whether AV2 plays in real time on today's machines.

## Facts

- Repository: https://code.videolan.org/videolan/dav2d
- Language: C, with hand-written assembly (x86 SSE to AVX-512, Arm NEON, RISC-V)
- License: BSD-2-Clause
- Open: Tue Dec 1 to Dec 31, 23:59 UTC
- Measured: Walltime, on [CodSpeed Macro Runners Gen 2](https://codspeed.io/docs/features/macro-runners#amd-ryzen-9950x-x86_64)
- Frozen at upstream commit e0d6911

## Start

```sh
curl -fsSL https://xmas.codspeed.io/install.sh | sh
codspeed-xmas init videolan/dav2d
```

Windows: `powershell -ExecutionPolicy Bypass -c "irm https://xmas.codspeed.io/install.ps1 | iex"`. More in the [CLI README](https://github.com/CodSpeedHQ/codspeed/blob/main/crates/codspeed-xmas/README.md).

## What to make faster

- `bench/sintel-1080p-8bit.obu` (sintel-1080p-8bit): Inter-frame decoding speed: 33 frames of the Sintel trailer, 8-bit 4:2:0 random access, on one thread and on 4 threads.
- `bench/sintel-1080p-10bit.obu` (sintel-1080p-10bit): The same 33 Sintel frames in 10-bit, which run the high bit depth code paths.
- `bench/ed-1080p-8bit-intra.obu` (elephants-dream-1080p-8bit-intra): Intra decoding speed: 8 key frames of Elephants Dream, where every block is predicted from its own frame.
- `bench/ed-1080p-8bit-filmgrain.obu` (elephants-dream-1080p-8bit-filmgrain): Decoding speed with film grain synthesis: 17 frames of Elephants Dream with grain applied to every output frame.

## Rules

- Submit only with the CodSpeed CLI. Don't open issues or pull requests on videolan/dav2d.
- AI tools are allowed and encouraged.
- dav2d's own tests have to pass. CodSpeed runs the frozen benchmarks on every submission; your speedup sets your rank.
- When submissions close, entries that break tests, only game a benchmark or aren't of mergeable quality are set aside. In early January the dav2d maintainers choose what they want merged upstream.
- By submitting, you license your changes under dav2d's own license (BSD-2-Clause).
- Full rules: [official rules (PDF)](https://xmas.codspeed.io/official-rules.pdf)

## Prizes

- The top 3 entries the dav2d maintainers choose split dav2d's share of the $15,000 project pool (50% / 30% / 20%), paid in cash.
- $20,000 in total prizes across the challenge: https://xmas.codspeed.io/#prizes

## Maintainers

- Jean-Baptiste Kempf ([@jbkempf](https://github.com/jbkempf))

## Links

- Page: https://xmas.codspeed.io/projects/dav2d
- Discord: https://discord.gg/5kU3aV2sRN
- All projects: https://xmas.codspeed.io/llms.txt
