Repository navigation
Closed
Description
tests/gtest/avifcodectest.cc fails at head. It was passing 3 days ago.
Expected: (testutil::GetPsnr(*image, *decoded)) > (32.0), actual: 12 vs 32
[ RUN ] All/CodecTest.EncodeDecode/6
Svt[info]: -------------------------------------------
Svt[info]: SVT [version]: SVT-AV1 Encoder Lib v3.1.2
Svt[info]: SVT [build] : Visual Studio 2022 64 bit
Svt[info]: -------------------------------------------
Svt[info]: Level of Parallelism: 1
Svt[info]: Number of PPCS 74
Svt[info]: [asm level on system : up to avx2]
Svt[info]: [asm level selected : up to avx2]
Svt[info]: -------------------------------------------
Svt[info]: SVT [config]: main profile tier (auto) level (auto)
Svt[info]: SVT [config]: width / height / fps numerator / fps denominator : 64 / 64 / 60000 / 1000
Svt[info]: SVT [config]: bit-depth / color format : 8 / YUV420
Svt[info]: SVT [config]: preset / tune / pred struct : 8 / PSNR / random access
Svt[info]: SVT [config]: gop size / mini-gop size / key-frame type : 321 / 32 / key frame
Svt[info]: SVT [config]: BRC mode / rate factor : CRF / 6
Svt[info]: SVT [config]: AQ mode / Variance Boost : 2 / 0
Svt[info]: SVT [config]: sharpness / luminance-based QP bias : 0 / 0
Svt[info]: -------------------------------------------
Svt[info]: -------------------------------------------
Svt[info]: SVT [version]: SVT-AV1 Encoder Lib v3.1.2
Svt[info]: SVT [build] : Visual Studio 2022 64 bit
Svt[info]: -------------------------------------------
Svt[info]: Level of Parallelism: 1
Svt[info]: Number of PPCS 74
Svt[info]: [asm level on system : up to avx2]
Svt[info]: [asm level selected : up to avx2]
Svt[info]: -------------------------------------------
Svt[info]: SVT [config]: main profile tier (auto) level (auto)
Svt[info]: SVT [config]: width / height / fps numerator / fps denominator : 64 / 64 / 60000 / 1000
Svt[info]: SVT [config]: bit-depth / color format : 8 / YUV420
Svt[info]: SVT [config]: preset / tune / pred struct : 8 / PSNR / random access
Svt[info]: SVT [config]: gop size / mini-gop size / key-frame type : 321 / 32 / key frame
Svt[info]: SVT [config]: BRC mode / rate factor : CRF / 6
Svt[info]: SVT [config]: AQ mode / Variance Boost : 2 / 0
Svt[info]: SVT [config]: sharpness / luminance-based QP bias : 0 / 0
Svt[info]: -------------------------------------------
Svt[info]: Only a single picture was passed in. Consider setting avif=1 for improved efficiency and reduced memory usage.
Svt[info]: Only a single picture was passed in. Consider setting avif=1 for improved efficiency and reduced memory usage.
D:\a\libavif\libavif\tests\gtest\avifcodectest.cc(48): error: Expected: (testutil::GetPsnr(*image, *decoded)) > (32.0), actual: 12.445797037453715 vs 32
[ FAILED ] All/CodecTest.EncodeDecode/6, where GetParam() = (5, 1) (63 ms)
(log)
Metadata
Metadata
Assignees
Labels
No labels
Activity
y-guyon commentedon Jun 15, 2026
#2974 does not provide any hint on what changed from SVT-AV1 v3.1.2 to v4.0.0 with regard to libavif.
y-guyon commentedon Jun 15, 2026
I do not think it is tied to the version of SVT-AV1. In #3254 the CI fails even with SVT-AV1 v4.1.0:
error: Expected: (testutil::GetPsnr(*image, *decoded)) > (20.0), actual: 12 vs 20(log)
However it only fails with
avifsvttest.avifcodectestpasses, surprisingly.[-]High distortion with SVT-AV1 3.1.2 in CI Windows Installed[/-][+]High distortion with SVT-AV1 in CI Windows Installed[/+][-]High distortion with SVT-AV1 in CI Windows Installed[/-][+]High distortion with SVT-AV1 in CI Windows[/+]y-guyon commentedon Jun 15, 2026
y-guyon commentedon Jun 15, 2026
-DAVIF_FUZZTEST=LOCALdoes not work inci-windows.yml("Compiler MSVC is not supported").y-guyon commentedon Jun 15, 2026
https://gitlab.com/AOMediaCodec/SVT-AV1/-/work_items/2322 seems quite relevant.
However the newly failing workflow "CI Windows Installed" relies on
vcpkg svt-av1being 3.1.2 built with Visual Studio 2022 according to the runtimeSvt[info]: SVT [build]log.The other newly failing workflow "CI Windows" builds SVT-AV1 4.1.0 from source with Visual Studio 2022 according to the runtime
Svt[info]: SVT [build]log.What surprises me is that I just merged #3254 because it was complaining about the missing "Visual Studio 17 2022" generator, so I am doubtful that Visual Studio 2022 was used to build SVT-AV1. Or is that the SDK's version or something?
The CMake step says
-- Building for: Visual Studio 18 2026 -- The C compiler identification is MSVC 19.51.36246.0.dimitry-unified-streaming commentedon Jun 15, 2026
As far as I could determine in https://gitlab.com/AOMediaCodec/SVT-AV1/-/work_items/2322, compiler versions >= 19.50 (those are confusingly called "MSVC Build Tools v14.50 for x64/x86" and higher in the Visual Studio Installer) expose a problem with inlining a few AVX2 intrinsics.
If you are using Visual Studio 2026, you can install an older version of the compiler by selecting "MSVC v143 - VS 2022 C++ x64/x86 build tools (v14.44-17.14)", and activate it via
vcvarsall.bat, to use it instead. The problem should then go away.Alternatively, you could try the diff I have put in https://gitlab.com/AOMediaCodec/SVT-AV1/-/work_items/2322#note_3455144085. But some more investigation is needed to narrow down a test case to report to Microsoft.
kmilos commentedon Jun 16, 2026
FYI, the GHA runners started transitioning from VS 2022 to VS 2026 by default during this week, so some builds might have very well used VS 2022, and some VS 2026... Don't know about GitLab runners...
Use windows-2022 until issue AOMediaCodec#3255 is fixed
Use windows-2022 until issue AOMediaCodec#3255 is fixed
wantehchang commentedon Jun 16, 2026
In both SVT-AV1 v3.1.2 and SVT-AV1 v4.1.0, the Visual Studio version detection is limited to Visual Studio 2022 or older:
Source/Lib/Globals/enc_handle.c:
Svt[info]: SVT [build] : Visual Studio 2022 64 bit
Use windows-2022 until issue #3255 is fixed
dimitry-unified-streaming commentedon Jul 28, 2026
Note that the fix in SVT-AV1 has been committed: https://gitlab.com/AOMediaCodec/SVT-AV1/-/commit/ce69eadbe0604e352807250212be0898d86bc8dc
wantehchang commentedon Jul 28, 2026
Dimitry: Thank you for the update. We forgot to close this issue.