{"id":1495,"date":"2024-02-04T10:20:41","date_gmt":"2024-02-04T10:20:41","guid":{"rendered":"https:\/\/mvermeulen.org\/perf\/?page_id=1495"},"modified":"2024-02-09T03:08:12","modified_gmt":"2024-02-09T03:08:12","slug":"build-imagemagick","status":"publish","type":"page","link":"https:\/\/mvermeulen.org\/perf\/workloads\/phoronix\/build-imagemagick\/","title":{"rendered":"build-imagemagick"},"content":{"rendered":"\n<p>This workload builds imagemagick.  Overall runs in about two minutes with a relatively quick parallel build and a link step.  There is also a preparation step before starting.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1280\" height=\"960\" src=\"https:\/\/mvermeulen.org\/perf\/wp-content\/uploads\/sites\/7\/2024\/02\/systemtime-38.png\" alt=\"\" class=\"wp-image-1603\" srcset=\"https:\/\/mvermeulen.org\/perf\/wp-content\/uploads\/sites\/7\/2024\/02\/systemtime-38.png 1280w, https:\/\/mvermeulen.org\/perf\/wp-content\/uploads\/sites\/7\/2024\/02\/systemtime-38-1024x768.png 1024w, https:\/\/mvermeulen.org\/perf\/wp-content\/uploads\/sites\/7\/2024\/02\/systemtime-38-768x576.png 768w\" sizes=\"auto, (max-width: 1280px) 100vw, 1280px\" \/><\/figure>\n\n\n\n<p>Topdown profile shows a familiar pattern for compiler builds, high and declining frontend stalls, rising backend stalls and overall a lower retirement rate.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1280\" height=\"960\" src=\"https:\/\/mvermeulen.org\/perf\/wp-content\/uploads\/sites\/7\/2024\/02\/amdtopdown-40.png\" alt=\"\" class=\"wp-image-1605\" srcset=\"https:\/\/mvermeulen.org\/perf\/wp-content\/uploads\/sites\/7\/2024\/02\/amdtopdown-40.png 1280w, https:\/\/mvermeulen.org\/perf\/wp-content\/uploads\/sites\/7\/2024\/02\/amdtopdown-40-1024x768.png 1024w, https:\/\/mvermeulen.org\/perf\/wp-content\/uploads\/sites\/7\/2024\/02\/amdtopdown-40-768x576.png 768w\" sizes=\"auto, (max-width: 1280px) 100vw, 1280px\" \/><\/figure>\n\n\n\n<p>AMD metrics show on average half the cores occupied, not much floating point.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>elapsed              121.463\non_cpu               0.517          # 8.27 \/ 16 cores\nutime                910.027\nstime                95.049\nnvcsw                86757          # 39.06%\nnivcsw               135379         # 60.94%\ninblock              0              # 0.00\/sec\nonblock              3834872        # 31572.30\/sec\ncpu-clock            1004331305928  # 1004.331 seconds\ntask-clock           1004388770173  # 1004.389 seconds\npage faults          24696037       # 24588.125\/sec\ncontext switches     197011         # 196.150\/sec\ncpu migrations       13647          # 13.587\/sec\nmajor page faults    529            # 0.527\/sec\nminor page faults    24695508       # 24587.599\/sec\nalignment faults     0              # 0.000\/sec\nemulation faults     0              # 0.000\/sec\nbranches             881822730340   # 209.423 branches per 1000 inst\nbranch misses        25658571898    # 2.91% branch miss\nconditional          681669337951   # 161.889 conditional branches per 1000 inst\nindirect             18455873299    # 4.383 indirect branches per 1000 inst\ncpu-cycles           3886473532658  # 2.02 GHz\ninstructions         4120028775049  # 1.06 IPC\nslots                8055904537614  #\nretiring             1361408959871  # 16.9% (20.5%)\n-- ucode             1620623294     #     0.0%\n-- fastpath          1359788336577  #    16.9%\nfrontend             2556571217388  # 31.7% (38.5%)\n-- latency           1898570714334  #    23.6%\n-- bandwidth         658000503054   #     8.2%\nbackend              2452525094427  # 30.4% (36.9%)\n-- cpu               254685635940   #     3.2%\n-- memory            2197839458487  #    27.3%\nspeculation          278229523338   #  3.5% ( 4.2%)\n-- branch mispredict 274936481894   #     3.4%\n-- pipeline restart  3293041444     #     0.0%\nsmt-contention       1407144242303  # 17.5% ( 0.0%)\ncpu-cycles           3886806462922  # 2.03 GHz\ninstructions         4125209256247  # 1.06 IPC\ninstructions         1400552808014  # 44.647 l2 access per 1000 inst\nl2 hit from l1       52031669429    # 21.21% l2 miss\nl2 miss from l1      7552194472     #\nl2 hit from l2 pf    4785652675     #\nl3 hit from l2 pf    2800899245     #\nl3 miss from l2 pf   2911846570     #\ninstructions         1398659814466  # 23.038 float per 1000 inst\nfloat 512            6354           # 0.000 AVX-512 per 1000 inst\nfloat 256            673666         # 0.000 AVX-256 per 1000 inst\nfloat 128            32221959755    # 23.038 AVX-128 per 1000 inst\nfloat MMX            0              # 0.000 MMX per 1000 inst\nfloat scalar         0              # 0.000 scalar per 1000 inst\ninstructions         2696065        #\nopcache              997995         # 370.167 opcache per 1000 inst\nopcache miss         536437         # 53.8% opcache miss rate\nl1 dTLB miss         6887           # 2.554 L1 dTLB per 1000 inst\nl2 dTLB miss         1278           # 0.474 L2 dTLB per 1000 inst\ninstructions         2718985        #\nicache               1318932        # 485.082 icache per 1000 inst\nicache miss          110459         #  8.4% icache miss rate\nl1 iTLB miss         6              # 0.002 L1 iTLB per 1000 inst\nl2 iTLB miss         0              # 0.000 L2 iTLB per 1000 inst\ntlb flush            20             # 0.007 TLB flush per 1000 inst\n<\/code><\/pre>\n\n\n\n<p>Intel metrics<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>elapsed              121.485\non_cpu               0.562          # 8.99 \/ 16 cores\nutime                1022.044\nstime                69.759\nnvcsw                92658          # 39.41%\nnivcsw               142426         # 60.59%\ninblock              125080         # 1029.60\/sec\nonblock              3791904        # 31213.03\/sec\ncpu-clock            1090495239228  # 1090.495 seconds\ntask-clock           1090585956640  # 1090.586 seconds\npage faults          24511292       # 22475.342\/sec\ncontext switches     209668         # 192.253\/sec\ncpu migrations       14190          # 13.011\/sec\nmajor page faults    776            # 0.712\/sec\nminor page faults    24510516       # 22474.630\/sec\nalignment faults     0              # 0.000\/sec\nemulation faults     0              # 0.000\/sec\nbranches             892377479585   # 208.705 branches per 1000 inst\nbranch misses        20956429584    # 2.35% branch miss\nconditional          892378359361   # 208.706 conditional branches per 1000 inst\nindirect             158427246548   # 37.052 indirect branches per 1000 inst\nslots                14900768800922 #\nretiring             5321604034467  # 35.7% (35.7%)\n-- ucode             347864243144   #     2.3%\n-- fastpath          4973739791323  #    33.4%\nfrontend             4722374590428  # 31.7% (31.7%)\n-- latency           2431102189741  #    16.3%\n-- bandwidth         2291272400687  #    15.4%\nbackend              2537383326802  # 17.0% (17.0%) low\n-- cpu               823856577841   #     5.5%\n-- memory            1713526748961  #    11.5%\nspeculation          2348952745971  # 15.8% (15.8%) high\n-- branch mispredict 2281107755722  #    15.3%\n-- pipeline restart  67844990249    #     0.5%\nsmt-contention       0              #  0.0% ( 0.0%)\ncpu-cycles           11318149180050 # 1.34 GHz\ninstructions         14751039414741 # 1.30 IPC\nl2 access            567303029759   # 47.056 l2 access per 1000 inst\nl2 miss              171315192603   # 30.20% l2 miss\ncpu-cycles           1925447658174  # 33.1% memory latency\nload stalls          616290044520   #  6.1% l1 bound\nl1 miss              498799560920   # 10.0% l2 bound\nl2 miss              306974929079   #  3.5% l3 bound\nl3 miss              238887483084   # 12.4% dram bound\nstore_stalls         21561635919    #  1.1% store bound\n<\/code><\/pre>\n\n\n\n<p>Process overview shows mostly C code with a small amount of C++.  Largest time is in the compiler front ends.  Also looks like we crashed partway so didn&#8217;t get all the process counts.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>27666 processes\n\t1829 cc1                    742.52    44.99\n\t130 cc1plus                 71.07     6.72\n\t1859 as                      24.57     1.78\n\t 68 clinfo                  17.01     5.66\n\t10705 bash                     6.01     1.92\n\t263 ld                       4.91     0.92\n\t 38 vulkaninfo               1.14     1.13\n\t 14 make                     1.00     0.19\n\t  1 bzip2                    0.86     0.03\n\t  4 vulkani:disk$0           0.12     0.12\n\t  6 glxinfo:gdrv0            0.11     0.04\n\t  6 glxinfo:gl0              0.11     0.04\n\t  8 gs                       0.10     0.03\n\t  6 php                      0.08     0.08\n\t  2 llvmpipe-0               0.06     0.06\n\t  2 llvmpipe-1               0.06     0.06\n\t  2 llvmpipe-10              0.06     0.06\n\t  2 llvmpipe-11              0.06     0.06\n\t  2 llvmpipe-12              0.06     0.06\n\t  2 llvmpipe-13              0.06     0.06\n\t  2 llvmpipe-14              0.06     0.06\n\t  2 llvmpipe-15              0.06     0.06\n\t  2 llvmpipe-2               0.06     0.06\n\t  2 llvmpipe-3               0.06     0.06\n\t  2 llvmpipe-4               0.06     0.06\n\t  2 llvmpipe-5               0.06     0.06\n\t  2 llvmpipe-6               0.06     0.06\n\t  2 llvmpipe-7               0.06     0.06\n\t  2 llvmpipe-8               0.06     0.06\n\t  2 llvmpipe-9               0.06     0.06\n\t  2 glxinfo                  0.06     0.02\n\t 11 ar                       0.05     0.40\n\t  6 clang                    0.05     0.07\n\t  2 glxinfo:cs0              0.05     0.02\n\t  2 glxinfo:disk$0           0.05     0.02\n\t  2 glxinfo:sh0              0.05     0.02\n\t  2 glxinfo:shlo0            0.05     0.02\n\t  3 rocminfo                 0.03     0.00\n\t  1 tar                      0.01     0.16\n\t 48 gawk                     0.01     0.00\n\t  6 print                    0.01     0.00\n\t  9 ranlib                   0.00     0.43\n\t2122 rm                       0.00     0.11\n\t1588 cat                      0.00     0.05\n\t  1 lspci                    0.00     0.03\n\t  1 ps                       0.00     0.01\n\t2853 sed                      0.00     0.00\n\t1909 gcc                      0.00     0.00\n\t1731 mv                       0.00     0.00\n\t485 dirname                  0.00     0.00\n\t286 grep                     0.00     0.00\n\t256 collect2                 0.00     0.00\n\t147 g++                      0.00     0.00\n\t122 mkdir                    0.00     0.00\n\t 95 sh                       0.00     0.00\n\t 61 expr                     0.00     0.00\n\t 45 chmod                    0.00     0.00\n\t 37 ln                       0.00     0.00\n\t 35 sort                     0.00     0.00\n\t 33 pkg-config               0.00     0.00\n\t 30 conftest                 0.00     0.00\n\t 23 tr                       0.00     0.00\n\t 16 configure                0.00     0.00\n\t 12 uname                    0.00     0.00\n\t  8 cp                       0.00     0.00\n\t  8 gsettings                0.00     0.00\n\t  8 stat                     0.00     0.00\n\t  8 systemd-detect-          0.00     0.00\n\t  7 rmdir                    0.00     0.00\n\t  6 basename                 0.00     0.00\n\t  6 llvm-link                0.00     0.00\n\t  5 awk                      0.00     0.00\n\t  5 gmain                    0.00     0.00\n\t  5 nm                       0.00     0.00\n\t  5 phoronix-test-s          0.00     0.00\n\t  4 cc                       0.00     0.00\n\t  4 hostname                 0.00     0.00\n\t  3 dconf worker             0.00     0.00\n\t  3 diff                     0.00     0.00\n\t  3 ls                       0.00     0.00\n\t  3 mktemp                   0.00     0.00\n\t  3 time-compile-im          0.00     0.00\n\t  2 arch                     0.00     0.00\n\t  2 date                     0.00     0.00\n\t  2 echo                     0.00     0.00\n\t  2 lscpu                    0.00     0.00\n\t  2 which                    0.00     0.00\n\t  2 xset                     0.00     0.00\n\t  1 cmp                      0.00     0.00\n\t  1 cut                      0.00     0.00\n\t  1 dmesg                    0.00     0.00\n\t  1 dmidecode                0.00     0.00\n\t  1 file                     0.00     0.00\n\t  1 getconf                  0.00     0.00\n\t  1 ifconfig                 0.00     0.00\n\t  1 install                  0.00     0.00\n\t  1 ip                       0.00     0.00\n\t  1 lsmod                    0.00     0.00\n\t  1 mt                       0.00     0.00\n\t  1 objdump                  0.00     0.00\n\t  1 qdbus                    0.00     0.00\n\t  1 readlink                 0.00     0.00\n\t  1 realpath                 0.00     0.00\n\t  1 sleep                    0.00     0.00\n\t  1 strip                    0.00     0.00\n\t  1 stty                     0.00     0.00\n\t  1 systemctl                0.00     0.00\n\t  1 template.sh              0.00     0.00\n\t  1 touch                    0.00     0.00\n\t  1 true                     0.00     0.00\n\t  1 uniq                     0.00     0.00\n\t  1 wc                       0.00     0.00\n\t  1 xml2-config              0.00     0.00\n\t  1 xrandr                   0.00     0.00\n254 processes running\n351 maximum processes\n<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>This workload builds imagemagick. Overall runs in about two minutes with a relatively quick parallel build and a link step. There is also a preparation step before starting. Topdown profile shows a familiar pattern for compiler builds, high and declining <span class=\"excerpt-dots\">&hellip;<\/span> <a class=\"more-link\" href=\"https:\/\/mvermeulen.org\/perf\/workloads\/phoronix\/build-imagemagick\/\"><span class=\"more-msg\">Continue reading &rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"parent":58,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-1495","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/mvermeulen.org\/perf\/wp-json\/wp\/v2\/pages\/1495","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mvermeulen.org\/perf\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/mvermeulen.org\/perf\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/mvermeulen.org\/perf\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mvermeulen.org\/perf\/wp-json\/wp\/v2\/comments?post=1495"}],"version-history":[{"count":3,"href":"https:\/\/mvermeulen.org\/perf\/wp-json\/wp\/v2\/pages\/1495\/revisions"}],"predecessor-version":[{"id":1606,"href":"https:\/\/mvermeulen.org\/perf\/wp-json\/wp\/v2\/pages\/1495\/revisions\/1606"}],"up":[{"embeddable":true,"href":"https:\/\/mvermeulen.org\/perf\/wp-json\/wp\/v2\/pages\/58"}],"wp:attachment":[{"href":"https:\/\/mvermeulen.org\/perf\/wp-json\/wp\/v2\/media?parent=1495"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}