GNU bug report logs -
#27779
26.0.50: read -- Re-entering top level after C stack overflow
Previous Next
Reported by: Keith David Bershatsky <esq <at> lawlist.com>
Date: Fri, 21 Jul 2017 02:13:01 UTC
Severity: normal
Tags: confirmed, moreinfo
Merged with 25160
Found in version 26.0.50
Done: Paul Eggert <eggert <at> cs.ucla.edu>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
TWO (2) TESTS:
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; TEST # 1.
SOURCE: git clone -b emacs-26 git://git.sv.gnu.org/emacs.git
CONFIGURE:
CFLAGS='-Wall -O2 -g3' ./configure \
--with-ns \
--enable-checking='yes,glyphs' \
--enable-check-lisp-object-type \
--without-compress-install \
--without-makeinfo \
--with-gnutls=no \
--with-mailutils \
--without-makeinfo
LISP:
(require 'cl-lib)
(defun make-deep-object (depth)
(let ((obj 1))
(while (> (cl-decf depth) 0)
(setq obj (vector (list obj))))
obj))
;;; STACK OVERFLOW: problem with `read'
;;; The bug was introduced on December 8, 2016 with
;;; commit: f0a1e9ec3fba3d5bea5bd62f525dba3fb005d1b1
(let* ((print-circle t)
(max-lisp-eval-depth most-positive-fixnum)
(max-specpdl-size most-positive-fixnum)
(deep-object (make-deep-object 6000))
(string (prin1-to-string deep-object))
(result (read string)))
(when result
(message "Bug #27779: Success! (%d)" (length string))))
TEST: Lanched without the terminal by opening Emacs.app.
RESULT: Bug #27779: Success! (23997)
No need to set the terminal with "ulimit -S -s unlimited" before launching Emacs from the terminal.
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; TEST # 2.
SOURCE: git clone -b emacs-26 git://git.sv.gnu.org/emacs.git
CONFIGURE:
CFLAGS='-Wall -O0 -g3' ./configure \
--with-ns \
--enable-check-lisp-object-type \
--without-compress-install \
--without-makeinfo \
--with-gnutls=no \
--with-mailutils \
--without-makeinfo
LISP:
(require 'cl-lib)
(defun make-deep-object (depth)
(let ((obj 1))
(while (> (cl-decf depth) 0)
(setq obj (vector (list obj))))
obj))
;;; STACK OVERFLOW: problem with `read'
;;; The bug was introduced on December 8, 2016 with
;;; commit: f0a1e9ec3fba3d5bea5bd62f525dba3fb005d1b1
(let* ((print-circle t)
(max-lisp-eval-depth most-positive-fixnum)
(max-specpdl-size most-positive-fixnum)
(deep-object (make-deep-object 6000))
(string (prin1-to-string deep-object))
(result (read string)))
(when result
(message "Bug #27779: Success! (%d)" (length string))))
TEST: Lanched without the terminal by opening Emacs.app.
RESULT: Re-entering top level after C stack overflow
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
> Date: [05-02-2019 00:26:45] <2 May 2019 00:26:45 -0700>
> From: Paul Eggert <eggert <at> cs.ucla.edu>
> To: Keith David Bershatsky <esq <at> lawlist.com>, Noam Postavsky <npostavs <at> gmail.com>
> Cc: 27779 <at> debbugs.gnu.org, mail <at> vasilij.de
> Subject: Re: bug#27779: #27779; C stack overflow from `read' on deeply nested lisp object.
>
> Keith David Bershatsky wrote:
> > CONFIGURE: CFLAGS='-Wall -O0 -g3' ./configure \
> > --with-ns \
> > --enable-checking='yes,glyphs' \
> > --enable-check-lisp-object-type \
> > --without-compress-install \
> > --without-makeinfo \
> > --with-gnutls=no \
> > --with-mailutils \
> > --without-makeinfo
>
> What happens if you try it with -O2 rather than -O0?
>
> Also, what happens if you try it without --enable-checking='yes,glyphs'?
>
> I have a suspicion that the debugging options are blowing the stack.
This bug report was last modified 3 years and 83 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.