Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-15039

Massive qdebug() slowdown in "Run" mode in 3.5+

    XMLWordPrintable

Details

    • Bug
    • Resolution: Duplicate
    • Not Evaluated
    • None
    • Qt Creator 3.5.0
    • None
    • windows 7, msvc qt 5.4.2, qtcreator 3.4.1/3.5.0 installed from binary distros

    Description

      For the simple progam below qtcreator 3.4.1 takes 4.5 seconds to output text in Run mode (debug build) and 3.5 takes 23 seconds. Both versions take the same amount to produce output if launched as Debug and this time is ~120ms

      2 Questions:
      1) Why is Run mode significantly slower?
      2) Why is Run mode 5 times slower in 3.5?

      My application produces walls of tracing code in certain modes and this slowdown nearly makes "Run" unusable.

      #include <iostream>
      #include <chrono>
      #include <QDebug>

      int main()
      {
      auto start = std::chrono::steady_clock::now();
      for (size_t i = 0; i < 100000; ++i)

      Unknown macro: { qDebug() << "This is line number}

      auto end = std::chrono::steady_clock::now();

      qDebug() << "Output took: " << std::chrono::duration <double, std::milli> (end - start).count() << " ms\n";
      }

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              dt Daniel Teske
              zekses Nikolai
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes