You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
i tried several on github, yours is sofar the best. But still an issue:
if not resumed, only a couple of jobs are done, not all;
if resumed, i got a warning: [THREADPOOL:RESM:WARNING] Pool is not suspended!
Following my main.c for reference:
void longJob(void *dummy){
volatile unsigned long long i;
// for (i = 0; i < 1000000000ULL; ++i);
printf("job done\n");
}
int main(){
uint64_t size=11;
ThreadPool *pool = createPool(size);
size=20;
for(int i = 0;i < size;i++)
addJobToPool(pool, &longJob, NULL);
resumePool(pool);
waitToComplete(pool);
printf("all jobs completed\n");
destroyPool(pool);
printf("pool destroyed\n");
}
The text was updated successfully, but these errors were encountered:
Hi subhranil,
i tried several on github, yours is sofar the best. But still an issue:
if not resumed, only a couple of jobs are done, not all;
if resumed, i got a warning: [THREADPOOL:RESM:WARNING] Pool is not suspended!
Following my main.c for reference:
void longJob(void *dummy){
volatile unsigned long long i;
// for (i = 0; i < 1000000000ULL; ++i);
printf("job done\n");
}
int main(){
uint64_t size=11;
ThreadPool *pool = createPool(size);
}
The text was updated successfully, but these errors were encountered: