Results 1 to 2 of 2

Thread: OpenMP problems with Qt Creator

  1. #1
    Join Date
    Oct 2010
    Posts
    2
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default OpenMP problems with Qt Creator

    Hi.

    I'm having some problems with OpenMP and Qt Creator. Everything I build that uses OpenMP seems to exit with code -1073741515.

    Here's a small test that exits upon #pragma omp parallel. If I comment it out however, it works just fine.
    Qt Code:
    1. #include <iostream>
    2. #include <omp.h>
    3.  
    4. int main(int argc, char* argv[]) {
    5.  
    6. #pragma omp parallel
    7. std::cout << "Hello, world!" << std::endl;
    8. return 0;
    9. }
    To copy to clipboard, switch view to plain text mode 

    And here's my .pro file. It seems to find the library just fine:
    Qt Code:
    1. TARGET = OpenMP
    2. TEMPLATE = app
    3. SOURCES += main.cpp
    4.  
    5. QMAKE_CXXFLAGS += -fopenmp
    6. QMAKE_LFLAGS += -fopenmp
    7. CONFIG += console
    8. LIBS += -lgomp
    To copy to clipboard, switch view to plain text mode 

    Any ideas?

  2. #2
    Join Date
    Oct 2010
    Posts
    2
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: OpenMP problems with Qt Creator

    I solved it. Basically, for some reason I seem to be missing pthreadCG2.dll which OpenMP seems to depend on. You can either compile Pthreads yourself or just go to Google for the missing dll.

Similar Threads

  1. Replies: 14
    Last Post: 17th August 2010, 12:17
  2. Complie problems in using Qt Creator.
    By Zmrca in forum Installation and Deployment
    Replies: 4
    Last Post: 20th April 2010, 17:16
  3. Qt + OpenMP missing pthreadGC2.dll
    By Sanuden in forum Installation and Deployment
    Replies: 1
    Last Post: 30th March 2010, 14:13
  4. Progress Bar set value inside OpenMP parallel for
    By lixo1 in forum Qt Programming
    Replies: 2
    Last Post: 18th February 2010, 19:51
  5. QThread and OpenMP on Mac problem
    By Debilski in forum Qt Programming
    Replies: 0
    Last Post: 7th April 2009, 17:41

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.