From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTPS id D9E1E385840D for ; Thu, 13 Jan 2022 16:58:47 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org D9E1E385840D Received: from mail-qv1-f69.google.com (mail-qv1-f69.google.com [209.85.219.69]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-542-ArtDpIwKO2C_HX_C4MLFMQ-1; Thu, 13 Jan 2022 11:58:41 -0500 X-MC-Unique: ArtDpIwKO2C_HX_C4MLFMQ-1 Received: by mail-qv1-f69.google.com with SMTP id ge12-20020a05621427cc00b00410de1dc898so6292756qvb.9 for ; Thu, 13 Jan 2022 08:58:41 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:cc:references:from:in-reply-to :content-transfer-encoding; bh=2NPfosp2YCdpkqvKRkFJ2XylQRSFt+EhFeM3VOCXmdA=; b=vVZSGF+pQTsm/imzL3hA63FdTxfe4aT3Hr69men53FLLpwYWA85nkgAWZCNBbWl/q0 QF+nLo2S5oTmxuFD//b7fgki7/D/ye0Xu2XRipY0192oN8YB62HRNCwllKueV+4Sr8n/ avk3P/v4k1MVa/EdQs8XOIyp5diiMXJEXWgiYF0HAp2YVYV49csOOXKQMxo6akaSLxkI DMozhU/BKjfBpYL7Fa6tgt+vnrqbkVo7gkDU9G93x0f82PI3eVnNS5AguOoB36cB0K7S kvFVjJ4BAGocfMQgCOWJSi5iV9nkBe/llaUKW1j31+C+wbnE6DuZbBTtxiUiXWLmjV5K N6nA== X-Gm-Message-State: AOAM5303XkkEPjaLsv6oA3Q5fiWNkGA0Dx32RKDr6af+iAiCMHTPcRvW MXpXJtx/Taw+RHwTe5xeOqvb8KQZoIE7Gb/X4UHuB3G9TlNdDaKq3fzM6PSpllOfGWbuo73f5UH 8cE+pgEC1yX0A83llFw== X-Received: by 2002:a37:5445:: with SMTP id i66mr3679624qkb.204.1642093121035; Thu, 13 Jan 2022 08:58:41 -0800 (PST) X-Google-Smtp-Source: ABdhPJz9wLZ0BblLRQV6DmUMek7xaqDPX/cmFyQnOgjKWHxKYYpkIuPdW+3AagPf44ZnZbRLYjyoQg== X-Received: by 2002:a37:5445:: with SMTP id i66mr3679615qkb.204.1642093120803; Thu, 13 Jan 2022 08:58:40 -0800 (PST) Received: from ?IPV6:2607:fea8:a262:5f00:e36d:32da:80f:d4e1? ([2607:fea8:a262:5f00:e36d:32da:80f:d4e1]) by smtp.gmail.com with ESMTPSA id z15sm2419820qtj.77.2022.01.13.08.58.40 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 13 Jan 2022 08:58:40 -0800 (PST) Message-ID: Date: Thu, 13 Jan 2022 11:58:39 -0500 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.4.1 Subject: Re: [PATCH] tree-optimization/83072 - Allow more precision when querying from fold_const. To: Richard Biener Cc: gcc-patches References: <159ff48e-32cf-da90-5b74-262b94d04095@redhat.com> From: Andrew MacLeod In-Reply-To: X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Language: en-CA Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-6.2 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, KAM_SHORT, NICE_REPLY_A, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) 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 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Jan 2022 16:58:49 -0000 On 1/13/22 10:13, Richard Biener wrote: > On Thu, Jan 13, 2022 at 2:59 PM Andrew MacLeod via Gcc-patches > wrote: >> This patch actually addresses a few PRs. >> >> The root PR was 97909. Ranger context functionality was added to >> fold_const back in early November >> (https://gcc.gnu.org/pipermail/gcc-patches/2021-November/583216.html) >> >> The other 2 PRs mentioned (83072 and 83073) partially worked after this, >> but the original patch did not change the result of the query in >> expr_not_equal_to () to a multi-range object. >> >> This patch simply changes the value_range variable in that routine to an >> int_range<5> so we can pick up more precision. This in turn allows us to >> capture all the tests as expected. >> >> Bootstrapped on x86_64-pc-linux-gnu with no regressions. >> >> OK for trunk? > OK (though I wonder why not use int_range_max?) > No good reason..  Initially it was just because I wasn't familiar with what call chains might end up here, but really, I guess it doesn't matter. I can change it to int_range_max before committing it. Andrew