PR #23796 opened by Niklas Haas (haasn)
URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/23796
Patch URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/23796.patch
Some state leaks in between test runs if we don't properly clean up the
tx_refs when restarting with a new seed.
Solves:
checkasm: iter=2/20 cpu=c test=av_tx checked=13240
Program received signal SIGSEGV, Segmentation fault.
0x0000000000c856e6 in ff_tx_fft_float_c (s=0x44849c0, _dst=0x5c35880,
_src=0x5bf5840, stride=8)
at ./src/libavutil/tx_template.c:769
769 int *map = s->sub[0].map;
>>> bt
at ./src/libavutil/tx_template.c:769
at ./src/tests/checkasm/ext/src/checkasm.c:855
argc@entry=2, argv=<optimized out>, argv@entry=0x7fffffffdf08)
at ./src/tests/checkasm/ext/src/checkasm.c:1236
Signed-off-by: Niklas Haas <[email protected]>
# Summary of changes
Briefly describe what this PR does and why.
<!--
If this PR requires new FATE test samples, attach them to the PR and
list their target paths below (relative to the fate-suite root).
Attached filenames must match the sample's filename:
```fate-samples
# e.g. vorbis/new-sample.ogg
```
-->
>From e3ee91247f3de75d394d7acc3b283ea2792609ed Mon Sep 17 00:00:00 2001
From: Niklas Haas <[email protected]>
Date: Mon, 13 Jul 2026 13:28:06 +0200
Subject: [PATCH] checkasm/av_tx: fix segfault when using --repeat
Some state leaks in between test runs if we don't properly clean up the
tx_refs when restarting with a new seed.
Solves:
checkasm: iter=2/20 cpu=c test=av_tx checked=13240
Program received signal SIGSEGV, Segmentation fault.
0x0000000000c856e6 in ff_tx_fft_float_c (s=0x44849c0, _dst=0x5c35880,
_src=0x5bf5840, stride=8)
at ./src/libavutil/tx_template.c:769
769 int *map = s->sub[0].map;
>>> bt
at ./src/libavutil/tx_template.c:769
at ./src/tests/checkasm/ext/src/checkasm.c:855
argc@entry=2, argv=<optimized out>, argv@entry=0x7fffffffdf08)
at ./src/tests/checkasm/ext/src/checkasm.c:1236
Signed-off-by: Niklas Haas <[email protected]>
---
tests/checkasm/av_tx.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/tests/checkasm/av_tx.c b/tests/checkasm/av_tx.c
index 2d7b4e662d..95ffec25b6 100644
--- a/tests/checkasm/av_tx.c
+++ b/tests/checkasm/av_tx.c
@@ -107,6 +107,9 @@ void checkasm_check_av_tx(void)
void *out_ref = av_malloc(16384*2*8);
void *out_new = av_malloc(16384*2*8);
+ if (!checkasm_get_cpu_info())
+ free_tx_refs();
+
randomize_complex(in, 16384, AVComplexFloat, SCALE_NOOP);
CHECK_TEMPLATE("float_fft", AV_TX_FLOAT_FFT, 0, AVComplexFloat, float,
check_lens,
!float_near_abs_eps_array(out_ref, out_new, EPS, len*2));
--
2.52.0
_______________________________________________
ffmpeg-devel mailing list -- [email protected]
To unsubscribe send an email to [email protected]