From: Pip Cet <pipcet@gmail.com>
To: Andrea Corallo <akrl@sdf.org>
Cc: 46540@debbugs.gnu.org, qythium@gmail.com
Subject: bug#46540: 28.0.50; Native-comp optimization bug
Date: Wed, 17 Feb 2021 07:50:00 +0000 [thread overview]
Message-ID: <CAOqdjBc_-v61DJUoxuD6obANFmvU33Yg8o_PndVFeugj14dKNg@mail.gmail.com> (raw)
In-Reply-To: <xjfzh03r8n2.fsf@sdf.org>
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).
next prev parent reply other threads:[~2021-02-17 7:50 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-02-15 19:19 bug#46540: 28.0.50; Native-comp optimization bug Yu Han Quek
2021-02-15 20:08 ` Andrea Corallo via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-02-16 21:43 ` Andrea Corallo via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-02-17 7:50 ` Pip Cet [this message]
2021-02-17 21:11 ` Andrea Corallo via Bug reports for GNU Emacs, the Swiss army knife of text editors
[not found] ` <CAGCUw0iUhX4xJK=2LYYVDECV7qo7RtS_Z2JewyFLu3dLXD_tYg@mail.gmail.com>
2021-02-18 8:01 ` Andrea Corallo via Bug reports for GNU Emacs, the Swiss army knife of text editors
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAOqdjBc_-v61DJUoxuD6obANFmvU33Yg8o_PndVFeugj14dKNg@mail.gmail.com \
--to=pipcet@gmail.com \
--cc=46540@debbugs.gnu.org \
--cc=akrl@sdf.org \
--cc=qythium@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).