c-std-porting.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
From: Florian Weimer <fweimer@redhat.com>
To: "G. Branden Robinson" <g.branden.robinson@gmail.com>
Cc: debian-devel@lists.debian.org,  debian-gcc@lists.debian.org,
	c-std-porting@lists.linux.dev
Subject: Re: RFC: More C errors by default in GCC 14 (no more implicit function declarations etc.)
Date: Wed, 19 Apr 2023 14:06:03 +0200	[thread overview]
Message-ID: <87a5z42i1g.fsf@oldenburg.str.redhat.com> (raw)
In-Reply-To: <20230418225420.qoedd6vam4pkobin@illithid> (G. Branden Robinson's message of "Tue, 18 Apr 2023 17:54:20 -0500")

* G. Branden Robinson:

> Perhaps the thing to do here is have, <gulp>, yet another command-line
> option for GCC.  The Ada language did something similar a couple of
> decades ago to tighten up the language for hard real-time demands, with
> what it called the "Ravenscar profile".[1]  That proved successful (as
> successful as anything was in poor neglected Ada).

The C++ front end calls this -fpermissive, which would probably match
here as well.

> Whatever its name, some advantages to this approach are that
> distributors could opt-in to such a thing, make it a clear matter of
> policy, and more easily track adoption and progress.  You could also
> version the contour much like the C standard itself.

I'm not sure if we need this fine level of control.  Either you want to
compile at all costs, or you are willing to make the effort to clean up
the sources.  At a package level, the required changes are almost always
minor (but of course there are packages that are different), so fixing
everything in one go (and the implied commitment to keep up with future
cleanups_ is not very onerous.  For one package, that is.

I'm not sure if opt-in is that easy because packages drop build flags
all the time.  Compiler wrapper scripts might be required.  The
instrumented compiler we use in Fedora sometimes reveals things that go
unnoticed with other approaches.

Thanks,
Florian


  parent reply	other threads:[~2023-04-19 12:06 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-18 14:07 RFC: More C errors by default in GCC 14 (no more implicit function declarations etc.) Florian Weimer
2023-04-18 22:54 ` G. Branden Robinson
2023-04-18 23:17   ` Guillem Jover
2023-04-19 12:06   ` Florian Weimer [this message]
2023-04-19  0:25 ` Paul Wise
2023-04-19  1:14   ` Arsen Arsenović
2023-04-19  2:39 ` Oskari Pirhonen
2023-04-19  4:10   ` Sam James

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=87a5z42i1g.fsf@oldenburg.str.redhat.com \
    --to=fweimer@redhat.com \
    --cc=c-std-porting@lists.linux.dev \
    --cc=debian-devel@lists.debian.org \
    --cc=debian-gcc@lists.debian.org \
    --cc=g.branden.robinson@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;
as well as URLs for NNTP newsgroup(s).