raz / commit cfff918d

commit
cfff918dadc5c8f8447209ef1f84fc5df570e62f
author
Luis <42945842+ldiaz94@users.noreply.github.com>
date
parent
92a199c6
site: v0.10.1

patch · log

6 files changed, +18 -17

site/public/_redirects (history) modified +1 -1

@@ -1 +1 @@
1-/download/latest /download/raz-0.10.0-linux-x86_64.tar.gz 302
1+/download/latest /download/raz-0.10.1-linux-x86_64.tar.gz 302

site/public/advanced/static.html (history) modified +4 -4

@@ -65,7 +65,7 @@
6565 <span class="cmd">$ ldd Bare</span>
6666 not a dynamic executable
6767 <span class="cmd">$ ls -l Bare | awk &#x27;{print $5, &quot;bytes&quot;}&#x27;</span>
68-26280 bytes</code></pre>
68+26288 bytes</code></pre>
6969 <p>It is statically linked: no interpreter, no shared libraries, no <code>libc</code>. <code>ldd</code> says so.</p>
7070 <h2>What it does when it runs</h2>
7171 <p><code>strace</code> lists every system call a program makes. This is the whole of it:</p>
@@ -135,14 +135,14 @@
135135 <span class="cmd">$ raz Heavy.raz</span>
136136 <span class="cmd">$ ls -l Lean Heavy | awk &#x27;{print $9, $5}&#x27;</span>
137137 Heavy 28496
138-Lean 28480</code></pre>
138+Lean 28488</code></pre>
139139 <p>The sizes differ by a few bytes, not by the hundreds of kilobytes that the table and the procedure would take: they are not in the executable at all. You can link in a library module without worrying what else it offers.</p>
140140 <h2>Stripping</h2>
141141 <p><code>-s</code> leaves out what is there for finding faults: the symbols and line numbers, the places a failure is told by, and the profiler. It is for the final build of a size-conscious program; the default keeps them so that gdb and failure messages work.</p>
142142 <pre class="output term"><code><span class="cmd">$ raz -s -o Lean-stripped Lean.raz</span>
143143 <span class="cmd">$ ls -l Lean Lean-stripped | awk &#x27;{print $9, $5}&#x27;</span>
144-Lean 28480
145-Lean-stripped 6848
144+Lean 28488
145+Lean-stripped 6880
146146 <span class="cmd">$ ./Lean-stripped</span>
147147 same program</code></pre>
148148 <p><code>raz -S Lean.raz</code> is the other direction: it prints the machine code the compiler made, one source line at a time. The next two parts of the tour use it.</p><p class="tryit">Save a program under its module&rsquo;s name and run it with <code>raz run Name.raz</code>.</p><div class="pager"><a href="allocators.html">&larr; Writing an allocator</a><a href="index.html">Contents</a><a class="next" href="linkstatic.html">Threads without C, and keeping the two apart &rarr;</a></div></article></div>

site/public/download/raz-0.10.1-linux-x86_64.tar.gz (history) added

Binary file; the patch has it.

site/public/download/raz-0.10.1-linux-x86_64.tar.gz.sha256 (history) added +1 -0

@@ -0,0 +1 @@
1+d844589a05ba97f25413cbf5befe8f60f33857ecdbc12e049c18fe703ab23097 raz-0.10.1-linux-x86_64.tar.gz

site/public/index.html (history) modified +11 -11

@@ -35,13 +35,13 @@
3535 system calls and call C libraries. It has no garbage collector and no hidden
3636 run time: what the program does is what its text says.</p>
3737
38-<p>The compiler is written in raz, about 10,500 lines, and builds itself. It makes
38+<p>The compiler is written in raz, about 10,700 lines, and builds itself. It makes
3939 x86-64 machine code and the ELF file itself, with no assembler or linker, in
40-one pass, at about 500,000 lines a second.</p>
40+one pass, at about 650,000 lines a second.</p>
4141
4242 <div class="facts">
43- <span><b>~10,500</b> lines of compiler</span>
44- <span><b>~500K</b> lines compiled a second</span>
43+ <span><b>~10,700</b> lines of compiler</span>
44+ <span><b>~650K</b> lines compiled a second</span>
4545 <span><b>static</b> executables, no run time to install</span>
4646 <span><b>1</b> report, about <b>30</b> pages</span>
4747 </div>
@@ -109,24 +109,24 @@
109109 short on purpose: whatever it doesn&rsquo;t allow, raz doesn&rsquo;t have.</p>
110110
111111 <h2 id="download">Download</h2>
112-<p>raz 0.10.0 is a tarball for x86-64 Linux with the compiler, <code>raz</code>,
112+<p>raz 0.10.1 is a tarball for x86-64 Linux with the compiler, <code>raz</code>,
113113 its library, <code>lib/</code>, which it finds beside itself, the formatter
114114 and the documentation tool as sources in <code>tools/</code>, and the manual
115115 pages. It needs nothing else installed.</p>
116116 <div class="cta">
117- <a class="btn primary" href="download/raz-0.10.0-linux-x86_64.tar.gz">Download raz 0.10.0</a>
118- <a class="btn" href="download/raz-0.10.0-linux-x86_64.tar.gz.sha256">SHA-256</a>
117+ <a class="btn primary" href="download/raz-0.10.1-linux-x86_64.tar.gz">Download raz 0.10.1</a>
118+ <a class="btn" href="download/raz-0.10.1-linux-x86_64.tar.gz.sha256">SHA-256</a>
119119 </div>
120-<pre class="code"><code>$ tar xzf raz-0.10.0-linux-x86_64.tar.gz
121-$ ln -s $PWD/raz-0.10.0-linux-x86_64/raz ~/.local/bin/raz
120+<pre class="code"><code>$ tar xzf raz-0.10.1-linux-x86_64.tar.gz
121+$ ln -s $PWD/raz-0.10.1-linux-x86_64/raz ~/.local/bin/raz
122122 $ raz run Hello.raz</code></pre>
123123 <p>The link works since raz finds <code>lib/</code> beside its real path. The
124124 manual pages are in <code>man/</code>: <code>man ./man/raz-tutorial.7</code>.
125125 The address <code>download/latest</code> always leads to the newest release,
126-and <code>download/raz-0.10.0-linux-x86_64.tar.gz</code> to this one, for
126+and <code>download/raz-0.10.1-linux-x86_64.tar.gz</code> to this one, for
127127 good. Earlier releases: <a href="download/raz-0.9.1-linux-x86_64.tar.gz">0.9.1</a>, <a href="download/raz-0.9.0-linux-x86_64.tar.gz">0.9.0</a>, <a href="download/raz-0.8.0-linux-x86_64.tar.gz">0.8.0</a>, <a href="download/raz-0.7.1-linux-x86_64.tar.gz">0.7.1</a>; each has its SHA-256 beside it, with
128128 <code>.sha256</code> added to its name.</p>
129-<p class="sha">SHA-256 <code>9ba56121485956986dd242259b9a1e797cd4949ec824e927b16d1f54f23c4a8f</code></p>
129+<p class="sha">SHA-256 <code>d844589a05ba97f25413cbf5befe8f60f33857ecdbc12e049c18fe703ab23097</code></p>
130130
131131 </main>
132132 <footer>raz is under the ISC license.</footer>

site/public/tour/hello.html (history) modified +1 -1

@@ -70,7 +70,7 @@
7070 <span class="cmd">$ raz run Quiet.raz</span>
7171 hello, again
7272 <span class="cmd">$ ls -l Quiet | awk &#x27;{print $5, &quot;bytes&quot;}&#x27;</span>
73-28488 bytes</code></pre>
73+28496 bytes</code></pre>
7474 <p>The program is a static executable with no run time besides the code it uses, so it is a few kilobytes, and runs without any library installed.</p>
7575 <h2>What <code>Out</code> can write</h2>
7676 <p><code>Out</code> is the library's buffered output. It writes strings, single characters, numbers in decimal or hexadecimal, and a line feed. A string is written as it is, with <code>\n</code> for a line feed, <code>\t</code> for a tab, <code>\"</code> and <code>\\</code>.</p>