From a788196e2041b431731b3441b27d4b5e8bc8df2e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?M=C3=A5ns=20Rullg=C3=A5rd?= <mans@mansr.com>
Date: Sat, 26 Jun 2010 22:23:29 +0000
Subject: [PATCH] Remove --enable-gprof flag

gprof is far too intrusive to be of use as a profile for ffmpeg,
and it fails to build in many configurations.  Oprofile is a
better tool for profiling on Linux.

Originally committed as revision 23807 to svn://svn.ffmpeg.org/ffmpeg/trunk
---
 configure                             |  8 --------
 libavcodec/alpha/dsputil_alpha_asm.S  | 15 ---------------
 libavcodec/alpha/motion_est_mvi_asm.S |  5 -----
 3 files changed, 28 deletions(-)

diff --git a/configure b/configure
index a206f29ee1d..c2374c2ed1c 100755
--- a/configure
+++ b/configure
@@ -237,7 +237,6 @@ Advanced options (experts only):
 Developer options (useful when working on FFmpeg itself):
   --disable-debug          disable debugging symbols
   --enable-debug=LEVEL     set the debug level [$debuglevel]
-  --enable-gprof           enable profiling with gprof [$gprof]
   --disable-optimizations  disable compiler optimizations
   --enable-extra-warnings  enable more compiler warnings
   --disable-stripping      disable stripping of executables and shared libraries
@@ -857,7 +856,6 @@ CONFIG_LIST="
     fft
     golomb
     gpl
-    gprof
     gray
     h264dsp
     hardcoded_tables
@@ -2714,11 +2712,6 @@ elif enabled tms470; then
     add_cflags -pds=824 -pds=837
 fi
 
-if enabled gprof; then
-    add_cflags  -p
-    add_ldflags -p
-fi
-
 enabled_any $THREADS_LIST      && enable threads
 
 check_deps $CONFIG_LIST       \
@@ -2784,7 +2777,6 @@ fi
 if enabled sparc; then
     echo "VIS enabled               ${vis-no}"
 fi
-echo "gprof enabled             ${gprof-no}"
 echo "debug symbols             ${debug-no}"
 echo "strip symbols             ${stripping-no}"
 echo "optimizations             ${optimizations-no}"
diff --git a/libavcodec/alpha/dsputil_alpha_asm.S b/libavcodec/alpha/dsputil_alpha_asm.S
index 57b21fca128..32a8bc9562d 100644
--- a/libavcodec/alpha/dsputil_alpha_asm.S
+++ b/libavcodec/alpha/dsputil_alpha_asm.S
@@ -53,11 +53,6 @@ put_pixels_axp_asm:
         .frame sp, 0, ra
         .prologue 0
 
-#if CONFIG_GPROF
-        lda     AT, _mcount
-        jsr     AT, (AT), _mcount
-#endif
-
         and     a1, 7, t0
         beq     t0, $aligned
 
@@ -150,11 +145,6 @@ put_pixels_clamped_mvi_asm:
         .frame sp, 0, ra
         .prologue 0
 
-#if CONFIG_GPROF
-        lda     AT, _mcount
-        jsr     AT, (AT), _mcount
-#endif
-
         lda     t8, -1
         lda     t9, 8           # loop counter
         zap     t8, 0xaa, t8    # 00ff00ff00ff00ff
@@ -205,11 +195,6 @@ add_pixels_clamped_mvi_asm:
         .frame sp, 0, ra
         .prologue 0
 
-#if CONFIG_GPROF
-        lda     AT, _mcount
-        jsr     AT, (AT), _mcount
-#endif
-
         lda     t1, -1
         lda     th, 8
         zap     t1, 0x33, tg
diff --git a/libavcodec/alpha/motion_est_mvi_asm.S b/libavcodec/alpha/motion_est_mvi_asm.S
index 2a08b07b0d4..2399085bcbc 100644
--- a/libavcodec/alpha/motion_est_mvi_asm.S
+++ b/libavcodec/alpha/motion_est_mvi_asm.S
@@ -55,11 +55,6 @@ pix_abs16x16_mvi_asm:
         .frame sp, 0, ra, 0
         .prologue 0
 
-#if CONFIG_GPROF
-        lda     AT, _mcount
-        jsr     AT, (AT), _mcount
-#endif
-
         and     a2, 7, t0
         clr     v0
         beq     t0, $aligned
-- 
GitLab