Devin Heitmueller
b2c82b23b9
avcodec/bitpacked_dec: optimize bitpacked_decode_yuv422p10
...
Rework the code a bit to speed up the 10-bit bitpacked decoding
routine. This is probably about as fast as I can get it without
switching to assembly language.
Demonstratable with:
./ffmpeg -f lavfi -i "smptehdbars=size=3840x2160" -c bitpacked -f image2 -frames:v 1 source.yuv
./ffmpeg -f bitpacked -pix_fmt yuv422p10le -s 3840x2160 -c:v bitpacked -i source.yuv -pix_fmt yuv422p10le out.yuv
On my development system, it went from 80ms for a 2160p frame
down to 20ms (i.e. a 4X speedup). Good enough for now, I hope...
Comments from Marton:
Originally on my system better performance could be achieved by simply
switching to the cached bitstream reader, but for Devin it was slower than
his direct byte operations.
I changed the order of writing output from u/y/v/y to u/v/y/y, and that made
the code faster than the cached bitstream reader on my system as well.
TIMER measurement of the decode loop on Ryzen 5 3600 with command line:
./ffmpeg -stream_loop 256 -threads 1 -f bitpacked -pix_fmt yuv422p10le -s 3840x2160 -c:v bitpacked -i source.yuv -pix_fmt yuv422p10le -f null none -loglevel error
Before: 823204127 decicycles in YUV, 256 runs, 0 skips
After: 315070524 decicycles in YUV, 256 runs, 0 skips
Signed-off-by: Devin Heitmueller <dheitmueller@ltnglobal.com>
Signed-off-by: Marton Balint <cus@passwd.hu>
2023-12-28 23:56:14 +01:00
..
2023-12-07 23:20:14 +02:00
2023-11-22 18:33:00 -03:00
2023-11-25 21:51:04 -03:00
2023-10-01 02:25:09 +02:00
2023-12-22 17:40:00 +02:00
2023-10-03 01:59:07 +02:00
2023-12-25 22:31:15 -03:00
2023-11-10 00:14:02 +01:00
2023-11-14 18:18:26 +01:00
2023-10-31 21:44:48 +01:00
2023-10-31 20:47:00 +01:00
2023-12-22 15:12:33 +01:00
2023-10-31 20:47:00 +01:00
2023-10-31 21:44:48 +01:00
2023-12-22 15:12:33 +01:00
2023-12-11 18:42:07 +02:00
2023-10-31 21:44:48 +01:00
2023-10-31 21:44:48 +01:00
2023-10-31 20:47:00 +01:00
2023-10-31 21:44:48 +01:00
2023-10-31 20:47:00 +01:00
2023-10-31 21:44:48 +01:00
2023-10-31 21:44:48 +01:00
2023-10-31 21:44:48 +01:00
2023-10-31 21:44:48 +01:00
2023-10-31 21:44:48 +01:00
2023-11-04 01:24:09 +01:00
2023-10-31 20:47:00 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-11-22 18:33:00 -03:00
2023-12-01 12:42:22 -03:00
2023-11-25 21:50:56 -03:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-11-26 17:49:09 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-31 20:46:59 +01:00
2023-10-31 20:47:00 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-07 22:35:22 +02:00
2023-10-07 22:34:10 +02:00
2023-10-06 10:11:18 -03:00
2023-11-12 14:47:56 -03:00
2023-12-18 15:19:30 -03:00
2023-10-01 01:02:53 +02:00
2023-10-01 01:02:53 +02:00
2023-12-28 23:56:14 +01:00
2023-12-18 15:19:36 -03:00
2023-12-18 15:19:36 -03:00
2023-10-16 01:05:07 +02:00
2023-12-22 15:12:33 +01:00
2023-10-07 22:35:05 +02:00
2023-11-18 19:55:42 +01:00
2023-10-07 22:35:05 +02:00
2023-10-07 22:35:05 +02:00
2023-12-14 23:53:10 +01:00
2023-11-11 11:53:21 -03:00
2023-11-04 01:27:41 +01:00
2023-11-15 10:29:03 -05:00
2023-10-07 22:35:14 +02:00
2023-10-07 22:35:14 +02:00
2023-10-07 22:35:14 +02:00
2023-11-15 10:29:03 -05:00
2023-12-19 00:27:26 +01:00
2023-11-15 10:29:03 -05:00
2023-11-15 10:29:03 -05:00
2023-10-07 22:35:05 +02:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-31 20:47:00 +01:00
2023-12-22 15:12:33 +01:00
2023-11-26 17:49:09 +01:00
2023-11-26 17:49:09 +01:00
2023-10-06 09:56:41 -03:00
2023-11-14 14:26:42 -03:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-21 16:15:23 +08:00
2023-12-21 16:15:23 +08:00
2023-12-21 13:55:16 +02:00
2023-12-21 16:15:23 +08:00
2023-12-21 16:15:23 +08:00
2023-12-21 16:15:23 +08:00
2023-12-21 16:15:23 +08:00
2023-12-21 16:15:23 +08:00
2023-12-21 16:15:23 +08:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-01 02:25:09 +02:00
2023-11-22 05:01:16 +01:00
2023-10-07 22:35:22 +02:00
2023-10-03 01:58:37 +02:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-11-01 16:40:20 +01:00
2023-10-07 22:34:49 +02:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-21 16:15:23 +08:00
2023-12-21 16:15:23 +08:00
2023-12-21 16:15:23 +08:00
2023-12-21 16:15:23 +08:00
2023-12-21 16:15:23 +08:00
2023-12-21 16:15:23 +08:00
2023-12-21 16:15:23 +08:00
2023-12-21 16:15:23 +08:00
2023-12-21 16:15:23 +08:00
2023-12-22 15:12:33 +01:00
2023-10-03 01:59:07 +02:00
2023-10-12 22:50:34 +02:00
2023-10-03 20:09:27 +02:00
2023-11-10 00:15:28 +01:00
2023-10-16 00:54:37 +02:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-11-14 19:15:51 +02:00
2023-10-09 19:52:51 +03:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-31 20:46:59 +01:00
2023-10-03 00:28:50 +02:00
2023-10-03 00:28:50 +02:00
2023-10-22 22:09:59 +02:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-01 01:02:53 +02:00
2023-10-01 01:02:53 +02:00
2023-12-22 15:12:33 +01:00
2023-11-17 23:59:22 +02:00
2023-11-17 23:59:22 +02:00
2023-12-22 15:12:33 +01:00
2023-11-03 22:16:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-18 15:19:36 -03:00
2023-10-07 22:34:10 +02:00
2023-11-12 02:19:53 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-31 20:46:59 +01:00
2023-10-05 22:05:21 +02:00
2023-10-31 20:46:59 +01:00
2023-10-31 20:46:59 +01:00
2023-10-13 14:35:07 +02:00
2023-10-07 22:36:04 +02:00
2023-12-22 15:12:33 +01:00
2023-11-22 19:42:14 +08:00
2023-10-08 21:36:09 +02:00
2023-11-20 00:19:04 +01:00
2023-10-07 22:34:20 +02:00
2023-10-07 22:34:20 +02:00
2023-11-20 00:19:25 +01:00
2023-10-07 22:34:20 +02:00
2023-12-21 16:15:23 +08:00
2023-12-22 15:12:33 +01:00
2023-11-20 00:19:25 +01:00
2023-10-13 14:35:07 +02:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-03 00:27:14 +02:00
2023-10-16 01:16:19 +02:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-09 21:23:25 +02:00
2023-10-26 13:18:01 +02:00
2023-10-07 22:34:28 +02:00
2023-10-19 20:46:55 +02:00
2023-10-07 22:34:28 +02:00
2023-11-01 20:10:20 +01:00
2023-10-07 22:34:28 +02:00
2023-12-22 15:12:33 +01:00
2023-11-01 20:10:20 +01:00
2023-10-03 08:33:42 -04:00
2023-10-31 21:33:25 +02:00
2023-10-31 21:33:25 +02:00
2023-12-22 15:12:33 +01:00
2023-10-07 22:35:22 +02:00
2023-12-21 16:15:23 +08:00
2023-12-21 16:15:23 +08:00
2023-10-31 20:47:00 +01:00
2023-10-31 20:47:00 +01:00
2023-10-31 20:47:00 +01:00
2023-10-07 22:34:10 +02:00
2023-10-31 20:47:00 +01:00
2023-10-31 20:46:59 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-11-01 18:52:55 +02:00
2023-11-01 18:52:55 +02:00
2023-12-14 23:53:10 +01:00
2023-12-22 15:12:33 +01:00
2023-12-05 05:53:32 -05:00
2023-12-27 10:10:09 -05:00
2023-10-31 20:47:00 +01:00
2023-10-03 20:09:27 +02:00
2023-11-08 17:37:58 +11:00
2023-11-08 17:37:58 +11:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 22:08:29 -05:00
2023-12-22 22:08:29 -05:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-18 23:59:51 +02:00
2023-12-18 23:59:51 +02:00
2023-12-18 23:59:51 +02:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-11-16 16:53:44 +02:00
2023-11-16 16:53:44 +02:00
2023-11-18 22:07:14 +02:00
2023-11-18 22:07:14 +02:00
2023-11-23 18:57:18 +02:00
2023-11-23 18:57:18 +02:00
2023-12-11 18:17:43 +02:00
2023-12-11 18:17:43 +02:00
2023-10-27 18:10:46 +02:00
2023-12-22 15:12:33 +01:00
2023-12-21 16:15:23 +08:00
2023-12-22 15:12:33 +01:00
2023-11-22 21:02:04 +08:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-31 20:47:00 +01:00
2023-12-28 23:15:56 +01:00
2023-12-22 15:12:33 +01:00
2023-10-20 17:07:22 +02:00
2023-10-18 23:01:40 +02:00
2023-12-22 15:12:33 +01:00
2023-12-21 22:42:34 +02:00
2023-12-21 22:42:34 +02:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-31 20:47:00 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-31 20:47:00 +01:00
2023-12-22 15:12:33 +01:00
2023-10-11 22:28:24 +02:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-31 21:44:48 +01:00
2023-12-21 16:15:23 +08:00
2023-10-31 21:44:48 +01:00
2023-12-22 15:12:33 +01:00
2023-10-31 21:44:48 +01:00
2023-10-31 21:44:48 +01:00
2023-10-31 21:44:48 +01:00
2023-10-31 21:44:48 +01:00
2023-10-01 01:53:32 +02:00
2023-10-22 22:09:59 +02:00
2023-10-22 22:09:59 +02:00
2023-10-22 22:09:59 +02:00
2023-12-22 15:12:33 +01:00
2023-10-03 16:57:02 +02:00
2023-10-22 22:09:59 +02:00
2023-10-05 22:05:21 +02:00
2023-10-31 20:46:59 +01:00
2023-10-31 20:46:59 +01:00
2023-10-31 20:47:00 +01:00
2023-10-31 20:47:00 +01:00
2023-10-31 20:47:00 +01:00
2023-10-31 20:46:59 +01:00
2023-10-31 20:47:00 +01:00
2023-10-31 20:47:00 +01:00
2023-12-22 15:12:33 +01:00
2023-10-12 20:57:35 +02:00
2023-11-01 20:13:01 +01:00
2023-11-01 20:13:01 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-09 20:17:44 +02:00
2023-10-09 20:17:44 +02:00
2023-12-22 15:12:33 +01:00
2023-10-06 09:49:47 +02:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-18 15:19:30 -03:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 22:07:35 -05:00
2023-12-22 15:12:33 +01:00
2023-11-09 12:53:35 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-22 22:09:59 +02:00
2023-12-05 14:50:21 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-11-01 20:15:54 +01:00
2023-11-01 20:15:54 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-05 22:05:21 +02:00
2023-10-31 20:47:00 +01:00
2023-10-31 20:47:00 +01:00
2023-10-31 20:47:00 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-11-01 22:53:26 +02:00
2023-11-01 22:53:26 +02:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-02 12:23:16 +02:00
2023-10-02 12:23:16 +02:00
2023-12-22 15:12:33 +01:00
2023-10-31 20:47:00 +01:00
2023-12-22 15:12:33 +01:00
2023-10-31 20:47:00 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 09:28:04 -03:00
2023-12-22 09:28:04 -03:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-22 22:09:59 +02:00
2023-10-22 22:09:59 +02:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-10-22 22:09:59 +02:00
2023-10-03 20:09:27 +02:00
2023-10-31 21:33:25 +02:00
2023-10-31 21:33:25 +02:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-21 23:29:02 +01:00
2023-12-22 15:12:33 +01:00
2023-10-22 22:11:37 +02:00
2023-10-03 01:59:07 +02:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-12-22 15:12:33 +01:00
2023-11-01 20:14:22 +01:00
2023-11-01 20:14:22 +01:00
2023-12-22 15:12:33 +01:00
2023-10-31 20:47:00 +01:00
2023-10-31 20:47:00 +01:00
2023-10-31 20:47:00 +01:00
2023-10-31 20:47:00 +01:00
2023-10-31 20:47:00 +01:00
2023-12-21 16:15:23 +08:00
2023-12-08 17:20:48 +02:00
2023-12-08 17:20:48 +02:00
2023-12-22 15:12:33 +01:00
2023-10-10 00:22:55 +02:00
2023-12-18 15:19:30 -03:00
2023-10-07 22:34:28 +02:00
2023-12-22 15:12:33 +01:00
2023-11-01 16:40:22 +01:00
2023-10-31 20:46:59 +01:00
2023-12-22 15:12:33 +01:00
2023-10-31 20:47:00 +01:00
2023-11-15 10:29:03 -05:00
2023-10-07 22:35:22 +02:00
2023-11-15 10:29:03 -05:00
2023-11-15 10:29:03 -05:00
2023-12-22 15:12:33 +01:00
2023-12-21 16:15:23 +08:00
2023-11-01 20:14:06 +01:00
2023-11-01 20:14:06 +01:00
2023-10-31 20:47:00 +01:00
2023-10-07 22:35:50 +02:00
2023-10-25 22:01:21 +02:00
2023-10-07 22:35:50 +02:00
2023-10-31 21:35:23 +01:00
2023-10-07 22:35:50 +02:00
2023-11-21 08:02:43 +08:00
2023-10-03 20:09:27 +02:00
2023-10-22 22:09:59 +02:00
2023-12-22 15:12:33 +01:00
2023-10-31 21:44:48 +01:00
2023-10-31 21:44:48 +01:00
2023-10-31 21:44:48 +01:00
2023-10-31 21:44:48 +01:00
2023-10-31 21:44:48 +01:00
2023-10-31 20:47:00 +01:00
2023-10-31 20:47:00 +01:00
2023-10-16 01:14:10 +02:00