Skip to content
Snippets Groups Projects
scalasca.md 2.66 KiB
Newer Older
  • Learn to ignore specific revisions
  • # Scalasca
    
    ## Introduction
    
    
    David Hrbáč's avatar
    David Hrbáč committed
    [Scalasca][a] is a software tool that supports the performance optimization of parallel programs by measuring and analyzing their runtime behavior. The analysis identifies potential performance bottlenecks – in particular those concerning communication and synchronization – and offers guidance in exploring their causes.
    
    
    Scalasca supports profiling of MPI, OpenMP and hybrid MPI+OpenMP applications.
    
    ## Installed Versions
    
    
    Jan Siwiec's avatar
    Jan Siwiec committed
    For the current list of installed versions, use:
    
    Jan Siwiec's avatar
    Jan Siwiec committed
    ```console
    $ ml av Scalasca
    ```
    
    
    ## Usage
    
    Profiling a parallel application with Scalasca consists of three steps:
    
    1. Instrumentation, compiling the application such way, that the profiling data can be generated.
    1. Runtime measurement, running the application with the Scalasca profiler to collect performance data.
    1. Analysis of reports
    
    ### Instrumentation
    
    
    David Hrbáč's avatar
    David Hrbáč committed
    Instrumentation via `scalasca -instrument` is discouraged. Use [Score-P instrumentation][5].
    
    
    ### Runtime Measurement
    
    After the application is instrumented, runtime measurement can be performed with the `scalasca -analyze` command. The syntax is:
    
    
    `scalasca -analyze [scalasca options] [launcher] [launcher options] [program] [program options]`
    
    Jan Siwiec's avatar
    Jan Siwiec committed
    An example:
    
    
    ```console
       $ scalasca -analyze mpirun -np 4 ./mympiprogram
    ```
    
    Some notable Scalasca options are:
    
    
    Jan Siwiec's avatar
    Jan Siwiec committed
    * `-t` enables trace data collection. By default, only summary data are collected.
    * `-e <directory>` specifies a directory to which the collected data is saved. By default, Scalasca saves the data to a directory with the scorep\_ prefix, followed by the name of the executable and the launch configuration.
    
    Lukáš Krupčík's avatar
    Lukáš Krupčík committed
        Scalasca can generate a huge amount of data, especially if tracing is enabled. Consider saving the data to a [scratch directory][6].
    
    
    ### Analysis of Reports
    
    
    Jan Siwiec's avatar
    Jan Siwiec committed
    For the analysis, you must have the [Score-P][5] and [CUBE][7] modules loaded. The analysis is done in two steps. First, the data is preprocessed and then, the CUBE GUI tool is launched.
    
    Jan Siwiec's avatar
    Jan Siwiec committed
    To launch the analysis, run:
    
    
    ```console
    scalasca -examine [options] <experiment_directory>
    ```
    
    
    Jan Siwiec's avatar
    Jan Siwiec committed
    If you do not wish to launch the GUI tool, use the `-s` option:
    
    
    ```console
    scalasca -examine -s <experiment_directory>
    ```
    
    
    Jan Siwiec's avatar
    Jan Siwiec committed
    Alternatively, you can open CUBE and load the data directly from here. Keep in mind that in this case, the pre-processing is not done and not all metrics will be shown in the viewer.
    
    Jan Siwiec's avatar
    Jan Siwiec committed
    Refer to the [CUBE documentation][7] on usage of the GUI viewer.
    
    David Hrbáč's avatar
    David Hrbáč committed
    1. [http://www.scalasca.org/][a]
    
    
    David Hrbáč's avatar
    David Hrbáč committed
    [1]: ../../modules-matrix.md
    
    David Hrbáč's avatar
    David Hrbáč committed
    [2]: ../compilers.md
    
    David Hrbáč's avatar
    David Hrbáč committed
    [3]: ../mpi/running_openmpi.md
    
    David Hrbáč's avatar
    David Hrbáč committed
    [4]: ../mpi/running-mpich2.md
    [5]: score-p.md
    [6]: ../../salomon/storage.md
    [7]: cube.md
    
    [a]: http://www.scalasca.org/