Menu ▾ ▴

#5649 Maxima built with ECL ignores the stack options of the maxima script

None
open
nobody
ECL (11)
5
2026-10-05
2026-10-05
No

By Claude:

The maxima script starts Maxima built with ECL with --frame-stack 4096 --lisp-stack 65536 and the options in MAXIMA_LISP_OPTIONS, but Maxima runs with ECL's defaults, a frame stack of 2048 and a Lisp stack of 32768, and MAXIMA_LISP_OPTIONS cannot change them either. With ECL 26.5.5 on Linux:

./maxima-local --no-init -q --batch-string=$':lisp (print (list (ext:get-limit (quote ext:frame-stack)) (ext:get-limit (quote ext:lisp-stack))))\ng(n) := if n = 0 then 0 else catch(1 + g(n - 1))$\ng(600);'
(2048 32768) 
(2048 32768)
(%i1) g(n):=if n = 0 then 0 else catch(1+g(n-1))
(%i2) g(600)
Maxima encountered a Lisp error:

 FRAME-STACK overflow at size 2048. Stack can probably be resized.
Proceed with caution.

Automatically continuing.
To enable the Lisp debugger set *debugger-hook* to nil.

The recursion through catch needs more than 2048 frames, which the frame stack of 4096 that the script asks for would hold.

Discussion


Log in to post a comment.