2024-04-05 00:04
michaelni changed the topic of #ffmpeg-devel to: Welcome to the FFmpeg development channel | Questions about using FFmpeg or developing with libav* libs should be asked in #ffmpeg | This channel is publicly logged | FFmpeg 7.0 has been released! | Please read ffmpeg.org/developer.html#Code-of-conduct
00:05
<
BtbN >
jamrial: something I don't understand about the use of ff_buffer_packet() in mov.c: What prevents the last packet from getting queued twice? it calls ff_buffer_packet() on it, but I don't see that "freeing" the packet?
00:06
<
BtbN >
So in ff_read_packet(), it'd call handle_new_packet() on the same packet again
00:09
<
jamrial >
BtbN: the FFERROR_REDO return value
00:09
<
BtbN >
Yeah, that makes the code easier for sure
00:49
AbleBacon has quit [Read error: Connection reset by peer]
00:55
thilo has quit [Ping timeout: 255 seconds]
00:57
thilo has joined #ffmpeg-devel
01:09
cone-418 has quit [Quit: transmission timeout]
01:21
kurosu has quit [Quit: Connection closed for inactivity]
01:23
<
BtbN >
Seems to be working fine. But my god, that nearly 2000 lines read_packet function for flv needs to be refactored badly
02:02
arch1t3cht4 has joined #ffmpeg-devel
02:03
lemourin has joined #ffmpeg-devel
02:04
arch1t3cht has quit [Ping timeout: 260 seconds]
02:04
arch1t3cht4 is now known as arch1t3cht
03:05
rvalue has quit [Read error: Connection reset by peer]
03:06
rvalue has joined #ffmpeg-devel
03:25
jamrial has quit []
03:54
Teukka` has quit [Read error: Connection reset by peer]
03:55
Martchus has joined #ffmpeg-devel
03:55
Martchus_ has quit [Ping timeout: 240 seconds]
03:57
Teukka has joined #ffmpeg-devel
03:57
Teukka has quit [Changing host]
03:57
Teukka has joined #ffmpeg-devel
04:23
kurosu has joined #ffmpeg-devel
05:26
deus0ww has joined #ffmpeg-devel
06:11
Livio has joined #ffmpeg-devel
06:32
kurosu has quit [Quit: Connection closed for inactivity]
06:44
cone-380 has joined #ffmpeg-devel
06:44
<
cone-380 >
ffmpeg Haihao Xiang master:4c0bb7d4a919: lavu/hwcontext_qsv: update AVQSVFramesContext to support dynamic frame pool
06:44
<
cone-380 >
ffmpeg Haihao Xiang master:3178c99fa93b: lavu/version: fix minor version
06:44
<
cone-380 >
ffmpeg Haihao Xiang master:932f78c4e561: lavu/hwcontext_qsv: add support for dynamic frame pool in qsv_frames_derive_to
06:44
<
cone-380 >
ffmpeg Haihao Xiang master:96db4a62e0ac: lavu/hwcontext_qsv: create dynamic frame pool if required
06:44
<
cone-380 >
ffmpeg Haihao Xiang master:d3cc5ead42dc: lavu/hwcontext_qsv: add support for dynamic frame pool in qsv_map_to
06:44
<
cone-380 >
ffmpeg Haihao Xiang master:cda721e01de5: lavc/qsv: fix the mfx allocator to support dynamic frame pool
06:44
<
cone-380 >
ffmpeg Haihao Xiang master:75015f9b0e0e: lavc/qsvenc: use the right info for encoding
06:44
<
cone-380 >
ffmpeg Haihao Xiang master:a00cfc6c2461: lavc/qsvdec: require a dynamic frame pool if possible
06:44
<
cone-380 >
ffmpeg Haihao Xiang master:5646285f761c: lavfi/qsvvpp: use the right mfxFrameInfo when dynamic frame pool is used
06:44
<
cone-380 >
ffmpeg Haihao Xiang master:127ded507828: lavfi/qsvvpp: require a dynamic frame pool for output if possible
06:57
kurosu has joined #ffmpeg-devel
07:07
Livio has quit [Ping timeout: 260 seconds]
07:13
feiwan1 has quit [Quit: Leaving]
07:16
Krowl has joined #ffmpeg-devel
08:04
Krowl has quit [Read error: Connection reset by peer]
08:10
<
courmisch >
BananaPi on delivery truck
08:12
<
courmisch >
BBB: it might well be that MMX is slightly better than C in real use... but I thought we were trying to get rid of MMX?
08:21
IndecisiveTurtle has joined #ffmpeg-devel
08:55
qeed_ has joined #ffmpeg-devel
08:56
qeed has quit [Ping timeout: 264 seconds]
08:58
Krowl has joined #ffmpeg-devel
09:02
kurosu has quit [Quit: Connection closed for inactivity]
09:04
System_Error has quit [Ping timeout: 260 seconds]
09:08
Livio has joined #ffmpeg-devel
09:17
Traneptora has quit [Quit: Quit]
09:23
System_Error has joined #ffmpeg-devel
09:26
mkver has joined #ffmpeg-devel
09:44
cone-380 has quit [Quit: transmission timeout]
09:46
Traneptora has joined #ffmpeg-devel
10:16
Livio has quit [Ping timeout: 264 seconds]
10:18
Livio has joined #ffmpeg-devel
10:22
cone-210 has joined #ffmpeg-devel
10:22
<
cone-210 >
ffmpeg Andreas Rheinhardt master:6c812a80ddfa: avcodec/adts_parser: Don't presume buffer to be padded
10:22
<
cone-210 >
ffmpeg Andreas Rheinhardt master:12ded9cd85be: avcodec/adts_header: Add ff_adts_header_parse_buf()
10:22
<
cone-210 >
ffmpeg Andreas Rheinhardt master:ae937c49027f: avcodec/aac_ac3_parser: Untangle AAC and AC3 parsing error codes
10:22
<
cone-210 >
ffmpeg Andreas Rheinhardt master:a2874c5721eb: avcodec/aac_ac3_parser: Use ff_adts_header_parse_buf()
10:34
Krowl has quit [Read error: Connection reset by peer]
11:03
<
BBB >
courmisch: yes
11:03
<
BBB >
courmisch: someone will replace it with sse2 soon[tm]
11:04
<
BBB >
"Convert MMX assembly language to SSE2 - For example: [..] (e.g. in libavcodec: [..] h263 [..]"
11:29
IndecisiveTurtle has quit [Ping timeout: 256 seconds]
11:42
jamrial has joined #ffmpeg-devel
11:46
Krowl has joined #ffmpeg-devel
11:52
cousin_luigi has joined #ffmpeg-devel
11:52
<
cousin_luigi >
Greetings.
11:53
<
cousin_luigi >
Where do I find the version for each library inside the source tree?
11:56
<
cousin_luigi >
nm found it
11:56
cousin_luigi has left #ffmpeg-devel [#ffmpeg-devel]
12:05
<
cone-210 >
ffmpeg Andreas Rheinhardt master:8b48b0adab0d: avformat/utils: Use static mutexes instead of ff_lock_avformat()
12:05
<
cone-210 >
ffmpeg Andreas Rheinhardt master:583c3d45fab6: avformat/tls_openssl: #if ff_openssl_init/deinit() away if possible
12:05
<
cone-210 >
ffmpeg Andreas Rheinhardt master:26f3e7911466: avformat/tee: Constify AVDictionaryEntry* pointee where possible
12:05
<
cone-210 >
ffmpeg Andreas Rheinhardt master:ce22e7ab289a: avformat/tee: Use smaller scope for variables
12:05
<
cone-210 >
ffmpeg Andreas Rheinhardt master:482afe8f3f7b: avcodec/lib*, avformat/tee: Simplify iterating over AVDictionary
12:05
<
cone-210 >
ffmpeg Andreas Rheinhardt master:f3d206d25ffd: fftools, avfilter, avformat: Simplify check for "is dictionary empty?"
12:33
jamrial has quit [Read error: Connection reset by peer]
12:33
* thardin
stares at av_rescale_rnd()
12:33
jamrial has joined #ffmpeg-devel
12:40
<
Lynne >
it is just a*b + c, with different settings for rounding
12:40
<
cone-210 >
ffmpeg Andreas Rheinhardt master:e863cbceaeb8: avcodec/ac3enc_template: Avoid always-true check
12:40
<
cone-210 >
ffmpeg Andreas Rheinhardt master:59b1838e0955: avcodec/ac3enc: Move transient PutBitContext to stack
12:40
<
cone-210 >
ffmpeg Andreas Rheinhardt master:b50c5d029003: avformat/flacdec: Reorder allocations to avoid leak on error
12:40
<
cone-210 >
ffmpeg Andreas Rheinhardt master:62929f40ee7c: fftools/ffmpeg_filter: Fix leak on error
12:40
<
cone-210 >
ffmpeg Andreas Rheinhardt master:2c94b1bbf101: avcodec/tiff: Fix leak on error
12:40
<
cone-210 >
ffmpeg Andreas Rheinhardt master:0d7430d3ab9a: avfilter/vf_v360: Add assert to suppress Coverity false positives
12:41
<
Lynne >
with 128-bit precision as a, b and c are all 64-bit values
12:46
<
thardin >
riscv has a 128-bit mode
12:51
<
Lynne >
ah, that hasn't been standardized yet, there's a draft
12:51
<
Lynne >
my version just uses 128-bit c23 ints, which should mean if its ever released it'll just work
12:53
Krowl has quit [Read error: Connection reset by peer]
12:53
<
thardin >
didn't know c23 had such large ints. neat
12:53
<
thardin >
does it also give int256, int512, int1024 and so on?
12:58
Livio has quit [Ping timeout: 264 seconds]
12:59
<
Lynne >
they're optional though, so compilers/libc doesn't have to implement bignum libs
12:59
<
Lynne >
but everything that matters supports 128-bit
13:00
<
thardin >
I only see mention of int128 in the spec
13:00
<
thardin >
but I guess you kind of have to draw the line somewhere
13:00
<
thardin >
else you get into generics territory
13:06
<
Lynne >
_BitInt(N) is the syntax, where N is a number of bits
13:07
<
Lynne >
its very flexible, you could in theory have 171-bit ints
13:12
<
thardin >
av_rescale_rnd() looks correct btw, frama-c just isn't very good at reasoning about truncation in division
13:14
<
courmisch >
afaik nobody implements int128_t because ...
13:14
<
courmisch >
... they would have to extend intmax_t to 128 bits
13:14
<
courmisch >
which would be an ABI break :facepalm:
13:16
<
courmisch >
there is totally not an integer type __int128 on GCC and Clang though
13:16
<
courmisch >
don't even need C23
13:16
<
Lynne >
int128_t is not standardized
13:16
<
Lynne >
it doesn't have a prefix or namespacing, so it's not like it can be implemented in a compliant way, at least I think so
13:17
<
Lynne >
the advantage of BitInt is that its in theory portable
13:17
<
courmisch >
IIRC the spec allows intN_t for any ?
13:17
Krowl has joined #ffmpeg-devel
13:17
<
Lynne >
it does? I didn't know that
13:17
<
courmisch >
int128_t is not required but then neither is BigInt, ain't it?
13:21
<
Lynne >
bigint or bitint?
13:22
<
courmisch >
anyhow, is there even a C23 compiler yet
13:27
<
jamrial >
clang and gcc support most of the current draft, afaik
13:30
<
cone-210 >
ffmpeg James Almer master:b113050d96d9: avcodec/cbs_h266: read vps_ptl_max_tid before using it
13:30
<
Lynne >
it was released last year
13:31
<
Lynne >
clang-18 + glibc 2.39 (for checked int adds) implements all of it
13:50
<
frankplow >
courmisch: BitInts are mandatory I believe. Not mandatory that they can be larger than the existing integer types though
14:05
<
courmisch >
frankplow: well, that's about as useful ad aligned_alloc() guaranteed to support only standard alignments
14:06
rvalue has quit [Read error: Connection reset by peer]
14:06
rvalue has joined #ffmpeg-devel
14:06
<
Lynne >
e.g. very useful
14:08
<
frankplow >
Bit-precise integers can be larger than intmax_t, so implementors can add larger ints without the ABI problem you mentioned.
14:09
<
courmisch >
also call me when you convinced mini to use checked ints instead of adhoc code
14:10
<
courmisch >
meanwhile ffmpeg still supporting gcc 4?
14:10
<
Lynne >
adhoc code? like putting (unsigned) casts?
14:11
<
thardin >
av_rescale_delta() is moderately cursed
14:12
<
courmisch >
Lynne: no, like manually checking for overflow
14:12
<
thardin >
if the timestamps are outside [INT64_MIN/3, INT64_MAX/3] then UB can occur
14:12
<
thardin >
probably in other cases too
14:14
<
jamrial >
<courmisch> meanwhile ffmpeg still supporting gcc 4? <- 4.9 minimum, because c11
14:31
<
courmisch >
F3 has arrived
14:37
<
Lynne >
courmisch: if you get it running, could you post checkasm --bench results on both it and the 908?
14:39
<
courmisch >
it takes forever, I think because checkasm benches C functions that don't have optimisations written for them, for naught
14:45
<
Lynne >
I don't think that happens, checkasm gives up if it finds nothing in cflags
14:45
<
jamrial >
courmisch: then run each test you know has risvc versions individually with --test=foo
14:46
<
courmisch >
Lynne: last I tried, it took 30+ minutes though
14:46
<
courmisch >
jamrial: well, that's what I usually do, yes
14:46
<
jamrial >
30 minutes?
14:46
<
jamrial >
not ready for prime time i guess
14:47
<
courmisch >
it takes 5 minutes on my Mordor86 Zen 2
14:49
<
Lynne >
30 minutes sounds about right for how fast a 908 is
14:49
<
Lynne >
but you have 8 cores on the m1
14:49
<
courmisch >
k1, but checkasm is not threaded is it
14:54
<
Lynne >
ah, no, it isn't
14:55
<
courmisch >
so the quick start guide says to use a TTL adapter, does not say where to plug it
14:57
klaxa has quit [Ping timeout: 252 seconds]
14:59
klaxa has joined #ffmpeg-devel
15:02
<
courmisch >
Lynne: and it relies on sigsetjmp so fat chance
15:03
<
courmisch >
I suppose the jump buffer could be put into TLS for the signal handler to use
15:44
Krowl has quit [Read error: Connection reset by peer]
15:50
AbleBacon has joined #ffmpeg-devel
15:54
<
BBB >
ffmpeg-english "capture video from the camera every 1 second and write it to jpg files"
15:54
<
BBB >
well that's cute
15:56
Sean_McG has joined #ffmpeg-devel
16:03
Livio has joined #ffmpeg-devel
16:04
lexano has joined #ffmpeg-devel
16:09
IndecisiveTurtle has joined #ffmpeg-devel
16:13
<
cone-210 >
ffmpeg LuMingYin master:9481b7d932e8: libavformat/hlsenc: fix a memory leak on error path
16:13
<
cone-210 >
ffmpeg LuMingYin master:14f9e47314ab: libavformat/rtsp: fix a memory leak on error path
16:13
<
cone-210 >
ffmpeg LuMingYin master:3f691c0c6a8c: libavfilter/vf_curves: fix a memory leak on error path
16:19
Livio has quit [Read error: Connection reset by peer]
16:19
<
courmisch >
I ain't going to wait the whole night for this
16:20
<
courmisch >
maybe VVC tests made checkasm impossibly slow
16:20
<
jamrial >
yeah, those run way too many iterations
16:22
Krowl has joined #ffmpeg-devel
16:24
Livio has joined #ffmpeg-devel
16:30
Livio has quit [Ping timeout: 264 seconds]
16:35
rvalue has quit [Ping timeout: 264 seconds]
16:36
rvalue- has joined #ffmpeg-devel
16:38
Livio has joined #ffmpeg-devel
16:43
<
courmisch >
two hours and still nothing
16:43
<
courmisch >
my patience is running out
16:43
rvalue- is now known as rvalue
16:45
<
courmisch >
fix checkasm if you want benchmarks
16:55
<
Lynne >
on the c908?
16:55
<
courmisch >
well on anything, I suspect
17:20
merbanan has joined #ffmpeg-devel
17:20
<
Lynne >
I'm sure it won't take more than eta(cur_time) = (cur_time + 1800)
17:24
<
courmisch >
hey, I know that oneMicrosoft ETA function
17:29
<
cone-210 >
ffmpeg James Almer release/7.0:5f23eecfba60: avformat/vvc: fix writing general_constraint_info bytes
17:29
<
cone-210 >
ffmpeg James Almer release/7.0:a8b8b1042f99: avformat/vvc: fix parsing some early VPS bitstream values
17:31
Livio has quit [Read error: Connection reset by peer]
17:31
IndecisiveTurtle has quit [Ping timeout: 256 seconds]
17:32
<
cone-210 >
ffmpeg Nuo Mi release/7.0:00ccb7be2948: avcodec/cbs_h266: fix sh_collocated_from_l0_flag and sh_collocated_ref_idx infer
17:32
<
cone-210 >
ffmpeg James Almer release/7.0:060d2ce8aed1: avcodec/cbs_h266: read vps_ptl_max_tid before using it
17:35
Livio has joined #ffmpeg-devel
17:37
System_Error has quit [Remote host closed the connection]
17:47
<
courmisch >
Lynne: the k230 literally crashed after 8000 seconds of checkasm, so tough luck
17:50
b50d has joined #ffmpeg-devel
17:54
System_Error has joined #ffmpeg-devel
17:56
<
Lynne >
courmisch: sad, could you limit the tests to 3 functions - something trivial, somewhat complex, and rocket science?
17:59
c1480 has joined #ffmpeg-devel
18:02
psykose has quit [Remote host closed the connection]
18:03
psykose has joined #ffmpeg-devel
18:06
b50d has quit [Remote host closed the connection]
18:15
psykose_ has joined #ffmpeg-devel
18:17
psykose has quit [Ping timeout: 268 seconds]
18:17
psykose_ is now known as psykose
18:30
cubicibo has joined #ffmpeg-devel
18:33
iive has joined #ffmpeg-devel
18:42
deer3 has quit [Ping timeout: 246 seconds]
18:48
Krowl has quit [Read error: Connection reset by peer]
18:54
sadome has joined #ffmpeg-devel
18:54
sadome has joined #ffmpeg-devel
18:54
sadome has quit [Changing host]
18:54
sadome has quit [Excess Flood]
18:57
kurosu has joined #ffmpeg-devel
19:04
<
courmisch >
If VVC devs can't be bothered to fix checkasm, I can't be bothered to run it.
19:06
<
Lynne >
it shouldn't even run any of those functions when --test=<test>
19:08
Livio has quit [Ping timeout: 255 seconds]
19:17
<
courmisch >
Lynne: ^
19:23
<
Lynne >
thanks, the cores look surprisingly similar in terms of timing, with the vectors simply being twice as fast, and the clock being higher
19:29
<
Lynne >
what's going on with the vector integer ops being slower than vector float ops?
19:31
<
courmisch >
...and it happened. RDCYCLE does not work.
19:32
<
courmisch >
Well it was only a matter of time until vendor firmware had the security fix.
19:32
<
courmisch >
Lynne: AI does not need integers
19:32
<
courmisch >
now, to port the video codecs to float
19:33
<
Lynne >
with quantizations, these days running AI is basically fixed-point matrix mults
19:33
<
Lynne >
that's why all tensor units offer 8*8 => 16bit fixed-point mults
19:33
<
courmisch >
do they even have mantissa bits left in F8 and F4 formats?
19:34
cubicibo has quit [Quit: Client closed]
19:34
<
Lynne >
actually they do
19:34
<
courmisch >
I think the benchmarks above may be a little biased because some of the integer stuff has additional shifts and roundings for fixed point
19:35
<
courmisch >
also perhaps scalar ALU competes with vector ALU?
19:35
<
Lynne >
ah, yeah, that would add overhead and latency
19:36
cubicibo has joined #ffmpeg-devel
19:36
<
Lynne >
curious if aac_fixed is slower than aac_float with no assembly optimizations enabled, I'll give it a test on the 908 I have access to
19:38
<
courmisch >
flac_lpc_32_31_c: 1070.2
19:38
<
courmisch >
flac_lpc_32_31_rvv_i64: 186.7
19:39
<
Lynne >
what's it like on the c908?
19:40
<
courmisch >
flac_lpc_32_31_c: 1119.0
19:40
<
courmisch >
flac_lpc_32_31_rvv_i64: 225.2
19:40
<
courmisch >
slightly worse
19:42
<
courmisch >
checkasm could take a page from dav1d and give the ratio
19:42
<
courmisch >
flac_lpc_32_31_c: 13296.1
19:42
<
courmisch >
flac_lpc_32_31_sse4: 6351.6
19:42
<
courmisch >
Booooooh, SSE4
19:44
<
Lynne >
every time LPC SIMD gets mentioned I have flashbacks to lpc_apply_welch_window
19:49
<
courmisch >
apply_welch_window_even_c: 812.0
19:49
<
courmisch >
apply_welch_window_odd_c: 925.7
19:49
<
courmisch >
apply_welch_window_even_rvv_f64: 147.7
19:49
<
courmisch >
apply_welch_window_odd_rvv_f64: 167.2
19:50
<
courmisch >
apply_welch_window_even_c: 8314.0
19:50
<
courmisch >
apply_welch_window_even_avx2: 1987.0
19:50
<
courmisch >
apply_welch_window_even_sse2: 3032.0
19:50
<
courmisch >
hey, at least x86 has a better TSC granularity, can't have everything
19:52
<
Lynne >
linux perf uses the perf timers, right? and the resolution issue is from the kernel/framework side
19:53
<
Lynne >
for arm64 there's a kernel mod I use which lets applications use the timers directly
19:53
<
courmisch >
I'm using RDTIME, not kperf
19:55
IndecisiveTurtle has joined #ffmpeg-devel
19:56
<
jamrial >
courmisch: order 31 in lpc_32 test?
19:56
<
jamrial >
is that a local change?
19:57
<
courmisch >
jamrial: yes
20:03
<
courmisch >
I wanted to test all sizes, especially 8 and lower
20:03
<
courmisch >
but I won't send that patch because I'm not a VVC dev
20:10
<
Lynne >
the fixed-point AAC decoder is 7% slower on risc-v with no assembly
20:10
<
Lynne >
those rounding adds and shifts do add up
20:19
<
Lynne >
aac_fixed is 13% slower on arm64
20:20
<
Lynne >
maybe we should disable it by default...
20:20
<
Lynne >
only MIPS went/wanted float-less and they are no more
20:32
cone-210 has quit [Quit: transmission timeout]
20:37
cubicibo has quit [Ping timeout: 250 seconds]
21:07
kurosu has quit [Quit: Connection closed for inactivity]
21:21
<
BBB >
mips is dead?
21:22
<
BBB >
I did not know that, interesting
21:22
<
kepstin >
there is a use case for a fixed-point aac decoder on risc-v; some microcontroller socs like esp32 are switching to RV32IMAC cores and the target market for those things includes voice assistants/smart speakers.
21:23
<
kepstin >
tho i suppose people might end up with chips that have a dsp and use that for codecs instead.
21:25
<
kepstin >
and yeah, MIPS just sells risc-v cores now.
21:31
<
Lynne >
I haven't heard of anyone running ffmpeg on microcontrollers tbh
22:06
Raz- has quit [Ping timeout: 260 seconds]
22:14
<
Lynne >
great, everyone does whatever they want for xhe-aac audio output levels
22:15
<
Lynne >
fdk-aac outputs super low levels, and assumes a mono downmix (?) so for stereo it reduces the levels even more
22:15
<
Lynne >
apple's decoder just outputs data like we do, at the native MDCT output level
22:19
Raz- has joined #ffmpeg-devel
22:36
Raz- has quit [Ping timeout: 240 seconds]
22:51
Raz- has joined #ffmpeg-devel
23:01
IndecisiveTurtle has quit [Ping timeout: 256 seconds]
23:14
mkver has quit [Ping timeout: 268 seconds]
23:35
merbanan has quit [Ping timeout: 240 seconds]