Message ID | 20230228134718.2C43413440@imap2.suse-dmz.suse.de |
---|---|
State | Accepted |
Headers |
Return-Path: <gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5915:0:0:0:0:0 with SMTP id v21csp3022024wrd; Tue, 28 Feb 2023 05:48:29 -0800 (PST) X-Google-Smtp-Source: AK7set9NDYKgzQ8W3zX1PBgTR7ssRWBiExI574/sT9BwHDs+4E2Y5BmQLQlNt29pQOz1lveMDM3i X-Received: by 2002:aa7:c715:0:b0:4ac:bdf7:dffd with SMTP id i21-20020aa7c715000000b004acbdf7dffdmr2957643edq.12.1677592109156; Tue, 28 Feb 2023 05:48:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1677592109; cv=none; d=google.com; s=arc-20160816; b=QacE5lXgHxGkusJy8XSlMX51hbiYlp7G75Ew/jDziCfm0tZySptHAUd+pG3KqLzCtk IA7eh/q4tCGqQDZStVuxc7WYmUMf++6TdCP8pOt7QK+NEKrrxuGWg1Cxc3WXAcgPR7JE KMkzXVspUIScv9ojnuuXqrN/UgbaPqGh5QvsZ6XQ5ZfI3tnNSjYCxZ+8DDS8mTUEfYPA 14eAC9khUCja8aVZ+/I0yj5xebArfX0yo0Z6wJL+XMOBEUR4LM7vi/15hvLKDr8bCenL cInOSgAmCzKeyMemxQXTIqDiJKe5XcKzTt2TAwUKVW6j6FdV11ywxvenQLbia+RYonRP B1zA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:reply-to:from:list-subscribe:list-help:list-post :list-archive:list-unsubscribe:list-id:precedence:message-id :mime-version:subject:to:date:dmarc-filter:delivered-to :dkim-signature:dkim-filter; bh=RUQnQXcXB0U6fIUREsdttO577V3aTfG7LxcRqCKeFoU=; b=nCk3B82Ln4Gu0Yxkr/DZpYxREwGmu6qXFJjr68E4bLB4Ux+gL+aMzPUaRqWw0d5gE4 ucpbVz6D+aOj6F8zB9dU0p00s4ZIopffXCTmhf6xp3iQ7ewfzCdYAOWGmnVUq/zbEVfY CWxf2GgztQCnyq5xQ0aCAiFUNBchBH0vgh2jA57Y/1McJyxIyZb9yaYSh4ecgn2ZfnT8 uUMEbKLHVSL1kDo+fWXwQl+IJPlZDUIfUfQDb8+DPwbPTpJ0+RgpqbwLJQMbuGud7MCd Z38OX4kjR3rVFK4RyA+D7eQQTdp5x1OJ3Pu4foua0s+aUOyRqDJ6xNv0E21xGbJ5HqSj 6z4g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=R7IZVddj; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gnu.org Received: from sourceware.org (server2.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id dy22-20020a05640231f600b004af6e956bd7si380246edb.421.2023.02.28.05.48.29 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 28 Feb 2023 05:48:29 -0800 (PST) Received-SPF: pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) client-ip=8.43.85.97; Authentication-Results: mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=R7IZVddj; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gnu.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id DDE91385087B for <ouuuleilei@gmail.com>; Tue, 28 Feb 2023 13:48:03 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org DDE91385087B DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1677592083; bh=RUQnQXcXB0U6fIUREsdttO577V3aTfG7LxcRqCKeFoU=; h=Date:To:Subject:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:From; b=R7IZVddjTxz+Mg1jsaqnBgbKQ5B+wdMoy+82wjRy+8h3IvmdStpJ789DZXwyfjdV7 YFmp63iygiydDnMCpBjgpYNprte4PWwxzDIFTwHiRnOXRTJ03eg/Pe8blvi3jV5GqK oXdCTW5g26R5Cdxna8t59KNoReO/z5oNLCrp1MJg= X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from smtp-out2.suse.de (smtp-out2.suse.de [IPv6:2001:67c:2178:6::1d]) by sourceware.org (Postfix) with ESMTPS id 257A33858C39 for <gcc-patches@gcc.gnu.org>; Tue, 28 Feb 2023 13:47:19 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 257A33858C39 Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 56AF11FDC1 for <gcc-patches@gcc.gnu.org>; Tue, 28 Feb 2023 13:47:18 +0000 (UTC) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 2C43413440 for <gcc-patches@gcc.gnu.org>; Tue, 28 Feb 2023 13:47:18 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id ImiCCeYF/mMdPwAAMHmgww (envelope-from <rguenther@suse.de>) for <gcc-patches@gcc.gnu.org>; Tue, 28 Feb 2023 13:47:18 +0000 Date: Tue, 28 Feb 2023 14:47:17 +0100 (CET) To: gcc-patches@gcc.gnu.org Subject: [PATCH 1/5] fix anti-range dumping MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Message-Id: <20230228134718.2C43413440@imap2.suse-dmz.suse.de> X-Spam-Status: No, score=-11.7 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list <gcc-patches.gcc.gnu.org> List-Unsubscribe: <https://gcc.gnu.org/mailman/options/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=unsubscribe> List-Archive: <https://gcc.gnu.org/pipermail/gcc-patches/> List-Post: <mailto:gcc-patches@gcc.gnu.org> List-Help: <mailto:gcc-patches-request@gcc.gnu.org?subject=help> List-Subscribe: <https://gcc.gnu.org/mailman/listinfo/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=subscribe> From: Richard Biener via Gcc-patches <gcc-patches@gcc.gnu.org> Reply-To: Richard Biener <rguenther@suse.de> Errors-To: gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org Sender: "Gcc-patches" <gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org> X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1759082823701893599?= X-GMAIL-MSGID: =?utf-8?q?1759082823701893599?= |
Series | Fix irange::legacy_upper_bound | |
Checks
Context | Check | Description |
---|---|---|
snail/gcc-patch-check | success | Github commit url |
Commit Message
Richard Biener
Feb. 28, 2023, 1:47 p.m. UTC
when vrange_printer::visit gets a VR_ANTI_RANGE it should print it as such, not just print the first element as range. When irange::num_pairs and upper/lower_bound are fixed that would no longer print a canonicalized anti-range. * value-range-pretty-print.cc (vrange_printer::visit): Handle all VR_ANTI_RANGE specially. --- gcc/value-range-pretty-print.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Comments
Ughh, you're touching everything I'm nuking next release ;-). But yes, that's an oversight. OK. On Tue, Feb 28, 2023 at 2:48 PM Richard Biener via Gcc-patches <gcc-patches@gcc.gnu.org> wrote: > > when vrange_printer::visit gets a VR_ANTI_RANGE it should print it > as such, not just print the first element as range. When > irange::num_pairs and upper/lower_bound are fixed that would no > longer print a canonicalized anti-range. > > * value-range-pretty-print.cc (vrange_printer::visit): > Handle all VR_ANTI_RANGE specially. > --- > gcc/value-range-pretty-print.cc | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/gcc/value-range-pretty-print.cc b/gcc/value-range-pretty-print.cc > index d20e2562431..23817f48a3d 100644 > --- a/gcc/value-range-pretty-print.cc > +++ b/gcc/value-range-pretty-print.cc > @@ -64,7 +64,7 @@ vrange_printer::visit (const irange &r) const > return; > } > // Handle legacy symbolics. > - if (!r.constant_p ()) > + if (!r.constant_p () || r.kind () == VR_ANTI_RANGE) > { > if (r.kind () == VR_ANTI_RANGE) > pp_character (pp, '~'); > -- > 2.35.3 >
diff --git a/gcc/value-range-pretty-print.cc b/gcc/value-range-pretty-print.cc index d20e2562431..23817f48a3d 100644 --- a/gcc/value-range-pretty-print.cc +++ b/gcc/value-range-pretty-print.cc @@ -64,7 +64,7 @@ vrange_printer::visit (const irange &r) const return; } // Handle legacy symbolics. - if (!r.constant_p ()) + if (!r.constant_p () || r.kind () == VR_ANTI_RANGE) { if (r.kind () == VR_ANTI_RANGE) pp_character (pp, '~');