mirror of
https://github.com/RGBCube/serenity
synced 2025-10-30 00:32:06 +00:00
Previously, FlacLoader would read the data for each frame into a separate vector, which are then combined via extend() in the end. This incurs an avoidable copy per frame. By having the next_frame() function write into a given Span, there's only one vector allocated per call to get_more_samples(). This increases performance by at least 100% realtime, as measured by abench, from about 1200%-1300% to (usually) 1400% on complex test files. |
||
|---|---|---|
| .. | ||
| Buffer.cpp | ||
| Buffer.h | ||
| ClientConnection.cpp | ||
| ClientConnection.h | ||
| CMakeLists.txt | ||
| FlacLoader.cpp | ||
| FlacLoader.h | ||
| FlacTypes.h | ||
| Loader.cpp | ||
| Loader.h | ||
| LoaderError.h | ||
| Sample.h | ||
| WavLoader.cpp | ||
| WavLoader.h | ||
| WavWriter.cpp | ||
| WavWriter.h | ||