Commit graph

8078 commits

Author SHA1 Message Date
Marius Gerbershagen
9176710d96 src/util: add script to run the testsuite on android 2021-01-30 15:41:45 +01:00
Marius Gerbershagen
3302289cdd Merge branch 'apple-arm64' into 'develop'
config-internal.h: automatically set ECL_C_COMPATIBLE_VARIADIC_DISPATCH for apple/arm64

See merge request embeddable-common-lisp/ecl!243
2021-01-30 12:50:47 +00:00
Marius Gerbershagen
d4e5a96c23 config-internal.h: automatically set ECL_C_COMPATIBLE_VARIADIC_DISPATCH for apple/arm64 2021-01-29 19:46:01 +01:00
Marius Gerbershagen
19780e2033 Merge branch 'xcode12-fixes' into 'develop'
Xcode12 fixes

See merge request embeddable-common-lisp/ecl!242
2021-01-26 18:29:37 +00:00
Marius Gerbershagen
da807da49a internal.h: fix ifdef for mp_get_rwlock_{read,write}_wait
rwlocks are emulated using standard locks if no OS primitive for them
exists, therefore we need the declarations in any case.
2021-01-24 18:00:17 +01:00
Marius Gerbershagen
4b6ee0536b gmp: configure: add missing include files 2021-01-24 17:56:34 +01:00
Marius Gerbershagen
2985758cd3 bytecmp: don't leave c_env->lex_env uninitialized
Was previously only initialized in si_eval_with_env. Due to the
introduction of si_bc_compile_from_stream, it was used uninitialized
in this new function, leading to segfaults.
2021-01-16 19:08:50 +01:00
Marius Gerbershagen
194a9e0eab cmp: fix bug in inlining local functions which are closures
See added test case for explanations.
2021-01-16 16:12:13 +01:00
Marius Gerbershagen
ba31f58784 Merge branch 'fix-620' into develop 2021-01-16 15:57:55 +01:00
Marius Gerbershagen
74e366c2e3 INSTALL: update iOS build instructions
Apparently the bdwgc workaround is no longer needed
2021-01-09 11:58:15 +01:00
Marius Gerbershagen
ecb4ed10ea cmp: fix progv for return during evaluation of symbol and value arguments
Closes #620.
2021-01-02 16:38:21 +01:00
Marius Gerbershagen
2cac9642d4 tests: with-compiler: print with *print-circle* and *print-readably* 2020-12-30 22:27:51 +01:00
Marius Gerbershagen
be009ddc15 unixint.d: fix compilation error when threads are disabled 2020-12-29 21:08:37 +01:00
Marius Gerbershagen
ca6297ddc8 cmp: disable precompiled headers by default
Precompiled headers may not work in every scenario (for example
compilation currently fails for the --with-cxx=yes configure option
due to precompiled headers). If we disable them by default, we are on
the safe side.
2020-12-29 20:43:04 +01:00
Marius Gerbershagen
fc4054d734 fix some compiler warnings
__attribute__((unused)) suppresses unused variable warnings for
the_env in dpp generated code.

:case keyword argument in translate-pathname is unused and not
required by the ANSI spec.

espace_flag in sharp_colon_reader is unused and not necessary for the
current implementation.

ihs_function_name is unused and duplicated as ihs-fname in lsp/top.lsp
2020-12-29 18:18:26 +01:00
Daniel Kochmański
594d47f23f Merge branch 'fix-load-forms' into 'develop'
fix load forms

Closes #562

See merge request embeddable-common-lisp/ecl!238
2020-12-27 20:53:28 +00:00
Marius Gerbershagen
cabf564327 package.d: find_pending_package: add missing return statement 2020-12-27 19:56:55 +01:00
Marius Gerbershagen
0ddcc9a5f3 update CHANGELOG 2020-12-27 19:28:29 +01:00
Daniel Kochmański
32704f8cf5 bytecmp: error when make-load-form has a circular dependency 2020-12-27 19:15:13 +01:00
Marius Gerbershagen
3cec96739d bytecmp: fix evaluation order of load time forms
We need to defer initialization forms until all dependent creation
forms have been compiled (see CLHS make-load-form). Closes #562.

Co-authored-by: Marius Gerbershagen <marius.gerbershagen@gmail.com>
2020-12-27 19:12:49 +01:00
Marius Gerbershagen
b730412ebc bytecmp: preserve the identity for literal objects
When a literal appears in the file multiple times its identity should be
preserved.

CLHS 3.2.4.4:

> If two literal objects appearing in the source code for a single
> file processed with the file compiler are the identical, the
> corresponding objects in the compiled code must also be the identical.

Previously, every bytecode object created during ext::bc-compile-file
had its own vector of constants making it impossible to satisfy this
constraint. Thus, we change ext::bc-compile-file to use the same
constants vector for all bytecode objects from the same file. The
simplest way to achieve this is to use the same compiler environment
for all of the compilation process and push the read-compile loop
into the si_bc_compile_from_stream function implemented in C.
2020-12-27 19:04:00 +01:00
Marius Gerbershagen
e5736d393a bytecmp: don't treat load time forms as toplevel forms
This prevents top level forms from being evaluated in the middle
of another top level form.
2020-12-27 19:04:00 +01:00
Marius Gerbershagen
be46fc0caa bytecmp: factor out c_restore_env (used together with c_new_env) 2020-12-27 19:03:57 +01:00
Daniel Kochmański
c18b6d6967 bytecmp: represent bytecodes as a lisp vector
Previously they were passed as an index array, now they are a simple
vector (the cl_object).
2020-12-27 18:53:22 +01:00
Marius Gerbershagen
4460a8c7f1 doc: fix argument order for ecl_alloc_simple_vector 2020-12-27 18:53:22 +01:00
Daniel Kochmański
1a6807170a tests: improve config.lsp to allow testing bytecmp via make check
Even when the C compiler is present. Also first install the bytecodes compiler
and then eventually try install the C compiler - that's because ASDF depends
on the :bytecmp feature to work with the bytecompiler.
2020-12-27 18:53:22 +01:00
Marius Gerbershagen
b20a675f64 tests: compiler: improve make-load-form tests
Also check for identical objects in CMP.0030.MAKE-LOAD-FORM

Be more aware of the bcmp in the test CMP.0076.MAKE-LOAD-FORM-NON-EQ - bytecmp
fails the test in a different manner, so remove the remark that a part of the
test pass, and change the description to 1) explain the test, 2) explain the
ccmp's failure mode.
2020-12-27 18:52:43 +01:00
Marius Gerbershagen
bf664c1887 Merge branch 'fix-604' into 'develop'
Fix 604

Closes #534 und #604

See merge request embeddable-common-lisp/ecl!230
2020-12-23 14:42:51 +00:00
Daniel Kochmański
9ec064ca23 ecl_symbol_value: detect early symbol access during compilation
This test is executed only when ECL itself is compiled. It is to ensure early
notice of issues similar to #604.
2020-12-23 12:08:33 +01:00
Daniel Kochmański
12df1255a9 ecl_make_package: don't look for local nicknames during bootstrap
No packages in the core use local nicknames, so there is no need to look for
them. Test for whether we are booted or not comes for free, because it was
simply lifted up from the static function find_pending_package. Also create a
static function find_local_nickname_package (a cosmetic change).

Fixes #604. Closes !228.
2020-12-23 12:08:33 +01:00
Daniel Kochmański
6e0124bc64 si::mangle-name: return the function name from symbols_list.h
To achieve that we store the symbol name in a separate ecl_symbol slot called
cname. It is initialized from the translation slot in the structure
cl_symbol_initializer. That makes dpp and runtime always resolve function
names to the same symbol. Fixes #534.
2020-12-23 12:08:33 +01:00
Daniel Kochmański
7908ba8003 refactor: remove the file symbols_list2.h
The file symbols_list2.h was automatically generated from the file
symbols_list.h for dpp. This commit unifies said structure definition and
removes a step for generating symbols_list2.h.

From now on at runtime the structurecl_symbol_initializer has an additional
element storing the function name. That will help solving #543.
2020-12-23 12:08:33 +01:00
Daniel Kochmański
a67d16bbc2 utils: add the utility to help parsing/generating symbols_list.h 2020-12-23 12:03:36 +01:00
Marius Gerbershagen
3b7efbbc78 Merge branch 'fix/615' into 'develop'
s/TCP/ECL_TCP/ among preprocessor defines

Closes #615

See merge request embeddable-common-lisp/ecl!234
2020-11-28 16:08:21 +00:00
Pritam Baral
a1b2909b8a s/TCP/ECL_TCP/ among preprocessor defines 2020-11-22 21:04:16 +00:00
Marius Gerbershagen
6ff3b2b86b Merge branch 'partial-fix-for-600' into 'develop'
si_spawn_subprocess: _exit instead of abort if exec fails

See merge request embeddable-common-lisp/ecl!232
2020-11-15 15:10:19 +00:00
Daniel Kochmański
3d4af11001 Merge branch 'develop' into 'develop'
Fix GET-PROTOCOL-BY-NAME with unknown protocols

See merge request embeddable-common-lisp/ecl!233
2020-11-14 12:15:55 +00:00
Michał "phoe" Herda
bb40da9fa6 Fix GET-PROTOCOL-BY-NAME with unknown protocols
The function SB-BSD-SOCKETS:GET-PROTOCOL-BY-NAME did not signal
an error when it was unable to find a protocol. This is fixed now
and an error of type UNKNOWN-PROTOCOL, with an accessor named
UNKNOWN-PROTOCOL-NAME, is being signaled. These two names are also
exported from the package SB-BSD-SOCKETS.

A test case is added.

Several other test cases are fixed with regard to :NO-ERROR clauses
inside HANDLER-CASEs.
2020-11-13 19:43:33 +01:00
Eric Timmons
6a058a4bfc si_spawn_subprocess: _exit instead of abort if exec fails
On MacOS, the stream flushing that happens as part of abort can corrupt streams
in the parent process. See: #600
2020-11-12 16:45:10 -05:00
Marius Gerbershagen
1effa6a160 predlib.lsp: fix type comparisons involving gray streams
Due to gray:fundamental-stream being treated as a built-in type,
subclass relationships were not checked (see added test case).
Fixes #614.
2020-11-06 20:35:22 +01:00
Marius Gerbershagen
cdb602e40d fpe: prevent spurious floating point exceptions in WITH_LISP_FPE
feenableexcept may generate a SIGFPE signal if exception status flags
are not cleared beforehand. Happens for example on powerpc platforms.

Fixes #612.
2020-10-31 11:36:52 +01:00
Daniel Kochmański
7f1813cd93 ecl_alloc_weak_pointer: don't register immediate objects as disappearing
We have special-cased all immediate objects except ECL_T. Creating such link
leads to a segmentation fault when GC tries to dereference the pointer. Fixes #610.
2020-10-19 16:54:40 +02:00
Daniel Kochmański
246f0a6d86 Merge branch 'fix-594' into 'develop'
Fix #594

Closes #594

See merge request embeddable-common-lisp/ecl!227
2020-09-19 10:34:33 +00:00
Marius Gerbershagen
0f75177676 tests: add regression test for #594 2020-09-18 21:22:32 +02:00
Marius Gerbershagen
4e1847f775 clos: don't call make-load-form in the code walker for defmethod
Fixes #594.
2020-09-18 21:22:32 +02:00
Daniel Kochmański
ec8d636964 Merge branch 'dev' into 'develop'
exit() prototype is in stdlib.h, include it

See merge request embeddable-common-lisp/ecl!231
2020-09-18 12:35:25 +00:00
Dima Pasechnik
cd2f19fedb exit() prototype is in stdlib.h, include it
this is needed to support Apple's clang 12, the
compiler in Xcode 12 on macOS 10.15 and upcoming macOS 11.

configure was regenerated by running autoreconf -ivf
with autoconf version 2.69
2020-09-18 13:18:56 +01:00
Marius Gerbershagen
b0dfcc38f5 Merge branch 'chrstphrchvz-develop-patch-41456' into 'develop'
Fix spelling

See merge request embeddable-common-lisp/ecl!229
2020-09-13 17:44:37 +00:00
Christopher Chavez
0f3d6e08d1 Fix spelling 2020-09-11 02:11:26 +00:00
Marius Gerbershagen
5277c82c85 Merge branch 'fix-605' into 'develop'
Fix 605

Closes #605

See merge request embeddable-common-lisp/ecl!226
2020-08-23 17:14:08 +00:00