kernel-hardening.lists.openwall.com archive mirror
 help / color / mirror / Atom feed
From: Emese Revfy <re.emese@gmail.com>
To: Kees Cook <keescook@chromium.org>
Cc: linux-kbuild <linux-kbuild@vger.kernel.org>,
	PaX Team <pageexec@freemail.hu>,
	Brad Spengler <spender@grsecurity.net>,
	"kernel-hardening@lists.openwall.com"
	<kernel-hardening@lists.openwall.com>,
	Michal Marek <mmarek@suse.com>,
	"linux-doc@vger.kernel.org" <linux-doc@vger.kernel.org>
Subject: [kernel-hardening] Re: [PATCH 3/3] Documentation for the GCC plugin infrastructure
Date: Tue, 9 Feb 2016 20:14:30 +0100	[thread overview]
Message-ID: <20160209201430.67b852830e40e74e4e80762f@gmail.com> (raw)
In-Reply-To: <CAGXu5j+ugmECzm7-ppjVLd=oii5tewUxrRVc5T25hdodeVkq2g@mail.gmail.com>

On Mon, 8 Feb 2016 20:27:31 -0800
Kees Cook <keescook@chromium.org> wrote:

> On Sun, Feb 7, 2016 at 1:32 PM, Emese Revfy <re.emese@gmail.com> wrote:
> > This is the GCC infrastructure documentation about its operation, how to add
> > and use a new plugin with an example.
> >
> > ---
> >  Documentation/example_gcc_plugin.c | 103 +++++++++++++++++++++++++++++++++++++
> 
> Perhaps this example should live in samples/gcc_plugin/ ?

Perhaps the example plugin is unnecessary. I should use the cyclomatic complexity plugin
because I already wrote about it in the sections "Usage" and "How to add a new GCC plugin"
and they differ by only two lines.

> For an example, I'd expect verbose comments. :) Imagine someone
> reading it who knows very little about plugins or compiler internals.

I think gcc has very good documentation about plugins, I reference them from gcc-plugins.txt,
you can see it below. If you think it isn't enough tell me please what you would like to
see as additional documentation.  

> > +1. Introduction
> > +===============
> > +
> > +GCC plugins are loadable modules that provide extra features to the
> > +compiler [1]. They are useful for runtime instrumentation and static analysis.
> > +We can analyse, change and add further code during compilation via
> > +callbacks [2], GIMPLE [3], IPA [4] and RTL passes [5].
> > +
> > +The GCC plugin infrastructure of the kernel supports all gcc versions from
> > +4.5 to 6.0, building out-of-tree modules, cross-compilation and building in a
> > +separate directory.
> > +
> > +Currently the GCC plugin infrastructure supports only the x86 architecture.
> > +
> > +This infrastructure was ported from grsecurity [6] and PaX [7].
> > +
> > +--
> > +[1] https://gcc.gnu.org/onlinedocs/gccint/Plugins.html
> > +[2] https://gcc.gnu.org/onlinedocs/gccint/Plugin-API.html#Plugin-API
> > +[3] https://gcc.gnu.org/onlinedocs/gccint/GIMPLE.html
> > +[4] https://gcc.gnu.org/onlinedocs/gccint/IPA.html
> > +[5] https://gcc.gnu.org/onlinedocs/gccint/RTL.html
> > +[6] https://grsecurity.net/
> > +[7] https://pax.grsecurity.net/

-- 
Emese

      reply	other threads:[~2016-02-09 19:14 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-07 21:27 [kernel-hardening] [PATCH 0/3] Introduce GCC plugin infrastructure Emese Revfy
2016-02-07 21:28 ` [kernel-hardening] [PATCH 1/3] " Emese Revfy
2016-02-08 20:28   ` [kernel-hardening] " Michal Marek
2016-02-08 21:31     ` Emese Revfy
2016-02-07 21:31 ` [kernel-hardening] [PATCH 2/3] Add Cyclomatic complexity GCC plugin Emese Revfy
2016-02-07 23:05   ` [kernel-hardening] " Rasmus Villemoes
2016-02-08 21:20     ` Emese Revfy
2016-02-09  4:23   ` Kees Cook
2016-02-09 18:55     ` Emese Revfy
2016-02-07 21:32 ` [kernel-hardening] [PATCH 3/3] Documentation for the GCC plugin infrastructure Emese Revfy
2016-02-09  4:27   ` [kernel-hardening] " Kees Cook
2016-02-09 19:14     ` Emese Revfy [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160209201430.67b852830e40e74e4e80762f@gmail.com \
    --to=re.emese@gmail.com \
    --cc=keescook@chromium.org \
    --cc=kernel-hardening@lists.openwall.com \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=mmarek@suse.com \
    --cc=pageexec@freemail.hu \
    --cc=spender@grsecurity.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).