Fwd: SOLVED: Was Garbage collector - ccl:terminate (memory stuff)

GrĂ©gory Vanuxem <[email protected]> Fri, 31 May 2024 19:05:28 +0200
Newsgroups gmane.lisp.openmcl.devel
Message-ID <CAHnU2davgBu21c5=GXaD0FJziZOpdrWi86DoEva7D6DdOr1OCQ@mail.gmail.com>
Sorry, when you respond to a mail in this mailing-list, it is not sent
to the mailing-list itself, I am not used.

---------- Forwarded message ---------
De : Gr=C3=A9gory Vanuxem <[email protected]>
Date: ven. 31 mai 2024 =C3=A0 19:03
Subject: Re: SOLVED: Was Garbage collector - ccl:terminate (memory stuff)
To: Robert Munyer <[email protected]>


Hello,

Le mer. 22 mai 2024 =C3=A0 23:22, Gr=C3=A9gory Vanuxem <[email protected]=
> a =C3=A9crit :

[snip]

> But a question remains: why, after a
> save-application, and running directly at startup the above method,
> fricas can not use ccl:::terminate, apparently only the "main" thread
> is allowed to do that?

Do I add an issue to GitHub or forget it, it is the expected behaviour?

- Greg

PS: Just to know.

> Thanks all!
>
> - Greg
>
> PS: the diff when saving FriCAS application
>
>           (top-fun #'(lambda ()
>                         (set-initial-parameters)
> -                       (funcall restart-fun))))
> +                       (funcall restart-fun)
> +                       (ccl::toplevel-loop))))
>          (setf *ccl-default-directory* ccl-dir)
> -        (setf *my-toplevel-function* top-fun)
> -        (CCL::save-application core-image
> -                                       :PREPEND-KERNEL t
> -                                       :application-class 'fricas-applic=
ation)
> +        (CCL::save-application core-image :toplevel-function top-fun
> +                                       :PREPEND-KERNEL t)
>          (QUIT))
>