[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Guile-commits] branch main updated: Revert shift of ndim in array tag f
From: |
Daniel Llorens |
Subject: |
[Guile-commits] branch main updated: Revert shift of ndim in array tag from 3df3ba1a2c956bba122328e1fc4be614171a4f42 |
Date: |
Fri, 17 Sep 2021 05:33:57 -0400 |
This is an automated email from the git hooks/post-receive script.
lloda pushed a commit to branch main
in repository guile.
The following commit(s) were added to refs/heads/main by this push:
new 96e3686 Revert shift of ndim in array tag from
3df3ba1a2c956bba122328e1fc4be614171a4f42
96e3686 is described below
commit 96e3686db14391310644d5237dcec8a0e2145903
Author: Daniel Llorens <lloda@sarc.name>
AuthorDate: Fri Sep 17 11:20:24 2021 +0200
Revert shift of ndim in array tag from
3df3ba1a2c956bba122328e1fc4be614171a4f42
To avoid breaking ABI.
* libguile/arrays.h (SCM_I_ARRAY_DIM, scm_i_raw_array): As stated.
* module/system/vm/assembler.scm: As stated.
---
libguile/arrays.h | 4 ++--
module/system/vm/assembler.scm | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/libguile/arrays.h b/libguile/arrays.h
index e427eab..5457ddb 100644
--- a/libguile/arrays.h
+++ b/libguile/arrays.h
@@ -94,7 +94,7 @@ typedef struct scm_t_array_dim
/* internal. */
#define SCM_I_ARRAYP(a) SCM_TYP16_PREDICATE (scm_tc7_array, a)
-#define SCM_I_ARRAY_NDIM(x) ((size_t) (SCM_CELL_WORD_0 (x)>>16))
+#define SCM_I_ARRAY_NDIM(x) ((size_t) (SCM_CELL_WORD_0 (x)>>17))
#define SCM_I_ARRAY_V(a) SCM_CELL_OBJECT_1 (a)
#define SCM_I_ARRAY_BASE(a) ((size_t) SCM_CELL_WORD_2 (a))
#define SCM_I_ARRAY_DIMS(a) ((scm_t_array_dim *) SCM_CELL_OBJECT_LOC (a, 3))
@@ -106,7 +106,7 @@ typedef struct scm_t_array_dim
static inline SCM
scm_i_raw_array (int ndim)
{
- return scm_words (((scm_t_bits) ndim << 16) + scm_tc7_array, 3 + ndim*3);
+ return scm_words (((scm_t_bits) ndim << 17) + scm_tc7_array, 3 + ndim*3);
}
SCM_INTERNAL SCM scm_i_make_array (int ndim);
diff --git a/module/system/vm/assembler.scm b/module/system/vm/assembler.scm
index ea50b5b..be1b79e 100644
--- a/module/system/vm/assembler.scm
+++ b/module/system/vm/assembler.scm
@@ -2063,7 +2063,7 @@ should be .data or .rodata), and return the resulting
linker object.
(let-values
;; 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)))
+ (((tag) (logior tc7-array (ash (array-rank obj) 17)))
((bv-set! bvs-set!)
(case word-size
((4) (values bytevector-u32-set! bytevector-s32-set!))
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Guile-commits] branch main updated: Revert shift of ndim in array tag from 3df3ba1a2c956bba122328e1fc4be614171a4f42,
Daniel Llorens <=