All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/3] kcov: support comparison operands collection
@ 2017-08-30 16:23 Dmitry Vyukov
  2017-08-30 16:23   ` Dmitry Vyukov
                   ` (2 more replies)
  0 siblings, 3 replies; 21+ messages in thread
From: Dmitry Vyukov @ 2017-08-30 16:23 UTC (permalink / raw)
  To: akpm, linux-mm; +Cc: tchibo, Dmitry Vyukov

Enables kcov to collect comparison operands from instrumented code.
This is done by using Clang's -fsanitize=trace-cmp instrumentation
(currently not available for GCC).

The comparison operands help a lot in fuzz testing. E.g. they are
used in syzkaller to cover the interiors of conditional statements
with way less attempts and thus make previously unreachable code
reachable.

To allow separate collection of coverage and comparison operands two
different work modes are implemented. Mode selection is now done via
a KCOV_ENABLE ioctl call with corresponding argument value.

Clang instrumentation:
https://clang.llvm.org/docs/SanitizerCoverage.html#tracing-data-flow
Syzkaller:
https://github.com/google/syzkaller

Victor Chibotaru (3):
  kcov: support comparison operands collection
  Makefile: support flag -fsanitizer-coverage=trace-cmp
  kcov: update documentation

 Documentation/dev-tools/kcov.rst |  94 +++++++++++++++++-
 Makefile                         |   5 +-
 include/linux/kcov.h             |  12 ++-
 include/uapi/linux/kcov.h        |  32 ++++++
 kernel/kcov.c                    | 203 ++++++++++++++++++++++++++++++++-------
 lib/Kconfig.debug                |   8 ++
 scripts/Makefile.kcov            |   6 ++
 scripts/Makefile.lib             |   6 ++
 8 files changed, 322 insertions(+), 44 deletions(-)
 create mode 100644 scripts/Makefile.kcov

-- 
2.14.1.581.gf28d330327-goog

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

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

end of thread, other threads:[~2017-09-12 17:42 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-08-30 16:23 [PATCH 0/3] kcov: support comparison operands collection Dmitry Vyukov
2017-08-30 16:23 ` [PATCH 1/3] " Dmitry Vyukov
2017-08-30 16:23   ` Dmitry Vyukov
2017-08-30 18:23   ` Mark Rutland
2017-08-30 18:23     ` Mark Rutland
2017-08-30 19:04     ` Alexander Potapenko
2017-08-30 19:04       ` Alexander Potapenko
2017-08-30 19:08     ` Dmitry Vyukov
2017-08-30 19:08       ` Dmitry Vyukov
2017-08-31  9:31       ` Mark Rutland
2017-08-31  9:31         ` Mark Rutland
2017-09-12 17:41       ` Dmitry Vyukov
2017-09-12 17:41         ` Dmitry Vyukov
2017-08-31 13:27   ` Andrey Konovalov
2017-08-31 13:27     ` Andrey Konovalov
     [not found]   ` <CAPZ9YJZUPYs8nbwG9aO1uCfr7vPY7PNr1WPpvOxP8d+vkMiDJw@mail.gmail.com>
2017-09-12 17:41     ` Dmitry Vyukov
2017-09-12 17:41       ` Dmitry Vyukov
2017-08-30 16:23 ` [PATCH 2/3] Makefile: support flag -fsanitizer-coverage=trace-cmp Dmitry Vyukov
2017-08-30 16:23   ` Dmitry Vyukov
2017-08-30 16:23 ` [PATCH 3/3] kcov: update documentation Dmitry Vyukov
2017-08-30 16:23   ` Dmitry Vyukov

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.