public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "zeccav at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libfortran/81986] sanitizer detects negation of large number in string.c
Date: Sat, 27 Feb 2021 09:21:58 +0000	[thread overview]
Message-ID: <bug-81986-4-5ajg1SUHi4@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-81986-4@http.gcc.gnu.org/bugzilla/>

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81986

Vittorio Zecca <zeccav at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|sanitizer                   |libfortran

--- Comment #4 from Vittorio Zecca <zeccav at gmail dot com> ---
On current trunk with sanitized libgfortran.so.5 I get

gfortran gfbug142.f
ldd ./a.out
        ........
        libgfortran.so.5 =>
/home/vitti/gcc-150221-undefined/x86_64-pc-linux-gnu/libgfortran/.libs/libgfortran.so.5
(0x000014a739133000)
        libubsan.so.1 =>
/home/vitti/local/gcc-150221-undefined/lib/../lib64/libubsan.so.1
(0x000014a738293000)
        libstdc++.so.6 =>
/home/vitti/local/gcc-150221-undefined/lib/../lib64/libstdc++.so.6
        ................

./a.out
../../../gcc-150221/libgfortran/io/write.c:835:7: runtime error: negation of
0x80000000000000000000000000000000 cannot be represented in type '__int128';
cast to an unsigned type to negate this value to itself
../../../gcc-150221/libgfortran/runtime/string.c:199:11: runtime error:
negation of 0x80000000000000000000000000000000 cannot be represented in type
'__int128'; cast to an unsigned type to negate this value to itself
80000000000000000000000000000000

       reply	other threads:[~2021-02-27  9:21 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <bug-81986-4@http.gcc.gnu.org/bugzilla/>
2021-02-27  9:21 ` zeccav at gmail dot com [this message]
2021-02-28 11:04 ` dominiq at lps dot ens.fr
2021-03-03  7:08 ` cvs-commit at gcc dot gnu.org
2021-03-03 11:03 ` dominiq at lps dot ens.fr
2021-12-25 13:04 ` fxcoudert at gcc dot gnu.org
2021-12-25 14:57 ` fxcoudert at gcc dot gnu.org

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=bug-81986-4-5ajg1SUHi4@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.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.
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).