diff options
author | Mike Pall <mike> | 2012-10-14 21:48:04 +0200 |
---|---|---|
committer | Mike Pall <mike> | 2012-10-14 21:48:04 +0200 |
commit | d70d77549b397a8b9ebeed199f32e7827214c00b (patch) | |
tree | 9337bcd70521cf80f1e39971abe2e0efc32082ef /doc | |
parent | a0ee70de6de0ade39de17b5678b23bf311d20d9e (diff) | |
download | luajit-d70d77549b397a8b9ebeed199f32e7827214c00b.tar.gz luajit-d70d77549b397a8b9ebeed199f32e7827214c00b.tar.bz2 luajit-d70d77549b397a8b9ebeed199f32e7827214c00b.zip |
Documentation cleanup and reorganization.
Diffstat (limited to 'doc')
-rw-r--r-- | doc/changes.html | 4 | ||||
-rw-r--r-- | doc/contact.html | 4 | ||||
-rw-r--r-- | doc/ext_c_api.html | 4 | ||||
-rw-r--r-- | doc/ext_ffi.html | 4 | ||||
-rw-r--r-- | doc/ext_ffi_api.html | 4 | ||||
-rw-r--r-- | doc/ext_ffi_semantics.html | 4 | ||||
-rw-r--r-- | doc/ext_ffi_tutorial.html | 4 | ||||
-rw-r--r-- | doc/ext_jit.html | 4 | ||||
-rw-r--r-- | doc/extensions.html | 70 | ||||
-rw-r--r-- | doc/faq.html | 4 | ||||
-rw-r--r-- | doc/install.html | 4 | ||||
-rw-r--r-- | doc/luajit.html | 182 | ||||
-rw-r--r-- | doc/running.html | 4 | ||||
-rw-r--r-- | doc/status.html | 156 |
14 files changed, 245 insertions, 207 deletions
diff --git a/doc/changes.html b/doc/changes.html index f3f8604c..50706a11 100644 --- a/doc/changes.html +++ b/doc/changes.html | |||
@@ -23,6 +23,8 @@ div.major { max-width: 600px; padding: 1em; margin: 1em 0 1em 0; } | |||
23 | <ul><li> | 23 | <ul><li> |
24 | <a href="luajit.html">LuaJIT</a> | 24 | <a href="luajit.html">LuaJIT</a> |
25 | <ul><li> | 25 | <ul><li> |
26 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
27 | </li><li> | ||
26 | <a href="install.html">Installation</a> | 28 | <a href="install.html">Installation</a> |
27 | </li><li> | 29 | </li><li> |
28 | <a href="running.html">Running</a> | 30 | <a href="running.html">Running</a> |
@@ -53,8 +55,6 @@ div.major { max-width: 600px; padding: 1em; margin: 1em 0 1em 0; } | |||
53 | </li><li> | 55 | </li><li> |
54 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> | 56 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> |
55 | </li><li> | 57 | </li><li> |
56 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
57 | </li><li> | ||
58 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> | 58 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> |
59 | </li><li> | 59 | </li><li> |
60 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> | 60 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> |
diff --git a/doc/contact.html b/doc/contact.html index aa725005..54c3aa9c 100644 --- a/doc/contact.html +++ b/doc/contact.html | |||
@@ -20,6 +20,8 @@ | |||
20 | <ul><li> | 20 | <ul><li> |
21 | <a href="luajit.html">LuaJIT</a> | 21 | <a href="luajit.html">LuaJIT</a> |
22 | <ul><li> | 22 | <ul><li> |
23 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
24 | </li><li> | ||
23 | <a href="install.html">Installation</a> | 25 | <a href="install.html">Installation</a> |
24 | </li><li> | 26 | </li><li> |
25 | <a href="running.html">Running</a> | 27 | <a href="running.html">Running</a> |
@@ -50,8 +52,6 @@ | |||
50 | </li><li> | 52 | </li><li> |
51 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> | 53 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> |
52 | </li><li> | 54 | </li><li> |
53 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
54 | </li><li> | ||
55 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> | 55 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> |
56 | </li><li> | 56 | </li><li> |
57 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> | 57 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> |
diff --git a/doc/ext_c_api.html b/doc/ext_c_api.html index df4084bf..812dce86 100644 --- a/doc/ext_c_api.html +++ b/doc/ext_c_api.html | |||
@@ -20,6 +20,8 @@ | |||
20 | <ul><li> | 20 | <ul><li> |
21 | <a href="luajit.html">LuaJIT</a> | 21 | <a href="luajit.html">LuaJIT</a> |
22 | <ul><li> | 22 | <ul><li> |
23 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
24 | </li><li> | ||
23 | <a href="install.html">Installation</a> | 25 | <a href="install.html">Installation</a> |
24 | </li><li> | 26 | </li><li> |
25 | <a href="running.html">Running</a> | 27 | <a href="running.html">Running</a> |
@@ -50,8 +52,6 @@ | |||
50 | </li><li> | 52 | </li><li> |
51 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> | 53 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> |
52 | </li><li> | 54 | </li><li> |
53 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
54 | </li><li> | ||
55 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> | 55 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> |
56 | </li><li> | 56 | </li><li> |
57 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> | 57 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> |
diff --git a/doc/ext_ffi.html b/doc/ext_ffi.html index 00623a3a..1dad3384 100644 --- a/doc/ext_ffi.html +++ b/doc/ext_ffi.html | |||
@@ -20,6 +20,8 @@ | |||
20 | <ul><li> | 20 | <ul><li> |
21 | <a href="luajit.html">LuaJIT</a> | 21 | <a href="luajit.html">LuaJIT</a> |
22 | <ul><li> | 22 | <ul><li> |
23 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
24 | </li><li> | ||
23 | <a href="install.html">Installation</a> | 25 | <a href="install.html">Installation</a> |
24 | </li><li> | 26 | </li><li> |
25 | <a href="running.html">Running</a> | 27 | <a href="running.html">Running</a> |
@@ -50,8 +52,6 @@ | |||
50 | </li><li> | 52 | </li><li> |
51 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> | 53 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> |
52 | </li><li> | 54 | </li><li> |
53 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
54 | </li><li> | ||
55 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> | 55 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> |
56 | </li><li> | 56 | </li><li> |
57 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> | 57 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> |
diff --git a/doc/ext_ffi_api.html b/doc/ext_ffi_api.html index 503c6e4a..e894f84b 100644 --- a/doc/ext_ffi_api.html +++ b/doc/ext_ffi_api.html | |||
@@ -25,6 +25,8 @@ td.abiparam { font-weight: bold; width: 6em; } | |||
25 | <ul><li> | 25 | <ul><li> |
26 | <a href="luajit.html">LuaJIT</a> | 26 | <a href="luajit.html">LuaJIT</a> |
27 | <ul><li> | 27 | <ul><li> |
28 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
29 | </li><li> | ||
28 | <a href="install.html">Installation</a> | 30 | <a href="install.html">Installation</a> |
29 | </li><li> | 31 | </li><li> |
30 | <a href="running.html">Running</a> | 32 | <a href="running.html">Running</a> |
@@ -55,8 +57,6 @@ td.abiparam { font-weight: bold; width: 6em; } | |||
55 | </li><li> | 57 | </li><li> |
56 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> | 58 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> |
57 | </li><li> | 59 | </li><li> |
58 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
59 | </li><li> | ||
60 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> | 60 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> |
61 | </li><li> | 61 | </li><li> |
62 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> | 62 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> |
diff --git a/doc/ext_ffi_semantics.html b/doc/ext_ffi_semantics.html index 275b5184..f8da1e60 100644 --- a/doc/ext_ffi_semantics.html +++ b/doc/ext_ffi_semantics.html | |||
@@ -25,6 +25,8 @@ td.convop { font-style: italic; width: 40%; } | |||
25 | <ul><li> | 25 | <ul><li> |
26 | <a href="luajit.html">LuaJIT</a> | 26 | <a href="luajit.html">LuaJIT</a> |
27 | <ul><li> | 27 | <ul><li> |
28 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
29 | </li><li> | ||
28 | <a href="install.html">Installation</a> | 30 | <a href="install.html">Installation</a> |
29 | </li><li> | 31 | </li><li> |
30 | <a href="running.html">Running</a> | 32 | <a href="running.html">Running</a> |
@@ -55,8 +57,6 @@ td.convop { font-style: italic; width: 40%; } | |||
55 | </li><li> | 57 | </li><li> |
56 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> | 58 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> |
57 | </li><li> | 59 | </li><li> |
58 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
59 | </li><li> | ||
60 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> | 60 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> |
61 | </li><li> | 61 | </li><li> |
62 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> | 62 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> |
diff --git a/doc/ext_ffi_tutorial.html b/doc/ext_ffi_tutorial.html index c5dc68ae..b8a08227 100644 --- a/doc/ext_ffi_tutorial.html +++ b/doc/ext_ffi_tutorial.html | |||
@@ -27,6 +27,8 @@ td.idiomlua b { font-weight: normal; color: #2142bf; } | |||
27 | <ul><li> | 27 | <ul><li> |
28 | <a href="luajit.html">LuaJIT</a> | 28 | <a href="luajit.html">LuaJIT</a> |
29 | <ul><li> | 29 | <ul><li> |
30 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
31 | </li><li> | ||
30 | <a href="install.html">Installation</a> | 32 | <a href="install.html">Installation</a> |
31 | </li><li> | 33 | </li><li> |
32 | <a href="running.html">Running</a> | 34 | <a href="running.html">Running</a> |
@@ -57,8 +59,6 @@ td.idiomlua b { font-weight: normal; color: #2142bf; } | |||
57 | </li><li> | 59 | </li><li> |
58 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> | 60 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> |
59 | </li><li> | 61 | </li><li> |
60 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
61 | </li><li> | ||
62 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> | 62 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> |
63 | </li><li> | 63 | </li><li> |
64 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> | 64 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> |
diff --git a/doc/ext_jit.html b/doc/ext_jit.html index 6d683899..c42ab788 100644 --- a/doc/ext_jit.html +++ b/doc/ext_jit.html | |||
@@ -20,6 +20,8 @@ | |||
20 | <ul><li> | 20 | <ul><li> |
21 | <a href="luajit.html">LuaJIT</a> | 21 | <a href="luajit.html">LuaJIT</a> |
22 | <ul><li> | 22 | <ul><li> |
23 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
24 | </li><li> | ||
23 | <a href="install.html">Installation</a> | 25 | <a href="install.html">Installation</a> |
24 | </li><li> | 26 | </li><li> |
25 | <a href="running.html">Running</a> | 27 | <a href="running.html">Running</a> |
@@ -50,8 +52,6 @@ | |||
50 | </li><li> | 52 | </li><li> |
51 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> | 53 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> |
52 | </li><li> | 54 | </li><li> |
53 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
54 | </li><li> | ||
55 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> | 55 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> |
56 | </li><li> | 56 | </li><li> |
57 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> | 57 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> |
diff --git a/doc/extensions.html b/doc/extensions.html index a5baf11c..0679921a 100644 --- a/doc/extensions.html +++ b/doc/extensions.html | |||
@@ -37,6 +37,8 @@ td.excinterop { | |||
37 | <ul><li> | 37 | <ul><li> |
38 | <a href="luajit.html">LuaJIT</a> | 38 | <a href="luajit.html">LuaJIT</a> |
39 | <ul><li> | 39 | <ul><li> |
40 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
41 | </li><li> | ||
40 | <a href="install.html">Installation</a> | 42 | <a href="install.html">Installation</a> |
41 | </li><li> | 43 | </li><li> |
42 | <a href="running.html">Running</a> | 44 | <a href="running.html">Running</a> |
@@ -67,8 +69,6 @@ td.excinterop { | |||
67 | </li><li> | 69 | </li><li> |
68 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> | 70 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> |
69 | </li><li> | 71 | </li><li> |
70 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
71 | </li><li> | ||
72 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> | 72 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> |
73 | </li><li> | 73 | </li><li> |
74 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> | 74 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> |
@@ -90,7 +90,7 @@ or LuaJIT. | |||
90 | </p> | 90 | </p> |
91 | <p> | 91 | <p> |
92 | LuaJIT extends the standard Lua VM with new functionality and adds | 92 | LuaJIT extends the standard Lua VM with new functionality and adds |
93 | several extension modules. Please note that this page is only about | 93 | several extension modules. Please note this page is only about |
94 | <em>functional</em> enhancements and not about performance enhancements, | 94 | <em>functional</em> enhancements and not about performance enhancements, |
95 | such as the optimized VM, the faster interpreter or the JIT compiler. | 95 | such as the optimized VM, the faster interpreter or the JIT compiler. |
96 | </p> | 96 | </p> |
@@ -236,6 +236,70 @@ across arbitrary C functions. Keep this in mind when | |||
236 | upgrading from LuaJIT 1.x. | 236 | upgrading from LuaJIT 1.x. |
237 | </p> | 237 | </p> |
238 | 238 | ||
239 | <h2 id="lua52">Extensions from Lua 5.2</h2> | ||
240 | <p> | ||
241 | LuaJIT supports some language and library extensions from Lua 5.2. | ||
242 | Features that are unlikely to break existing code are unconditionally | ||
243 | enabled: | ||
244 | </p> | ||
245 | <ul> | ||
246 | <li><tt>goto</tt> and <tt>::labels::</tt>.</li> | ||
247 | <li>Hex escapes <tt>'\x3F'</tt> and <tt>'\*'</tt> escape in strings.</li> | ||
248 | <li><tt>load(string|reader, chunkname [,mode [,env]])</tt>. | ||
249 | <tt>loadstring()</tt> is an alias.</li> | ||
250 | <li><tt>math.log(x [,base])</tt>. | ||
251 | <li><tt>string.rep(s, n [,sep])</tt>. | ||
252 | <li><tt>string.format()</tt>: <tt>%q</tt> reversible. | ||
253 | <tt>%s</tt> checks <tt>__tostring</tt>. | ||
254 | <tt>%a</tt> and <tt>"%A</tt> added.</li> | ||
255 | <li>String matching pattern <tt>%g</tt> added.</li> | ||
256 | <li><tt>io.read("*L")</tt>.</li> | ||
257 | <li><tt>io.lines()</tt> and <tt>file:lines()</tt> process | ||
258 | <tt>io.read()</tt> options.</li> | ||
259 | <li><tt>os.exit(status|true|false [,close])</tt>.</li> | ||
260 | <li><tt>package.searchpath(name, path [, sep [, rep]])</tt>.</li> | ||
261 | <li><tt>package.loadlib(name, "*")</tt>.</li> | ||
262 | <li><tt>debug.getinfo()</tt> returns <tt>nparams</tt> and <tt>isvararg</tt> | ||
263 | for option <tt>"u"</tt>.</li> | ||
264 | <li><tt>debug.getlocal()</tt> accepts function instead of level.</li> | ||
265 | <li><tt>debug.getlocal()</tt> and <tt>debug.setlocal()</tt> accept negative | ||
266 | indexes for varargs.</li> | ||
267 | <li><tt>debug.getupvalue()</tt> and <tt>debug.setupvalue()</tt> handle | ||
268 | C functions.</li> | ||
269 | <li><tt>debug.upvalueid()</tt> and <tt>debug.upvaluejoin()</tt>.</li> | ||
270 | <li>Command line option <tt>-E</tt>.</li> | ||
271 | <li>Command line checks <tt>__tostring</tt> for errors.</li> | ||
272 | </ul> | ||
273 | <p> | ||
274 | Other features are only enabled, if LuaJIT is built with | ||
275 | <tt>-DLUAJIT_ENABLE_LUA52COMPAT</tt>: | ||
276 | </p> | ||
277 | <ul> | ||
278 | <li><tt>goto</tt> is a keyword and not a valid variable name anymore.</li> | ||
279 | <li><tt>break</tt> can be placed anywhere. Empty statements (<tt>;;</tt>) | ||
280 | are allowed.</li> | ||
281 | <li><tt>__lt</tt>, <tt>__le</tt> are invoked for mixed types.</li> | ||
282 | <li><tt>__len</tt> for tables. <tt>rawlen()</tt> library function.</li> | ||
283 | <li><tt>pairs()</tt> and <tt>ipairs()</tt> check for <tt>__pairs</tt> and | ||
284 | <tt>__ipairs</tt>.</li> | ||
285 | <li><tt>coroutine.running()</tt> returns two results.</li> | ||
286 | <li><tt>table.pack()</tt> and <tt>table.unpack()</tt> | ||
287 | (same as <tt>unpack()</tt>).</li> | ||
288 | <li><tt>io.write()</tt> and <tt>file:write()</tt> return file handle | ||
289 | instead of <tt>true</tt>.</li> | ||
290 | <li><tt>os.execute()</tt> and <tt>pipe:close()</tt> return detailed | ||
291 | exit status.</li> | ||
292 | <li><tt>debug.setmetatable()</tt> returns object.</li> | ||
293 | <li><tt>debug.getuservalue()</tt> and <tt>debug.setuservalue()</tt>.</li> | ||
294 | <li>Remove <tt>math.mod()</tt>, <tt>string.gfind()</tt>. | ||
295 | </ul> | ||
296 | <p> | ||
297 | Note: this provides only partial compatibility with Lua 5.2 at the | ||
298 | language and Lua library level. LuaJIT is API+ABI-compatible with | ||
299 | Lua 5.1, which prevents implementing features that would otherwise | ||
300 | break the Lua/C API and ABI (e.g. <tt>_ENV</tt>). | ||
301 | </p> | ||
302 | |||
239 | <h2 id="exceptions">C++ Exception Interoperability</h2> | 303 | <h2 id="exceptions">C++ Exception Interoperability</h2> |
240 | <p> | 304 | <p> |
241 | LuaJIT has built-in support for interoperating with C++ exceptions. | 305 | LuaJIT has built-in support for interoperating with C++ exceptions. |
diff --git a/doc/faq.html b/doc/faq.html index a36e878d..21997e77 100644 --- a/doc/faq.html +++ b/doc/faq.html | |||
@@ -23,6 +23,8 @@ dd { margin-left: 1.5em; } | |||
23 | <ul><li> | 23 | <ul><li> |
24 | <a href="luajit.html">LuaJIT</a> | 24 | <a href="luajit.html">LuaJIT</a> |
25 | <ul><li> | 25 | <ul><li> |
26 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
27 | </li><li> | ||
26 | <a href="install.html">Installation</a> | 28 | <a href="install.html">Installation</a> |
27 | </li><li> | 29 | </li><li> |
28 | <a href="running.html">Running</a> | 30 | <a href="running.html">Running</a> |
@@ -53,8 +55,6 @@ dd { margin-left: 1.5em; } | |||
53 | </li><li> | 55 | </li><li> |
54 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> | 56 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> |
55 | </li><li> | 57 | </li><li> |
56 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
57 | </li><li> | ||
58 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> | 58 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> |
59 | </li><li> | 59 | </li><li> |
60 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> | 60 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> |
diff --git a/doc/install.html b/doc/install.html index b8a4fc71..cbf33f6c 100644 --- a/doc/install.html +++ b/doc/install.html | |||
@@ -48,6 +48,8 @@ td.compatno { | |||
48 | <ul><li> | 48 | <ul><li> |
49 | <a href="luajit.html">LuaJIT</a> | 49 | <a href="luajit.html">LuaJIT</a> |
50 | <ul><li> | 50 | <ul><li> |
51 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
52 | </li><li> | ||
51 | <a class="current" href="install.html">Installation</a> | 53 | <a class="current" href="install.html">Installation</a> |
52 | </li><li> | 54 | </li><li> |
53 | <a href="running.html">Running</a> | 55 | <a href="running.html">Running</a> |
@@ -78,8 +80,6 @@ td.compatno { | |||
78 | </li><li> | 80 | </li><li> |
79 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> | 81 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> |
80 | </li><li> | 82 | </li><li> |
81 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
82 | </li><li> | ||
83 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> | 83 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> |
84 | </li><li> | 84 | </li><li> |
85 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> | 85 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> |
diff --git a/doc/luajit.html b/doc/luajit.html index d8f20b35..9ab12899 100644 --- a/doc/luajit.html +++ b/doc/luajit.html | |||
@@ -9,6 +9,87 @@ | |||
9 | <link rel="stylesheet" type="text/css" href="bluequad.css" media="screen"> | 9 | <link rel="stylesheet" type="text/css" href="bluequad.css" media="screen"> |
10 | <link rel="stylesheet" type="text/css" href="bluequad-print.css" media="print"> | 10 | <link rel="stylesheet" type="text/css" href="bluequad-print.css" media="print"> |
11 | <meta name="description" content="LuaJIT is a Just-In-Time (JIT) compiler for the Lua language."> | 11 | <meta name="description" content="LuaJIT is a Just-In-Time (JIT) compiler for the Lua language."> |
12 | <style type="text/css"> | ||
13 | table.feature { | ||
14 | width: inherit; | ||
15 | line-height: 1.2; | ||
16 | margin: 0; | ||
17 | } | ||
18 | table.feature td { | ||
19 | width: 80px; | ||
20 | height: 40px; | ||
21 | vertical-align: middle; | ||
22 | text-align: center; | ||
23 | font-weight: bold; | ||
24 | border: 4px solid #e6ecff; | ||
25 | border-radius: 12px; | ||
26 | } | ||
27 | table.os td { | ||
28 | background: #7080d0; | ||
29 | background-image: linear-gradient(#4060c0 10%, #b0b0ff 95%); | ||
30 | background-image: -moz-linear-gradient(#4060c0 10%, #b0b0ff 95%); | ||
31 | background-image: -webkit-linear-gradient(#4060c0 10%, #b0b0ff 95%); | ||
32 | background-image: -o-linear-gradient(#4060c0 10%, #b0b0ff 95%); | ||
33 | background-image: -ms-linear-gradient(#4060c0 10%, #b0b0ff 95%); | ||
34 | } | ||
35 | table.os1 td { | ||
36 | color: #ffff80; | ||
37 | } | ||
38 | table.os2 td { | ||
39 | color: #ffa040; | ||
40 | } | ||
41 | table.compiler td { | ||
42 | color: #2080ff; | ||
43 | background: #62bf41; | ||
44 | background-image: linear-gradient(#62bf41 10%, #b0ffb0 95%); | ||
45 | background-image: -moz-linear-gradient(#62bf41 10%, #b0ffb0 95%); | ||
46 | background-image: -webkit-linear-gradient(#62bf41 10%, #b0ffb0 95%); | ||
47 | background-image: -o-linear-gradient(#62bf41 10%, #b0ffb0 95%); | ||
48 | background-image: -ms-linear-gradient(#62bf41 10%, #b0ffb0 95%); | ||
49 | } | ||
50 | table.cpu td { | ||
51 | color: #ffff00; | ||
52 | background: #cf7251; | ||
53 | background-image: linear-gradient(#bf6241 10%, #ffb0b0 95%); | ||
54 | background-image: -moz-linear-gradient(#bf6241 10%, #ffb0b0 95%); | ||
55 | background-image: -webkit-linear-gradient(#bf6241 10%, #ffb0b0 95%); | ||
56 | background-image: -o-linear-gradient(#bf6241 10%, #ffb0b0 95%); | ||
57 | background-image: -ms-linear-gradient(#bf6241 10%, #ffb0b0 95%); | ||
58 | } | ||
59 | table.fcompat td { | ||
60 | color: #2060e0; | ||
61 | background: #61cfcf; | ||
62 | background-image: linear-gradient(#41bfbf 10%, #b0ffff 95%); | ||
63 | background-image: -moz-linear-gradient(#41bfbf 10%, #b0ffff 95%); | ||
64 | background-image: -webkit-linear-gradient(#41bfbf 10%, #b0ffff 95%); | ||
65 | background-image: -o-linear-gradient(#41bfbf 10%, #b0ffff 95%); | ||
66 | background-image: -ms-linear-gradient(#41bfbf 10%, #b0ffff 95%); | ||
67 | } | ||
68 | table.stats td { | ||
69 | color: #ffffff; | ||
70 | background: #a0a0a0; | ||
71 | background-image: linear-gradient(#808080 10%, #d0d0d0 95%); | ||
72 | background-image: -moz-linear-gradient(#808080 10%, #d0d0d0 95%); | ||
73 | background-image: -webkit-linear-gradient(#808080 10%, #d0d0d0 95%); | ||
74 | background-image: -o-linear-gradient(#808080 10%, #d0d0d0 95%); | ||
75 | background-image: -ms-linear-gradient(#808080 10%, #d0d0d0 95%); | ||
76 | } | ||
77 | table.stats td.speed { | ||
78 | color: #ff4020; | ||
79 | } | ||
80 | table.stats td.kb { | ||
81 | color: #ffff80; | ||
82 | background: #808080; | ||
83 | background-image: linear-gradient(#606060 10%, #c0c0c0 95%); | ||
84 | background-image: -moz-linear-gradient(#606060 10%, #c0c0c0 95%); | ||
85 | background-image: -webkit-linear-gradient(#606060 10%, #c0c0c0 95%); | ||
86 | background-image: -o-linear-gradient(#606060 10%, #c0c0c0 95%); | ||
87 | background-image: -ms-linear-gradient(#606060 10%, #c0c0c0 95%); | ||
88 | } | ||
89 | table.feature small { | ||
90 | font-size: 50%; | ||
91 | } | ||
92 | </style> | ||
12 | </head> | 93 | </head> |
13 | <body> | 94 | <body> |
14 | <div id="site"> | 95 | <div id="site"> |
@@ -21,6 +102,8 @@ | |||
21 | <ul><li> | 102 | <ul><li> |
22 | <a class="current" href="luajit.html">LuaJIT</a> | 103 | <a class="current" href="luajit.html">LuaJIT</a> |
23 | <ul><li> | 104 | <ul><li> |
105 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
106 | </li><li> | ||
24 | <a href="install.html">Installation</a> | 107 | <a href="install.html">Installation</a> |
25 | </li><li> | 108 | </li><li> |
26 | <a href="running.html">Running</a> | 109 | <a href="running.html">Running</a> |
@@ -51,8 +134,6 @@ | |||
51 | </li><li> | 134 | </li><li> |
52 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> | 135 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> |
53 | </li><li> | 136 | </li><li> |
54 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
55 | </li><li> | ||
56 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> | 137 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> |
57 | </li><li> | 138 | </li><li> |
58 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> | 139 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> |
@@ -60,77 +141,78 @@ | |||
60 | </div> | 141 | </div> |
61 | <div id="main"> | 142 | <div id="main"> |
62 | <p> | 143 | <p> |
63 | LuaJIT is a <b>Just-In-Time Compiler</b> for the Lua<sup>*</sup> | 144 | LuaJIT is a <b>Just-In-Time Compiler</b> (JIT) for the |
64 | programming language. | 145 | <a href="http://www.lua.org/"><span class="ext">»</span> Lua</a> programming language. |
65 | </p> | 146 | Lua is a powerful, dynamic and light-weight programming language. |
66 | <p> | 147 | It may be embedded or used as a general-purpose, stand-alone language. |
67 | LuaJIT is Copyright © 2005-2012 Mike Pall. | ||
68 | LuaJIT is open source software, released under the | ||
69 | <a href="http://www.opensource.org/licenses/mit-license.php"><span class="ext">»</span> MIT license</a>. | ||
70 | </p> | ||
71 | <p class="indent" style="color: #606060;"> | ||
72 | * Lua is a powerful, dynamic and light-weight programming language | ||
73 | designed for extending applications. Lua is also frequently used as a | ||
74 | general-purpose, stand-alone language. More information about | ||
75 | Lua can be found at: <a href="http://www.lua.org/"><span class="ext">»</span> http://www.lua.org/</a> | ||
76 | </p> | 148 | </p> |
77 | <h2>Compatibility</h2> | ||
78 | <p> | 149 | <p> |
79 | LuaJIT implements the full set of language features defined by Lua 5.1. | 150 | LuaJIT is Copyright © 2005-2012 Mike Pall, released under the |
80 | The virtual machine (VM) is <b>API- and ABI-compatible</b> to the | 151 | <a href="http://www.opensource.org/licenses/mit-license.php"><span class="ext">»</span> MIT open source license</a>. |
81 | standard Lua interpreter and can be deployed as a drop-in replacement. | ||
82 | </p> | 152 | </p> |
83 | <p> | 153 | <p> |
84 | LuaJIT offers more performance, at the expense of portability. It | ||
85 | currently runs on all popular operating systems based on | ||
86 | <b>x86</b> or <b>x64</b> CPUs (Linux, Windows, OSX etc.) or embedded | ||
87 | systems based on <b>ARM</b> (Android, iOS), <b>PPC</b> or <b>MIPS</b> CPUs. | ||
88 | Other platforms will be supported in the future, based on user demand | ||
89 | and sponsoring. | ||
90 | </p> | 154 | </p> |
91 | 155 | ||
156 | <h2>Compatibility</h2> | ||
157 | <table class="feature os os1"> | ||
158 | <tr><td>Windows</td><td>Linux</td><td>BSD</td><td>OSX</td><td>POSIX</td></tr> | ||
159 | </table> | ||
160 | <table class="feature os os2"> | ||
161 | <tr><td><span style="font-size:90%;">Embedded</span></td><td>Android</td><td>iOS</td><td>PS3</td></tr> | ||
162 | </table> | ||
163 | <table class="feature compiler"> | ||
164 | <tr><td>GCC</td><td>CLANG<br>LLVM</td><td>MSVC</td></tr> | ||
165 | </table> | ||
166 | <table class="feature cpu"> | ||
167 | <tr><td>x86</td><td>x64</td><td>ARM</td><td>PPC</td><td>e500</td><td>MIPS</td></tr> | ||
168 | </table> | ||
169 | <table class="feature fcompat"> | ||
170 | <tr><td>Lua 5.1<br>API+ABI</td><td>+ JIT</td><td>+ BitOp</td><td>+ FFI</td><td>Drop-in<br>DLL/.so</td></tr> | ||
171 | </table> | ||
172 | |||
92 | <h2>Overview</h2> | 173 | <h2>Overview</h2> |
93 | <p> | 174 | <table class="feature stats"> |
175 | <tr> | ||
176 | <td class="speed">3x<br>- 100x</td> | ||
177 | <td class="kb">115 <small>KB</small><br>VM</td> | ||
178 | <td class="kb">90 <small>KB</small><br>JIT</td> | ||
179 | <td class="kloc">73 <small>KLOC</small><br>C</td> | ||
180 | <td class="kloc">24 <small>KLOC</small><br>ASM</td> | ||
181 | <td class="kloc">11 <small>KLOC</small><br>Lua</td> | ||
182 | </tr> | ||
183 | </table> | ||
184 | <p style="margin-top: 1em;"> | ||
94 | LuaJIT has been successfully used as a <b>scripting middleware</b> in | 185 | LuaJIT has been successfully used as a <b>scripting middleware</b> in |
95 | games, 3D modellers, numerical simulations, trading platforms and many | 186 | games, appliances, network and graphics apps, numerical simulations, |
96 | other specialty applications. It combines high flexibility with high | 187 | trading platforms and many other specialty applications. It scales from |
97 | performance and an unmatched <b>low memory footprint</b>: less than | 188 | embedded devices, smartphones, desktops up to server farms. It combines |
98 | <b>125K</b> for the VM plus less than <b>85K</b> for the JIT compiler (on x86). | 189 | high flexibility with <a href="http://luajit.org/performance.html"><span class="ext">»</span> high performance</a> |
190 | and an unmatched <b>low memory footprint</b>. | ||
99 | </p> | 191 | </p> |
100 | <p> | 192 | <p> |
101 | LuaJIT has been in continuous development since 2005. It's widely | 193 | LuaJIT has been in continuous development since 2005. It's widely |
102 | considered to be <b>one of the fastest dynamic language | 194 | considered to be <b>one of the fastest dynamic language |
103 | implementations</b>. It has outperformed other dynamic languages on many | 195 | implementations</b>. It has outperformed other dynamic languages on many |
104 | cross-language benchmarks since its first release — often by a | 196 | cross-language benchmarks since its first release — often by a |
105 | substantial margin. In 2009 other dynamic language VMs started to catch up | 197 | substantial margin. |
106 | with the performance of LuaJIT 1.x. Well, I couldn't let that slide. ;-) | ||
107 | </p> | 198 | </p> |
108 | <p> | 199 | <p> |
109 | 2009 also marks the first release of the long-awaited <b>LuaJIT 2.0</b>. | 200 | For <b>LuaJIT 2.0</b> the whole VM has been rewritten from the ground up |
110 | The whole VM has been rewritten from the ground up and relentlessly | 201 | and relentlessly optimized for performance. It combines a <b>high-speed |
111 | optimized for performance. It combines a high-speed interpreter, | 202 | interpreter</b>, written in assembler, with a <b>state-of-the-art JIT |
112 | written in assembler, with a state-of-the-art JIT compiler. | 203 | compiler</b>. |
113 | </p> | 204 | </p> |
114 | <p> | 205 | <p> |
115 | An innovative <b>trace compiler</b> is integrated with advanced, | 206 | An innovative <b>trace compiler</b> is integrated with advanced, |
116 | SSA-based optimizations and a highly tuned code generation backend. This | 207 | SSA-based optimizations and highly tuned code generation backends. |
117 | allows a substantial reduction of the overhead associated with dynamic | 208 | A substantial reduction of the overhead associated with dynamic languages |
118 | language features. | 209 | allows it to break into the performance range traditionally reserved for |
119 | </p> | 210 | offline, static language compilers. |
120 | <p> | ||
121 | It's destined to break into the <a href="http://luajit.org/performance.html"><span class="ext">»</span> performance</a> | ||
122 | range traditionally reserved for offline, static language compilers. | ||
123 | </p> | 211 | </p> |
124 | 212 | ||
125 | <h2>More ...</h2> | 213 | <h2>More ...</h2> |
126 | <p> | 214 | <p> |
127 | Click on the LuaJIT sub-topics in the navigation bar to learn more | 215 | Please select a sub-topic in the navigation bar to learn more about LuaJIT. |
128 | about LuaJIT. | ||
129 | </p> | ||
130 | <p><p> | ||
131 | Click on the Logo in the upper left corner to visit | ||
132 | the LuaJIT project page on the web. All other links to online | ||
133 | resources are marked with a '<span class="ext">»</span>'. | ||
134 | </p> | 216 | </p> |
135 | <br class="flush"> | 217 | <br class="flush"> |
136 | </div> | 218 | </div> |
diff --git a/doc/running.html b/doc/running.html index e725f636..eddb7ad7 100644 --- a/doc/running.html +++ b/doc/running.html | |||
@@ -42,6 +42,8 @@ td.param_default { | |||
42 | <ul><li> | 42 | <ul><li> |
43 | <a href="luajit.html">LuaJIT</a> | 43 | <a href="luajit.html">LuaJIT</a> |
44 | <ul><li> | 44 | <ul><li> |
45 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
46 | </li><li> | ||
45 | <a href="install.html">Installation</a> | 47 | <a href="install.html">Installation</a> |
46 | </li><li> | 48 | </li><li> |
47 | <a class="current" href="running.html">Running</a> | 49 | <a class="current" href="running.html">Running</a> |
@@ -72,8 +74,6 @@ td.param_default { | |||
72 | </li><li> | 74 | </li><li> |
73 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> | 75 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> |
74 | </li><li> | 76 | </li><li> |
75 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
76 | </li><li> | ||
77 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> | 77 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> |
78 | </li><li> | 78 | </li><li> |
79 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> | 79 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> |
diff --git a/doc/status.html b/doc/status.html index eae43966..6bb4df89 100644 --- a/doc/status.html +++ b/doc/status.html | |||
@@ -23,6 +23,8 @@ ul li { padding-bottom: 0.3em; } | |||
23 | <ul><li> | 23 | <ul><li> |
24 | <a href="luajit.html">LuaJIT</a> | 24 | <a href="luajit.html">LuaJIT</a> |
25 | <ul><li> | 25 | <ul><li> |
26 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
27 | </li><li> | ||
26 | <a href="install.html">Installation</a> | 28 | <a href="install.html">Installation</a> |
27 | </li><li> | 29 | </li><li> |
28 | <a href="running.html">Running</a> | 30 | <a href="running.html">Running</a> |
@@ -53,8 +55,6 @@ ul li { padding-bottom: 0.3em; } | |||
53 | </li><li> | 55 | </li><li> |
54 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> | 56 | <a href="http://luajit.org/performance.html">Performance <span class="ext">»</span></a> |
55 | </li><li> | 57 | </li><li> |
56 | <a href="http://luajit.org/download.html">Download <span class="ext">»</span></a> | ||
57 | </li><li> | ||
58 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> | 58 | <a href="http://wiki.luajit.org/">Wiki <span class="ext">»</span></a> |
59 | </li><li> | 59 | </li><li> |
60 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> | 60 | <a href="http://luajit.org/list.html">Mailing List <span class="ext">»</span></a> |
@@ -62,7 +62,7 @@ ul li { padding-bottom: 0.3em; } | |||
62 | </div> | 62 | </div> |
63 | <div id="main"> | 63 | <div id="main"> |
64 | <p> | 64 | <p> |
65 | The <span style="color: #0000c0;">LuaJIT 1.x</span> series represents | 65 | The <span style="color: #0000c0;">LuaJIT 1.x</span> series represents |
66 | the current <span style="color: #0000c0;">stable branch</span>. | 66 | the current <span style="color: #0000c0;">stable branch</span>. |
67 | Only a single bug has been discovered in the last three years. So, if | 67 | Only a single bug has been discovered in the last three years. So, if |
68 | you need a rock-solid VM, you are encouraged to fetch the latest | 68 | you need a rock-solid VM, you are encouraged to fetch the latest |
@@ -70,85 +70,34 @@ release of LuaJIT 1.x from the <a href="http://luajit.org/download.html"><span c | |||
70 | page. | 70 | page. |
71 | </p> | 71 | </p> |
72 | <p> | 72 | <p> |
73 | <span style="color: #c00000;">LuaJIT 2.0</span> is the currently active | 73 | <span style="color: #c00000;">LuaJIT 2.0</span> is the currently active |
74 | <span style="color: #c00000;">development branch</span>. | 74 | <span style="color: #c00000;">development branch</span> in beta test. |
75 | It still has <b>Beta Test</b> status, but it's not undergoing substantial | 75 | It has <a href="http://luajit.org/performance.html"><span class="ext">»</span> much better performance</a> than |
76 | changes anymore. | 76 | LuaJIT 1.x and runs on many more platforms and architectures. |
77 | It has <a href="http://luajit.org/performance.html"><span class="ext">»</span> much better performance</a> than LuaJIT 1.x. | 77 | It's nearing a stable release, so you should definitely |
78 | It's nearly feature-complete, so you should definitely | ||
79 | start to evaluate it for new projects right now. | 78 | start to evaluate it for new projects right now. |
80 | </p> | 79 | </p> |
81 | 80 | ||
82 | <h2>Current Status</h2> | 81 | <h2>Current Status</h2> |
83 | <p> | 82 | <p> |
84 | This is a list of the things you should know about the LuaJIT 2.0 beta test: | 83 | LuaJIT ought to run all Lua 5.1-compatible source code just fine. |
84 | It's considered a serious bug if the VM crashes or produces unexpected | ||
85 | results — please report this. | ||
86 | </p> | ||
87 | <p> | ||
88 | Known incompatibilities and issues in LuaJIT 2.0: | ||
85 | </p> | 89 | </p> |
86 | <ul> | 90 | <ul> |
87 | <li> | 91 | <li> |
88 | Obviously there will be some <b>bugs</b> in a VM which has been | 92 | There are some differences in <b>implementation-defined</b> behavior. |
89 | rewritten from the ground up. Please report your findings together with | 93 | These either have a good reason, are arbitrary design choices |
90 | the circumstances needed to reproduce the bug. If possible, reduce the | ||
91 | problem down to a simple test case.<br> | ||
92 | There is no formal bug tracker at the moment. The best place for | ||
93 | discussion is the <a href="http://luajit.org/list.html"><span class="ext">»</span> LuaJIT mailing list</a>. Of course | ||
94 | you may also send your bug reports <a href="contact.html">directly to me</a>, | ||
95 | especially when they contain lengthy debug output or if you require | ||
96 | confidentiality. | ||
97 | </li> | ||
98 | <li> | ||
99 | The x86 JIT compiler only generates code for CPUs with support for | ||
100 | <b>SSE2</b> instructions. I.e. you need at least a P4, Core 2/i3/i5/i7, | ||
101 | Atom or K8/K10 to get the full benefit.<br> | ||
102 | If you run LuaJIT on older CPUs without SSE2 support, the JIT compiler | ||
103 | is disabled and the VM falls back to the LuaJIT interpreter. This is faster | ||
104 | than the Lua interpreter, but not nearly as fast as the JIT compiler of course. | ||
105 | Run the command line executable without arguments to show the current status | ||
106 | (<tt>JIT: ON</tt> or <tt>JIT: OFF</tt>). | ||
107 | </li> | ||
108 | <li> | ||
109 | The VM is complete in the sense that it <b>should</b> run all Lua code | ||
110 | just fine. It's considered a serious bug if the VM crashes or produces | ||
111 | unexpected results — please report this. There are only very few | ||
112 | known incompatibilities with standard Lua: | ||
113 | <ul> | ||
114 | <li> | ||
115 | The Lua <b>debug API</b> is missing a couple of features (return | ||
116 | hooks for non-Lua functions) and shows slightly different behavior | ||
117 | (no per-coroutine hooks, no tail call counting). | ||
118 | </li> | ||
119 | <li> | ||
120 | Some of the <b>configuration options</b> of Lua 5.1 are not supported: | ||
121 | <ul> | ||
122 | <li>The <b>number type</b> cannot be changed (it's always a <tt>double</tt>).</li> | ||
123 | <li>The stand-alone executable cannot be linked with <b>readline</b> | ||
124 | to enable line editing. It's planned to add support for loading it | ||
125 | on-demand.</li> | ||
126 | </ul> | ||
127 | </li> | ||
128 | <li> | ||
129 | Most other issues you're likely to find (e.g. with the existing test | ||
130 | suites) are differences in the <b>implementation-defined</b> behavior. | ||
131 | These either have a good reason (like early tail call resolving which | ||
132 | may cause differences in error reporting), are arbitrary design choices | ||
133 | or are due to quirks in the VM. The latter cases may get fixed if a | 94 | or are due to quirks in the VM. The latter cases may get fixed if a |
134 | demonstrable need is shown. | 95 | demonstrable need is shown. |
135 | </li> | 96 | </li> |
136 | </ul> | ||
137 | </li> | ||
138 | <li> | 97 | <li> |
139 | The <b>JIT compiler</b> falls back to the | 98 | The Lua <b>debug API</b> is missing a couple of features (return |
140 | interpreter in some cases. All of this works transparently, so unless | 99 | hooks for non-Lua functions) and shows slightly different behavior |
141 | you use <tt>-jv</tt>, you'll probably never notice (the interpreter is | 100 | in LuaJIT (no per-coroutine hooks, no tail call counting). |
142 | <a href="http://luajit.org/performance.html"><span class="ext">»</span> quite fast</a>, too). Here are the known issues: | ||
143 | <ul> | ||
144 | <li> | ||
145 | Most known issues cause a <b>NYI</b> (not yet implemented) trace abort | ||
146 | message. E.g. for calls to some internal library | ||
147 | functions. Reporting these is only mildly useful, except if you have good | ||
148 | example code that shows the problem. Obviously, reports accompanied with | ||
149 | a patch to fix the issue are more than welcome. But please check back | ||
150 | with me, before writing major improvements, to avoid duplication of | ||
151 | effort. | ||
152 | </li> | 101 | </li> |
153 | <li> | 102 | <li> |
154 | Some checks are missing in the JIT-compiled code for obscure situations | 103 | Some checks are missing in the JIT-compiled code for obscure situations |
@@ -159,10 +108,8 @@ this. | |||
159 | <li> | 108 | <li> |
160 | Currently some <b>out-of-memory</b> errors from <b>on-trace code</b> are not | 109 | Currently some <b>out-of-memory</b> errors from <b>on-trace code</b> are not |
161 | handled correctly. The error may fall through an on-trace | 110 | handled correctly. The error may fall through an on-trace |
162 | <tt>pcall</tt> (x86) or it may be passed on to the function set with | 111 | <tt>pcall</tt> or it may be passed on to the function set with |
163 | <tt>lua_atpanic</tt> (x64). | 112 | <tt>lua_atpanic</tt> on x64. This issue will be fixed in LuaJIT 2.1. |
164 | </li> | ||
165 | </ul> | ||
166 | </li> | 113 | </li> |
167 | </ul> | 114 | </ul> |
168 | 115 | ||
@@ -170,65 +117,10 @@ handled correctly. The error may fall through an on-trace | |||
170 | <p> | 117 | <p> |
171 | Please refer to the | 118 | Please refer to the |
172 | <a href="http://www.freelists.org/post/luajit/LuaJIT-Roadmap-20122013"><span class="ext">»</span> LuaJIT | 119 | <a href="http://www.freelists.org/post/luajit/LuaJIT-Roadmap-20122013"><span class="ext">»</span> LuaJIT |
173 | Roadmap 2012/2013</a> for the latest release plan. Here's the general | 120 | Roadmap 2012/2013</a> for details. |
174 | project plan for LuaJIT 2.0: | 121 | </p> |
122 | <p> | ||
175 | </p> | 123 | </p> |
176 | <ul> | ||
177 | <li> | ||
178 | The main goal right now is to stabilize LuaJIT 2.0 and get it out of | ||
179 | beta test. <b>Correctness</b> has priority over completeness. This | ||
180 | implies the first stable release will certainly NOT compile every | ||
181 | library function call and will fall back to the interpreter from time | ||
182 | to time. This is perfectly ok, since it still executes all Lua code, | ||
183 | just not at the highest possible speed. | ||
184 | </li> | ||
185 | <li> | ||
186 | The next step is to get it to compile more library functions and handle | ||
187 | more cases where the compiler currently bails out. This doesn't mean it | ||
188 | will compile every corner case. It's much more important that it | ||
189 | performs well in a majority of use cases. Every compiler has to make | ||
190 | these trade-offs — <b>completeness</b> just cannot be the | ||
191 | overriding goal for a low-footprint, low-overhead JIT compiler. | ||
192 | </li> | ||
193 | <li> | ||
194 | More <b>optimizations</b> will be added in parallel to the last step on | ||
195 | an as-needed basis. Sinking of stores | ||
196 | to aggregates and sinking of allocations are high on the list. | ||
197 | More complex optimizations with less pay-off, such as value-range-propagation | ||
198 | (VRP) will have to wait. | ||
199 | </li> | ||
200 | <li> | ||
201 | LuaJIT 2.0 has been designed with <b>portability</b> in mind. | ||
202 | Nonetheless, it compiles to native code and needs to be adapted to each | ||
203 | architecture. The two major work items are porting the the fast interpreter, | ||
204 | which is written in assembler, and porting the compiler backend. | ||
205 | Most other portability issues like endianess or 32 vs. 64 bit CPUs | ||
206 | have already been taken care of.<br> | ||
207 | Several ports are already available, thanks to the | ||
208 | <a href="http://luajit.org/sponsors.html"><span class="ext">»</span> LuaJIT sponsorship program</a>. | ||
209 | More ports will follow in the future — companies which are | ||
210 | interested in sponsoring a port to a particular architecture, please | ||
211 | use the given contact address. | ||
212 | </li> | ||
213 | <li> | ||
214 | <b>Documentation</b> about the <b>internals</b> of LuaJIT is still sorely | ||
215 | missing. Although the source code is included and is IMHO well | ||
216 | commented, many basic design decisions are in need of an explanation. | ||
217 | The rather un-traditional compiler architecture and the many highly | ||
218 | optimized data structures are a barrier for outside participation in | ||
219 | the development. Alas, as I've repeatedly stated, I'm better at | ||
220 | writing code than papers and I'm not in need of any academic merits. | ||
221 | Someday I will find the time for it. :-) | ||
222 | </li> | ||
223 | <li> | ||
224 | Producing good code for unbiased branches is a key problem for trace | ||
225 | compilers. This is the main cause for "trace explosion". | ||
226 | <b>Hyperblock scheduling</b> promises to solve this nicely at the | ||
227 | price of a major redesign of the compiler. This would also pave the | ||
228 | way for emitting predicated instructions, which is a prerequisite | ||
229 | for efficient <b>vectorization</b>. | ||
230 | </li> | ||
231 | </ul> | ||
232 | <br class="flush"> | 124 | <br class="flush"> |
233 | </div> | 125 | </div> |
234 | <div id="foot"> | 126 | <div id="foot"> |