linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] Documentation: note that KCOV is supported since gcc 4.5
@ 2016-12-13 15:20 Dmitry Vyukov
  2016-12-13 23:43 ` Jonathan Corbet
  0 siblings, 1 reply; 3+ messages in thread
From: Dmitry Vyukov @ 2016-12-13 15:20 UTC (permalink / raw)
  To: akpm, keescook, corbet
  Cc: Dmitry Vyukov, Vegard Nossum, linux-kernel, linux-doc, syzkaller

Now that we have gcc plugins and in particular sancov plugin,
KCOV can be used with gcc 4.5+. Note this in the docs.

I've tested CONFIG_KCOV with gcc 4.8.4 (stock for ubuntu 14.04)
and it works. It even emits very comparable number of coverage
callbacks: 420153 vs 422211 for gcc 7.0.

Cc: Jonathan Corbet <corbet@lwn.net>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Kees Cook <keescook@google.com>
Cc: Vegard Nossum <vegard.nossum@oracle.com>
Cc: linux-kernel@vger.kernel.org
Cc: linux-doc@vger.kernel.org
Cc: syzkaller@googlegroups.com
Signed-off-by: Dmitry Vyukov <dvyukov@google.com>
---
 Documentation/dev-tools/kcov.rst | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/Documentation/dev-tools/kcov.rst b/Documentation/dev-tools/kcov.rst
index 2c41b71..50d515a 100644
--- a/Documentation/dev-tools/kcov.rst
+++ b/Documentation/dev-tools/kcov.rst
@@ -19,7 +19,9 @@ Configure the kernel with::
 
         CONFIG_KCOV=y
 
-CONFIG_KCOV requires gcc built on revision 231296 or later.
+CONFIG_KCOV is natively supported by gcc 6.0+ (revision 231296) via
+-fsanitize-coverage=trace-pc flag. gcc 4.5+ supports CONFIG_KCOV with plugins
+(see Documentation/gcc-plugins.txt and CONFIG_GCC_PLUGIN_SANCOV).
 Profiling data will only become accessible once debugfs has been mounted::
 
         mount -t debugfs none /sys/kernel/debug
-- 
2.8.0.rc3.226.g39d4020

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] Documentation: note that KCOV is supported since gcc 4.5
  2016-12-13 15:20 [PATCH] Documentation: note that KCOV is supported since gcc 4.5 Dmitry Vyukov
@ 2016-12-13 23:43 ` Jonathan Corbet
  2017-06-28  7:49   ` Dmitry Vyukov
  0 siblings, 1 reply; 3+ messages in thread
From: Jonathan Corbet @ 2016-12-13 23:43 UTC (permalink / raw)
  To: Dmitry Vyukov
  Cc: akpm, keescook, Vegard Nossum, linux-kernel, linux-doc, syzkaller

On Tue, 13 Dec 2016 16:20:59 +0100
Dmitry Vyukov <dvyukov@google.com> wrote:

> Now that we have gcc plugins and in particular sancov plugin,
> KCOV can be used with gcc 4.5+. Note this in the docs.

Makes sense.  Applied to docs-next, thanks.

jon

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] Documentation: note that KCOV is supported since gcc 4.5
  2016-12-13 23:43 ` Jonathan Corbet
@ 2017-06-28  7:49   ` Dmitry Vyukov
  0 siblings, 0 replies; 3+ messages in thread
From: Dmitry Vyukov @ 2017-06-28  7:49 UTC (permalink / raw)
  To: syzkaller; +Cc: Andrew Morton, Kees Cook, Vegard Nossum, LKML, linux-doc

On Wed, Dec 14, 2016 at 12:43 AM, Jonathan Corbet <corbet@lwn.net> wrote:
> On Tue, 13 Dec 2016 16:20:59 +0100
> Dmitry Vyukov <dvyukov@google.com> wrote:
>
>> Now that we have gcc plugins and in particular sancov plugin,
>> KCOV can be used with gcc 4.5+. Note this in the docs.
>
> Makes sense.  Applied to docs-next, thanks.


Hi Jon,

I am looking at v4.12-rc7 docs, and this patch is still not there:

http://elixir.free-electrons.com/linux/v4.12-rc7/source/Documentation/dev-tools/kcov.rst

Did you forget to commit it? Or push to Linus?

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-06-28  7:50 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-12-13 15:20 [PATCH] Documentation: note that KCOV is supported since gcc 4.5 Dmitry Vyukov
2016-12-13 23:43 ` Jonathan Corbet
2017-06-28  7:49   ` Dmitry Vyukov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).