changeset 10867:bf309c7ce615 libavcodec

More av_cold for infrequently called functions.
author zuxy
date Wed, 13 Jan 2010 02:16:00 +0000
parents d26e9b4d2ca1
children 13a84faba50d
files cavsdsp.c dsputil.c h264dspenc.c intrax8dsp.c rv30dsp.c utils.c vc1dsp.c
diffstat 7 files changed, 8 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/cavsdsp.c	Wed Jan 13 01:59:19 2010 +0000
+++ b/cavsdsp.c	Wed Jan 13 02:16:00 2010 +0000
@@ -515,7 +515,7 @@
 void ff_put_cavs_qpel16_mc00_c(uint8_t *dst, uint8_t *src, int stride);
 void ff_avg_cavs_qpel16_mc00_c(uint8_t *dst, uint8_t *src, int stride);
 
-void ff_cavsdsp_init(DSPContext* c, AVCodecContext *avctx) {
+av_cold void ff_cavsdsp_init(DSPContext* c, AVCodecContext *avctx) {
 #define dspfunc(PFX, IDX, NUM) \
     c->PFX ## _pixels_tab[IDX][ 0] = ff_ ## PFX ## NUM ## _mc00_c; \
     c->PFX ## _pixels_tab[IDX][ 1] = ff_ ## PFX ## NUM ## _mc10_c; \
--- a/dsputil.c	Wed Jan 13 01:59:19 2010 +0000
+++ b/dsputil.c	Wed Jan 13 02:16:00 2010 +0000
@@ -4452,7 +4452,7 @@
 static void just_return(void *mem av_unused, int stride av_unused, int h av_unused) { return; }
 
 /* init static data */
-void dsputil_static_init(void)
+av_cold void dsputil_static_init(void)
 {
     int i;
 
@@ -4489,7 +4489,7 @@
     return 0;
 }
 
-void dsputil_init(DSPContext* c, AVCodecContext *avctx)
+av_cold void dsputil_init(DSPContext* c, AVCodecContext *avctx)
 {
     int i;
 
--- a/h264dspenc.c	Wed Jan 13 01:59:19 2010 +0000
+++ b/h264dspenc.c	Wed Jan 13 02:16:00 2010 +0000
@@ -71,7 +71,7 @@
     H264_DCT_PART2(3);
 }
 
-void ff_h264dspenc_init(DSPContext* c, AVCodecContext *avctx)
+av_cold void ff_h264dspenc_init(DSPContext* c, AVCodecContext *avctx)
 {
     c->h264_dct = h264_dct_c;
 }
--- a/intrax8dsp.c	Wed Jan 13 01:59:19 2010 +0000
+++ b/intrax8dsp.c	Wed Jan 13 02:16:00 2010 +0000
@@ -413,7 +413,7 @@
     x8_loop_filter(src, 1, stride, qscale);
 }
 
-void ff_intrax8dsp_init(DSPContext* dsp, AVCodecContext *avctx) {
+av_cold void ff_intrax8dsp_init(DSPContext* dsp, AVCodecContext *avctx) {
     dsp->x8_h_loop_filter=x8_h_loop_filter;
     dsp->x8_v_loop_filter=x8_v_loop_filter;
     dsp->x8_setup_spatial_compensation=x8_setup_spatial_compensation;
--- a/rv30dsp.c	Wed Jan 13 01:59:19 2010 +0000
+++ b/rv30dsp.c	Wed Jan 13 02:16:00 2010 +0000
@@ -251,7 +251,7 @@
 RV30_MC(avg_, 8)
 RV30_MC(avg_, 16)
 
-void ff_rv30dsp_init(DSPContext* c, AVCodecContext *avctx) {
+av_cold void ff_rv30dsp_init(DSPContext* c, AVCodecContext *avctx) {
     c->put_rv30_tpel_pixels_tab[0][ 0] = c->put_h264_qpel_pixels_tab[0][0];
     c->put_rv30_tpel_pixels_tab[0][ 1] = put_rv30_tpel16_mc10_c;
     c->put_rv30_tpel_pixels_tab[0][ 2] = put_rv30_tpel16_mc20_c;
--- a/utils.c	Wed Jan 13 01:59:19 2010 +0000
+++ b/utils.c	Wed Jan 13 02:16:00 2010 +0000
@@ -662,7 +662,7 @@
     return ret;
 }
 
-int avcodec_close(AVCodecContext *avctx)
+av_cold int avcodec_close(AVCodecContext *avctx)
 {
     /* If there is a user-supplied mutex locking routine, call it. */
     if (ff_lockmgr_cb) {
--- a/vc1dsp.c	Wed Jan 13 01:59:19 2010 +0000
+++ b/vc1dsp.c	Wed Jan 13 02:16:00 2010 +0000
@@ -612,7 +612,7 @@
 PUT_VC1_MSPEL(2, 3)
 PUT_VC1_MSPEL(3, 3)
 
-void ff_vc1dsp_init(DSPContext* dsp, AVCodecContext *avctx) {
+av_cold void ff_vc1dsp_init(DSPContext* dsp, AVCodecContext *avctx) {
     dsp->vc1_inv_trans_8x8 = vc1_inv_trans_8x8_c;
     dsp->vc1_inv_trans_4x8 = vc1_inv_trans_4x8_c;
     dsp->vc1_inv_trans_8x4 = vc1_inv_trans_8x4_c;