1.0.4.39: get rid of hardcoded mutex and spinlock slot indexes
[sbcl.git] / src / code / linux-os.lisp
index 1d87b6f..640320e 100644 (file)
@@ -1,4 +1,4 @@
-;;;; OS interface functions for CMU CL under Linux
+;;;; OS interface functions for SBCL under Linux
 
 ;;;; This software is part of the SBCL system. See the README file for
 ;;;; more information.
   "Return a string describing the supporting software."
   (values "Linux"))
 
-(defvar *software-version* nil)
-
+;;; FIXME: More duplicated logic here vrt. other oses. Abstract into
+;;; uname-software-version?
 (defun software-version ()
   #!+sb-doc
   "Return a string describing version of the supporting software, or NIL
   if not available."
   (or *software-version*
       (setf *software-version*
-           (string-trim '(#\newline)
-                        (with-output-to-string (stream)
-                          (sb!ext:run-program "/bin/uname" `("-r")
-                                              :output stream))))))
-
-(defun os-cold-init-or-reinit () ; KLUDGE: don't know what to do here
-  #!+sparc ;; Can't use #x20000000 thru #xDFFFFFFF, but mach tries to let us.
-  (sb!sys:allocate-system-memory-at (sb!sys:int-sap #x20000000) #xc0000000)
-  (setf *software-version* nil)
-  (setf *default-pathname-defaults*
-       (pathname (sb!ext::default-directory))))
+            (string-trim '(#\newline)
+                         (with-output-to-string (stream)
+                           (sb!ext:run-program "/bin/uname" `("-r")
+                                               :output stream))))))
 
-;;; Return system time, user time and number of page faults.
+;;; Return user time, system time, and number of page faults.
 (defun get-system-info ()
   (multiple-value-bind
       (err? utime stime maxrss ixrss idrss isrss minflt majflt)
@@ -52,7 +45,4 @@
 
 ;;; Return the system page size.
 (defun get-page-size ()
-  ;; probably should call getpagesize()
-  ;; FIXME: Or we could just get rid of this, since the uses of it look
-  ;; disposable.
-  4096)
+  sb!c:*backend-page-size*)
\ No newline at end of file