This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] Copy x86_64 _mcount.op from _mcount.o
- From: "H.J. Lu" <hjl dot tools at gmail dot com>
- To: GNU C Library <libc-alpha at sourceware dot org>
- Cc: Paul Pluzhnikov <ppluzhnikov at google dot com>
- Date: Thu, 3 Mar 2016 06:54:59 -0800
- Subject: Re: [PATCH] Copy x86_64 _mcount.op from _mcount.o
- Authentication-results: sourceware.org; auth=none
- References: <20160303134500 dot GA18701 at intel dot com>
On Thu, Mar 3, 2016 at 5:45 AM, H.J. Lu <hongjiu.lu@intel.com> wrote:
> No need to compile x86_64 _mcount.S with -pg. We can just copy the
> normal static object.
>
> * gmon/Makefile (noprof): Add $(sysdep_noprof).
> * sysdeps/x86_64/Makefile (sysdep_noprof): Add _mcount.
> ---
> gmon/Makefile | 2 +-
> sysdeps/x86_64/Makefile | 1 +
> 2 files changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/gmon/Makefile b/gmon/Makefile
> index abb96d7..c7c9e58 100644
> --- a/gmon/Makefile
> +++ b/gmon/Makefile
> @@ -45,7 +45,7 @@ include ../Rules
> # On systems where `profil' is not a system call, the same
> # problem exists for the internal functions in profil.c.
>
> -noprof := mcount
> +noprof := mcount $(sysdep_noprof)
> ifeq (,$(filter profil,$(unix-syscalls)))
> noprof += profil sprofil
> endif
> diff --git a/sysdeps/x86_64/Makefile b/sysdeps/x86_64/Makefile
> index 67ed5ba..9fcadd8 100644
> --- a/sysdeps/x86_64/Makefile
> +++ b/sysdeps/x86_64/Makefile
> @@ -7,6 +7,7 @@ endif
>
> ifeq ($(subdir),gmon)
> sysdep_routines += _mcount
> +sysdep_noprof += _mcount
> endif
>
> ifeq ($(subdir),malloc)
> --
> 2.5.0
>
There is no difference in gmon/_mcount.op before and after
my patch. I will check it in shortly.
--
H.J.