From 486fe140b5cf986809b38a36d80ccb9e4879bfb7 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Tue, 28 Apr 2026 13:25:52 +0200 Subject: [PATCH 1/9] add jobs for format-switching --- includes/format-switching.yml | 56 +++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 includes/format-switching.yml diff --git a/includes/format-switching.yml b/includes/format-switching.yml new file mode 100644 index 0000000..9196e2f --- /dev/null +++ b/includes/format-switching.yml @@ -0,0 +1,56 @@ +format-switching-smoke-test: + extends: + - .test-job-linux + - .rules-merge-request-to-main + stage: test + needs: ["build-codec-linux-clang-make"] + tags: + - ivas-linux + script: + - bash "${CI_PROJECT_DIR}"/ivas-codec-ci/snippets/print-common-info.sh + - | + if [ "$CI_PROJECT_ID" == "$PROJECT_ID_BASOP" ]; then + bash "${CI_PROJECT_DIR}"/ivas-codec-ci/snippets/basop/update-scripts-repo.sh + fi + - make -j IVAS_dec + - python3 -m pytest tests/format_switching/test_format_switching.py --html report.html --self-contained-html --junit-xml report.xml + timeout: "20 minutes" + artifacts: + paths: + - report.html + - report.xml + name: "$CI_JOB_NAME--$CI_MERGE_REQUEST_IID--sha-$CI_COMMIT_SHORT_SHA--fmt-sw-smoketest" + expose_as: "fmt-sw-smoketest" + expire_in: "5 days" + +format-switching-compare-test: + extends: + - .test-job-linux + - .rules-merge-request-to-main + stage: compare + needs: ["build-codec-linux-clang-make"] + tags: + - ivas-linux + script: + - bash "${CI_PROJECT_DIR}"/ivas-codec-ci/snippets/print-common-info.sh + - | + if [ "$CI_PROJECT_ID" == "$PROJECT_ID_BASOP" ]; then + bash "${CI_PROJECT_DIR}"/ivas-codec-ci/snippets/basop/update-scripts-repo.sh + fi + + - git checkout $CI_MERGE_REQUEST_TARGET_BRANCH_NAME + - make -j IVAS_dec + - mv IVAS_dec IVAS_dec_ref + - git checkout $CI_COMMIT_SHORT_SHA + - make clean + - make -j IVAS_dec + - python3 -m pytest tests/format_switching/test_format_switching.py --create_ref + - python3 -m pytest tests/format_switching/test_format_switching.py --html report.html --self-contained-html --junit-xml report.xml --create_cut + timeout: "20 minutes" + artifacts: + paths: + - report.html + - report.xml + name: "$CI_JOB_NAME--$CI_MERGE_REQUEST_IID--sha-$CI_COMMIT_SHORT_SHA--fmt-sw-smoketest" + expose_as: "fmt-sw-smoketest" + expire_in: "5 days" -- GitLab From 034948c23293d4a1ce94249323c230ba5e45c4ed Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Tue, 28 Apr 2026 13:26:36 +0200 Subject: [PATCH 2/9] include new file in float config --- main-float.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/main-float.yml b/main-float.yml index 1503dc2..69dacf3 100644 --- a/main-float.yml +++ b/main-float.yml @@ -7,6 +7,7 @@ include: - local: includes/build-jobs.yml - local: includes/rules.yml - local: includes/check-first-frame-is-sid.yml + - local: includes/format-switching.yml default: # by default, we want all jobs to be interruptible, and we need to configure this explicitly -- GitLab From e71c098699e9925a4bac88dc80a52475a807c415 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Tue, 28 Apr 2026 14:26:10 +0200 Subject: [PATCH 3/9] add sanitizer test for fmt switching --- includes/format-switching.yml | 43 ++++++++++++++++++++++++++++++++++- 1 file changed, 42 insertions(+), 1 deletion(-) diff --git a/includes/format-switching.yml b/includes/format-switching.yml index 9196e2f..ea23d7b 100644 --- a/includes/format-switching.yml +++ b/includes/format-switching.yml @@ -51,6 +51,47 @@ format-switching-compare-test: paths: - report.html - report.xml - name: "$CI_JOB_NAME--$CI_MERGE_REQUEST_IID--sha-$CI_COMMIT_SHORT_SHA--fmt-sw-smoketest" + name: "$CI_JOB_NAME--$CI_MERGE_REQUEST_IID--sha-$CI_COMMIT_SHORT_SHA--fmt-sw-compare" + expose_as: "fmt-sw-smoketest" + expire_in: "5 days" + +format-switching-sanitizers: + extends: + - .test-job-linux + - .rules-merge-request-to-main + stage: compare + needs: ["build-codec-linux-clang-make"] + parallel: + matrix: + - SANITIZER: + - MSAN + - ASAN + - USAN + tags: + - ivas-linux + script: + - bash "${CI_PROJECT_DIR}"/ivas-codec-ci/snippets/print-common-info.sh + - | + if [ "$CI_PROJECT_ID" == "$PROJECT_ID_BASOP" ]; then + bash "${CI_PROJECT_DIR}"/ivas-codec-ci/snippets/basop/update-scripts-repo.sh + fi + + - declare -A CLANG_NUM_4_SANITIZER + - CLANG_NUM_4_SANITIZER["MSAN"] = 1 + - CLANG_NUM_4_SANITIZER["ASAN"] = 2 + - CLANG_NUM_4_SANITIZER["USAN"] = 3 + + - clang_num="$CLANG_NUM_4_SANITIZER[$SANITIZER]" + + - make -j IVAS_dec CLANG=$clang_num + # TODO: for basop - ignorelist + - export UBSAN_OPTIONS="suppressions=scripts/ubsan_basop.supp,report_error_type=1,print_stacktrace=1" + - python3 -m pytest tests/format_switching/test_format_switching.py --create_ref --ref_encoder_path ./IVAS_dec + timeout: "20 minutes" + artifacts: + paths: + - report.html + - report.xml + name: "$CI_JOB_NAME--$CI_MERGE_REQUEST_IID--sha-$CI_COMMIT_SHORT_SHA--fmt-sw-sanitizers" expose_as: "fmt-sw-smoketest" expire_in: "5 days" -- GitLab From ff8e2a3ee63d47b31683df66bb641b6b6393f49b Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Wed, 29 Apr 2026 14:56:49 +0200 Subject: [PATCH 4/9] fix associative array syntax --- includes/format-switching.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/includes/format-switching.yml b/includes/format-switching.yml index ea23d7b..b4b5991 100644 --- a/includes/format-switching.yml +++ b/includes/format-switching.yml @@ -77,11 +77,11 @@ format-switching-sanitizers: fi - declare -A CLANG_NUM_4_SANITIZER - - CLANG_NUM_4_SANITIZER["MSAN"] = 1 - - CLANG_NUM_4_SANITIZER["ASAN"] = 2 - - CLANG_NUM_4_SANITIZER["USAN"] = 3 + - CLANG_NUM_4_SANITIZER["MSAN"]=1 + - CLANG_NUM_4_SANITIZER["ASAN"]=2 + - CLANG_NUM_4_SANITIZER["USAN"]=3 - - clang_num="$CLANG_NUM_4_SANITIZER[$SANITIZER]" + - clang_num="${CLANG_NUM_4_SANITIZER[$SANITIZER]}" - make -j IVAS_dec CLANG=$clang_num # TODO: for basop - ignorelist -- GitLab From b82334eba4165e99890c938628d9bb53a0ffa048 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Wed, 29 Apr 2026 15:44:10 +0200 Subject: [PATCH 5/9] fix pytest calls --- includes/format-switching.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/format-switching.yml b/includes/format-switching.yml index b4b5991..d8dbf2d 100644 --- a/includes/format-switching.yml +++ b/includes/format-switching.yml @@ -44,7 +44,7 @@ format-switching-compare-test: - git checkout $CI_COMMIT_SHORT_SHA - make clean - make -j IVAS_dec - - python3 -m pytest tests/format_switching/test_format_switching.py --create_ref + - python3 -m pytest tests/format_switching/test_format_switching.py --create_ref --ref_decoder_path ./IVAS_dec_ref - python3 -m pytest tests/format_switching/test_format_switching.py --html report.html --self-contained-html --junit-xml report.xml --create_cut timeout: "20 minutes" artifacts: @@ -86,7 +86,7 @@ format-switching-sanitizers: - make -j IVAS_dec CLANG=$clang_num # TODO: for basop - ignorelist - export UBSAN_OPTIONS="suppressions=scripts/ubsan_basop.supp,report_error_type=1,print_stacktrace=1" - - python3 -m pytest tests/format_switching/test_format_switching.py --create_ref --ref_encoder_path ./IVAS_dec + - python3 -m pytest tests/format_switching/test_format_switching.py --create_ref --ref_decoder_path ./IVAS_dec timeout: "20 minutes" artifacts: paths: -- GitLab From 9da73db48bc6e4ae7f5a810843e57036323b9f2a Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Wed, 29 Apr 2026 16:12:36 +0200 Subject: [PATCH 6/9] always store artifacts --- includes/format-switching.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/includes/format-switching.yml b/includes/format-switching.yml index d8dbf2d..47118a7 100644 --- a/includes/format-switching.yml +++ b/includes/format-switching.yml @@ -16,6 +16,7 @@ format-switching-smoke-test: - python3 -m pytest tests/format_switching/test_format_switching.py --html report.html --self-contained-html --junit-xml report.xml timeout: "20 minutes" artifacts: + when: always paths: - report.html - report.xml @@ -48,6 +49,7 @@ format-switching-compare-test: - python3 -m pytest tests/format_switching/test_format_switching.py --html report.html --self-contained-html --junit-xml report.xml --create_cut timeout: "20 minutes" artifacts: + when: always paths: - report.html - report.xml @@ -89,6 +91,7 @@ format-switching-sanitizers: - python3 -m pytest tests/format_switching/test_format_switching.py --create_ref --ref_decoder_path ./IVAS_dec timeout: "20 minutes" artifacts: + when: always paths: - report.html - report.xml -- GitLab From bcf53401d34c268b77a4df1b327ca86d3cfbfced Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Wed, 29 Apr 2026 16:16:52 +0200 Subject: [PATCH 7/9] correct stage for sanitizer fmt sw test --- includes/format-switching.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/format-switching.yml b/includes/format-switching.yml index 47118a7..449125b 100644 --- a/includes/format-switching.yml +++ b/includes/format-switching.yml @@ -61,7 +61,7 @@ format-switching-sanitizers: extends: - .test-job-linux - .rules-merge-request-to-main - stage: compare + stage: test needs: ["build-codec-linux-clang-make"] parallel: matrix: -- GitLab From 9119402ff296d56985889fef994f3c0fc4bc83b7 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Wed, 29 Apr 2026 16:22:38 +0200 Subject: [PATCH 8/9] create reports in sanitizer tests --- includes/format-switching.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/format-switching.yml b/includes/format-switching.yml index 449125b..37c6007 100644 --- a/includes/format-switching.yml +++ b/includes/format-switching.yml @@ -88,7 +88,7 @@ format-switching-sanitizers: - make -j IVAS_dec CLANG=$clang_num # TODO: for basop - ignorelist - export UBSAN_OPTIONS="suppressions=scripts/ubsan_basop.supp,report_error_type=1,print_stacktrace=1" - - python3 -m pytest tests/format_switching/test_format_switching.py --create_ref --ref_decoder_path ./IVAS_dec + - python3 -m pytest tests/format_switching/test_format_switching.py --create_ref --ref_decoder_path ./IVAS_dec --html report.html --self-contained-html --junit-xml report.xml timeout: "20 minutes" artifacts: when: always -- GitLab From 762c1a21d88c2b696202c31690387b19acd28d78 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Wed, 29 Apr 2026 17:13:44 +0200 Subject: [PATCH 9/9] use correct suppressions file --- includes/format-switching.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/format-switching.yml b/includes/format-switching.yml index 37c6007..d807d7e 100644 --- a/includes/format-switching.yml +++ b/includes/format-switching.yml @@ -87,7 +87,7 @@ format-switching-sanitizers: - make -j IVAS_dec CLANG=$clang_num # TODO: for basop - ignorelist - - export UBSAN_OPTIONS="suppressions=scripts/ubsan_basop.supp,report_error_type=1,print_stacktrace=1" + - export UBSAN_OPTIONS=suppressions=scripts/ubsan.supp,report_error_type=1,print_stacktrace=1 - python3 -m pytest tests/format_switching/test_format_switching.py --create_ref --ref_decoder_path ./IVAS_dec --html report.html --self-contained-html --junit-xml report.xml timeout: "20 minutes" artifacts: -- GitLab