In the case of Linux/IRAF the initial distribution contains two architectures: linux and linuz. The latter option are the same linux binaries but compressed using the GNU gzexe task. This can result in a significant disk space savings at some cost in runtime performance. Compressed executables are automatically and transparently uncompressed when executed. Compressed executables take about half the disk space of uncompressed executables, but start up slower as the file must be uncompressed before it can be executed. In the case of IRAF the start up penalty is not as great it might otherwise be due to the CL process cache. A disadvantage of compressed executables is that they require *more* memory to execute if multiple copies of the same executable are simultaneously executed, e.g. if there are multiple IRAF users or sessions, or background IRAF jobs, because no sharing of the text segment takes place.
Since IRAF is a large system it is undesirable to have to maintain a separate copy of IRAF for each machine architecture on a network. For this reason IRAF provides support for multiple architectures within a single copy of IRAF. To be accessible by multiple network clients, this central IRAF system will typically be NFS mounted on each client. It should be noted however that it is not always possible to use the multiple architecture support within the core system to maintain a single IRAF source tree for the entire heterogeneous network. The Host System Interface (HSI) for IRAF ports is different for platforms as diverse as Linux and Sun so there should be a separate installation for each system to minimize difficulties (the update schedules usually differ as well so maintaining the same version is also more difficult). In the case of supporting Linux with both the normal and compressed executable options installed, one installation is sufficient since it's generally only the binaries that will differ (i.e. the OS is still the same). Almost any combination of architectures may be supported by a single copy of an external package.
Multiple architecture support is implemented by separating the IRAF sources and binaries into different directory trees. The sources are architecture independent and hence sharable by machines of any architecture. All of the architecture dependence is concentrated into the binaries, which are collected together into the so-called BIN directories, one for each architecture. The BIN directory contains all the object files, object libraries, and executables, supporting both IRAF execution and software development for that architecture. A given system can support any number of BIN directories, and therefore any number of architectures.
In IRAF terminology, when we refer to an ``architecture'' what we really mean is a type of BIN. The correspondence between BINs and hardware architectures is not necessarily one-to-one, i.e., multiple BINs can exist for a single compiler architecture by compiling the system with different compilation flags, as different versions of the software, and so on. Examples of some currently supported software architectures are shown below.
Architecture System Description generic any no binaries linux PC PC platforms running Linux linuz PC PC platforms running Linux - compressed binaries sx86 PC PC platforms running Solaris x86 ssun Sun-4 Sun SPARC under Solaris (RISC) architecture, integral fpu sparc Sun-4 Sun SPARC (RISC) architecture, integral fpu f68881 Sun-3 mc68020, 68881 floating point coprocessor pg Sun-4 Sun/IRAF compiled for profiling ddec Decstation DEC Fortran version of DSUX/IRAF dmip Decstation MIPS Risc Fortran version of DSUX/IRAF rs6000 IBM IBM RS/6000 running AIX irix SGI SGI IRIX, MIPS cpu f2c Macintosh A/UX, using Fortran-to-C translation and GCC
Most of these correspond to hardware architectures or floating point hardware options. The exceptions are the generic architecture, which is what the distributed system is configured to by default (to avoid having any architecture dependent binary files mingled with the sources), and the ``pg'' architecture, which is not normally distributed to user sites, but is a good example of a custom software architecture used for software development.
When running IRAF on a system configured for multiple architectures,
selection of the BIN (architecture) to be used is controlled by the UNIX
environment variable IRAFARCH, e.g.,
% setenv IRAFARCH linuxwould cause IRAF to run using the linux architecture, corresponding to the BIN directory bin.linux. Once inside the CL one can check the current architecture by entering one of the following commands (the output in each case is shown as well).
cl> show IRAFARCH
linux
or
cl> show arch
.linux
If IRAFARCH is undefined at CL startup time a default architecture will be selected based on the current machine architecture, the available floating point hardware, and the available BINs. The IRAFARCH variable controls not only the architecture of the executables used to run IRAF, but the libraries used to link IRAF programs, when doing software development from within the IRAF or host environment.
Additional information on multiple architecture support is provided in the system notes file for V2.8, file doc$notes.v28.