#include <semaphore.h>
#include <pthread.h>
#include <iostream>;
#include <unistd.h>
#include <time.h>
using namespace std;

#define PROCESS 325000

int i;

void do_work(unsigned int duration);

void do_work(unsigned int duration)
{
	for(i=0; i<duration*PROCESS; i++)
	{
		asm volatile (" NOP"); // Le compilateur effectue un travail
	}	
}

int main()
{

	do_work(1000); // 1 en secondes
	cout << "Fin du travail\n";
	
    return 0;
}

// Combien de nop à faire pour avoir le temps correspondant ?