From owner-svn-src-all@freebsd.org Fri Mar 1 01:39:56 2019 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0F2ED1521F6E; Fri, 1 Mar 2019 01:39:56 +0000 (UTC) (envelope-from mmacy@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id A79686CFD2; Fri, 1 Mar 2019 01:39:55 +0000 (UTC) (envelope-from mmacy@freebsd.org) Received: from mail-it1-f170.google.com (mail-it1-f170.google.com [209.85.166.170]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G3" (verified OK)) (Authenticated sender: mmacy) by smtp.freebsd.org (Postfix) with ESMTPSA id 7C91D14E1F; Fri, 1 Mar 2019 01:39:55 +0000 (UTC) (envelope-from mmacy@freebsd.org) Received: by mail-it1-f170.google.com with SMTP id v2so17823980ith.3; Thu, 28 Feb 2019 17:39:55 -0800 (PST) X-Gm-Message-State: AHQUAuaOK+3320eOwlo1+JgjXn8OPopeBBk/4k6XvX28c8k19aWRyj6g xtHjvfR3ypvjPzd1fFMEuJSTLm/O9JCKfVOUvOg= X-Google-Smtp-Source: APXvYqwoJUMMgW/KKDvcwXmpfM0vnjYVgKwbdU5Pjc4qmFCF1o2V39xMsQZ2eq6plIQ0tqheb2Lf/XfJnmzb6QBI6i4= X-Received: by 2002:a24:2b0e:: with SMTP id h14mr1594574ita.168.1551404394884; Thu, 28 Feb 2019 17:39:54 -0800 (PST) MIME-Version: 1.0 References: <201902232114.x1NLE0cH085345@repo.freebsd.org> In-Reply-To: From: Matthew Macy Date: Thu, 28 Feb 2019 17:39:43 -0800 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: svn commit: r344487 - in head/sys: conf gnu/gcov To: Alan Somers Cc: src-committers , svn-src-all , svn-src-head Content-Type: text/plain; charset="UTF-8" X-Rspamd-Queue-Id: A79686CFD2 X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-6.97 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; NEURAL_HAM_SHORT(-0.97)[-0.969,0]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; REPLY(-4.00)[] X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 01 Mar 2019 01:39:56 -0000 to config add: options LINDEBUGFS options GCOV compile kernel with gcc (otherwise it will be a no-op) sysctl debug.gcov.enable=1 mount -t debugfs debugfs /sys/kernel/debug (or wherever) and the output artifacts will appear under gcov/ - you need to be root to see the artifacts gcov can then generate the results as it would normally from the profiling and the build time artifacts bug reports welcome -M On Thu, Feb 28, 2019 at 2:50 PM Alan Somers wrote: > > On Sat, Feb 23, 2019 at 2:14 PM Matt Macy wrote: > > > > Author: mmacy > > Date: Sat Feb 23 21:14:00 2019 > > New Revision: 344487 > > URL: https://svnweb.freebsd.org/changeset/base/344487 > > > > Log: > > gcov support > > > > add gcov support and export results as files in debugfs > > > > Reviewed by: hps@ > > MFC after: 1 week > > Sponsored by: iX Systems > > Differential Revision: https://reviews.freebsd.org/D19260 > > > > Added: > > head/sys/gnu/gcov/ > > head/sys/gnu/gcov/gcc_4_7.c (contents, props changed) > > head/sys/gnu/gcov/gcov.h (contents, props changed) > > head/sys/gnu/gcov/gcov_fs.c (contents, props changed) > > head/sys/gnu/gcov/gcov_subr.c (contents, props changed) > > Modified: > > head/sys/conf/files > > head/sys/conf/kern.mk > > head/sys/conf/kern.post.mk > > head/sys/conf/kern.pre.mk > > head/sys/conf/kmod.mk > > head/sys/conf/options > > On a more practical note, how does one use this new feature? It looks > like it could be quite useful. > -Alan