[SCore-users-jp] Re: [SCore-users] sleep or signal problems

Atsushi HORI hori @ swimmy-soft.com
2002年 10月 8日 (火) 19:05:29 JST


Hi, I am sorry for this late answer. I have been busy for preparing 
the next SCore release.

>I'm trying to run the following simple C program on SCore 4.2.1:
>
>#include <stdio.h>
>#include <unistd.h>
>#include <mpi.h>
>
>int main(int argc, char *argv[])
>{
>int r;
>
>r = MPI_Init(&argc, &argv);
>printf("Sleeping...\n");
>r = sleep(10);
>printf("Finalizing. Sleep left: %d\n", r);
>MPI_Finalize();
>return 1;
>}
>
>I expect that after the processes are started on nodes, they all sleep for 
>10 seconds then they finish. On SCore this doesn't happen, the 'sleep' 
>call doesn't pause execution, instead returns 10 (or whatever number of 
>seconds I ask for). The man page for sleep(3) suggests that this situation 
>should occur when a signal which is not ignored arrives.
>The same program functions as expected when using MPICH 1.2.2 over TCP.

Well, this can happen because user processes is kept receiving 
SIGSTOP and SIGCONT for gang scheduling.

The easiest way is to change the function name of sleep() to sc_sleep().


r = sc_sleep(10);  /* sc_sleep() is an SCore builtin function */


----
Atsushi HORI
Swimmy Software, Inc.

_______________________________________________
SCore-users mailing list
SCore-users @ pccluster.org
http://www.pccluster.org/mailman/listinfo/score-users



SCore-users-jp メーリングリストの案内