[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
eval proposals
From: |
Dmitry Antipov |
Subject: |
eval proposals |
Date: |
Fri, 06 Jun 2014 19:33:41 +0400 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.5.0 |
I would like to propose and discuss two small features below:
1) Protection against C stack overflow caused by enormously huge
`max-lisp-eval-depth'. Note that the stack size limit is examined
just once (because doing it each time when eval_sub or funcall is
called introduces too much overhead), but some OSes are capable to
change this limit when the program is running (prlimit on Linux,
for example).
2) Capability to shrink specpdl stack if it becomes too large. When
`max-specpdl-size' is 83200000 and `max-lisp-eval-depth' is 640000,
this extreme example with 10K let bindings:
(defun f ()
(let ((x0 0)
(x1 1)
...
(x9999 9999)) (f)))
creates 73622255-slots specpdl stack before running out of C stack
on my system, which results in 2.5G RSS. And currently there is no
way to reduce it back to reasonable size.
Dmitry
eval.patch
Description: Text Data
- eval proposals,
Dmitry Antipov <=