From owner-freebsd-hackers@FreeBSD.ORG Thu Mar 12 15:09:36 2015 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 1EAD6362 for ; Thu, 12 Mar 2015 15:09:36 +0000 (UTC) Received: from bigwig.baldwin.cx (bigwig.baldwin.cx [IPv6:2001:470:1f11:75::1]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id EAB47797 for ; Thu, 12 Mar 2015 15:09:35 +0000 (UTC) Received: from ralph.baldwin.cx (pool-173-54-116-245.nwrknj.fios.verizon.net [173.54.116.245]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id E2452B941; Thu, 12 Mar 2015 11:09:32 -0400 (EDT) From: John Baldwin To: freebsd-hackers@freebsd.org Subject: Re: [Rebuild Kernel] Part of the kernel functions are not recompiled when rebuilding the kernel Date: Thu, 12 Mar 2015 10:57 -0400 Message-ID: <2868982.gUMQ0OnoyR@ralph.baldwin.cx> User-Agent: KMail/4.14.2 (FreeBSD/10.1-STABLE; KDE/4.14.2; amd64; ; ) In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Thu, 12 Mar 2015 11:09:33 -0400 (EDT) Cc: Yue Chen X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 12 Mar 2015 15:09:36 -0000 On Monday, March 09, 2015 04:18:07 PM Yue Chen wrote: > Hi all, > > When I used my customized LLVM (insert some instructions after each basic > block) to rebuild the 10.1-RELEASE kernel, I found that about 10% of the > kernel functions (in a continuous address range, in "objdump -S kernel", > about 79%-88%) are not recompiled with my LLVM (does not have the feature > of my customized LLVM). For example, these functions: > > calc_rebuild_progress > ID_TO_VDEV > ldm_spinup_vdev > hpt27xx_ldm_suspend > ldm_start_rebuild > hptnr_ldm_acquire_lock > __ldm_finish_cmd > > I believe the rebuilding process would do a CLEAN first. Maybe something is > wrong with my building process? I followed the instructions here: > https://www.freebsd.org/doc/en/books/handbook/kernelconfig-building.html > > Or these functions are in kernel modules that are statically linked? Some drivers ship with pre-compiled .o files provided by external vendors and not the source. Several hpt drivers are this way, so I suspect that is what you are running into. -- John Baldwin