From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Noam Postavsky Newsgroups: gmane.emacs.bugs Subject: bug#24358: 25.1.50; re-search-forward errors with "Variable binding depth exceeds max-specpdl-size" Date: Sun, 23 Oct 2016 19:18:32 -0400 Message-ID: References: <87eg3rvtsf.fsf@users.sourceforge.net> <83k2dihpm9.fsf@gnu.org> <8760p2wzgj.fsf@users.sourceforge.net> <838ttyhhzu.fsf@gnu.org> <871szqwu51.fsf@users.sourceforge.net> <831szqhbc2.fsf@gnu.org> <87h98hujcx.fsf@users.sourceforge.net> <831szkahyz.fsf@gnu.org> <87eg3jvfj6.fsf@users.sourceforge.net> <8360ov8lbu.fsf@gnu.org> <877f95uj66.fsf@users.sourceforge.net> <83zim0vn1t.fsf@gnu.org> <874m48v7wj.fsf@users.sourceforge.net> <83insov1zr.fsf@gnu.org> <87zilztzd5.fsf@users.sourceforge.net> <83oa2ftnvp.fsf@gnu.org> <87wph2ts1a.fsf@users.sourceforge.net> <83oa2erx0k.fsf@gnu.org> <87lgxht8hp.fsf@users.sourceforge.net> <871sz8kq2v.fsf@gmail.com> <87shroroh8.fsf@users.sourceforge.net> <838ttfpnxt.fsf@gnu.org> <83vawjo21l.fsf@gnu.org> <83bmybnopx.fsf@gnu.org> <8360ojnk0n.fsf@gnu.org> <83twc3m198.fsf@gnu.org> <83pomrlz27.fsf@gnu.org> <83lgxenao0.fsf@gnu.org> <83insin9n8.fsf@gnu.org> <83h982n7k4.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 1477264778 13304 195.159.176.226 (23 Oct 2016 23:19:38 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 23 Oct 2016 23:19:38 +0000 (UTC) Cc: Sam Halliday , 24358@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Oct 24 01:19:34 2016 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 1byS2q-00005G-1j for geb-bug-gnu-emacs@m.gmane.org; Mon, 24 Oct 2016 01:19:12 +0200 Original-Received: from localhost ([::1]:42817 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1byS2s-000657-Ek for geb-bug-gnu-emacs@m.gmane.org; Sun, 23 Oct 2016 19:19:14 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:48948) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1byS2j-000650-8R for bug-gnu-emacs@gnu.org; Sun, 23 Oct 2016 19:19:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1byS2g-0006kH-3Q for bug-gnu-emacs@gnu.org; Sun, 23 Oct 2016 19:19:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:35262) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1byS2f-0006io-Vm for bug-gnu-emacs@gnu.org; Sun, 23 Oct 2016 19:19:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1byS2f-00067c-Ox for bug-gnu-emacs@gnu.org; Sun, 23 Oct 2016 19:19:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Noam Postavsky Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 23 Oct 2016 23:19:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 24358 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch fixed Original-Received: via spool by 24358-submit@debbugs.gnu.org id=B24358.147726472023436 (code B ref 24358); Sun, 23 Oct 2016 23:19:01 +0000 Original-Received: (at 24358) by debbugs.gnu.org; 23 Oct 2016 23:18:40 +0000 Original-Received: from localhost ([127.0.0.1]:50659 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1byS2K-00065v-IK for submit@debbugs.gnu.org; Sun, 23 Oct 2016 19:18:40 -0400 Original-Received: from mail-yw0-f173.google.com ([209.85.161.173]:36463) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1byS2J-00065P-4z for 24358@debbugs.gnu.org; Sun, 23 Oct 2016 19:18:39 -0400 Original-Received: by mail-yw0-f173.google.com with SMTP id u124so153853753ywg.3 for <24358@debbugs.gnu.org>; Sun, 23 Oct 2016 16:18:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=kSvDsujOkhfQ9oLJMCe9mebCJ7sI+tcx2hE9rlWmmiU=; b=OXODpJFc2Q151oR/S5d/1aGYgMA5fxDY630r0TYpvO9Wql/7FeLtiPsrT/qBb0XF9e prF3nDgL5pJeiis5Qa0bB3eIz1VAYIPQN6AgD7yKucA6PIAhNTiFvd3I34EUE2y3xuaB +kx+vJ0h1XXMlnPKucK1gGTaxb5HXbO7f1GeWSmIIxXL5bOAwFS0Efc0ndjG48rJ4vR3 MJ3RXtaxcUpcKpOIA0D35HgKQ6GCNrXQwI6vVPzi9uRRS5inao78z7RfZNngX2V3jL8J UnszC+0naaQG7jI/eCuAUCspls/4STc5QxbtPNw/VMJK3Bf68SG7jXb5P39xu6u05j6y yUzg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc; bh=kSvDsujOkhfQ9oLJMCe9mebCJ7sI+tcx2hE9rlWmmiU=; b=YGWZ+PIj178+9a4pIM18o2Fj5tBMaI0VkYct9qpX+ALpTWX/7WTh6WSi3F8Eq24T9i k+xquXLBGLb6/+GdyPr/BBil4Ufy46YV8DZ5Kx99ELbJFhvx7SL7sT9I91kv4DWIAYdJ Fmvjn+X7uMtShTi7fwRSsKqjbV6j++pcF5mHVQuKwU4uz5TMbbz0qMQh4P2qYqmyGMHl ZQ+Nb/eyxCzVqdWDi889SxNmJCVh1WqYtctdsOfkxw3jufTXXgDKuwl0rSpOWu++u5xG Pjcxx25U92AiQZJNFIFcOit/VyX/HXCdagTKmg4CJxuR6zeuRug7H8PGe9Hx4C7ZWF8t mz9w== X-Gm-Message-State: ABUngvfOmvO4MbykGEZMosTpgBecQdzJUKU4Y9FxzMQ7hlDB2zM57nZ1fsRkkrtQc40nOJNwrpglsMjyS60pbg== X-Received: by 10.157.9.201 with SMTP id 9mr364988otz.14.1477264713456; Sun, 23 Oct 2016 16:18:33 -0700 (PDT) Original-Received: by 10.157.29.239 with HTTP; Sun, 23 Oct 2016 16:18:32 -0700 (PDT) In-Reply-To: <83h982n7k4.fsf@gnu.org> X-Google-Sender-Auth: nCi_3g8hBiGCqqrFhh_TT5m2VZ0 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:124938 Archived-At: Eli Zaretskii wrote: > Noam, do you configure Emacs with --enable-check-lisp-object-type? > If not, please do, because that's what Sam does; perhaps that is the > reason why he gets the problem and you don't. > > One other difference is that Sam is running a bootstrap, so his > bootstrap-emacs used to build ja-dic has the necessary Lisp files > loaded as *.el files, not *.elc. Therefore another thing to try > (perhaps even before reconfiguring) is a full bootstrap, preferably in > a separate clean directory, maybe you will see this problem then. I will try both of these tomorrow. Sam, if you want to post the docker thing somewhere I can give that a try tomorrow as well, in case Eli's suggestions are not sufficient to reproduce this. > Noam, there's something I don't understand here: why is regex.c using > malloc for allocating the failure stack? AFAICS, REGEX_MALLOC is not > defined, so the only way I can explain this to myself is that we use > SAFE_ALLOCA, and that falls back to malloc because the failure stack > needs more than 16KB of memory. Is that correct? Yes, this is correct, see also http://debbugs.gnu.org/cgi/bugreport.cgi?bug=24358#47 > > If so, then one other way of solving the original problem that doesn't > open the gates of the ralloc.c hell is to allow a larger amount of > stack allocations in regex.c before we fall back to malloc. Since the > maximum size of the failure stack is limited by something like 800KB, > and the C stack limit is set in main.c to allow the failure stack be > allocated off the stack, why don't we make use of this fact? It sounds reasonable in principle. This would mean changing MAX_ALLOCA?