Specifications

Red Hat Enterprise Linux to Oracle Solaris Porting Guide
55
applications. The number of simultaneous threads that can be accommodated is quite large. Oracle
Solaris 11 provides specific features that take advantage of chip multithreading technology. Systems
based on Oracle’s CMT processors appear as a familiar SMP system to the operating system and the
applications it supports.
The operating system is designed to take advantage of latest hardware trends.Oracle Solaris is aware
of the CMT processor hierarchy, enabling the scheduler to effectively balance the load across
available pipelines. Even though it exposes the processor as multiple logical processors, the
operating system understands the correlation between cores and the threads they support.
There is better system control. Oracle Solaris can enable or disable individual processors. In the case
of CMT processors, this ability extends to enabling or disabling individual cores and logical
processors (hardware threads). In addition, standard operating system features such as processor sets
provide the ability to define a group of logical processors and schedule processes or threads on the
group.
Oracle Solaris allows considerable flexibility for controlling process affinity. Processes and individual
threads can be bound to either a processor or a processor set, if required or desired.
OpenMP Support
Support for OpenMP in Oracle Solaris Studio compilers means that the compilers can look for
OpenMP directives (pragma) in the source code in order to build a parallel version of the application.
Similar to automatic parallelization, an Oracle Solaris Studio compiler does the additional work so that
developers do not have to manage their own threads. OpenMP represents an incremental approach to
parallelization with potentially fine granularity. OpenMP allows developers to set directives around
specific loops to be optimized through threading while leaving other loops untouched. The other
distinct advantage of this approach is that developers can derive a serial version and a parallel version
of the application from the exact same code base, which can be helpful for debugging. Several
compiler flags are available in Oracle Solaris Studio to support OpenMP.
You can enable OpenMP with the -xopenmp compiler flag.
Directives are recognized only when the flag is used.
You can set the -xvpara compiler flag to report potential parallelization issues.
You can set the -loopinfo compiler flag to instruct the compiler to provide details on which
loops were parallelized.
Set the OMP_NUM_THREADS or PARALLEL environment variables at runtime to take advantage
of multiprocessor execution. These environment variables specify the number of processors
available to the program. The variables are equivalent, and only one needs to be set.
Auto Parallelization and Compile-Time Optimizations
Traditionally, most code was developed without support for parallel threads of execution, making it
difficult to fully exploit advancements in the lasted hardware technologies. The latest Oracle Solaris
Studio compilers provide mechanisms to let applications run multiple threads without requiring the