Hi everybody!<br><br>A time ago I sent a email about an error reported on Visual Studio 2005 debugger. I was tring to debug an MPI application.<br><br>That is a simple test, just to see what happens on each process.<br><br>
That's the code:<br><br>// Somas parciais<br> <br>#include <mpi.h><br>#include <stdio.h><br><br>int main(int argc, char *argv[]){<br> int soma = 0, s= 0, myid, numprocs, i, v[100];<br> <br> <br> MPI_Init(&argc, &argv);
<br> MPI_Comm_rank (MPI_COMM_WORLD, &myid);<br> MPI_Comm_size(MPI_COMM_WORLD, &numprocs);<br> if(myid ==0)<br> for(i = 0; i < 100; i++)<br> v[i] = i+1;<br> MPI_Bcast(v, 100, MPI_INT, 0, MPI_COMM_WORLD);
<br> soma = 0;<br> <br> for (i = myid; i< 100; i += numprocs )<br> soma += v[i];<br> <br> printf ("Resultado parcial no processador: %d = %d \n", myid, soma); <br> MPI_Reduce(&soma, &s, 1, MPI_INT, MPI_SUM, 0, MPI_COMM_WORLD);
<br> if(myid == 0)<br> printf("Soma final = %d\n", s);<br> MPI_Finalize();<br> return(0);<br>}<br clear="all"><br>It returns the addition of 100 numbers. The charge is shared equally on each process.
<br><br>But when I try debbug that, the console returns:<br><br>soma.exe on 'bruno' failed, error 5 - Access Denied.<br><br>Windows do not permit Visual Studio create process.<br><br>Anybody has experimented the same error?
<br><br>Thanks!<br><br>-- <br>Bruno Simioni<br>Bacharelado em Ciências da Computação<br>Universidade Estadual Paulista - Unesp - Rio Claro / São Paulo<br><a href="mailto:brunosimioni@gmail.com">brunosimioni@gmail.com</a>
<br>14 - 9753-4380