all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "N. Jackson" <njackson@posteo.net>
To: emacs-devel@gnu.org
Subject: pdumper.c Wstringop-overflow warnings with CFLAGS="-O3" [Re: Emacs 29.2 released]
Date: Fri, 19 Jan 2024 01:40:31 +0000	[thread overview]
Message-ID: <87a5p23xtc.fsf@moondust.localdomain> (raw)
In-Reply-To: <83ttnaaojz.fsf@gnu.org> (Eli Zaretskii's message of "Thu, 18 Jan 2024 13:06:24 +0200")


At 13:06 +0200 on Thursday 2024-01-18, Eli Zaretskii wrote:
>
> Version 29.2 of Emacs, the extensible text editor, should now
> be available

Thank you Eli for your stalwart maintenance of Emacs and to everyone
else who has contributed recently (and, indeed, ever).

Building Emacs 29.2 with CFLAGS="-O3" I get four Wstringop-overflow
warnings in pdumper.c (see below).  Can I (as an Emacs user) safely
ignore these warnings?  Note: I don't get these warnings with
CFLAGS="-O2".

My version of gcc is:

  gcc (GCC) 13.2.1 20231011 (Red Hat 13.2.1-4)

The four warnings are:

  In function ‘dump_field_lv_or_rawptr’,
      inlined from ‘dump_field_lv_rawptr’ at pdumper.c:1882:3,
      inlined from ‘dump_field_finalizer_ref’ at pdumper.c:2205:5,
      inlined from ‘dump_field_finalizer_ref’ at pdumper.c:2197:1,
      inlined from ‘dump_finalizer’ at pdumper.c:2222:3:
  pdumper.c:1863:3: warning: writing 8 bytes into a region of size 0 [-Wstringop-overflow=]
   1863 |   memcpy (out_field, &out_value, sizeof (out_value));
        |   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

and

  In function ‘cpyptr’,
      inlined from ‘dump_field_emacs_ptr’ at pdumper.c:1967:3,
      inlined from ‘dump_field_emacs_ptr’ at pdumper.c:1949:1,
      inlined from ‘dump_field_finalizer_ref’ at pdumper.c:2203:5,
      inlined from ‘dump_finalizer’ at pdumper.c:2222:3:
  pdumper.c:1774:3: warning: writing 8 bytes into a region of size 0 [-Wstringop-overflow=]
   1774 |   memcpy (out, in, sizeof (void *));
        |   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

and

  In function ‘cpyptr’,
      inlined from ‘dump_field_emacs_ptr’ at pdumper.c:1967:3,
      inlined from ‘dump_field_emacs_ptr’ at pdumper.c:1949:1,
      inlined from ‘dump_field_finalizer_ref’ at pdumper.c:2203:5,
      inlined from ‘dump_finalizer’ at pdumper.c:2223:3:
  pdumper.c:1774:3: warning: writing 8 bytes into a region of size 0 [-Wstringop-overflow=]
   1774 |   memcpy (out, in, sizeof (void *));
        |   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

and

  In function ‘dump_field_lv_or_rawptr’,
      inlined from ‘dump_field_lv_rawptr’ at pdumper.c:1882:3,
      inlined from ‘dump_field_finalizer_ref’ at pdumper.c:2205:5,
      inlined from ‘dump_field_finalizer_ref’ at pdumper.c:2197:1,
      inlined from ‘dump_finalizer’ at pdumper.c:2223:3:
  pdumper.c:1863:3: warning: writing 8 bytes into a region of size 0 [-Wstringop-overflow=]
   1863 |   memcpy (out_field, &out_value, sizeof (out_value));
        |   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Thanks.

N.



  parent reply	other threads:[~2024-01-19  1:40 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-18 11:06 Emacs 29.2 released Eli Zaretskii
2024-01-18 12:06 ` Po Lu
2024-01-18 12:27   ` Eli Zaretskii
2024-01-18 12:38     ` Po Lu
2024-01-18 13:00       ` Eli Zaretskii
2024-01-20 14:41         ` Eli Zaretskii
2024-01-22  6:20           ` Po Lu
2024-01-23 17:41             ` Eli Zaretskii
2024-01-19  1:40 ` N. Jackson [this message]
2024-01-19  7:23   ` pdumper.c Wstringop-overflow warnings with CFLAGS="-O3" [Re: Emacs 29.2 released] Eli Zaretskii
2024-01-19 21:22 ` Emacs 29.2 released Michael Albinus
2024-01-20  6:51   ` Eli Zaretskii
2024-01-20  8:17     ` Michael Albinus
2024-01-20  9:01       ` Eli Zaretskii

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=87a5p23xtc.fsf@moondust.localdomain \
    --to=njackson@posteo.net \
    --cc=emacs-devel@gnu.org \
    /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.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

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.