SPARC Solaris (32 bit)
The 32 bit SPARC Solaris port is designed to work with the SPARC V8 or compatible processors. The port is built for Solaris 9 and also supports Solaris 8.
SCL is intended to be installed in the directory: /opt/scl/. If installed elsewhere then the location of the lisp core file will need to be specified on the command line or the SCLLIB environment variable set to the directory containing the lisp core file.
SCL uses the 1:1 T2 threading library introduced in Solaris 8 and it is strongly recommended that you upgrade to the Solaris 8 Update 7 to use the T2 library. The T2 library became the default in Solaris 9.
The latest patches for Solaris are recommended, in particular patch 108827 fixes a nasty regression - the count on recursive locks was not being initialized causing random failures.
When compiling foreign C code to be loaded into SCL, define _REENTRANT so that the code is built for thread safety, such as thread safe errno handling.
Foreign code may be compiled into a shared object to speed the loading of the object, see ext:load-dynamic-object. The code should be compiled to be position independent, and the shared object must resolve all dependent libraries. Below is an example of compiling the C code in the file tst.c into a shared object that may be loaded by ext:load-dynamic-object where the shared object uses a library named libmylib.
gcc -fPIC -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS -c tst.c
ld -G -o tst.so tst.o -L/mylibs -R/mylibs -lmylib -lc
Character encoding conversion
For character format converstion, between the internal UCS-2 format, the libiconv library is used. This libraray is available under the terms of the LGPL license and the source code may be downloaded from ftp://ftp.gnu.org/pub/gnu/libiconv/. A precompiler binary of libiconv is provided with SCL and is installed under /opt/scl/. If recompiling libiconv for SCL, be sure to compile for thread safety by defining the C flag -D_REENTRANT.
The SPARC port uses a precise garbage collector in contrast to the conservative garbage collector used on the x86 port. This reduces the chance of garbage being kept alive.
The alien stack and the number stack are shared.
Up to 3728M bytes of memory may be allocated for the lisp heap. The default size is 512M bytes, which may be overridden using the command line option -dynamic-space-size followed by the size in MBytes.
The license keys for the SPARC Solaris port are locked to the machine hostname and the machine hostid. These can be found using the commands: hosthname and hostid respectively.These are also output by SCL as part of the machine configuration if SCL fails to find a valid key.
The range of file descriptors that the C library stdio library can handle is limit to just 256 on Solaris running 32 applications. Although SCL has no limits, if a foreign library is called, such as OpenSSL which uses stdio then for reliable operation the process will likely be restricted to the use of at most 256 open files or sockets. For the running of larger web services etc, it is recommended that the 64-bit port be used.
Tracing and breakpoints are not thread safe but should be fine so long as only a single thread touches the code with a breakpoint.
Recursive locks on Solaris 8 have a small limit on the recursive count of 255.
Recursive locks do not work well with condition variables on Solaris 8 and these should not be used together - SCL will catch such attempts and generate an error.