Hello,
I've tested this following example in windows wiht gcc4.3.3 to gcc4.4.2 and it
systematly crash. I've tested the same example with linux and it works well

#include <iostream>
#include <pthread.h>
#include <omp.h>

void *myThreadEmit(void *)
{
  std::cout << "start thread.\n";
  #pragma omp parallel  // CRASH HERE CRASH HERE CRASH HERE

  std::cout << "Hello, world in thread.\n";
  return(NULL);
}


int main(int argc, char *argv[])
{
  pthread_t tid;
  omp_set_num_threads(2);

  #pragma omp parallel
  std::cout << "Hello, world.\n";
  pthread_create(&tid,NULL, myThreadEmit, NULL);
  pthread_join(tid,NULL);
  return 0;
}


-- 
           Summary: Very basic example failing
           Product: gcc
           Version: 4.4.0
            Status: UNCONFIRMED
          Severity: major
          Priority: P3
         Component: libgomp
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: duriot at cea dot fr


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41910

Reply via email to