[GE users] cpu intensive test job?

reuti reuti at staff.uni-marburg.de
Fri Feb 6 16:14:06 GMT 2009


Hi,

Am 06.02.2009 um 17:03 schrieb russray:

> Does anyone have a good way to test their queue changes?  I'm  
> looking for a script or something that will suck up cpu time but  
> not consume any of my licenses so that I can test out changes to  
> the scheduler.  Does anyone have something?  RIght now I've been  
> using sleep, but it doesn't do anything to the cpu.

you can use just a loop doing some simple computations:

int main(void)
{
     float x;
     long  i,j;

     for (;;)
         for (i=0;i<=10000;i++)
             x=3.1415926*i+i+i*i*2.7182818;

     return 0;
}

or for the parallel case:

#include <stdio.h>
#include <mpi.h>

main(int argc, char **argv)
{
    int node;

    int i;
    float f;

    MPI_Init(&argc,&argv);
    MPI_Comm_rank(MPI_COMM_WORLD, &node);

    printf("Hello World from Node %d.\n", node);
    for(;;)
       for(i=0;i <= 100; i++)
           f=i*2.718281828*i+i+i*3.141592654;

    MPI_Finalize();
}

Both you have to kill or adjust the programs and put an ending loop  
there instead of the endless one.

-- Reuti

>
> Russell Ray
> rray at semtech.com

------------------------------------------------------
http://gridengine.sunsource.net/ds/viewMessage.do?dsForumId=38&dsMessageId=102431

To unsubscribe from this discussion, e-mail: [users-unsubscribe at gridengine.sunsource.net].



More information about the gridengine-users mailing list