From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#35770: [PATCH] Broken duplicate case elimination in switch byte-compilation Date: Sun, 26 May 2019 21:43:09 +0300 Message-ID: <838sut2h1e.fsf@gnu.org> References: <91DFE4D0-BDB6-4365-BA51-A2A3F209177C@acm.org> <752237291204505cd6b3fb98f667c2718fa6361f.camel@acm.org> <7C514C39-A204-44F4-A806-0B7DC3F4E6B4@acm.org> <83sgt67o2x.fsf@gnu.org> <87d0kaag5z.fsf@gmail.com> <83r28q7mxo.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="267048"; mail-complaints-to="usenet@blaine.gmane.org" Cc: npostavs@gmail.com, 35770@debbugs.gnu.org, vibhavp@gmail.com, monnier@iro.umontreal.ca To: Mattias =?UTF-8?Q?Engdeg=C3=A5rd?= Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun May 26 20:44:21 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hUy85-0017Jw-9z for geb-bug-gnu-emacs@m.gmane.org; Sun, 26 May 2019 20:44:21 +0200 Original-Received: from localhost ([127.0.0.1]:60005 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hUy83-0002Nh-Qb for geb-bug-gnu-emacs@m.gmane.org; Sun, 26 May 2019 14:44:19 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:37543) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hUy7p-0002Nc-5Y for bug-gnu-emacs@gnu.org; Sun, 26 May 2019 14:44:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hUy7m-0005De-3k for bug-gnu-emacs@gnu.org; Sun, 26 May 2019 14:44:05 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:38203) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hUy7m-0005Da-1O for bug-gnu-emacs@gnu.org; Sun, 26 May 2019 14:44:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hUy7l-0007xq-Uh for bug-gnu-emacs@gnu.org; Sun, 26 May 2019 14:44:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 26 May 2019 18:44:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 35770 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 35770-submit@debbugs.gnu.org id=B35770.155889619830545 (code B ref 35770); Sun, 26 May 2019 18:44:01 +0000 Original-Received: (at 35770) by debbugs.gnu.org; 26 May 2019 18:43:18 +0000 Original-Received: from localhost ([127.0.0.1]:51747 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hUy73-0007wb-NT for submit@debbugs.gnu.org; Sun, 26 May 2019 14:43:17 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:51310) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hUy71-0007wO-Q4 for 35770@debbugs.gnu.org; Sun, 26 May 2019 14:43:16 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:48926) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hUy6u-0004aY-CL; Sun, 26 May 2019 14:43:09 -0400 Original-Received: from [176.228.60.248] (port=3019 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1hUy6t-0005JF-Lr; Sun, 26 May 2019 14:43:08 -0400 In-reply-to: (message from Mattias =?UTF-8?Q?Engdeg=C3=A5rd?= on Sun, 26 May 2019 19:05:55 +0200) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:159795 Archived-At: > From: Mattias EngdegÄrd > Date: Sun, 26 May 2019 19:05:55 +0200 > Cc: Eli Zaretskii , Noam Postavsky , > vibhavp@gmail.com, 35770@debbugs.gnu.org > > 22 maj 2019 kl. 16.19 skrev Stefan Monnier : > > > > turning off byte-compile-cond-use-jump-table by default is the safer way > > to do that, I think. > > Is the consensus then that the patch is fine for master, and that the switch op generation should be disabled by default in emacs-26? Maybe with an explanation in the doc string: > > -(defcustom byte-compile-cond-use-jump-table t > - "Compile `cond' clauses to a jump table implementation (using a hash-table)." > +(defcustom byte-compile-cond-use-jump-table nil > + "Compile `cond' clauses to a jump table implementation (using a hash-table). > + > +In Emacs 26, this feature is disabled by default because of a bug > +in the code generation of `cond' forms with duplicated test clauses." > :version "26.1" > :group 'bytecomp > :type 'boolean) I don't think we should explain why we did this in a doc string. And :version should change as well. More generally, I can't say I like this, and don't understand why this would be better than reverting the offending change on emacs-26. Why is it a problem to defer the features which caused the regression to Emacs 27?