summaryrefslogtreecommitdiff
path: root/devdocs/elisp/byte-compilation.html
diff options
context:
space:
mode:
authorCraig Jennings <c@cjennings.net>2024-04-07 13:41:34 -0500
committerCraig Jennings <c@cjennings.net>2024-04-07 13:41:34 -0500
commit754bbf7a25a8dda49b5d08ef0d0443bbf5af0e36 (patch)
treef1190704f78f04a2b0b4c977d20fe96a828377f1 /devdocs/elisp/byte-compilation.html
new repository
Diffstat (limited to 'devdocs/elisp/byte-compilation.html')
-rw-r--r--devdocs/elisp/byte-compilation.html48
1 files changed, 48 insertions, 0 deletions
diff --git a/devdocs/elisp/byte-compilation.html b/devdocs/elisp/byte-compilation.html
new file mode 100644
index 00000000..73c33544
--- /dev/null
+++ b/devdocs/elisp/byte-compilation.html
@@ -0,0 +1,48 @@
+ <h2 class="chapter">Byte Compilation</h2> <p>Emacs Lisp has a <em>compiler</em> that translates functions written in Lisp into a special representation called <em>byte-code</em> that can be executed more efficiently. The compiler replaces Lisp function definitions with byte-code. When a byte-code function is called, its definition is evaluated by the <em>byte-code interpreter</em>. </p> <p>Because the byte-compiled code is evaluated by the byte-code interpreter, instead of being executed directly by the machine’s hardware (as true compiled code is), byte-code is completely transportable from machine to machine without recompilation. It is not, however, as fast as true compiled code. </p> <p>In general, any version of Emacs can run byte-compiled code produced by recent earlier versions of Emacs, but the reverse is not true. </p> <p>If you do not want a Lisp file to be compiled, ever, put a file-local variable binding for <code>no-byte-compile</code> into it, like this: </p> <div class="example"> <pre class="example">;; -*-no-byte-compile: t; -*-
+</pre>
+</div> <table class="menu" border="0" cellspacing="0"> <tr>
+<td align="left" valign="top">• <a href="speed-of-byte_002dcode" accesskey="1">Speed of Byte-Code</a>
+</td>
+<td> </td>
+<td align="left" valign="top">An example of speedup from byte compilation. </td>
+</tr> <tr>
+<td align="left" valign="top">• <a href="compilation-functions" accesskey="2">Compilation Functions</a>
+</td>
+<td> </td>
+<td align="left" valign="top">Byte compilation functions. </td>
+</tr> <tr>
+<td align="left" valign="top">• <a href="docs-and-compilation" accesskey="3">Docs and Compilation</a>
+</td>
+<td> </td>
+<td align="left" valign="top">Dynamic loading of documentation strings. </td>
+</tr> <tr>
+<td align="left" valign="top">• <a href="dynamic-loading" accesskey="4">Dynamic Loading</a>
+</td>
+<td> </td>
+<td align="left" valign="top">Dynamic loading of individual functions. </td>
+</tr> <tr>
+<td align="left" valign="top">• <a href="eval-during-compile" accesskey="5">Eval During Compile</a>
+</td>
+<td> </td>
+<td align="left" valign="top">Code to be evaluated when you compile. </td>
+</tr> <tr>
+<td align="left" valign="top">• <a href="compiler-errors" accesskey="6">Compiler Errors</a>
+</td>
+<td> </td>
+<td align="left" valign="top">Handling compiler error messages. </td>
+</tr> <tr>
+<td align="left" valign="top">• <a href="byte_002dcode-objects" accesskey="7">Byte-Code Objects</a>
+</td>
+<td> </td>
+<td align="left" valign="top">The data type used for byte-compiled functions. </td>
+</tr> <tr>
+<td align="left" valign="top">• <a href="disassembly" accesskey="8">Disassembly</a>
+</td>
+<td> </td>
+<td align="left" valign="top">Disassembling byte-code; how to read byte-code. </td>
+</tr> </table><div class="_attribution">
+ <p class="_attribution-p">
+ Copyright &copy; 1990-1996, 1998-2022 Free Software Foundation, Inc. <br>Licensed under the GNU GPL license.<br>
+ <a href="https://www.gnu.org/software/emacs/manual/html_node/elisp/Byte-Compilation.html" class="_attribution-link">https://www.gnu.org/software/emacs/manual/html_node/elisp/Byte-Compilation.html</a>
+ </p>
+</div>