The GC is enabled when we create initial symbols. The function make_this_symbol initializes symbols from a static table as follows: 1. initialize symbol structure fields 2. associate the symbol with its package 3. associate the symbol with its function 4. increment cl_num_symbols_in_core Most notably in point 2: s->symbol.name = ecl_make_constant_base_string(name,-1); GC's stacks_scanner marks [cl_symbols; cl_symbols+cl_num_symbols_in_core] in other words, if the GC kicks in between 1. and 4., the symbol name may be garbage collected, messing the symbol name and package exports. To mitigate that, we assign intermediate values on the stack and increment the number of symbols in core after the symbol is initialized: 1. store initialization values on stack -- cl_object foo = alloc(); 2. initialize symbol structure fields 3. increment cl_num_symbols_in_core 4. associate the symbol with its package and function |
||
|---|---|---|
| contrib | ||
| examples | ||
| msvc | ||
| src | ||
| .gitignore | ||
| .gitlab-ci.yml | ||
| appveyor.yml | ||
| CHANGELOG | ||
| configure | ||
| COPYING | ||
| INSTALL | ||
| LICENSE | ||
| Makefile.in | ||
| README.md | ||
ECL stands for Embeddable Common-Lisp. The ECL project aims to produce an implementation of the Common-Lisp language which complies to the ANSI X3J13 definition of the language.
The term embeddable refers to the fact that ECL includes a Lisp to C compiler, which produces libraries (static or dynamic) that can be called from C programs. Furthermore, ECL can produce standalone executables from Lisp code and can itself be linked to your programs as a shared library. It also features an interpreter for situations when a C compiler isn't available.
ECL supports the operating systems Linux, FreeBSD, NetBSD, DragonFly BSD, OpenBSD, Solaris (at least v. 9), Microsoft Windows (MSVC, MinGW and Cygwin) and OSX, running on top of the Intel, Sparc, Alpha, ARM and PowerPC processors. Porting to other architectures should be rather easy.