A Plan 9 C compiler for RISC-V [pdf]
Just double-checking the part of the presentation where they cite Plan 9&#x27;s C compiler as &quot;predictable&quot; because it doesn&#x27;t optimize away a useless loop... that&#x27;s because the compiler is missing a bunch of useful optimizations isn&#x27;t it?<p>Specifically they say GCC requires this form for the busy loop to be emitted:<p>for (int i = 0; i &lt; 1000000; i++)
     asm volatile (&quot;&quot; ::: &quot;memory&quot;);<p>Where 9c will output a bunch of useless code when you tell it this:<p>for (int i = 0; i &lt; 1000000; i++);<p>And this is... a good thing?