All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
To: "Carlo Marcelo Arenas Belón" <carenas@gmail.com>
Cc: git@vger.kernel.org, gitster@pobox.com, phillip.wood@talktalk.net
Subject: Re: [PATCH 1/2] config.mak.dev: workaround gcc 12 bug affecting "pedantic" CI job
Date: Sat, 16 Apr 2022 01:41:27 +0200	[thread overview]
Message-ID: <220416.8635idc3mk.gmgdl@evledraar.gmail.com> (raw)
In-Reply-To: <20220415231342.35980-2-carenas@gmail.com>


On Fri, Apr 15 2022, Carlo Marcelo Arenas Belón wrote:

> Originally noticed by Peff[1], but yet to be corrected[2] and planned to
> be released with Fedora 36 (scheduled for Apr 19).
>
>   dir.c: In function ‘git_url_basename’:
>   dir.c:3085:13: error: ‘memchr’ specified bound [9223372036854775808, 0] exceeds maximum object size 9223372036854775807 [-Werror=stringop-overread]
>    3085 |         if (memchr(start, '/', end - start) == NULL
>         |             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
> Fedora is used as part of the CI, and therefore that release will trigger
> failures, unless the version of the image used is locked to an older
> release, as an alternative.
>
> Restricting the flag to the affected source file, as well as implementing
> an independent facility to track these workarounds was specifically punted
> to minimize the risk of introducing problems so close to a release.
>
> This change should be reverted once the underlying gcc bug is solved and
> which should be visible by NOT triggering a warning, otherwise.
>
> [1] https://lore.kernel.org/git/YZQhLh2BU5Hquhpo@coredump.intra.peff.net/
> [2] https://bugzilla.redhat.com/show_bug.cgi?id=2075786
>
> Signed-off-by: Carlo Marcelo Arenas Belón <carenas@gmail.com>
> ---
>  config.mak.dev | 5 +++++
>  1 file changed, 5 insertions(+)
>
> diff --git a/config.mak.dev b/config.mak.dev
> index 3deb076d5e3..335efd46203 100644
> --- a/config.mak.dev
> +++ b/config.mak.dev
> @@ -65,4 +65,9 @@ DEVELOPER_CFLAGS += -Wno-uninitialized
>  endif
>  endif
>  
> +# https://bugzilla.redhat.com/show_bug.cgi?id=2075786
> +ifneq ($(filter gcc12,$(COMPILER_FEATURES)),)
> +DEVELOPER_CFLAGS += -Wno-error=stringop-overread
> +endif

What I meant with "just set -Wno-error=stringop-overread on gcc12 for
dir.(o|s|sp)?" was that you can set this per-file:

	dir.sp dir.s dir.o: EXTRA_CPPFLAGS += -Wno-error=stringop-overread

Ditto for the warning suppression in 2/2, we don't currently have any
other warnings like this, but we can suppress them more narrowly.

  reply	other threads:[~2022-04-15 23:45 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-15 12:39 [PATCH] ci: lock "pedantic" job into fedora 35 and other cleanup Carlo Marcelo Arenas Belón
2022-04-15 13:17 ` Ævar Arnfjörð Bjarmason
2022-04-15 13:50 ` Phillip Wood
2022-04-15 18:31 ` Junio C Hamano
2022-04-15 21:03   ` Carlo Arenas
2022-04-15 22:20     ` Junio C Hamano
2022-04-15 23:13 ` [PATCH 0/2] ci: avoid failures for pedantic job with fedora 36 Carlo Marcelo Arenas Belón
2022-04-15 23:13   ` [PATCH 1/2] config.mak.dev: workaround gcc 12 bug affecting "pedantic" CI job Carlo Marcelo Arenas Belón
2022-04-15 23:41     ` Ævar Arnfjörð Bjarmason [this message]
2022-04-16  0:08       ` Carlo Arenas
2022-04-16  0:55         ` Ævar Arnfjörð Bjarmason
2022-04-16  5:56           ` Junio C Hamano
2022-04-16 12:33             ` Ævar Arnfjörð Bjarmason
2022-04-16  0:19       ` Junio C Hamano
2022-04-15 23:56     ` Junio C Hamano
2022-04-15 23:13   ` [PATCH 2/2] config.mak.dev: alternative workaround to gcc 12 warning in http.c Carlo Marcelo Arenas Belón
2022-04-15 23:34     ` Junio C Hamano
2022-04-16  0:02       ` Carlo Arenas
2022-04-16  0:28         ` Junio C Hamano
2022-04-16  0:51           ` Carlo Arenas
2022-04-16  1:00           ` Junio C Hamano
2022-04-16 12:50             ` Ævar Arnfjörð Bjarmason
2022-04-16  1:20           ` Ævar Arnfjörð Bjarmason
2022-04-16 14:23             ` Junio C Hamano
2022-04-16  1:08         ` Ævar Arnfjörð Bjarmason

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=220416.8635idc3mk.gmgdl@evledraar.gmail.com \
    --to=avarab@gmail.com \
    --cc=carenas@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=phillip.wood@talktalk.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 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.