This content originally appeared on DEV Community and was authored by 阿豪
mpv-v8v7 is a JavaScript script for running v8-v7 benchmark tests directly inside the mpv player.
The original benchmark code comes from mozilla/arewefastyet, and has been bundled and converted into a CommonJS format compatible with mpv using ahaoboy/js-engine-benchmark.
📜 How It Works
- When mpv starts, the script automatically pauses video playback.
- It runs the v8-v7 benchmark test.
- The test results are displayed on-screen via mpv’s OSD (On-Screen Display).
- Once completed, the results are saved to a log file:
scripts/mpv-v8v7-<timestamp>.log
💡 Why Run This Benchmark?
The v8-v7 benchmark is designed to evaluate JavaScript engine performance.
- Higher scores mean faster JavaScript execution.
- Developers can use this test to compare the effects of different compilation options (e.g., PGO, MIMALLOC) on JS execution speed.
This makes it especially useful for performance tuning and testing custom mpv builds.
📦 Requirements
- mpv with JavaScript scripting enabled.
⚙️ Installation
Download the latest
portable_config.zip
from:
mpv-buildExtract
portable_config.zip
into your local mpv directory.To avoid interference, it’s recommended to install only this script for testing purposes.
📝 Example Output
When the benchmark runs, mpv will pause playback and display results like:
Richards: 526
DeltaBlue: 766
Crypto: 366
RayTrace: 1085
EarleyBoyer: 1300
RegExp: 513
Splay: 2380
NavierStokes: 957
----
Score: 838
The full details are stored in scripts/mpv-v8v7-<timestamp>.log
.
🔗 Related Projects
- mozilla/arewefastyet — Original benchmark suite.
- ahaoboy/mpv-v8v7 — mpv script.
- ahaoboy/js-engine-benchmark — Tool used to bundle and convert the benchmark to CommonJS format.
This content originally appeared on DEV Community and was authored by 阿豪

阿豪 | Sciencx (2025-08-11T02:47:32+00:00) Running v8-v7 Benchmarks in mpv Player. Retrieved from https://www.scien.cx/2025/08/11/running-v8-v7-benchmarks-in-mpv-player/
Please log in to upload a file.
There are no updates yet.
Click the Upload button above to add an update.