ksummit.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
From: "Luis R. Rodriguez" <mcgrof@suse.com>
To: David Howells <dhowells@redhat.com>
Cc: Michael Matz <matz@suse.de>,
	agraf@suse.de, ksummit-discuss@lists.linuxfoundation.org,
	valentinrothberg@gmail.com
Subject: Re: [Ksummit-discuss] [TECH TOPIC] Compiler shopping list
Date: Mon, 25 Jul 2016 20:49:16 +0200	[thread overview]
Message-ID: <20160725184916.GR5537@wotan.suse.de> (raw)
In-Reply-To: <15569.1469184060@warthog.procyon.org.uk>

On Fri, Jul 22, 2016 at 11:41:00AM +0100, David Howells wrote:
> Are there additional things we can get the compiler to do for us?  Some
> things I've seen brought up:
> 
>  (1) Additional __atomic_*() ops could be useful.  Suggestions I've heard
>      include direct LL/SC support - though the compiler people don't seem so
>      keen on that.
> 
>  (2) -mmodel=kernel flag so that the compiler can optimise better for the
>      kernel memory model.

Do we have enough compiler folk presentation attending? I know a few kernel
developers take on compiler features on their own these days, but I think
this is rather rare.

One idea that came up while evaluating further optimizations possible with
paravirtualized kernels was the possibility of supporting a thing called
"compiler multiverse" support [0] which would try to generalize the binary
patching technique used in the Linux kernel for use for any application. While
this topic and precise domain interests only a very few, a generic solution for
this sort of problem has uses outside of PV support, and even outside of Linux.
One of the side benefits of a thing could be for instance a mechanism to avoid
/ vet for dead code and vetting such code never runs. I've had my eyes on a
kernel-based solution for this, compiler multiverse support is a counter idea
by Alexander that came up in evaluating similar issues with other code bases
(qemu in particular) and trying to brain storm a more general solution.

I'll note, as it stands, the potential size constraints (even though only bool
has been considered), and the fact we already have a framework for dealing with
some of these sorts of things (although not exactly this very feature -- *yet*),
has put this feature lower on a priority list of things to write it is worth
mentioning should others out there working on the kernel likely be looking for
something similar to help address dead code and which would be generic as well.
A kernel-based-only solution pivoted on our existing alternatives model and
further features still being developed may enable such feature without this
compiler feature, but this is still in the works.

If this is a topic of interest folks required would be:

  o Michael Matz <matz@suse.de>
  o Valentin Rothberg <valentinrothberg@gmail.com>
  o Alexander Graf <agraf@suse.de>

This sort of feature is useful when distributions support large variability
and such variability incurs significant run time deltas, and dead code becomes
more of a concern.

[0] https://kernelnewbies.org/KernelProjects/compiler-multiverse

  Luis

  parent reply	other threads:[~2016-07-25 18:49 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-22 10:41 David Howells
2016-07-22 15:52 ` Christian Borntraeger
2016-07-22 15:59   ` David Woodhouse
2016-07-22 17:05     ` Christian Borntraeger
2016-07-22 17:17       ` James Bottomley
2016-07-22 17:33         ` David Woodhouse
2016-07-29  1:16       ` Steven Rostedt
2016-07-23 20:35     ` Benjamin Herrenschmidt
2016-07-23 23:09       ` Alexei Starovoitov
2016-07-25 18:49 ` Luis R. Rodriguez [this message]
2016-07-29  1:32 ` Steven Rostedt

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=20160725184916.GR5537@wotan.suse.de \
    --to=mcgrof@suse.com \
    --cc=agraf@suse.de \
    --cc=dhowells@redhat.com \
    --cc=ksummit-discuss@lists.linuxfoundation.org \
    --cc=matz@suse.de \
    --cc=valentinrothberg@gmail.com \
    /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