{"id":1493,"date":"2024-02-04T10:19:48","date_gmt":"2024-02-04T10:19:48","guid":{"rendered":"https:\/\/mvermeulen.org\/perf\/?page_id=1493"},"modified":"2024-02-09T03:01:00","modified_gmt":"2024-02-09T03:01:00","slug":"build-gem5","status":"publish","type":"page","link":"https:\/\/mvermeulen.org\/perf\/workloads\/phoronix\/build-gem5\/","title":{"rendered":"build-gem5"},"content":{"rendered":"\n<p>Workload builds the Gem5 architectural simulator, much of the build looks parallel followed by a more serial link type step.<\/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-37.png\" alt=\"\" class=\"wp-image-1599\" srcset=\"https:\/\/mvermeulen.org\/perf\/wp-content\/uploads\/sites\/7\/2024\/02\/systemtime-37.png 1280w, https:\/\/mvermeulen.org\/perf\/wp-content\/uploads\/sites\/7\/2024\/02\/systemtime-37-1024x768.png 1024w, https:\/\/mvermeulen.org\/perf\/wp-content\/uploads\/sites\/7\/2024\/02\/systemtime-37-768x576.png 768w\" sizes=\"auto, (max-width: 1280px) 100vw, 1280px\" \/><\/figure>\n\n\n\n<p>Topdown profile has some general trends of increasing and decreasing backend stalls vs frontend stalls with retirement rate fairly constant. Link steps are also more scattered.<\/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-39.png\" alt=\"\" class=\"wp-image-1601\" srcset=\"https:\/\/mvermeulen.org\/perf\/wp-content\/uploads\/sites\/7\/2024\/02\/amdtopdown-39.png 1280w, https:\/\/mvermeulen.org\/perf\/wp-content\/uploads\/sites\/7\/2024\/02\/amdtopdown-39-1024x768.png 1024w, https:\/\/mvermeulen.org\/perf\/wp-content\/uploads\/sites\/7\/2024\/02\/amdtopdown-39-768x576.png 768w\" sizes=\"auto, (max-width: 1280px) 100vw, 1280px\" \/><\/figure>\n\n\n\n<p>AMD metrics show an average of ~3\/4 of the cores.  Not much floating point and a relatively low retirement rate. Overall frontend stalls are more than backend stalls.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>elapsed              1810.174\non_cpu               0.798          # 12.77 \/ 16 cores\nutime                21039.238\nstime                2080.631\nnvcsw                5803731        # 49.87%\nnivcsw               5834033        # 50.13%\ninblock              264736         # 146.25\/sec\nonblock              28346440       # 15659.51\/sec\ncpu-clock            23120522443545 # 23120.522 seconds\ntask-clock           23121037448160 # 23121.037 seconds\npage faults          570590844      # 24678.427\/sec\ncontext switches     11599518       # 501.687\/sec\ncpu migrations       85722          # 3.708\/sec\nmajor page faults    355            # 0.015\/sec\nminor page faults    570590489      # 24678.412\/sec\nalignment faults     0              # 0.000\/sec\nemulation faults     0              # 0.000\/sec\nbranches             16761584492164 # 212.300 branches per 1000 inst\nbranch misses        551611408858   # 3.29% branch miss\nconditional          12834111922087 # 162.555 conditional branches per 1000 inst\nindirect             447266406613   # 5.665 indirect branches per 1000 inst\ncpu-cycles           93170670452725 # 3.21 GHz\ninstructions         78575451599875 # 0.84 IPC\nslots                187059658915890 #\nretiring             25539899492009 # 13.7% (16.7%)\n-- ucode             28169462556    #     0.0%\n-- fastpath          25511730029453 #    13.6%\nfrontend             66132587341647 # 35.4% (43.3%)\n-- latency           50402032103478 #    26.9%\n-- bandwidth         15730555238169 #     8.4%\nbackend              55784381168682 # 29.8% (36.5%)\n-- cpu               5570341440845  #     3.0%\n-- memory            50214039727837 #    26.8%\nspeculation          5229248647360  #  2.8% ( 3.4%)\n-- branch mispredict 5186046814231  #     2.8%\n-- pipeline restart  43201833129    #     0.0%\nsmt-contention       34373330798460 # 18.4% ( 0.0%)\ncpu-cycles           93195909000520 # 3.22 GHz\ninstructions         78560812172363 # 0.84 IPC\ninstructions         26242593467181 # 56.818 l2 access per 1000 inst\nl2 hit from l1       1312292335999  # 22.59% l2 miss\nl2 miss from l1      243869038203   #\nl2 hit from l2 pf    85842273432    #\nl3 hit from l2 pf    33296301776    #\nl3 miss from l2 pf   59615007749    #\ninstructions         26232003919217 # 16.024 float per 1000 inst\nfloat 512            18926          # 0.000 AVX-512 per 1000 inst\nfloat 256            15702223       # 0.001 AVX-256 per 1000 inst\nfloat 128            420327679598   # 16.023 AVX-128 per 1000 inst\nfloat MMX            0              # 0.000 MMX per 1000 inst\nfloat scalar         96             # 0.000 scalar per 1000 inst\ninstructions         2688226        #\nopcache              992870         # 369.340 opcache per 1000 inst\nopcache miss         533920         # 53.8% opcache miss rate\nl1 dTLB miss         6899           # 2.566 L1 dTLB per 1000 inst\nl2 dTLB miss         1234           # 0.459 L2 dTLB per 1000 inst\ninstructions         2731843        #\nicache               1332619        # 487.810 icache per 1000 inst\nicache miss          114026         #  8.6% icache miss rate\nl1 iTLB miss         11             # 0.004 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\n\n<\/code><\/pre>\n\n\n\n<p>Intel metrics<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>elapsed              2076.244\non_cpu               0.816          # 13.06 \/ 16 cores\nutime                25333.567\nstime                1777.001\nnvcsw                5656806        # 49.63%\nnivcsw               5740028        # 50.37%\ninblock              5287080        # 2546.46\/sec\nonblock              28341616       # 13650.43\/sec\ncpu-clock            27109637330759 # 27109.637 seconds\ntask-clock           27110152714913 # 27110.153 seconds\npage faults          570476396      # 21042.906\/sec\ncontext switches     11358674       # 418.982\/sec\ncpu migrations       77819          # 2.870\/sec\nmajor page faults    3385           # 0.125\/sec\nminor page faults    570473011      # 21042.781\/sec\nalignment faults     0              # 0.000\/sec\nemulation faults     0              # 0.000\/sec\nbranches             16554533948074 # 210.331 branches per 1000 inst\nbranch misses        420682840418   # 2.54% branch miss\nconditional          16554535761194 # 210.331 conditional branches per 1000 inst\nindirect             3208214057581  # 40.761 indirect branches per 1000 inst\nslots                131943668586950 #\nretiring             41217833930568 # 31.2% (31.2%)\n-- ucode             3112135628076  #     2.4%\n-- fastpath          38105698302492 #    28.9%\nfrontend             48463557156999 # 36.7% (36.7%)\n-- latency           27839065050420 #    21.1%\n-- bandwidth         20624492106579 #    15.6%\nbackend              25399276106394 # 19.3% (19.3%)\n-- cpu               7245422419378  #     5.5%\n-- memory            18153853687016 #    13.8%\nspeculation          17330208537534 # 13.1% (13.1%) high\n-- branch mispredict 16790007180191 #    12.7%\n-- pipeline restart  540201357343   #     0.4%\nsmt-contention       0              #  0.0% ( 0.0%)\ncpu-cycles           56299806242194 # 1.71 GHz\ninstructions         58419307240398 # 1.04 IPC\nl2 access            2518816460984  # 58.099 l2 access per 1000 inst\nl2 miss              761491659232   # 30.23% l2 miss\ncpu-cycles           41773327892901 # 39.7% memory latency\nload stalls          16220631545169 #  6.6% l1 bound\nl1 miss              13482977988921 #  9.4% l2 bound\nl2 miss              9548023073896  #  4.6% l3 bound\nl3 miss              7615533491900  # 18.2% dram bound\nstore_stalls         357499861823   #  0.9% store bound\n<\/code><\/pre>\n\n\n\n<p>Process overview shows C++ code with most time in the c11plus front end.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>56641 processes\n\t6774 cc1plus              18279.62  1401.27\n\t 54 scons                 2290.93   186.88\n\t7803 as                    1291.39   202.47\n\t2730 gem5py_m5              761.97    38.80\n\t 51 ld                     261.27    23.85\n\t2781 gem5py                 104.47     9.99\n\t 68 clinfo                  17.85     6.34\n\t1029 cc1                      1.66     0.19\n\t  3 gzip                     1.00     0.09\n\t 38 vulkaninfo               0.76     1.52\n\t  6 php                      0.18     0.43\n\t  6 glxinfo:gdrv0            0.13     0.05\n\t  6 glxinfo:gl0              0.13     0.05\n\t  4 vulkani:disk$0           0.08     0.16\n\t  4 python3                  0.08     0.03\n\t  2 glxinfo                  0.08     0.02\n\t  2 glxinfo:cs0              0.08     0.02\n\t  2 glxinfo:disk$0           0.08     0.02\n\t  2 glxinfo:sh0              0.08     0.02\n\t  2 glxinfo:shlo0            0.08     0.02\n\t  6 clang                    0.07     0.05\n\t  3 tar                      0.04     1.03\n\t  2 llvmpipe-0               0.04     0.08\n\t  2 llvmpipe-1               0.04     0.08\n\t  2 llvmpipe-10              0.04     0.08\n\t  2 llvmpipe-11              0.04     0.08\n\t  2 llvmpipe-12              0.04     0.08\n\t  2 llvmpipe-13              0.04     0.08\n\t  2 llvmpipe-14              0.04     0.08\n\t  2 llvmpipe-15              0.04     0.08\n\t  2 llvmpipe-2               0.04     0.08\n\t  2 llvmpipe-3               0.04     0.08\n\t  2 llvmpipe-4               0.04     0.08\n\t  2 llvmpipe-5               0.04     0.08\n\t  2 llvmpipe-6               0.04     0.08\n\t  2 llvmpipe-7               0.04     0.08\n\t  2 llvmpipe-8               0.04     0.08\n\t  2 llvmpipe-9               0.04     0.08\n\t  3 rocminfo                 0.03     0.00\n\t  7 rm                       0.02     2.94\n\t 21 ar                       0.02     0.07\n\t6833 g++                      0.00     0.06\n\t 21 ranlib                   0.00     0.06\n\t  1 lspci                    0.00     0.02\n\t  1 ps                       0.00     0.01\n\t26956 sh                       0.00     0.00\n\t1078 gcc                      0.00     0.00\n\t 66 python3-config           0.00     0.00\n\t 51 collect2                 0.00     0.00\n\t 28 sed                      0.00     0.00\n\t 13 dirname                  0.00     0.00\n\t 13 readlink                 0.00     0.00\n\t  9 m4                       0.00     0.00\n\t  9 native-elf-form          0.00     0.00\n\t  8 stat                     0.00     0.00\n\t  8 systemd-detect-          0.00     0.00\n\t  8 which                    0.00     0.00\n\t  6 gsettings                0.00     0.00\n\t  6 llvm-link                0.00     0.00\n\t  6 pkg-config               0.00     0.00\n\t  6 swig                     0.00     0.00\n\t  5 cc                       0.00     0.00\n\t  5 dconf worker             0.00     0.00\n\t  5 gmain                    0.00     0.00\n\t  5 phoronix-test-s          0.00     0.00\n\t  4 bash                     0.00     0.00\n\t  4 date                     0.00     0.00\n\t  4 mktemp                   0.00     0.00\n\t  3 awk                      0.00     0.00\n\t  3 basename                 0.00     0.00\n\t  3 build-gem5               0.00     0.00\n\t  3 conftest_2176b2          0.00     0.00\n\t  3 conftest_283931          0.00     0.00\n\t  3 readelf                  0.00     0.00\n\t  3 touch                    0.00     0.00\n\t  2 lscpu                    0.00     0.00\n\t  2 uname                    0.00     0.00\n\t  2 xset                     0.00     0.00\n\t  1 dmesg                    0.00     0.00\n\t  1 dmidecode                0.00     0.00\n\t  1 grep                     0.00     0.00\n\t  1 ifconfig                 0.00     0.00\n\t  1 ip                       0.00     0.00\n\t  1 lsmod                    0.00     0.00\n\t  1 python                   0.00     0.00\n\t  1 qdbus                    0.00     0.00\n\t  1 realpath                 0.00     0.00\n\t  1 sort                     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 wc                       0.00     0.00\n\t  1 xrandr                   0.00     0.00\n1 processes running\n108 maximum processes\n<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Workload builds the Gem5 architectural simulator, much of the build looks parallel followed by a more serial link type step. Topdown profile has some general trends of increasing and decreasing backend stalls vs frontend stalls with retirement rate fairly constant. <span class=\"excerpt-dots\">&hellip;<\/span> <a class=\"more-link\" href=\"https:\/\/mvermeulen.org\/perf\/workloads\/phoronix\/build-gem5\/\"><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-1493","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/mvermeulen.org\/perf\/wp-json\/wp\/v2\/pages\/1493","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=1493"}],"version-history":[{"count":3,"href":"https:\/\/mvermeulen.org\/perf\/wp-json\/wp\/v2\/pages\/1493\/revisions"}],"predecessor-version":[{"id":1602,"href":"https:\/\/mvermeulen.org\/perf\/wp-json\/wp\/v2\/pages\/1493\/revisions\/1602"}],"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=1493"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}