Skip to content

Commit f869103

Browse files
committed
mpi
1 parent 20b44e8 commit f869103

File tree

1 file changed

+25
-0
lines changed

1 file changed

+25
-0
lines changed

material/aulas/aula07/index.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,31 @@ int main(int argc, char** argv) {
9090
}
9191
```
9292
93+
### Compile o programa:
94+
```bash
95+
mpic++ -FlagdeOtimização seu_codigo.cpp -o seu_binario
96+
```
97+
98+
99+
### Script SLURM
100+
101+
```bash
102+
#!/bin/bash
103+
#SBATCH --job-name=mpi_hello
104+
#SBATCH --output=saida_%j.txt
105+
#SBATCH --ntasks=5
106+
#SBATCH --time=00:01:00
107+
#SBATCH --partition=gpu
108+
109+
110+
mpirun -np $SLURM_NTASKS ./seu_binario
111+
```
112+
113+
### Submeta o job com SLURM:
114+
```bash
115+
sbatch SeuSlurm.slurm
116+
```
117+
93118

94119
## **Token em anel**
95120

0 commit comments

Comments
 (0)