[prev in list] [next in list] [prev in thread] [next in thread] 

List:       sbcl-commits
Subject:    [Sbcl-commits] master: Fix builds without sb-aprof on the runtime side.
From:       stassats via Sbcl-commits <sbcl-commits () lists ! sourceforge ! net>
Date:       2023-04-20 20:44:25
Message-ID: 1682023465.983220.27074 () sfp-scm-6 ! v30 ! lw ! sourceforge ! com
[Download RAW message or body]

The branch "master" has been updated in SBCL:
       via  d933c913ead3926647696746999d9cf04a3a1b4e (commit)
      from  da1043800077de415105cbe4d4387296a98904a1 (commit)

- Log -----------------------------------------------------------------
commit d933c913ead3926647696746999d9cf04a3a1b4e
Author: Stas Boukarev <stassats@gmail.com>
Date:   Thu Apr 20 21:09:07 2023 +0300

    Fix builds without sb-aprof on the runtime side.
---
 src/assembly/x86-64/tramps.lisp | 2 ++
 src/runtime/x86-64-arch.c       | 6 ++++--
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/src/assembly/x86-64/tramps.lisp b/src/assembly/x86-64/tramps.lisp
index 3f2ca8292..b974df0d2 100644
--- a/src/assembly/x86-64/tramps.lisp
+++ b/src/assembly/x86-64/tramps.lisp
@@ -148,11 +148,13 @@
 (define-assembly-routine (enable-alloc-counter) ()
   (with-registers-preserved (c)
     (inst lea rdi-tn (ea 8 rbp-tn))
+    #+sb-thread
     (pseudo-atomic () (inst call (make-fixup "allocation_tracker_counted" :foreign)))))
 
 (define-assembly-routine (enable-sized-alloc-counter) ()
   (with-registers-preserved (c)
     (inst lea rdi-tn (ea 8 rbp-tn))
+    #+sb-thread
     (pseudo-atomic () (inst call (make-fixup "allocation_tracker_sized" :foreign)))))
 
 (define-assembly-routine (undefined-tramp (:return-style :none))
diff --git a/src/runtime/x86-64-arch.c b/src/runtime/x86-64-arch.c
index 5779c2220..48827a9a2 100644
--- a/src/runtime/x86-64-arch.c
+++ b/src/runtime/x86-64-arch.c
@@ -655,18 +655,19 @@ lispobj decode_fdefn_rawfun(struct fdefn* fdefn) {
     return entrypoint_taggedptr((uword_t)fdefn->raw_addr);
 }
 
+#ifdef LISP_FEATURE_SB_THREAD
 #include "genesis/vector.h"
 #define LOCK_PREFIX 0xF0
 #undef SHOW_PC_RECORDING
 
 extern unsigned int max_alloc_point_counters;
-#ifdef LISP_FEATURE_SB_THREAD
+
 #ifdef LISP_FEATURE_WIN32
 extern CRITICAL_SECTION alloc_profiler_lock;
 #else
 extern pthread_mutex_t alloc_profiler_lock;
 #endif
-#endif
+
 
 static unsigned int claim_index(int qty) // qty is 1 or 2
 {
@@ -816,6 +817,7 @@ allocation_tracker_sized(uword_t* sp)
     int __attribute__((unused)) ret = mutex_release(&alloc_profiler_lock);
     gc_assert(ret);
 }
+#endif
 
 __attribute__((sysv_abi)) lispobj call_into_lisp(lispobj fun, lispobj *args, int nargs) {
     extern lispobj call_into_lisp_(lispobj, lispobj *, int, struct thread *)

-----------------------------------------------------------------------


hooks/post-receive
-- 
SBCL


_______________________________________________
Sbcl-commits mailing list
Sbcl-commits@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sbcl-commits
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic