diff options
author | Daniel Llorens <lloda@sarc.name> | 2021-08-16 19:02:43 +0200 |
---|---|---|
committer | Daniel Llorens <lloda@sarc.name> | 2021-08-16 19:02:43 +0200 |
commit | 3df3ba1a2c956bba122328e1fc4be614171a4f42 (patch) | |
tree | d905779c2a31f7909ded18c46462afe65a68e353 /module/system/vm/assembler.scm | |
parent | c60601332e8f328b014ac09ebd9b0e1c562f9238 (diff) | |
download | guile-3df3ba1a2c956bba122328e1fc4be614171a4f42.tar.gz |
Remove array contp flag
This flag was set, but never used in Guile, and there was no documented
API to access it.
To check if an array is contiguous, use (array-contents <> #t).
* libguile/arrays.h (scm_i_raw_array): New function.
SCM_I_ARRAY_CONTIGUOUS, SCM_SET_ARRAY_CONTIGUOUS_FLAG,
SCM_CLR_ARRAY_CONTIGUOUS_FLAG, SCM_I_ARRAY_CONTP: Remove.
scm_t_array_dim: Declare here, not in array-handle.h.
SCM_I_ARRAY_NDIM: Shift by one bit since the contp flag isn't there
anymore.
* module/syste/vm/assembler.scm: Match removal of contp flag.
* libguile/arrays.c (scm_i_make_array): Reuse scm_i_raw_array.
(scm_i_ra_set_contp): Remove.
(scm_transpose_array): Don't set or clear the contp flag.
(scm_make_shared_array): Don't set or clear the contp flag.
(scm_make_typed_array): Don't set the contp flag.
* libguile/array-map.c (scm_i_array_rebase): Reuse scm_i_raw_array.
Diffstat (limited to 'module/system/vm/assembler.scm')
-rw-r--r-- | module/system/vm/assembler.scm | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/module/system/vm/assembler.scm b/module/system/vm/assembler.scm index d4c9de86d..ea50b5bb6 100644 --- a/module/system/vm/assembler.scm +++ b/module/system/vm/assembler.scm @@ -2061,8 +2061,9 @@ should be .data or .rodata), and return the resulting linker object. ((array? obj) (let-values - ;; array tag + rank + contp flag: see libguile/arrays.h . - (((tag) (logior tc7-array (ash (array-rank obj) 17) (ash 1 16))) + ;; array tag + rank + ;; see libguile/arrays.h: SCM_I_ARRAY_NDIM, SCM_I_ARRAYP, scm_i_raw_array + (((tag) (logior tc7-array (ash (array-rank obj) 16))) ((bv-set! bvs-set!) (case word-size ((4) (values bytevector-u32-set! bytevector-s32-set!)) |