Remove hint.html and index.html

As per discussions on GitHub the index.html and hint.html files should
be deleted in favour of README.md files (from any
.text/.txt/.markdown/.md files which will be turned into README.md in an
upcoming commit).
This commit is contained in:
Cody Boone Ferguson committed 2023-02-08 05:07:05 -08:00
1 parent ee8a36310f
commit 77fb0f11a2
143 files changed
-28606

No files matched your search

-104
View File
@@ -1,104 +0,0 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta name="GENERATOR" content="mkd2html 2.1.3 DL=DISCOUNT">
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=utf-8">
<link rel="stylesheet"
type="text/css"
href="../hint.css">
<title>Most surprisingly portable</title>
</head>
<body>
<h1>Most surprisingly portable</h1>
<p>Gregor Richards<br>
<a href="&#x6d;&#x61;&#105;&#108;&#116;&#111;&#58;&#82;&#105;&#99;&#x68;&#97;&#114;&#100;&#x73;&#64;&#x63;&#111;&#100;&#117;&#46;&#111;&#x72;&#103;">&#82;&#105;&#99;&#104;&#x61;&#114;&#100;&#115;&#x40;&#99;&#111;&#x64;&#117;&#x2e;&#x6f;&#x72;&#x67;</a></p>
<h2>Judges' comments:</h2>
<h3>To build:</h3>
<pre><code>make richards
</code></pre>
<h3>To run:</h3>
<pre><code>./richards
</code></pre>
<h3>Try:</h3>
<pre><code>echo '10 9 8 7 6 5 4 3 2 1*p*p*p*p*p*p*p*p*p' | ./richards
</code></pre>
<h3>Selected Judges Remarks:</h3>
<p>Oh no, yet another dc-style calculator? (see 2000/dlowe using an embedded Perl
interpreter and deemed Worst Abuse of the Rules).
Well, this one does it (expression calculation, that is, not the rule abuse) in a different way.
The author claims that his calculator does just-in-time compilation.
What would you do to prove or disprove his claim without attempting to unravel the source?</p>
<h2>Author&rsquo;s comments:</h2>
<p>This is an implementation of the classic UNIX dc command, the reverse-polish
calculator. Actually it&rsquo;s a pretty bad implementation, since it only implements
32-bit integers (well, sizeof(int)-sized integers). It only implements the
commands +, -, *, /, p (only for numbers), register stacks, macros and
comparisons. Wow, you&rsquo;d think I could&rsquo;ve done better in 2K of code.</p>
<p>OH! I forgot to mention! It&rsquo;s a JIT.</p>
<p>Wait, don&rsquo;t stop reading! I know what you&rsquo;re thinking, platform-specific code
is discouraged in IOCCC. But do you see any platform-specific code? There&rsquo;s no
assembler here! This JIT works on a dozen platforms, and the only
platform-specific assumptions it makes are that the stack grows down and
integers are at least 32-bit.</p>
<p>You will probably get warnings while compiling the code. In particular:</p>
<ul>
<li>If your system requires the inclusion of alloca.h to use alloca, use the
compile flag -DAH</li>
<li>If your system cannot use mmap, use the compile flag -DNM</li>
<li>I don&rsquo;t include any headers I don&rsquo;t strictly need to, so you&rsquo;ll get warnings
about (at least) memcpy, isdigit, atoi, calloc, malloc and alloca if you
didn&rsquo;t use -DAH.</li>
<li>GCC likes to complain about while (a = b) (assignments as a condition).</li>
<li>I don&rsquo;t return from main, even though it&rsquo;s declared to return int.</li>
</ul>
<p>Platforms on which all known/tested optimization levels work with no additional
flags:</p>
<ul>
<li>gcc 4.6.2 + x86[_64] + GNU/Linux, Mac OS X or Windows</li>
<li>clang 2.9-16 + x86[_64] + GNU/Linux or Mac OS X</li>
<li>tcc 0.9.25</li>
<li>gcc 4.4.5 + alpha, arm, mips[el], powerpc[64], s390x (IBM zSeries)</li>
<li>gcc 4.1.3 + vax + NetBSD</li>
</ul>
<p>Platforms which work but not at all optimization levels or needing special
flags:</p>
<ul>
<li>owcc 1.9 + x86 + Windows: Needs -DNM -DAH -fno-stack-check</li>
<li>gcc 4.4.5 + sh4: -O0 works, higher optimization levels don&rsquo;t work for unknown reasons.</li>
</ul>
<hr />
<TABLE><TR>
<TD><a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by-sa/3.0/88x31.png" /></a></TD>
<TD><P>&copy; Copyright 1984-2012,
<A HREF="/judges.html">Leo Broukhis, Simon Cooper, Landon Curt Noll</A>
- All rights reserved<BR>
This work is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">Creative Commons Attribution-ShareAlike 3.0 Unported License</a>.</P></TD>
<TD>&nbsp;<!--<a href="http://validator.w3.org/check?uri=referer"><img src="http://www.w3.org/Icons/valid-html401" alt="Valid HTML 4.01 Transitional" height="31" width="88"></a>--></TD>
</TR></TABLE>
</body>
</html>