From: MeanGene
Subject: Help: CMUCL on Solaris
Date: 
Message-ID: <slrn9fjice.2k8.gene@daBox.local>
Hello,

I just installed the 18c release, and it's broken:

* (save-lisp *corename*)

Error in function GET-INTERNAL-RUN-TIME:
   Syscall times failed: No such file or directory

Here're the details on my installation:

SunOS 5.7 Generic sun4u sparc SUNW,Ultra-5_10

I just uncompressed the release cmucl-18c (non-v9!):
cmucl-18c.sparc.solaris27.tgz
cmucl-18c.sparc.solaris27.extra.tgz

and setup $CMUCLLIB and $CMUCL_EMPTYFILE as required in the wrapper.

Any ideas?

--ET.

From: Eric Marsden
Subject: Re: Help: CMUCL on Solaris
Date: 
Message-ID: <wzin18l4lfx.fsf@mail.dotcom.fr>
>>>>> "et" == MeanGene  <····@daBox.local> writes:

  et> I just installed the 18c release, and it's broken:
  et> 
  et> * (save-lisp *corename*)
  et> 
  et> Error in function GET-INTERNAL-RUN-TIME:
  et> Syscall times failed: No such file or directory

this is a bug in CMUCL's syscall interface on Solaris: the function
UNIX-TIMES raises an error if the return value is negative. This will
be the case for an uptime of around 10 months. The easy solution is to
reboot your machine; a correct solution would be to redefine UNIX-TIMES
using the INT-SYSCALL macro (this should be fixed in a future
version).

For the curious, GET-INTERNAL-RUN-TIME is called during GC, and the
bogus "No such file or directory" comes from the fact that errno is
not reset around syscalls.

-- 
Eric Marsden                          <URL:http://www.laas.fr/~emarsden/>
From: Eric Marsden
Subject: Re: Help: CMUCL on Solaris
Date: 
Message-ID: <wzipudh16xg.fsf@mail.dotcom.fr>
>>>>> "ecm" == Eric Marsden <········@mail.dotcom.fr> writes:

  ecm> The easy solution is to reboot your machine; a correct solution
  ecm> would be to redefine UNIX-TIMES using the INT-SYSCALL macro
  ecm> (this should be fixed in a future version).

actually Raymond Toy pointed out to me that this is already fixed in
the current sources. You could try rebuilding CMUCL from CVS, or wait
for binaries built from CVS to be uploaded to cons.org, or add the
following to your ~/.cmucl-init

,----
| (in-package :unix)
| (declaim (inline unix-times))
| (defun unix-times ()
|   "Unix-times returns information about the cpu time usage of the process
|    and its children."
|   (with-alien ((usage (struct tms)))
|     (alien-funcall (extern-alien "times" (function int (* (struct tms))))
|                    (addr usage))
|     (values t
|             (slot usage 'tms-utime)
|             (slot usage 'tms-stime)
|             (slot usage 'tms-cutime)
|             (slot usage 'tms-cstime))))
| (compile 'unix-times)
`----

-- 
Eric Marsden                          <URL:http://www.laas.fr/~emarsden/>