From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-ej1-x62b.google.com (mail-ej1-x62b.google.com [IPv6:2a00:1450:4864:20::62b]) by sourceware.org (Postfix) with ESMTPS id A76513858D32 for ; Mon, 5 Sep 2022 09:14:11 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org A76513858D32 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-ej1-x62b.google.com with SMTP id og21so15791105ejc.2 for ; Mon, 05 Sep 2022 02:14:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date; bh=7WRcrXRUTl4BqupwTOR5NbOoyeqcdNByBHR3+hsp+po=; b=IuO2Jo28QhzkMEGj7SSTAH3dywEHMlk8RBLWv76Ovxcc8rdl8PMijbyYlQpUT18Zwg S29lbVQ9BC8vgCEpWLlQAhWq255MW43C5e6ikYURH73i4JLRUuIeQ/eRPJ0kPVQbAxIy 5oxcAyJY1gzHXk5abYVKEyOrBbzRKiwaDfov09tTQVXkcoI4dGmzYAtEI+uDabrgJoQf enKzijQk8lm3YUdlF73pCyShxuUGFZOYVVwn2wHdwW9vnuKMIVwe0uJFGQli0Yhqu1ML m0bBchb580l8gFeJSSmGuKGbnm3+6B+ehydLWKYtOHxtUkd5ktE0kcy2WfDaeQCjOnCk 38mQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date; bh=7WRcrXRUTl4BqupwTOR5NbOoyeqcdNByBHR3+hsp+po=; b=rQR5v/se6IO2NUutFn/Q2LQQ37NWtrqCsmphceZ2Kfm5x3+9mkanyi0lk7qLzvO87K B5PwOa1o+PNyGAeES3kl+JURr8Qt7LRxEgj0cwyO8fmTX5e2VTtu2lueAa4HOxsOGgR0 7iIjopKDMMPgeO87bitS0+faB5Qldm/5crv8/hknEt3xCgy/ASYaQ42En+coCQqNmoT1 sPl+iWcqMDLT82pfomeekeFrLpHWBvGZbyXd0lBrKLcChVmPefqkFFCuEceb9FZT5CUh vLf1WmCn5fClkGD55fZCFoVaH58Ko0LhZBkT6nFS3d3J8UBaBKh5j/4ZmMlDUaFT/hUI gXrQ== X-Gm-Message-State: ACgBeo3OFx3+50sIOcLV/C0Yh7yj1965goSx23H553E8DzwzmHFRJ7v6 CkMGqiYiBKkRGyhTHikNyuZDxXBkXBq0GIMyrJP6dMN5 X-Google-Smtp-Source: AA6agR7YdNCd0YvNk/BO+nK+Jgk6tppOkbmSJIUuWrjH1S9iV3hZVLGseTFsY05OD7cDPw9z/mF3xZ3J3ooCGlxaAMg= X-Received: by 2002:a17:906:5d16:b0:74c:32ce:208b with SMTP id g22-20020a1709065d1600b0074c32ce208bmr11880653ejt.594.1662369250334; Mon, 05 Sep 2022 02:14:10 -0700 (PDT) MIME-Version: 1.0 References: <20220905062301.3240191-1-aldyh@redhat.com> In-Reply-To: From: Richard Biener Date: Mon, 5 Sep 2022 11:13:58 +0200 Message-ID: Subject: Re: [COMMITTED] Be even more conservative in intersection of NANs. To: Jakub Jelinek Cc: Aldy Hernandez , GCC patches Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-2.2 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On Mon, Sep 5, 2022 at 11:06 AM Jakub Jelinek wrote: > > On Mon, Sep 05, 2022 at 11:00:54AM +0200, Richard Biener wrote: > > On Mon, Sep 5, 2022 at 8:24 AM Aldy Hernandez via Gcc-patches > > wrote: > > > > > > Intersecting two ranges where one is a NAN is keeping the sign bit of > > > the NAN range. This is not correct as the sign bits may not match. > > > > > > I think the only time we're absolutely sure about the intersection of > > > a NAN and something else, is when both are a NAN with exactly the same > > > properties (sign bit). If we're intersecting two NANs of differing > > > sign, we can decide later whether that's undefined or just a NAN with > > > no known sign. For now I've done the latter. > > > > > > I'm still mentally working on intersections involving NANs, especially > > > if we want to keep track of signbits. For now, let's be extra careful > > > and only do things we're absolutely sure about. > > > > > > Later we may want to fold the intersect of [NAN,NAN] and say [3,5] > > > with the posibility of NAN, to a NAN, but I'm not 100% sure. > > > > The intersection of [NAN, NAN] and [3, 5] is empty. The intersection > > of [NAN, NAN] and VARYING is [NAN, NAN]. > > I think [3.0, 5.0] printed that way currently means U maybe NAN, > it would be [3.0, 5.0] !NAN if it was known not to be NAN. Uh, that's confusing. So [3, 5] U maybe NAN intersected with ][ NAN is ][ NAN. [3, 5] !NAN intersected with ][ NAN is ][ !NAN. In fact [3, 5] U maybe NAN is just [3, 5] U NAN, there's no "maybe" ranges, if the value may be NAN then NAN is in the value-range. So it's either [3, 5] U NAN or [3, 5] (without U NAN). Richard. > > Jakub >