From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Andrea Corallo via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#46540: 28.0.50; Native-comp optimization bug Date: Wed, 17 Feb 2021 21:11:53 +0000 Message-ID: References: Reply-To: Andrea Corallo Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="11158"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: 46540@debbugs.gnu.org, Pip Cet To: qythium@gmail.com Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Feb 17 22:39:04 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lCUXG-0002lm-RG for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 17 Feb 2021 22:39:02 +0100 Original-Received: from localhost ([::1]:49850 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lCUXF-0000iZ-OY for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 17 Feb 2021 16:39:01 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:45258) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lCU78-000099-Mz for bug-gnu-emacs@gnu.org; Wed, 17 Feb 2021 16:12:03 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:33709) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lCU78-0003fu-Fe for bug-gnu-emacs@gnu.org; Wed, 17 Feb 2021 16:12:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lCU78-00074W-Av for bug-gnu-emacs@gnu.org; Wed, 17 Feb 2021 16:12:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Andrea Corallo Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 17 Feb 2021 21:12:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 46540 X-GNU-PR-Package: emacs Original-Received: via spool by 46540-submit@debbugs.gnu.org id=B46540.161359631827174 (code B ref 46540); Wed, 17 Feb 2021 21:12:02 +0000 Original-Received: (at 46540) by debbugs.gnu.org; 17 Feb 2021 21:11:58 +0000 Original-Received: from localhost ([127.0.0.1]:45255 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lCU74-00074E-5K for submit@debbugs.gnu.org; Wed, 17 Feb 2021 16:11:58 -0500 Original-Received: from mx.sdf.org ([205.166.94.24]:50885) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lCU72-000744-2y for 46540@debbugs.gnu.org; Wed, 17 Feb 2021 16:11:57 -0500 Original-Received: from mab (ma.sdf.org [205.166.94.33]) by mx.sdf.org (8.15.2/8.14.5) with ESMTPS id 11HLBr3B003708 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits) verified NO); Wed, 17 Feb 2021 21:11:54 GMT In-Reply-To: (Pip Cet's message of "Wed, 17 Feb 2021 07:50:00 +0000") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:200222 Archived-At: Pip Cet writes: > On Tue, Feb 16, 2021 at 9:44 PM Andrea Corallo wrote: >> The following constrain insn clearly resolves in the wrong way: >> >> (assume #(mvar 79140560 0 (integer 0 0)) (<= #(mvar 79118120 0 (integer 0 *)) #(mvar 79118988 3 (integer 0 *)))) >> >> Will come-up with a fix. > > My guess is that this code in comp-cstr.el: > > (defun comp-cstr-<= (dst old-dst src) > "Constraint DST being <= than SRC. > SRC can be either a comp-cstr or an integer." > (with-comp-cstr-accessors > (let ((ext-range > (if (integerp src) > `((- . ,src)) > (when-let* ((range (range src)) > (low (comp-cstr-smallest-in-range range)) > (okay (integerp low))) > `((- . ,low)))))) > (comp-cstr-set-cmp-range dst old-dst ext-range)))) > > should use comp-cstr-greatest-in-range rather than > comp-cstr-smallest-in-range. Same for comp-cstr-<. Analogous for > comp-cstr->, comp-cstr->=. > > (If A's possible values are {3, 4, 5}, and B is <= A, we can only > conclude B <= 5, not that B <= 3, since A = 5, B = 5 is a solution to > the constraint problem). Yep, Pip spot on. Small oversight from me... :D 1fe5994bcb should fix. Yu Han Quek would you mind to confirm rx now works as excpected for you? Thanks Andrea