{"id":181,"date":"2020-10-11T16:02:19","date_gmt":"2020-10-11T23:02:19","guid":{"rendered":"http:\/\/junsun.net\/wordpress\/?p=181"},"modified":"2020-10-11T16:02:19","modified_gmt":"2020-10-11T23:02:19","slug":"aws-arm64-vs-x86_64-bitcoin-performance-comparison","status":"publish","type":"post","link":"http:\/\/junsun.net\/wordpress\/2020\/10\/aws-arm64-vs-x86_64-bitcoin-performance-comparison\/","title":{"rendered":"AWS ARM64 vs. X86_64 &#8211; Bitcoin Performance Comparison"},"content":{"rendered":"\n<p>I&#8217;m running some experiments with bitcoin core software on AWS.  I&#8217;m intrigued by 2 questions:<\/p>\n\n\n\n<ul><li>Which performs better, ARM64 vs X86_64?<\/li><li>What is performance loss of 32bit ARM vs 64bit ARM?<\/li><\/ul>\n\n\n\n<h4>The Experiment<\/h4>\n\n\n\n<ul><li>I fired up a t3.medium instance with <a href=\"https:\/\/aws.amazon.com\/marketplace\/pp\/B08BRR772D\">ubuntu desktop 20.04(x86_64)<\/a>  image<\/li><li>I fired a second instance of t4g.medium type with <a href=\"https:\/\/aws.amazon.com\/marketplace\/pp\/B08FCJSTSS\">ubuntu desktop 20.04 (arm64) image<\/a><\/li><li>To run 32bit ARM program, I followed the <a href=\"http:\/\/junsun.net\/wordpress\/2020\/06\/develop-32bit-applications-in-64bit-linux\/\">chroot approach documented in my previous post<\/a> and set up an armhf Ubuntu 20.04 (focal) chroot environment  <\/li><li>Then I download all 3 versions of bitcoin core software from<a href=\"https:\/\/bitcoincore.org\/en\/download\/\"> its download site<\/a> : 32bit ARM, 64bit ARM and 64bit Intel.<\/li><li>Run bitcoin-qt from scratch (delete ~\/.bitcoin directory if any) and count the time duration for the verifying first 200,000 blocks.<ul><li>Each configuration runs 2 times.  We then take the average.<\/li><li>Other system variables are monitored to ensure similar running environment.   Specifically networking or disk don&#8217;t seem to be a factor.<\/li><\/ul><\/li><\/ul>\n\n\n\n<h4>The Results<\/h4>\n\n\n\n<p>See results listed below.  It seems for bitcoin related workload 64bit ARM version performs 20% faster than 32bit ARM version and 64bit Intel instance.<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><tbody><tr><td>category<\/td><td>64bit ARM <\/td><td>32bit ARM<\/td><td>64bit Intel<\/td><\/tr><tr><td>Instance type<\/td><td>t4g.medium<\/td><td>t4g.medium<\/td><td>t3.medium<\/td><\/tr><tr><td>CPU <\/td><td>Graviton2<\/td><td>Graviton2<\/td><td>Intel Xeon Platinum 8000 series<\/td><\/tr><tr><td># CPU cores<\/td><td>2<\/td><td>2<\/td><td>2<\/td><\/tr><tr><td>RAM (GB)<\/td><td>4<\/td><td>4<\/td><td>4<\/td><\/tr><tr><td>run duration #1<\/td><td>8&#8217;44&#8221; (524&#8243;)<\/td><td>10&#8217;24&#8221; (624&#8243;)<\/td><td>11&#8217;16&#8243;(676&#8243;)<\/td><\/tr><tr><td>run duration #2<\/td><td>7&#8217;30&#8221; (450&#8243;)<\/td><td>9&#8217;58&#8243;(598&#8243;)<\/td><td>9&#8217;04&#8243;(544&#8243;)<\/td><\/tr><tr><td>run duration average<\/td><td>487&#8243;<\/td><td>611&#8243;<\/td><td>610&#8243;<\/td><\/tr><tr><td>relative performance to 64bit ARM<\/td><td>100%<\/td><td>80%<\/td><td>80%<\/td><\/tr><tr><td>Pricing (us-west-2\/Orgon) ($\/hr)<\/td><td>0.0336<\/td><td>0.0336<\/td><td>0.0416<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>I&#8217;m running some experiments with bitcoin core software on AWS. I&#8217;m intrigued by 2 questions: Which performs better, ARM64 vs X86_64? What is performance loss of 32bit ARM vs 64bit ARM? The Experiment I fired up a t3.medium instance with ubuntu desktop 20.04(x86_64) image I fired a second instance of t4g.medium type with ubuntu desktop &hellip; <\/p>\n<p class=\"link-more\"><a href=\"http:\/\/junsun.net\/wordpress\/2020\/10\/aws-arm64-vs-x86_64-bitcoin-performance-comparison\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;AWS ARM64 vs. X86_64 &#8211; Bitcoin Performance Comparison&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"spay_email":""},"categories":[3],"tags":[8,48,49,45],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"http:\/\/junsun.net\/wordpress\/wp-json\/wp\/v2\/posts\/181"}],"collection":[{"href":"http:\/\/junsun.net\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/junsun.net\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/junsun.net\/wordpress\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/junsun.net\/wordpress\/wp-json\/wp\/v2\/comments?post=181"}],"version-history":[{"count":1,"href":"http:\/\/junsun.net\/wordpress\/wp-json\/wp\/v2\/posts\/181\/revisions"}],"predecessor-version":[{"id":182,"href":"http:\/\/junsun.net\/wordpress\/wp-json\/wp\/v2\/posts\/181\/revisions\/182"}],"wp:attachment":[{"href":"http:\/\/junsun.net\/wordpress\/wp-json\/wp\/v2\/media?parent=181"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/junsun.net\/wordpress\/wp-json\/wp\/v2\/categories?post=181"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/junsun.net\/wordpress\/wp-json\/wp\/v2\/tags?post=181"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}