This is an automated email from the git hooks/post-receive script.
Git pushed a commit to branch master
in repository ffmpeg.
The following commit(s) were added to refs/heads/master by this push:
new e908c92f5a avcodec/cavs: Don't allocate block separately
e908c92f5a is described below
commit e908c92f5ae8444d4ba832e9a1e151aa47ed6ebc
Author: Andreas Rheinhardt <[email protected]>
AuthorDate: Thu Apr 16 22:45:20 2026 +0200
Commit: Andreas Rheinhardt <[email protected]>
CommitDate: Mon Apr 20 12:21:41 2026 +0200
avcodec/cavs: Don't allocate block separately
Signed-off-by: Andreas Rheinhardt <[email protected]>
---
libavcodec/cavs.c | 5 +----
libavcodec/cavs.h | 2 +-
2 files changed, 2 insertions(+), 5 deletions(-)
diff --git a/libavcodec/cavs.c b/libavcodec/cavs.c
index 4db6892452..034819d5c7 100644
--- a/libavcodec/cavs.c
+++ b/libavcodec/cavs.c
@@ -770,11 +770,10 @@ int ff_cavs_init_top_lines(AVSContext *h)
h->col_mv = av_calloc(h->mb_width * h->mb_height,
4 * sizeof(*h->col_mv));
h->col_type_base = av_mallocz(h->mb_width * h->mb_height);
- h->block = av_mallocz(64 * sizeof(int16_t));
if (!h->top_qp || !h->top_mv[0] || !h->top_mv[1] || !h->top_pred_Y ||
!h->top_border_y || !h->top_border_u || !h->top_border_v ||
- !h->col_mv || !h->col_type_base || !h->block) {
+ !h->col_mv || !h->col_type_base) {
av_freep(&h->top_qp);
av_freep(&h->top_mv[0]);
av_freep(&h->top_mv[1]);
@@ -784,7 +783,6 @@ int ff_cavs_init_top_lines(AVSContext *h)
av_freep(&h->top_border_v);
av_freep(&h->col_mv);
av_freep(&h->col_type_base);
- av_freep(&h->block);
return AVERROR(ENOMEM);
}
return 0;
@@ -850,7 +848,6 @@ av_cold int ff_cavs_end(AVCodecContext *avctx)
av_freep(&h->top_border_v);
av_freep(&h->col_mv);
av_freep(&h->col_type_base);
- av_freep(&h->block);
av_freep(&h->edge_emu_buffer);
return 0;
}
diff --git a/libavcodec/cavs.h b/libavcodec/cavs.h
index d3a88ca403..944ede7036 100644
--- a/libavcodec/cavs.h
+++ b/libavcodec/cavs.h
@@ -223,6 +223,7 @@ typedef struct AVSContext {
int qp_fixed;
int pic_qp_fixed;
int cbp;
+ DECLARE_ALIGNED(32, int16_t, block)[64];
uint8_t permutated_scantable[64];
/** intra prediction is done with un-deblocked samples
@@ -244,7 +245,6 @@ typedef struct AVSContext {
uint8_t *edge_emu_buffer;
int got_keyframe;
- int16_t *block;
} AVSContext;
extern const uint8_t ff_cavs_chroma_qp[64];
_______________________________________________
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]