From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Vibhav Pant Newsgroups: gmane.emacs.bugs,gmane.emacs.devel Subject: bug#26518: 26.0.50; M-x bubbles crashes emacs Date: Sun, 16 Apr 2017 20:26:27 +0530 Message-ID: References: <87bmrxhi88.fsf@rosalinde> <83vaq5g27v.fsf@gnu.org> <83pogdfxem.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Trace: blaine.gmane.org 1492354637 22718 195.159.176.226 (16 Apr 2017 14:57:17 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 16 Apr 2017 14:57:17 +0000 (UTC) Cc: Stephen Berman , 26518@debbugs.gnu.org To: Eli Zaretskii , "emacs-devel@gnu.org" Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Apr 16 16:57:10 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1czlbw-0005kD-UQ for geb-bug-gnu-emacs@m.gmane.org; Sun, 16 Apr 2017 16:57:09 +0200 Original-Received: from localhost ([::1]:60825 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1czlc2-0001zi-3a for geb-bug-gnu-emacs@m.gmane.org; Sun, 16 Apr 2017 10:57:14 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:44739) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1czlbt-0001xx-6e for bug-gnu-emacs@gnu.org; Sun, 16 Apr 2017 10:57:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1czlbq-0002gA-57 for bug-gnu-emacs@gnu.org; Sun, 16 Apr 2017 10:57:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:52672) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1czlbq-0002fR-1U for bug-gnu-emacs@gnu.org; Sun, 16 Apr 2017 10:57:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1czlbp-0006qx-Rc for bug-gnu-emacs@gnu.org; Sun, 16 Apr 2017 10:57:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Vibhav Pant Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 16 Apr 2017 14:57:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 26518 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 26518-submit@debbugs.gnu.org id=B26518.149235461626331 (code B ref 26518); Sun, 16 Apr 2017 14:57:01 +0000 Original-Received: (at 26518) by debbugs.gnu.org; 16 Apr 2017 14:56:56 +0000 Original-Received: from localhost ([127.0.0.1]:50871 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1czlbj-0006qd-Lx for submit@debbugs.gnu.org; Sun, 16 Apr 2017 10:56:55 -0400 Original-Received: from mail-yw0-f178.google.com ([209.85.161.178]:34437) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1czlbh-0006qQ-GD for 26518@debbugs.gnu.org; Sun, 16 Apr 2017 10:56:53 -0400 Original-Received: by mail-yw0-f178.google.com with SMTP id k13so48623811ywk.1 for <26518@debbugs.gnu.org>; Sun, 16 Apr 2017 07:56:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=8yHQWjtoC3FNnFh5QarVAWlzdh6+1kpemlunuEGZIwU=; b=oURM1OhSjyjZi0GBSgwqZTatrR4HwqNPYZP+Bu7B3TPSxoh9J/+fPdEZjCpRCYwYQo TOIWU4e7EUrmgUrgj18KflHNvf8snq/B2/EtFr/fz8jMmlCKnH8UbkLdt1U8C8EzTlc/ okk2eTVxCuGJUw6G/z7logTPzyQjCUCDd0u8lC4KUBS3NR/8qCAxWJsHOmvN1GIYCrQN +F+yoS7AFSu4Z/vciwRw0nn7nsI/C9aR4g2Ex4ffA4JWcP9osjmNOVWJuQ9VJTPEShqE go5JuFBdOyj9Z7oUIvqg6zqDkD4iY074fMgUNgpo0MiywMhAharz6h5tk+gbBLR8HraT 0Bww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=8yHQWjtoC3FNnFh5QarVAWlzdh6+1kpemlunuEGZIwU=; b=tGbW8nmocw0lj88I/C1n41h/Y7uqKnfzJeD/4EJGn+HntPjZWLBxiXfU4Ho10XOczy 1uQ35DHZZjn4jZH1+aheUN4zDIR0PVpQMNzOfSYwBEC17lZHd3SFWdfbYWbgsHR/CeS3 lbHmgX2Ju8fxBNxowgaVdrLP3ReAIag/i3950yRTOzJ3yqMwTXO+xpTIW3GvpyxliFqH MPVAwj0Qpzs4yMgXhiX64UrzsuUx2M71XAAfRNcw8HfDlDraO4CJ7n2ClQaDEPka36Xs K7WZkw5Nrw1xbUs5UQlGFG2pXLj0+fgTK58Jqgh2/CkwJ0VdYYn2DO5hKdgms0PDtGNP vvmg== X-Gm-Message-State: AN3rC/7pMdJ6oIxK4YpjzlT1+t6JUfxV7hb1maO7niJ4YxZ41RKW0zOU OvPGu0Tluw7VZaahH0/zj7j+MWJMdw== X-Received: by 10.129.141.82 with SMTP id w18mr13889316ywj.139.1492354607656; Sun, 16 Apr 2017 07:56:47 -0700 (PDT) Original-Received: by 10.129.117.85 with HTTP; Sun, 16 Apr 2017 07:56:27 -0700 (PDT) In-Reply-To: <83pogdfxem.fsf@gnu.org> 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: 208.118.235.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:131650 gmane.emacs.devel:214003 Archived-At: The following code also crashes Emacs: (defun fun1 (v) (car (cond ((eq v 1) '(one . 1)) ((eq v 2) '(two . 2)) ((eq v 3) '(three . 3))))) (byte-compile 'fun1) (defun fun2 (v) (inline (fun1 v))) (byte-compile 'fun2) (fun2 1) The problem lies in byte-compile-inline-lapcode not being able to inline bytecode that uses switch, because the peephole optimizer will often merge tags and convert goto-to-return to returns, making it impossible restore the correct byte-compile-depth while inlining it. I can think of two ways to fix this: Disable certain optimizations for byte-switch code, and allow the jump table to store certain properties that will make it possible to inline switch code properly (specifically, the donetag). This could be done by replacing the hash table with a (DONETAG . JUMP-TABLE) cons pair (inline-lapcode would use the car, while the bytecode VM would use it's cdr). Disable inlining byte-switch code entirely. However, this would impact performance negatively. Thoughts? Regards, Vibhav -- Vibhav Pant vibhavp@gmail.com