INSTALLATION INSTRUCTIONS To build and install the Viterbi decoder libraries, simply say ./configure make make install (as root) This will put the libraries in /usr/local/lib, the include files in /usr/local/include, and the manual page in /usr/local/man. SIMD-ASSISTED VERSIONS Four separate versions of each decoder are provided. One is in portable C and should run on any system with the GCC compiler and linker. Three more versions in assembler use the three Intel SIMD (single instruction, multiple data) instruction sets: MMX, SSE and SSE2. These SIMD-assisted versions yield dramatically better performance than the portable C version and should be used whenever possible. The MMX (MultiMedia eXtension) instruction set was introduced on later Pentium CPUs; it is also implemented on the Pentium II and most AMD CPUs starting with the K6. SSE (SIMD Streaming Extensions) was introduced in the Pentium III; AMD calls it "3D Now! Professional". Intel introduced SSE2 on the Pentium 4; to my knowledge it has not yet been implemented on any AMD CPU. SSE support implies MMX support, while SSE2 support implies both SSE and MMX support. If the target system is IA32 (i.e., i386/i486/i586/i686), all four versions of the decoder (portable C,MMX,SSE and SSE2) are built. Additionally, the configure script determines which, if any, of the three SIMD instruction sets (MMX/SSE/SSE2) are supported on the local CPU and installs the "best" one as the default for both the static and shared versions. If none of the SIMD instruction sets are supported, the portable C version is installed as the default. On non-IA32 targets only the portable C version is built. Since the usual GNU-style target_cpu name (e.g., "i686") does not indicate which SIMD instructions are supported (if any), the configure script has to run local tests to determine this information. This currently precludes cross-compilation of the package. TESTING THE VITERBI DECODER LIBRARY After running the ./configure script, optional tests can be run as follows: make tests make alltests "make tests" tests each decoder using the default library, verifying correct operation and estimating decoding speed. These tests should always succeed unless something is broken. On a IA32 machine, "make alltests" tests all four versions of the library. (On non-IA32 machines, "make alltests" is identical to "make tests"). Because "make alltests" tries every available SIMD version, whether or not the local CPU supports it, some of these tests may fail. E.g., on a Pentium III, the portable C, MMX and SSE tests will succeed while the SSE2 test will fail. LINKING APPLICATIONS TO THE VITERBI DECODER LIBRARY Specifying -lviterbi to the linker links with the default version as determined by the configure script. Unless the -static flag is also specified to the loader, the shared version will be used. This default can be overridden, for static linking only, as follows: -lviterbi_port - portable C version -lviterbi_mmx - MMX version -lviterbi_sse - SSE version -lviterbi_sse2 - SSE2 version 7 Dec 2001 Phil Karn, karn@ka9q.net