[MERGED] osmo-bsc[master]: Add optional profiling support

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Max gerrit-no-reply at lists.osmocom.org
Thu Dec 28 23:45:03 UTC 2017


Max has submitted this change and it was merged.

Change subject: Add optional profiling support
......................................................................


Add optional profiling support

This facilitates the use of programs like uftrace. It's disabled by
default due to associated overhead.

Change-Id: Ia5a48a38962fc99446887a34008c40efd8344d9b
---
M configure.ac
1 file changed, 9 insertions(+), 0 deletions(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/configure.ac b/configure.ac
index 97b2e2f..433e3bf 100644
--- a/configure.ac
+++ b/configure.ac
@@ -113,6 +113,15 @@
    AC_SUBST([COVERAGE_LDFLAGS])
 fi
 
+AC_ARG_ENABLE(profile,
+		[AS_HELP_STRING([--enable-profile], [Compile with profiling support enabled], )],
+		[profile=$enableval], [profile="no"])
+if test x"$profile" = x"yes"
+then
+	CFLAGS="$CFLAGS -pg"
+	CPPFLAGS="$CPPFLAGS -pg"
+fi
+
 AC_ARG_ENABLE([vty_tests],
 		AC_HELP_STRING([--enable-vty-tests],
 				[Include the VTY/CTRL tests in make check (deprecated)

-- 
To view, visit https://gerrit.osmocom.org/5613
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ia5a48a38962fc99446887a34008c40efd8344d9b
Gerrit-PatchSet: 1
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Owner: Max <msuraev at sysmocom.de>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Max <msuraev at sysmocom.de>



More information about the gerrit-log mailing list