From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS22989 209.51.188.0/24 X-Spam-Status: No, score=-4.3 required=3.0 tests=AWL,BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_DNSWL_LOW, SPF_HELO_NONE,SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id 862D21F487 for ; Sun, 29 Mar 2020 23:22:09 +0000 (UTC) Received: from localhost ([::1]:42660 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jIhFo-00089F-AV for normalperson@yhbt.net; Sun, 29 Mar 2020 19:22:08 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35479) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jIhFl-000898-56 for bug-gnulib@gnu.org; Sun, 29 Mar 2020 19:22:06 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jIhFk-0001OF-0s for bug-gnulib@gnu.org; Sun, 29 Mar 2020 19:22:05 -0400 Received: from mail-io1-xd2d.google.com ([2607:f8b0:4864:20::d2d]:37101) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jIhFj-0001Nv-Qp for bug-gnulib@gnu.org; Sun, 29 Mar 2020 19:22:03 -0400 Received: by mail-io1-xd2d.google.com with SMTP id q9so15850303iod.4 for ; Sun, 29 Mar 2020 16:22:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:reply-to:from:date:message-id :subject:to:cc; bh=oMP+W4zG26YUBSKkA1qWNhPmH0KRKWMD5I+mndNTRZs=; b=qhsB0cUY+ftE5LWtbOsyKVW+wyIc+7B/aWej3SJS5356XqJmtQE2XFcirbHMmAZ8iP 2aZ6Zp9GqawiFrkvKe9to0wNo/SaESYPkenFE1Y6X7zX365KTKgYye4Oz5Lm9oc5Cz2P jT6TSplZKQrTiRU7Cb+wVSzQLXEAEyelKXD+XIQ7PxpAliVrATmA9its4kYiAF7SBhlu 4TGYA2LajX/bVyZDPQkrHyfBrm0nE0GTu2hkYvtBoY0n07NchKIkidMGJYM36h6fyFQk SFHN1X1Uo0ypRdUrkAmAX9nJXnYOLpQfW68GPnk/2N5B8wDwPtG+sF431HBiuw7e7h2G R9Kw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:reply-to :from:date:message-id:subject:to:cc; bh=oMP+W4zG26YUBSKkA1qWNhPmH0KRKWMD5I+mndNTRZs=; b=RmTZUyrq7IE0eiySRUxklc+Z08IM5dnR1sReyibRXL5n24jg8ltf1Bt9BwEe3bMdWo mQDW+KC/wfI2A+QPkMqU+m/G2J8LCPeH+ZrtVfR1sEA10fF4q6Z8YAl8U27nUVIeMgzj wRJqhsYn59FktacvRMQpGX9MXEmMFz/Vp43jLxVQi54SniTwHnfYjRiZ4bNAYFq6FfJs 90l01zppLWaTxbV5Va78+EqwLbVheQjhVRZ4ejRI1r4vm5fKdJy2teQ5nP/Ehs4jd8qG 1w7ObEi6QUyd7DpbMQN6GuHQaoMzk1fmCGdh5hzoG33agiGphEXugKN4/1fB8liMXPAF Jzow== X-Gm-Message-State: ANhLgQ0huX09qGXiNguHHWFuxI4mbSit8H+WVZ0Q5av9XWnNUr9+/N/0 SUHSZp1LNFSFpvU7vl+eDakDzq+dwEBGjoEwC/NUubmN6aY= X-Google-Smtp-Source: ADFU+vsehJWc+HWaiX2czwr9P9YDlzCtXceG7SBA2wPev5x1ldHhFeWduvUHCdFiDDs0s3p0WG7FBLLbOuCSlTfBrGo= X-Received: by 2002:a05:6638:28d:: with SMTP id c13mr8705456jaq.17.1585524122844; Sun, 29 Mar 2020 16:22:02 -0700 (PDT) MIME-Version: 1.0 References: <1848192.VuvhVD494M@omega> <1665625.n3MASsG4Sn@omega> In-Reply-To: <1665625.n3MASsG4Sn@omega> From: Jeffrey Walton Date: Sun, 29 Mar 2020 19:21:52 -0400 Message-ID: Subject: Re: test-math.c:89:3: runtime error: division by zero To: Bruno Haible Content-Type: text/plain; charset="UTF-8" X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4864:20::d2d X-BeenThere: bug-gnulib@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Gnulib discussion list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: noloader@gmail.com Cc: bug-gnulib@gnu.org Errors-To: bug-gnulib-bounces+normalperson=yhbt.net@gnu.org Sender: "bug-gnulib" On Sun, Mar 29, 2020 at 5:59 PM Bruno Haible wrote: > > Jeffrey Walton wrote: > > Let's see what the GCC folks recommend: "GCC and division by 0 under > > sanitizers", https://gcc.gnu.org/pipermail/gcc-help/2020-March/138746.html. > > The way I interpret their answer > https://gcc.gnu.org/pipermail/gcc-help/2020-March/138747.html > is: > 1) You need to distinguish integer division by zero and floating-point > division by zero. > 2) For floating-point division by zero GCC warns but should not warn. > You should enter a bug report about this. > 3) The undefined-behaviour sanitizer should report integer division by zero > but not floating-point division by zero ("as it can be a legitimate way > of obtaining infinities and NaNs"). > > In the gnulib code, test-math.c:89, we clearly have a floating-point > division by zero. Yeah, GCC looks partially clean. It is not producing a sanitizer finding, so I guess no blood, no foul. Clang is a problem: https://bugs.llvm.org/show_bug.cgi?id=45352. Jeff