Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. How to get building time w QT Creator
Forum Updated to NodeBB v4.3 + New Features

How to get building time w QT Creator

Scheduled Pinned Locked Moved Unsolved General and Desktop
5 Posts 3 Posters 428 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • I Offline
    I Offline
    icebergenergy
    wrote on last edited by
    #1

    Need to output total building time.
    If possible, please advise for compilation time too

    sierdzioS 1 Reply Last reply
    0
    • I icebergenergy

      Need to output total building time.
      If possible, please advise for compilation time too

      sierdzioS Online
      sierdzioS Online
      sierdzio
      Moderators
      wrote on last edited by
      #2

      @icebergenergy Just look at the bottom of "Compilation output" pane after you build, Qt Creator always writes how long it took.

      (Z(:^

      1 Reply Last reply
      0
      • I Offline
        I Offline
        icebergenergy
        wrote on last edited by
        #3

        OK! how is there a way to get same + miliseconds?

        JonBJ 1 Reply Last reply
        0
        • I icebergenergy

          OK! how is there a way to get same + miliseconds?

          JonBJ Offline
          JonBJ Offline
          JonB
          wrote on last edited by
          #4

          @icebergenergy
          I wouldn't have thought you can choose its output format. But for milliseconds you realize it's calling qmake/cmake, and that will be calling up compilers and linkers.... How accurate or useful will milliseconds be here?

          1 Reply Last reply
          1
          • sierdzioS Online
            sierdzioS Online
            sierdzio
            Moderators
            wrote on last edited by sierdzio
            #5

            Yes, miliseconds is an overkill. You will get different results in seconds for different runs. Compilation time depends on a lot of things you have little control over:

            • maybe OS is doing something in the background?
            • antivirus can be scanning some file just as you build your project
            • your CPU is a bit hotter because it did some heavy tasks a few seconds ago, so boost clocks will behave differently
            • maybe the day is a bit warmer and will affect boost clocks as well
            • is cmake cache cold, does cmake need to re-run?
            • is ccache used?
            • is unity build used?
            • and many, many more

            On my current project, the whole compilation (when both ccache and unity builds are turned off) will take about 2 minutes +- 5 seconds. Using miliseconds here gives no benefit, it might only prompt you to do needless optimisation.

            (Z(:^

            1 Reply Last reply
            1

            • Login

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups
            • Search
            • Get Qt Extensions
            • Unsolved