<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Danilo Orfeo</title>
    <description>The latest articles on DEV Community by Danilo Orfeo (@danilor).</description>
    <link>https://dev.to/danilor</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4283366%2F87c1d061-ab91-4ddf-8b57-a2964177b016.png</url>
      <title>DEV Community: Danilo Orfeo</title>
      <link>https://dev.to/danilor</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/danilor"/>
    <language>en</language>
    <item>
      <title>I Built a 39-Line WebAssembly Phone Benchmark and Collected 2,000+ Real Runs: Here Is What Surprised Me</title>
      <dc:creator>Danilo Orfeo</dc:creator>
      <pubDate>Fri, 04 Dec 2026 18:39:17 +0000</pubDate>
      <link>https://dev.to/danilor/i-built-a-39-line-webassembly-phone-benchmark-and-collected-2000-real-runs-here-is-what-1lff</link>
      <guid>https://dev.to/danilor/i-built-a-39-line-webassembly-phone-benchmark-and-collected-2000-real-runs-here-is-what-1lff</guid>
      <description>&lt;p&gt;A few weeks ago I wanted to answer a simple question: instead of abstract benchmark scores that only engineers care about, what if you measured smartphone CPU speed in a unit anyone can picture instantly?&lt;/p&gt;

&lt;p&gt;So I built &lt;a href="https://cardmark.net" rel="noopener noreferrer"&gt;Cardmark&lt;/a&gt;: a free, 1-second browser benchmark that counts how many &lt;strong&gt;52-card poker decks&lt;/strong&gt; your phone can genuinely shuffle across all CPU cores using WebAssembly and Web Workers — no app install, no sign-up, and zero tracking.&lt;/p&gt;

&lt;p&gt;After sharing it online, users organically ran &lt;strong&gt;2,000+ anonymous tests across 195 smartphone models&lt;/strong&gt; (and shuffled over 31 billion decks in its live Android vs. iPhone arena). Looking at the real-world dataset, four genuinely surprising patterns popped out.&lt;/p&gt;

&lt;h2&gt;
  
  
  How the 39-Line WebAssembly Kernel Works
&lt;/h2&gt;

&lt;p&gt;To keep the workload honest across browsers and architectures (ARM64, Apple Silicon, x86):&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Unbiased Fisher–Yates shuffle&lt;/strong&gt; on a 52-card array (&lt;code&gt;0..51&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Zero modulo bias&lt;/strong&gt; via rejection sampling (&lt;code&gt;uint32_t threshold = (0u - bound) % bound&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Deterministic PRNG:&lt;/strong&gt; instead of &lt;code&gt;Math.random()&lt;/code&gt; (which differs by browser), every worker runs &lt;strong&gt;`xoshiro128&lt;/strong&gt;`** (Blackman &amp;amp; Vigna), bit-identical on every device.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Anti-dead-code-elimination:&lt;/strong&gt; an &lt;strong&gt;FNV-1a&lt;/strong&gt; check hashes 5 fixed card slots after every single deck, plus a &lt;strong&gt;52-bit bitmask&lt;/strong&gt; verifies every 1,024 decks that all 52 distinct cards are present.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Best of 3×1s runs&lt;/strong&gt; after warm-up, with all UI animations paused so the screen doesn't steal CPU cycles.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  4 Surprising Findings From 2,000+ Real-World Runs
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. Apple Wins Single-Core, but Android Nearly Doubles It in Multi-Core
&lt;/h3&gt;

&lt;p&gt;On a single CPU core, Apple still holds the #1 and #2 spots: &lt;strong&gt;iPhone 18 Pro Max&lt;/strong&gt; reaches &lt;strong&gt;10.33M decks/sec&lt;/strong&gt; and &lt;strong&gt;iPhone 18 Pro&lt;/strong&gt; hits &lt;strong&gt;10.27M&lt;/strong&gt;, ahead of &lt;strong&gt;Galaxy Z Fold8 Ultra (9.45M)&lt;/strong&gt; and &lt;strong&gt;Galaxy S26 Ultra (9.27M)&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Once you fan out across Web Workers, however, every iPhone generation consistently caps around &lt;strong&gt;2.6×–2.8× scaling&lt;/strong&gt; (~28M total), whereas Snapdragon 8 Elite / Gen 5 flagships scale &lt;strong&gt;5.0×–6.1×&lt;/strong&gt;, pushing Multi-Core to &lt;strong&gt;48.57M decks/sec&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;You can explore the live table here: &lt;a href="https://cardmark.net/single-core/" rel="noopener noreferrer"&gt;Single-Core vs. Multi-Core Observatory&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Custom Oryon Cores vs. Standard ARM Cores on Tight 32-Bit WASM Loops
&lt;/h3&gt;

&lt;p&gt;Across the live database, chips using standard ARM core designs cluster surprisingly close together on this tight 32-bit integer loop:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Galaxy S24 Ultra&lt;/strong&gt; (Snapdragon 8 Gen 3, 50 runs): &lt;strong&gt;13.4M&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Google Pixel 11 Pro&lt;/strong&gt; (Tensor, 24 runs): &lt;strong&gt;15.1M&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Oppo Find X9 Pro&lt;/strong&gt; (Dimensity 9500, 5 runs): &lt;strong&gt;13.6M&lt;/strong&gt; (5.7× scaling)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Meanwhile, Qualcomm's custom &lt;strong&gt;Oryon&lt;/strong&gt; cores jump more than 3× higher (&lt;strong&gt;43.2M&lt;/strong&gt; on S25 Ultra, &lt;strong&gt;47.3M&lt;/strong&gt; on S26 Ultra).&lt;/p&gt;

&lt;h3&gt;
  
  
  3. Same Phone, Different Browser = Up to 22%–33% Speed Gap
&lt;/h3&gt;

&lt;p&gt;Because the benchmark runs inside everyday mobile browsers instead of a native lab app, it also exposes real differences between browser engines on &lt;strong&gt;identical hardware&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;On &lt;strong&gt;Galaxy Z Fold7&lt;/strong&gt;, &lt;strong&gt;Samsung Internet&lt;/strong&gt; beats Chrome by &lt;strong&gt;+22%&lt;/strong&gt; (41.1M vs. 33.6M).&lt;/li&gt;
&lt;li&gt;On &lt;strong&gt;Galaxy S25&lt;/strong&gt;, &lt;strong&gt;Samsung Internet&lt;/strong&gt; beats Chrome by &lt;strong&gt;+16%&lt;/strong&gt; (46.2M vs. 39.9M).&lt;/li&gt;
&lt;li&gt;Across devices, the in-app &lt;strong&gt;Google App&lt;/strong&gt; browser is the slowest overall — dropping up to &lt;strong&gt;33%&lt;/strong&gt; on iPhone 16 compared to Chrome.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Live browser data is tracked here: &lt;a href="https://cardmark.net/browsers/" rel="noopener noreferrer"&gt;Fastest Mobile Browsers Observatory&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  4. Up to 40% Real-World Spread on the Exact Same Model
&lt;/h3&gt;

&lt;p&gt;On popular models with 10+ runs, the spread between healthy units and throttled units of the &lt;strong&gt;exact same phone&lt;/strong&gt; reaches &lt;strong&gt;32%–40%&lt;/strong&gt; (e.g. Galaxy S25 Ultra ranges from 47.7M down to 28.6M; Pixel 9a drops 40%; iPhone 17 Pro drops 32%).&lt;/p&gt;

&lt;p&gt;Because of that, I added a free &lt;strong&gt;1-second CPU Health Report&lt;/strong&gt; right after each test: it compares your phone against the real-world average of other owners of your exact model, breaks down every individual core, and flags likely throttling or browser bottlenecks (&lt;a href="https://cardmark.net/phone-health/" rel="noopener noreferrer"&gt;CPU Health Guide&lt;/a&gt;).&lt;/p&gt;

&lt;h2&gt;
  
  
  Open Data &amp;amp; Try It Yourself
&lt;/h2&gt;

&lt;p&gt;All aggregated model data is published under &lt;strong&gt;CC BY 4.0&lt;/strong&gt; with a free JSON API (&lt;a href="https://cardmark.net/api/" rel="noopener noreferrer"&gt;CARDMARK API&lt;/a&gt;) and full live rankings (&lt;a href="https://cardmark.net/leaderboard/" rel="noopener noreferrer"&gt;Worldwide Smartphone Leaderboard&lt;/a&gt;).&lt;/p&gt;

&lt;p&gt;If you want to see where your own phone lands — or test how your browser compares — you can run the 1-second test at &lt;a href="https://cardmark.net/" rel="noopener noreferrer"&gt;&lt;strong&gt;cardmark.net&lt;/strong&gt;&lt;/a&gt;. Curious to hear what scores and scaling factors you get!&lt;/p&gt;

</description>
      <category>webassembly</category>
      <category>javascript</category>
      <category>webdev</category>
      <category>performance</category>
    </item>
  </channel>
</rss>
