A thread is a sequence of instructions, that can run independently from and concurrently with other portions of an application. This section assumes that you are familiar with threads. For information on designing an application to use threads, please consult a multithreaded programming book. For a brief list of possible resources, see Section 49.5, Selected Bibliography.
WARNING:For multiple threads of your application to run concurrently, your threads must be preemptible. For more information, see Section 49.3, Preemption.
LibC supports the following thread interfaces:
POSIX threads, commonly called pthreads, supported on most operating systems. Pthreads are implemented on top of NKS threads and are not available until NetWare® 5.1 SP5 and NetWare 6.0 SP2.
UNIX International, commonly called UI threads, supported by most UNIX operating systems. UI threads are implemented on top of NKS threads and are not available until NetWare 5.1 SP5 and NetWare 6.0 SP2.
Novell® Kernel Services (NKS) threads, supported on NetWare® 5.1 SP4 or later and NetWare 6.0 or later.
When deciding which thread interface to use in your application, consider the following points:
If your application needs to run on multiple operating systems, use pthreads which are available on most operating systems. A few pthread features are not supported on NetWare. For more information, see Pthread Functions.
If you are porting an application from a UNIX operating system that uses UNIX International threads, use UI threads. A few UI thread features are not supported on NetWare. For more information, see UI Thread Functions.
If your application needs the expanded features of NKS threads, design your application to use NKS threads. For more information, see NKS Thread Concepts.
For a brief overview that compares the functionality available in these interfaces, see Section 49.4, Overview of the Thread Interfaces.
WARNING:Once you have decided on an thread interface, you should use only that interface. Results are unpredictable if you mix two thread interfaces in the same application.
Regardless of which thead interface you select, you should have some knowledge of the following features when you design your application: