From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Rafael D Sorkin Newsgroups: gmane.emacs.bugs Subject: bug#20427: bug in optimizing compiler? Date: Sun, 26 Apr 2015 00:15:51 -0400 Message-ID: Reply-To: Rafael D Sorkin NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1430021847 14486 80.91.229.3 (26 Apr 2015 04:17:27 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 26 Apr 2015 04:17:27 +0000 (UTC) To: 20427@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Apr 26 06:17:13 2015 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1YmE0E-0006FU-Fq for geb-bug-gnu-emacs@m.gmane.org; Sun, 26 Apr 2015 06:17:10 +0200 Original-Received: from localhost ([::1]:49851 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YmE0D-0001qo-Fw for geb-bug-gnu-emacs@m.gmane.org; Sun, 26 Apr 2015 00:17:09 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:45416) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YmE09-0001nq-Jo for bug-gnu-emacs@gnu.org; Sun, 26 Apr 2015 00:17:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YmE06-0001KM-6N for bug-gnu-emacs@gnu.org; Sun, 26 Apr 2015 00:17:05 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:50314) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YmE06-0001KG-4R for bug-gnu-emacs@gnu.org; Sun, 26 Apr 2015 00:17:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1YmE05-00073Q-RV for bug-gnu-emacs@gnu.org; Sun, 26 Apr 2015 00:17:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Rafael D Sorkin Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 26 Apr 2015 04:17:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 20427 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.143002176625548 (code B ref -1); Sun, 26 Apr 2015 04:17:01 +0000 Original-Received: (at submit) by debbugs.gnu.org; 26 Apr 2015 04:16:06 +0000 Original-Received: from localhost ([127.0.0.1]:40090 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1YmDzB-0006dg-Q4 for submit@debbugs.gnu.org; Sun, 26 Apr 2015 00:16:06 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:59974) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1YmDzA-0006WL-Fo for submit@debbugs.gnu.org; Sun, 26 Apr 2015 00:16:05 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YmDz4-00019l-61 for submit@debbugs.gnu.org; Sun, 26 Apr 2015 00:15:59 -0400 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:50275) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YmDz4-00019U-1n for submit@debbugs.gnu.org; Sun, 26 Apr 2015 00:15:58 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:45247) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YmDz2-0001Li-Tw for bug-gnu-emacs@gnu.org; Sun, 26 Apr 2015 00:15:57 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YmDyz-000178-OS for bug-gnu-emacs@gnu.org; Sun, 26 Apr 2015 00:15:56 -0400 Original-Received: from mail-qg0-f100.google.com ([209.85.192.100]:36673) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YmDyz-000171-Kz for bug-gnu-emacs@gnu.org; Sun, 26 Apr 2015 00:15:53 -0400 Original-Received: by qgdz60 with SMTP id z60so2892098qgd.3 for ; Sat, 25 Apr 2015 21:15:52 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:reply-to:from:to:subject:message-id:date; bh=MWH7gdUT6atWdoTvVvr5VistfPRAXI8UCUzfbu5ZVsY=; b=PDkrwaTXjPaMiqkjk5mOoAhe2F16pZd3ZIR1AYN/Oketw96F5jMRVrm9g3IKAN38c/ MMNSrQfUMx0BjrQ7cQ3jF5DpicNu5Tb7+gdn7GgTf+KZ1f58OEbPO/atCtCh2sLOY4BI J/9uw2sJ1J7invZ5/i7aOxI872TteumJN0UDOScp6+hDuWOf+ogTks3tRRnqPfhDLNxQ 4N5IGxfSOQf4uN+QZNoNJBGcf7bWxTZml6txiGgOCEzXL5A3Vyfu6AoRqrA/qiPrXtkq 8gP8pxufO8LBiLcA5F3OW/i/wAnbGelb1fdy/iCoLIaeclhf0xVbpz95F/58SmEPhCmo hPTw== X-Gm-Message-State: ALoCoQlMzBx9IcgKjuA5M2TGcoiD/+/U68Z1vfGHugWHwCMpmQ/UGxYSg235j/JWjCYB6PibwmGkSFd89Q5K3t+OSssxjChtkw== X-Received: by 10.50.119.101 with SMTP id kt5mr2793979igb.49.1430021752204; Sat, 25 Apr 2015 21:15:52 -0700 (PDT) Original-Received: from mail2.pi.local (nat.perimeterinstitute.ca. [107.6.61.163]) by mx.google.com with ESMTP id ee9sm361618igb.4.2015.04.25.21.15.51; Sat, 25 Apr 2015 21:15:52 -0700 (PDT) X-Relaying-Domain: perimeterinstitute.ca Original-Received: from mars.pi.local (mars.pi.local [10.10.7.6]) by mail2.pi.local (Postfix) with ESMTPS id 93890C0964; Sat, 25 Apr 2015 22:06:37 -0500 (CDT) Original-Received: from rsorkin by mars.pi.local with local (Exim 4.69) (envelope-from ) id 1YmDyx-0003q2-LQ; Sun, 26 Apr 2015 00:15:51 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.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-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:102048 Archived-At: The following report refers to this version of emacs: GNU Emacs 24.3.1 (x86_64-pc-linux-gnu, GTK+ Version 3.10.7) of 2014-03-07 on lamiak, modified by Debian Hello, When I byte-compile a file containing the following code, with optimization safety=0, the compiler deletes the assertion test. (defmacro buggy () (assert nil nil "assertion failed -- it always should fail") "This should never show up!") This only seems to happen when i compile a file containing the macro, not when i compile the macro individually. Here is a full example (the defmacro of `buggy' is in the file "bug.test.el") (declaim (optimize (safety 3))) (byte-compile-file "bug.test.el" 'load) ; t (buggy) ; error: "assertion failed -- it always should fail" (declaim (optimize (safety 0))) (byte-compile-file "bug.test.el" 'load) ; t (buggy) ; This should never show up! I'm not sure whether this officially qualifies as a bug, but it's certainly not the behavior I was expecting. (It also doesn't seem to be present in Emacs 23.1.1) Thanks, Rafael ~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~- Rafael Sorkin Perimeter Institute for Theoretical Physics 31 Caroline Street North Waterloo, ON N2L 2Y5 Canada ~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-