Skip to content
Snippets Groups Projects
Commit 0fe86aa9 authored by Lukáš Krupčík's avatar Lukáš Krupčík
Browse files

fix

parent 406d1229
No related branches found
No related tags found
6 merge requests!368Update prace.md to document the change from qprace to qprod as the default...,!367Update prace.md to document the change from qprace to qprod as the default...,!366Update prace.md to document the change from qprace to qprod as the default...,!323extended-acls-storage-section,!196Master,!174MIC
...@@ -76,7 +76,7 @@ int main(int argc, char* argv[]) ...@@ -76,7 +76,7 @@ int main(int argc, char* argv[])
To compile a code using Intel compiler run. To compile a code using Intel compiler run.
* Create source-offload.cpp * Create source-offload.cpp
```console ```console
$ vim source-offload.cpp $ vim source-offload.cpp
...@@ -99,14 +99,14 @@ int main(int argc, char* argv[]) ...@@ -99,14 +99,14 @@ int main(int argc, char* argv[])
std::cout << "Pi ~ " << result << '\n'; std::cout << "Pi ~ " << result << '\n';
} }
``` ```
* Compile * Compile
```console ```console
$ ml intel/2017b $ ml intel/2017b
$ icc source-offload.cpp -o bin-offload $ icc source-offload.cpp -o bin-offload
``` ```
* To execute the code, run the following command on the host * To execute the code, run the following command on the host
```console ```console
$ ./bin-offload $ ./bin-offload
...@@ -119,7 +119,7 @@ On Salomon cluster we have module `GCC/5.1.1-knc` with cross-compiled support. ( ...@@ -119,7 +119,7 @@ On Salomon cluster we have module `GCC/5.1.1-knc` with cross-compiled support. (
To compile a code using GCC compiler run. To compile a code using GCC compiler run.
* Create reduce_mul.c * Create `reduce_mul.c`
```console ```console
$ vim reduce_mul.c $ vim reduce_mul.c
...@@ -135,7 +135,7 @@ double reduce(double* values) ...@@ -135,7 +135,7 @@ double reduce(double* values)
} }
``` ```
* A create main.c * A create main.c
```console ```console
vim main.c vim main.c
...@@ -168,7 +168,7 @@ int main(int argc, char* argv[]) ...@@ -168,7 +168,7 @@ int main(int argc, char* argv[])
} }
``` ```
* Compile * Compile
```console ```console
$ ml GCC/5.1.1-knc $ ml GCC/5.1.1-knc
...@@ -178,7 +178,7 @@ $ gcc -std=c99 -O3 -c main.c -o main_gcc.o ...@@ -178,7 +178,7 @@ $ gcc -std=c99 -O3 -c main.c -o main_gcc.o
$ gcc -O3 reduce_mul.o main_gcc.o -o reduce_mul $ gcc -O3 reduce_mul.o main_gcc.o -o reduce_mul
``` ```
* To execute the code, run the following command on the host * To execute the code, run the following command on the host
```console ```console
$ micnativeloadex ./reduce_mul $ micnativeloadex ./reduce_mul
...@@ -278,24 +278,24 @@ int main() ...@@ -278,24 +278,24 @@ int main()
$ icc -xhost -no-offload -fopenmp vect-add.c -o vect-add-host $ icc -xhost -no-offload -fopenmp vect-add.c -o vect-add-host
``` ```
* To run this code on host, use * To run this code on host, use
```console ```console
$ ./vect-add-host $ ./vect-add-host
Test passed Test passed
``` ```
* The second example shows how to compile the same code for Intel Xeon Phi * The second example shows how to compile the same code for Intel Xeon Phi
```console ```console
$ icc -mmic -fopenmp vect-add.c -o vect-add-mic $ icc -mmic -fopenmp vect-add.c -o vect-add-mic
``` ```
* Execution of the Program in Native Mode on Intel Xeon Phi * Execution of the Program in Native Mode on Intel Xeon Phi
The user access to the Intel Xeon Phi is through the SSH. Since user home directories are mounted using NFS on the accelerator, users do not have to copy binary files or libraries between the host and accelerator. Get the PATH of MIC enabled libraries for currently used Intel Compiler. The user access to the Intel Xeon Phi is through the SSH. Since user home directories are mounted using NFS on the accelerator, users do not have to copy binary files or libraries between the host and accelerator. Get the PATH of MIC enabled libraries for currently used Intel Compiler.
* To run this code on Intel Xeon Phi * To run this code on Intel Xeon Phi
```console ```console
$ ssh mic0 $ ssh mic0
...@@ -385,7 +385,7 @@ r21u02n578-mic0:~$ ml av ...@@ -385,7 +385,7 @@ r21u02n578-mic0:~$ ml av
After load module `devel_environment` are available modules for architecture k10m-mpss-linux and now exists systems software (gcc, cmake, make, git, htop, vim, ...). After load module `devel_environment` are available modules for architecture k10m-mpss-linux and now exists systems software (gcc, cmake, make, git, htop, vim, ...).
* Example * Example
```console ```console
r21u02n578-mic0:~$ gcc --version r21u02n578-mic0:~$ gcc --version
...@@ -424,7 +424,7 @@ Internet, point your browser at http://www.perl.org/, the Perl Home Page. ...@@ -424,7 +424,7 @@ Internet, point your browser at http://www.perl.org/, the Perl Home Page.
... ...
``` ```
* Execute previous cross-compiled code `vect-add-mic` * Execute previous cross-compiled code `vect-add-mic`
```console ```console
r21u01n577-mic1:~$ ml devel_environment r21u01n577-mic1:~$ ml devel_environment
...@@ -436,7 +436,6 @@ Test passed ...@@ -436,7 +436,6 @@ Test passed
!!! tip !!! tip
PATH of MIC libraries for Intel Compiler set automatically. PATH of MIC libraries for Intel Compiler set automatically.
## MPI ## MPI
Load module for devel environment `devel_environment` and load mpi module `impi/2017.3.196-iccifort-2017.4.196-GCC-6.4.0-2.28` (intel/2017b) Load module for devel environment `devel_environment` and load mpi module `impi/2017.3.196-iccifort-2017.4.196-GCC-6.4.0-2.28` (intel/2017b)
...@@ -514,18 +513,18 @@ r21u01n577-mic0:~$ cat test.mat ...@@ -514,18 +513,18 @@ r21u01n577-mic0:~$ cat test.mat
Compiler Compiler
* gcc (GCC) 5.1.1 without gfortran support * gcc (GCC) 5.1.1 without gfortran support
Architecture (depends on compiled software): Architecture (depends on compiled software):
* k1om-unknown-linux-gnu * k1om-unknown-linux-gnu
* k1om-mpss-linux-gnu * k1om-mpss-linux-gnu
* x86_64-k1om-linux * x86_64-k1om-linux
* k1om-mpss-linux * k1om-mpss-linux
Configure (for `configure`,`make` and `make install` software) Configure (for `configure`,`make` and `make install` software)
* specify architecture `--build=` * specify architecture `--build=`
```console ```console
./configure --prefix=/apps/phi/software/ncurses/6.0 --build=k1om-mpss-linux ./configure --prefix=/apps/phi/software/ncurses/6.0 --build=k1om-mpss-linux
...@@ -533,4 +532,4 @@ Configure (for `configure`,`make` and `make install` software) ...@@ -533,4 +532,4 @@ Configure (for `configure`,`make` and `make install` software)
Modulefile and Lmod Modulefile and Lmod
* Read [Lmod](../../../software/modules/lmod/) * Read [Lmod](../../../software/modules/lmod/)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment