Results 1 to 17 of 17

Thread: does a Qt application run faster on a windows 64 bit machine?

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,376
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Thanks
    4
    Thanked 5,019 Times in 4,795 Posts
    Wiki edits
    10

    Default Re: does a Qt application run faster on a windows 64 bit maschine?

    Quote Originally Posted by pkohut View Post
    While technically true, there is no free lunch. "easy paralellized" "simple OpenCl kernel", again are dependent an the OP's capabilities and understanding of parallel programming issues.
    It's not that bad. If you have a for loop such as the following:
    Qt Code:
    1. for(int r = 0; r < rows; ++r) {
    2. for(int c = 0; c < cols; ++c) {
    3. doSomething(r,c);
    4. }
    5. }
    To copy to clipboard, switch view to plain text mode 
    Can be rewritten as
    Qt Code:
    1. QFutureSynchronizer<void> waiter;
    2. for(int r = 0; r < rows; ++r) {
    3. for(int c = 0; c < cols; ++c) {
    4. waiter.addFuture(QtConcurrent::run(doSomething, r, c));
    5. }
    6. }
    7. waiter.waitForFinished(); // or do something else in the meantime
    To copy to clipboard, switch view to plain text mode 

    This doesn't require any skills and provided that doSomething() does more than just add two ints together, you will get a decent speed improvement on a multicore system. Of course there is a good chance the loop can be substituted with a flat call to QtConcurrent::mappedReduced(). OpenCL is more tricky although I see the OP's calculations are mostly simple vector operations (additions and multiplications) so the code doesn't need many changes.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  2. #2
    Join Date
    Jul 2009
    Posts
    92
    Qt products
    Qt4
    Platforms
    Windows
    Thanks
    7
    Thanked 3 Times in 3 Posts

    Default Re: does a Qt application run faster on a windows 64 bit maschine?

    thanks for the help and suggestions guys, I really apreciate it.

Similar Threads

  1. Replies: 7
    Last Post: 29th January 2009, 19:47
  2. Deploying application on Linux machine without Qt
    By will49 in forum Installation and Deployment
    Replies: 2
    Last Post: 10th July 2008, 22:41
  3. Replies: 8
    Last Post: 9th May 2008, 16:54
  4. Qt 4.3.0 on Windows in a Virtual Machine
    By Tux-Slack in forum Installation and Deployment
    Replies: 2
    Last Post: 12th July 2007, 22:52
  5. Porting my program to another windows machine !
    By probine in forum Qt Programming
    Replies: 1
    Last Post: 14th March 2007, 06:46

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
  •  
Qt is a trademark of The Qt Company.