From f989f9625c993917b5d141084dd0320b3812a88e Mon Sep 17 00:00:00 2001 From: ryo Date: Wed, 27 Oct 2021 03:06:59 +0000 Subject: [PATCH] revert previous: http://mail-index.netbsd.org/source-changes/2021/10/25/msg133295.html going to add __always_inline to the functions called from _mcount() discussed on http://mail-index.netbsd.org/source-changes-d/2021/10/25/msg013480.html --- share/mk/bsd.README | 6 +----- share/mk/bsd.lib.mk | 5 ++--- sys/conf/Makefile.kern.inc | 6 +++--- sys/lib/libkern/Makefile.libkern | 8 ++------ 4 files changed, 8 insertions(+), 17 deletions(-) diff --git a/share/mk/bsd.README b/share/mk/bsd.README index 65e6fb544ac5..36a936787ca7 100644 --- a/share/mk/bsd.README +++ b/share/mk/bsd.README @@ -1,4 +1,4 @@ -# $NetBSD: bsd.README,v 1.420 2021/10/25 07:54:44 ryo Exp $ +# $NetBSD: bsd.README,v 1.421 2021/10/27 03:06:59 ryo Exp $ # @(#)bsd.README 8.2 (Berkeley) 4/2/94 This is the README file for the make "include" files for the NetBSD @@ -1630,10 +1630,6 @@ OBJCOPTS. Additional flags to the compiler when creating the ObjC objects for . For .[ly], ".c" must be used. -PROF. Alternative flag instead of "-pg" to pass to the compiler - when profiling . For .[ly], ".c" must be used. - Usually used to exclude a particular file from profiling. - SYMLINKS See MAN Manual pages (should end in .1 - .9). If no MAN variable is diff --git a/share/mk/bsd.lib.mk b/share/mk/bsd.lib.mk index 90441b5f19be..575748dae3f8 100644 --- a/share/mk/bsd.lib.mk +++ b/share/mk/bsd.lib.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.lib.mk,v 1.386 2021/10/25 07:54:44 ryo Exp $ +# $NetBSD: bsd.lib.mk,v 1.387 2021/10/27 03:06:59 ryo Exp $ # @(#)bsd.lib.mk 8.3 (Berkeley) 4/22/94 .include @@ -51,8 +51,7 @@ CFLAGS+= ${PIE_CFLAGS} AFLAGS+= ${PIE_AFLAGS} .endif -PROF?= -pg -PGFLAGS+= ${PROF.${.IMPSRC:T}:U${PROF}} +PGFLAGS+= -pg .if ${MKPIC} != "no" PGFLAGS+= -fPIC .endif diff --git a/sys/conf/Makefile.kern.inc b/sys/conf/Makefile.kern.inc index c218196bac2f..7e5ee5359d04 100644 --- a/sys/conf/Makefile.kern.inc +++ b/sys/conf/Makefile.kern.inc @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.kern.inc,v 1.283 2021/10/25 07:54:44 ryo Exp $ +# $NetBSD: Makefile.kern.inc,v 1.284 2021/10/27 03:06:59 ryo Exp $ # # This file contains common `MI' targets and definitions and it is included # at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}. @@ -150,8 +150,8 @@ KLINK.o= ${LD} -r ${LINKFORMAT} -Map=${.TARGET}.map -o ${.TARGET} ${.ALLSRC} # compile rules: rules are named ${TYPE}_${SUFFIX} where TYPE is NORMAL or # NOPROF and SUFFIX is the file suffix, capitalized (e.g. C for a .c file). NORMAL_C?= @${_MKSHMSG} "compile ${.CURDIR:T}/${.TARGET}" && \ - ${_MKSHECHO} ${KCOMPILE.c} ${PROF.${.IMPSRC:T}:U${PROF}} && \ - ${KCOMPILE.c} ${PROF.${.IMPSRC:T}:U${PROF}} && \ + ${_MKSHECHO} ${KCOMPILE.c} ${PROF} && \ + ${KCOMPILE.c} ${PROF} && \ ${COMPILE_CTFCONVERT} NOPROF_C?= @${_MKSHMSG} "compile ${.CURDIR:T}/${.TARGET}" && \ ${_MKSHECHO} ${KCOMPILE.c} && \ diff --git a/sys/lib/libkern/Makefile.libkern b/sys/lib/libkern/Makefile.libkern index b56d7b594c21..3ee17a737817 100644 --- a/sys/lib/libkern/Makefile.libkern +++ b/sys/lib/libkern/Makefile.libkern @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.libkern,v 1.52 2021/10/25 07:54:44 ryo Exp $ +# $NetBSD: Makefile.libkern,v 1.53 2021/10/27 03:06:59 ryo Exp $ # # Variable definitions for libkern. @@ -55,7 +55,7 @@ SRCS+= cpuset.c inet_addr.c intoa.c SRCS+= bswap64.c .endif SRCS+= md4c.c md5c.c rmd160.c sha1.c sha2.c sha3.c keccak.c murmurhash.c -SRCS+= pmatch.c crc32.c +SRCS+= pmatch.c mcount.c crc32.c SRCS+= strlist.c SRCS+= ppath_kmem_alloc.c @@ -102,10 +102,6 @@ SRCS+= entpool.c SRCS+= dkcksum.c SRCS+= disklabel_swap.c -# for profiling -SRCS+= mcount.c -PROF.mcount.c= # mcount.c itself is never a profiling target - .PATH: ${NETBSDSRCDIR}/common/lib/libc/cdb SRCS+= cdbr.c SRCS+= mi_vector_hash.c