public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* False warnings on arm-gcc?
@ 2022-07-29  8:56 Amol
  2022-07-29 22:54 ` Martin Sebor
  0 siblings, 1 reply; 2+ messages in thread
From: Amol @ 2022-07-29  8:56 UTC (permalink / raw)
  To: gcc-help; +Cc: suratiamol

Hello,

The compilation of a program at [1] raises warnings which say that it
attempted to write beyond the buffer when it did not.

Cmdline given to godbolt's arm-gcc-trunk(Linux) compiler:
-O3 -mno-unaligned-access -ffreestanding -mfloat-abi=soft

Changing O3 to O2, or defaulting to hard float-abi, or removing
-mno-unaligned-access, or removing -ffreestanding - any one these
four steps result in a compilatoin with no warnings at all.

Is it because of any alignment or other issues that the program has
neglected?

Thanks,
Amol

[1] https://godbolt.org/z/rGvxP5qsr

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-07-29 22:54 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-29  8:56 False warnings on arm-gcc? Amol
2022-07-29 22:54 ` Martin Sebor

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 read-only IMAP folder(s) and NNTP newsgroup(s).