diff --git a/third_party/luajit/Makefile b/third_party/luajit/Makefile
index 48a2e1a8b0a9c85d5e1f5a406699003a5a40e6a7..61b0cf22d71444f119b879e30b531dbed78aadf0 100644
--- a/third_party/luajit/Makefile
+++ b/third_party/luajit/Makefile
@@ -16,7 +16,7 @@
 MAJVER=  2
 MINVER=  0
 RELVER=  0
-PREREL=  -beta8
+PREREL=  -beta9
 VERSION= $(MAJVER).$(MINVER).$(RELVER)$(PREREL)
 ABIVER=  5.1
 NODOTABIVER=  51
@@ -76,7 +76,8 @@ FILE_SO= libluajit.so
 FILE_MAN= luajit.1
 FILE_PC= luajit.pc
 FILES_INC= lua.h lualib.h lauxlib.h luaconf.h lua.hpp luajit.h
-FILES_JITLIB= bc.lua v.lua dump.lua dis_x86.lua dis_x64.lua bcsave.lua vmdef.lua
+FILES_JITLIB= bc.lua v.lua dump.lua dis_x86.lua dis_x64.lua dis_arm.lua \
+	      dis_ppc.lua bcsave.lua vmdef.lua
 
 ifeq (,$(findstring Windows,$(OS)))
   ifeq (Darwin,$(shell uname -s))
@@ -103,7 +104,7 @@ install: $(INSTALL_DEP)
 	cd src && test -f $(FILE_A) && $(INSTALL_F) $(FILE_A) $(INSTALL_STATIC) || :
 	$(RM) $(INSTALL_DYN) $(INSTALL_SHORT1) $(INSTALL_SHORT2)
 	cd src && test -f $(FILE_SO) && \
-	  $(INSTALL_F) $(FILE_SO) $(INSTALL_DYN) && \
+	  $(INSTALL_X) $(FILE_SO) $(INSTALL_DYN) && \
 	  $(LDCONFIG) $(INSTALL_LIB) && \
 	  $(SYMLINK) $(INSTALL_SONAME) $(INSTALL_SHORT1) && \
 	  $(SYMLINK) $(INSTALL_SONAME) $(INSTALL_SHORT2) || :
diff --git a/third_party/luajit/README b/third_party/luajit/README
index e288bdfb594f3382d9664941dacd47eb068b2626..271e3128f0ce177758ece635fda403c79db44e7a 100644
--- a/third_party/luajit/README
+++ b/third_party/luajit/README
@@ -1,4 +1,4 @@
-README for LuaJIT 2.0.0-beta8
+README for LuaJIT 2.0.0-beta9
 -----------------------------
 
 LuaJIT is a Just-In-Time (JIT) compiler for the Lua programming language.
@@ -6,7 +6,7 @@ LuaJIT is a Just-In-Time (JIT) compiler for the Lua programming language.
 Project Homepage: http://luajit.org/
 
 LuaJIT is Copyright (C) 2005-2011 Mike Pall.
-LuaJIT is free software, released under the MIT/X license.
+LuaJIT is free software, released under the MIT license.
 See full Copyright Notice in the COPYRIGHT file or in luajit.h.
 
 Documentation for LuaJIT is available in HTML format.
diff --git a/third_party/luajit/doc/changes.html b/third_party/luajit/doc/changes.html
index fc299864cfa988221b1092b623a124c9f0105e1e..51027a9313a3cc05c1c3f14dc85ebf3bfded9d63 100644
--- a/third_party/luajit/doc/changes.html
+++ b/third_party/luajit/doc/changes.html
@@ -59,7 +59,7 @@ div.major { max-width: 600px; padding: 1em; margin: 1em 0 1em 0; }
 <div id="main">
 <p>
 This is a list of changes between the released versions of LuaJIT.<br>
-The current <span style="color: #c00000;">development version</span> is <strong>LuaJIT&nbsp;2.0.0-beta8</strong>.<br>
+The current <span style="color: #c00000;">development version</span> is <strong>LuaJIT&nbsp;2.0.0-beta9</strong>.<br>
 The current <span style="color: #0000c0;">stable version</span> is <strong>LuaJIT&nbsp;1.1.7</strong>.
 </p>
 <p>
@@ -69,6 +69,79 @@ to see whether newer versions are available.
 </p>
 
 <div class="major" style="background: #ffd0d0;">
+<h2 id="LuaJIT-2.0.0-beta9">LuaJIT 2.0.0-beta9 &mdash; 2011-12-14</h2>
+<ul>
+<li>New features:
+<ul>
+<li>PPC port of LuaJIT is complete. Default is the dual-number port
+(usually faster). Single-number port selectable via <tt>src/Makefile</tt>
+at build time.</li>
+<li>Add FFI callback support.</li>
+<li>Extend <tt>-b</tt> to generate <tt>.c</tt>, <tt>.h</tt> or <tt>.obj/.o</tt>
+files with embedded bytecode.</li>
+<li>Allow loading embedded bytecode with <tt>require()</tt>.</li>
+<li>From Lua 5.2: Change to <tt>'\z'</tt> escape. Reject undefined escape
+sequences.</li>
+</ul></li>
+<li>Correctness and completeness:
+<ul>
+<li>Fix OSX 10.7 build. Fix <tt>install_name</tt> and versioning on OSX.</li>
+<li>Fix iOS build.</li>
+<li>Install <tt>dis_arm.lua</tt>, too.</li>
+<li>Mark installed shared library as executable.</li>
+<li>Add debug option to <tt>msvcbuild.bat</tt> and improve error handling.</li>
+<li>Fix data-flow analysis for iterators.</li>
+<li>Fix forced unwinding triggered by external unwinder.</li>
+<li>Record missing <tt>for</tt> loop slot loads (return to lower frame).</li>
+<li>Always use ANSI variants of Windows system functions.</li>
+<li>Fix GC barrier for multi-result table constructor (<tt>TSETM</tt>).</li>
+<li>Fix/add various FOLD rules.</li>
+<li>Add potential PHI for number conversions due to type instability.</li>
+<li>Do not eliminate PHIs only referenced from other PHIs.</li>
+<li>Correctly anchor implicit number to string conversions in Lua/C API.</li>
+<li>Fix various stack limit checks.</li>
+<li>x64: Use thread-safe exceptions for external unwinding (GCC platforms).</li>
+<li>x64: Fix result type of cdata index conversions.</li>
+<li>x64: Fix <tt>math.random()</tt> and <tt>bit.bswap()</tt> code generation.</li>
+<li>x64: Fix <tt>lightuserdata</tt> comparisons.</li>
+<li>x64: Always extend stack-passed arguments to pointer size.</li>
+<li>ARM: Many fixes to code generation backend.</li>
+<li>PPC/e500: Fix dispatch for binop metamethods.</li>
+<li>PPC/e500: Save/restore condition registers when entering/leaving the VM.</li>
+<li>PPC/e500: Fix write barrier in stores of strings to upvalues.</li>
+</ul></li>
+<li>FFI library:
+<ul>
+<li>Fix C comment parsing.</li>
+<li>Fix snapshot optimization for cdata comparisons.</li>
+<li>Fix recording of const/enum lookups in namespaces.</li>
+<li>Fix call argument and return handling for <tt>I8/U8/I16/U16</tt> types.</li>
+<li>Fix unfused loads of float fields.</li>
+<li>Fix <tt>ffi.string()</tt> recording.</li>
+<li>Save <tt>GetLastError()</tt> around <tt>ffi.load()</tt> and symbol
+resolving, too.</li>
+<li>Improve ld script detection in <tt>ffi.load()</tt>.</li>
+<li>Record loads/stores to external variables in namespaces.</li>
+<li>Compile calls to stdcall, fastcall and vararg functions.</li>
+<li>Treat function ctypes like pointers in comparisons.</li>
+<li>Resolve <tt>__call</tt> metamethod for pointers, too.</li>
+<li>Record C function calls with bool return values.</li>
+<li>Record <tt>ffi.errno()</tt>.</li>
+<li>x86: Fix number to <tt>uint32_t</tt> conversion rounding.</li>
+<li>x86: Fix 64 bit arithmetic in assembler backend.</li>
+<li>x64: Fix struct-by-value calling conventions.</li>
+<li>ARM: Ensure invocation of SPLIT pass for float conversions.</li>
+</ul></li>
+<li>Structural and performance enhancements:
+<ul>
+<li>Display trace types with <tt>-jv</tt> and <tt>-jdump</tt>.</li>
+<li>Record isolated calls. But prefer recording loops over calls.</li>
+<li>Specialize to prototype for non-monomorphic functions. Solves the
+trace-explosion problem for closure-heavy programming styles.</li>
+<li>Always generate a portable <tt>vmdef.lua</tt>. Easier for distros.</li>
+</ul></li>
+</ul>
+
 <h2 id="LuaJIT-2.0.0-beta8">LuaJIT 2.0.0-beta8 &mdash; 2011-06-23</h2>
 <ul>
 <li>New features:
diff --git a/third_party/luajit/doc/ext_ffi_api.html b/third_party/luajit/doc/ext_ffi_api.html
index e865a5f7a0a75e2b9c49ba1c355f33e4634e8519..222c580eb90c6a9eaaf8dc9c27716fa36e8294a6 100644
--- a/third_party/luajit/doc/ext_ffi_api.html
+++ b/third_party/luajit/doc/ext_ffi_api.html
@@ -78,6 +78,9 @@ corresponding <b>ctype</b>.</li>
 <li><b>ct</b> &mdash; A C&nbsp;type specification which can be used for
 most of the API functions. Either a <b>cdecl</b>, a <b>ctype</b> or a
 <b>cdata</b> serving as a template type.</li>
+<li><b>cb</b> &mdash; A callback object. This is a C&nbsp;data object
+holding a special function pointer. Calling this function from
+C&nbsp;code runs an associated Lua function.</li>
 <li><b>VLA</b> &mdash; A variable-length array is declared with a
 <tt>?</tt> instead of the number of elements, e.g. <tt>"int[?]"</tt>.
 The number of elements (<tt>nelem</tt>) must be given when it's
@@ -473,6 +476,31 @@ Contains the target architecture name. Same contents as
 <a href="ext_jit.html#jit_arch"><tt>jit.arch</tt></a>.
 </p>
 
+<h2 id="callback">Methods for Callbacks</h2>
+<p>
+The C&nbsp;types for <a href="ext_ffi_semantics.html#callback">callbacks</a>
+have some extra methods:
+</p>
+
+<h3 id="callback_free"><tt>cb:free()</tt></h3>
+<p>
+Free the resources associated with a callback. The associated Lua
+function is unanchored and may be garbage collected. The callback
+function pointer is no longer valid and must not be called anymore
+(it may be reused by a subsequently created callback).
+</p>
+
+<h3 id="callback_set"><tt>cb:set(func)</tt></h3>
+<p>
+Associate a new Lua function with a callback. The C&nbsp;type of the
+callback and the callback function pointer are unchanged.
+</p>
+<p>
+This method is useful to dynamically switch the receiver of callbacks
+without creating a new callback each time and registering it again (e.g.
+with a GUI library).
+</p>
+
 <h2 id="extended">Extended Standard Library Functions</h2>
 <p>
 The following standard library functions have been extended to work
diff --git a/third_party/luajit/doc/ext_ffi_semantics.html b/third_party/luajit/doc/ext_ffi_semantics.html
index aff7e16256a1a17886944176bd89cbcdf05bac05..661b0b4c641f6618164d45b5fdb50100bca5eac0 100644
--- a/third_party/luajit/doc/ext_ffi_semantics.html
+++ b/third_party/luajit/doc/ext_ffi_semantics.html
@@ -297,10 +297,12 @@ arguments to C&nbsp;calls:
 <tr class="even">
 <td class="convin">string</td><td class="convop">string data &rarr;</td><td class="convout"><tt>const char[]</tt></td></tr>
 <tr class="odd separate">
+<td class="convin">function</td><td class="convop"><a href="#callback">create callback</a> &rarr;</td><td class="convout">C function type</td></tr>
+<tr class="even separate">
 <td class="convin">table</td><td class="convop"><a href="#init_table">table initializer</a></td><td class="convout">Array</td></tr>
-<tr class="even">
+<tr class="odd">
 <td class="convin">table</td><td class="convop"><a href="#init_table">table initializer</a></td><td class="convout"><tt>struct</tt>/<tt>union</tt></td></tr>
-<tr class="odd separate">
+<tr class="even separate">
 <td class="convin">cdata</td><td class="convop">cdata payload &rarr;</td><td class="convout">C type</td></tr>
 </table>
 <p>
@@ -461,8 +463,8 @@ when a single initializer is given. Otherwise they are treated like
 regular arrays.</li>
 
 <li>Aggregate types (arrays and structs) accept either a single
-<a href="#init_table">table initializer</a> or a flat list of initializers.
-Byte arrays can be initialized with a Lua string, too.</li>
+<a href="#init_table">table initializer</a> or a flat list of
+initializers.</li>
 
 <li>The elements of an array are initialized, starting at index zero.
 If a single initializer is given for an array, it's repeated for all
@@ -470,6 +472,10 @@ remaining elements. This doesn't happen if two or more initializers
 are given: all remaining uninitialized elements are filled with zero
 bytes.</li>
 
+<li>Byte arrays may also be initialized with a Lua string. This copies
+the whole string plus a terminating zero-byte. The copy stops early only
+if the array has a known, fixed size.</li>
+
 <li>The fields of a <tt>struct</tt> are initialized in the order of
 their declaration. Uninitialized fields are filled with zero
 bytes.</li>
@@ -812,11 +818,134 @@ vararg functions</a>.
 <p>
 Memory areas returned by C functions (e.g. from <tt>malloc()</tt>)
 must be manually managed, of course (or use
-<a href="ext_ffi_api.html#ffi_gc"><tt>ffi.gc()</tt></a>)). Pointers to
+<a href="ext_ffi_api.html#ffi_gc"><tt>ffi.gc()</tt></a>). Pointers to
 cdata objects are indistinguishable from pointers returned by C
 functions (which is one of the reasons why the GC cannot follow them).
 </p>
 
+<h2 id="callback">Callbacks</h2>
+<p>
+The LuaJIT FFI automatically generates special callback functions
+whenever a Lua function is converted to a C&nbsp;function pointer. This
+associates the generated callback function pointer with the C&nbsp;type
+of the function pointer and the Lua function object (closure).
+</p>
+<p>
+This can happen implicitly due to the usual conversions, e.g. when
+passing a Lua function to a function pointer argument. Or you can use
+<tt>ffi.cast()</tt> to explicitly cast a Lua function to a
+C&nbsp;function pointer.
+</p>
+<p>
+Currently only certain C&nbsp;function types can be used as callback
+functions. Neither C&nbsp;vararg functions nor functions with
+pass-by-value aggregate argument or result types are supported. There
+are no restrictions for the kind of Lua functions that can be called
+from the callback &mdash; no checks for the proper number of arguments
+are made. The return value of the Lua function will be converted to the
+result type and an error will be thrown for invalid conversions.
+</p>
+<p>
+It's allowed to throw errors across a callback invocation, but it's not
+advisable in general. Do this only if you know the C&nbsp;function, that
+called the callback, copes with the forced stack unwinding and doesn't
+leak resources.
+</p>
+
+<h3 id="callback_resources">Callback resource handling</h3>
+<p>
+Callbacks take up resources &mdash; you can only have a limited number
+of them at the same time (500&nbsp;-&nbsp;1000, depending on the
+architecture). The associated Lua functions are anchored to prevent
+garbage collection, too.
+</p>
+<p>
+<b>Callbacks due to implicit conversions are permanent!</b> There is no
+way to guess their lifetime, since the C&nbsp;side might store the
+function pointer for later use (typical for GUI toolkits). The associated
+resources cannot be reclaimed until termination:
+</p>
+<pre class="code">
+ffi.cdef[[
+typedef int (__stdcall *WNDENUMPROC)(void *hwnd, intptr_t l);
+int EnumWindows(WNDENUMPROC func, intptr_t l);
+]]
+
+-- Implicit conversion to a callback via function pointer argument.
+local count = 0
+ffi.C.EnumWindows(function(hwnd, l)
+  count = count + 1
+  return true
+end, 0)
+-- The callback is permanent and its resources cannot be reclaimed!
+-- Ok, so this may not be a problem, if you do this only once.
+</pre>
+<p>
+Note: this example shows that you <em>must</em> properly declare
+<tt>__stdcall</tt> callbacks on Windows/x86 systems. The calling
+convention cannot be automatically detected, unlike for
+<tt>__stdcall</tt> calls <em>to</em> Windows functions.
+</p>
+<p>
+For some use cases it's necessary to free up the resources or to
+dynamically redirect callbacks. Use an explicit cast to a
+C&nbsp;function pointer and keep the resulting cdata object. Then use
+the <a href="ext_ffi_api.html#callback_free"><tt>cb:free()</tt></a>
+or <a href="ext_ffi_api.html#callback_set"><tt>cb:set()</tt></a> methods
+on the cdata object:
+</p>
+<pre class="code">
+-- Explicitly convert to a callback via cast.
+local count = 0
+local cb = ffi.cast("WNDENUMPROC", function(hwnd, l)
+  count = count + 1
+  return true
+end)
+
+-- Pass it to a C function.
+ffi.C.EnumWindows(cb, 0)
+-- EnumWindows doesn't need the callback after it returns, so free it.
+
+cb:free()
+-- The callback function pointer is no longer valid and its resources
+-- will be reclaimed. The created Lua closure will be garbage collected.
+</pre>
+
+<h3 id="callback_performance">Callback performance</h3>
+<p>
+<b>Callbacks are slow!</b> First, the C&nbsp;to Lua transition itself
+has an unavoidable cost, similar to a <tt>lua_call()</tt> or
+<tt>lua_pcall()</tt>. Argument and result marshalling add to that cost.
+And finally, neither the C&nbsp;compiler nor LuaJIT can inline or
+optimize across the language barrier and hoist repeated computations out
+of a callback function.
+</p>
+<p>
+Do not use callbacks for performance-sensitive work: e.g. consider a
+numerical integration routine which takes a user-defined function to
+integrate over. It's a bad idea to call a user-defined Lua function from
+C&nbsp;code millions of times. The callback overhead will be absolutely
+detrimental for performance.
+</p>
+<p>
+It's considerably faster to write the numerical integration routine
+itself in Lua &mdash; the JIT compiler will be able to inline the
+user-defined function and optimize it together with its calling context,
+with very competitive performance.
+</p>
+<p>
+As a general guideline: <b>use callbacks only when you must</b>, because
+of existing C&nbsp;APIs. E.g. callback performance is irrelevant for a
+GUI application, which waits for user input most of the time, anyway.
+</p>
+<p>
+For new designs <b>avoid push-style APIs</b> (C&nbsp;function repeatedly
+calling a callback for each result). Instead <b>use pull-style APIs</b>
+(call a C&nbsp;function repeatedly to get a new result). Calls from Lua
+to C via the FFI are much faster than the other way round. Most well-designed
+libraries already use pull-style APIs (read/write, get/put).
+</p>
+
 <h2 id="clib">C Library Namespaces</h2>
 <p>
 A C&nbsp;library namespace is a special kind of object which allows
@@ -981,18 +1110,16 @@ alignment &gt; 8&nbsp;bytes.</li>
 <li>Conversions from lightuserdata to <tt>void&nbsp;*</tt>.</li>
 <li>Pointer differences for element sizes that are not a power of
 two.</li>
-<li>Calls to non-cdecl or vararg C&nbsp;functions.</li>
 <li>Calls to C&nbsp;functions with aggregates passed or returned by
 value.</li>
 <li>Calls to ctype metamethods which are not plain functions.</li>
 <li>ctype <tt>__newindex</tt> tables and non-string lookups in ctype
 <tt>__index</tt> tables.</li>
-<li>Accesses to external variables in C&nbsp;library namespaces.</li>
 <li><tt>tostring()</tt> for cdata types.</li>
 <li>Calls to the following <a href="ext_ffi_api.html">ffi.* API</a>
 functions: <tt>cdef</tt>, <tt>load</tt>, <tt>typeof</tt>,
 <tt>metatype</tt>, <tt>gc</tt>, <tt>sizeof</tt>, <tt>alignof</tt>,
-<tt>offsetof</tt>, <tt>errno</tt>.</li>
+<tt>offsetof</tt>.</li>
 </ul>
 <p>
 Other missing features:
@@ -1000,10 +1127,10 @@ Other missing features:
 <ul>
 <li>Bit operations for 64&nbsp;bit types.</li>
 <li>Arithmetic for <tt>complex</tt> numbers.</li>
-<li>Callbacks from C&nbsp;code to Lua functions.</li>
 <li>Passing structs by value to vararg C&nbsp;functions.</li>
 <li><a href="extensions.html#exceptions">C++ exception interoperability</a>
-does not extend to C&nbsp;functions called via the FFI.</li>
+does not extend to C&nbsp;functions called via the FFI, if the call is
+compiled.</li>
 </ul>
 <br class="flush">
 </div>
diff --git a/third_party/luajit/doc/ext_ffi_tutorial.html b/third_party/luajit/doc/ext_ffi_tutorial.html
index d5b04bc68ff183bd4d655c49aae2b522cd0f3535..fb46a84226dbd0d88f652d902eea06080d73b690 100644
--- a/third_party/luajit/doc/ext_ffi_tutorial.html
+++ b/third_party/luajit/doc/ext_ffi_tutorial.html
@@ -15,6 +15,7 @@ span.mark { color: #4040c0; font-family: Courier New, Courier, monospace;
 pre.mark { padding-left: 2em; }
 table.idiomtable { line-height: 1.2; }
 table.idiomtable tt { font-size: 100%; }
+table.idiomtable td { vertical-align: top; }
 tr.idiomhead td { font-weight: bold; }
 td.idiomc { width: 12em; }
 td.idiomlua { width: 14em; }
@@ -454,13 +455,13 @@ the origin.
 <span class="mark">&#9315;</span> If we run out of operators, we can
 define named methods, too. Here the <tt>__index</tt> table defines an
 <tt>area</tt> function. For custom indexing needs, one might want to
-define <tt>__index</tt> and <tt>__newindex</tt> functions instead.
+define <tt>__index</tt> and <tt>__newindex</tt> <em>functions</em> instead.
 </p>
 <p>
 <span class="mark">&#9316;</span> This associates the metamethods with
 our C&nbsp;type. This only needs to be done once. For convenience, a
 constructor is returned by
-<a href="ffi_ext_api.html#ffi_metatype"><tt>ffi.metatype()</tt></a>.
+<a href="ext_ffi_api.html#ffi_metatype"><tt>ffi.metatype()</tt></a>.
 We're not required to use it, though. The original C&nbsp;type can still
 be used e.g. to create an array of points. The metamethods automatically
 apply to any and all uses of this type.
@@ -478,6 +479,24 @@ defined metamethods. Note that <tt>area</tt> is a method and must be
 called with the Lua syntax for methods: <tt>a:area()</tt>, not
 <tt>a.area()</tt>.
 </p>
+<p>
+The C&nbsp;type metamethod mechanism is most useful when used in
+conjunction with C&nbsp;libraries that are written in an object-oriented
+style. Creators return a pointer to a new instance and methods take an
+instance pointer as the first argument. Sometimes you can just point
+<tt>__index</tt> to the library namespace and <tt>__gc</tt> to the
+destructor and you're done. But often enough you'll want to add
+convenience wrappers, e.g. to return actual Lua strings or when
+returning multiple values.
+</p>
+<p>
+Some C libraries only declare instance pointers as an opaque
+<tt>void&nbsp;*</tt> type. In this case you can use a fake type for all
+declarations, e.g. a pointer to a named (incomplete) struct will do:
+<tt>typedef struct foo_type *foo_handle</tt>. The C&nbsp;side doesn't
+know what you declare with the LuaJIT FFI, but as long as the underlying
+types are compatible, everything still works.
+</p>
 
 <h2 id="idioms">Translating C&nbsp;Idioms</h2>
 <p>
diff --git a/third_party/luajit/doc/install.html b/third_party/luajit/doc/install.html
index ebf3ff73b2faf0e195c9f47061ea3cbdc723ec8c..4e226d173f0c33702100608d3840b08af18cbcce 100644
--- a/third_party/luajit/doc/install.html
+++ b/third_party/luajit/doc/install.html
@@ -105,7 +105,7 @@ operating systems, CPUs and compilers:
 <td class="compatos"><a href="#posix">Linux</a> or<br><a href="#android">Android</a></td>
 <td class="compatos"><a href="#posix">*BSD, Other</a></td>
 <td class="compatos"><a href="#posix">OSX 10.3+</a> or<br><a href="#ios">iOS 3.0+</a></td>
-<td class="compatos"><a href="#windows">Windows<br>98/XP/Vista/7</a></td>
+<td class="compatos"><a href="#windows">Windows<br>XP/Vista/7</a></td>
 </tr>
 <tr class="odd separate">
 <td class="compatcpu">x86 (32 bit)</td>
@@ -122,14 +122,21 @@ operating systems, CPUs and compilers:
 <td class="compatos">MSVC + SDK v7.0<br>WinSDK v7.0</td>
 </tr>
 <tr class="odd">
-<td class="compatcpu">ARMv5+<br>ARM9E+</td>
+<td class="compatcpu"><a href="#android">ARMv5+<br>ARM9E+</a></td>
 <td class="compatos">GCC 4.2+</td>
 <td class="compatos">GCC 4.2+</td>
 <td class="compatos">GCC 4.2+</td>
 <td class="compatos compatno">&nbsp;</td>
 </tr>
 <tr class="even">
-<td class="compatcpu">PPC/e500v2</td>
+<td class="compatcpu"><a href="#ppc">PPC</a></td>
+<td class="compatos">GCC 4.3+</td>
+<td class="compatos">GCC 4.3+</td>
+<td class="compatos compatno">&nbsp;</td>
+<td class="compatos compatno">&nbsp;</td>
+</tr>
+<tr class="odd">
+<td class="compatcpu"><a href="#ppc">PPC/e500v2</a></td>
 <td class="compatos">GCC 4.3+</td>
 <td class="compatos">GCC 4.3+</td>
 <td class="compatos compatno">&nbsp;</td>
@@ -171,8 +178,8 @@ open a terminal window and change to this directory. Now unpack the archive
 and change to the newly created directory:
 </p>
 <pre class="code">
-tar zxf LuaJIT-2.0.0-beta8.tar.gz
-cd LuaJIT-2.0.0-beta8</pre>
+tar zxf LuaJIT-2.0.0-beta9.tar.gz
+cd LuaJIT-2.0.0-beta9</pre>
 <h3>Building LuaJIT</h3>
 <p>
 The supplied Makefiles try to auto-detect the settings needed for your
@@ -222,11 +229,11 @@ Obviously the prefixes given during build and installation need to be the same.
 <p style="color: #c00000;">
 Note: to avoid overwriting a previous version, the beta test releases
 only install the LuaJIT executable under the versioned name (i.e.
-<tt>luajit-2.0.0-beta8</tt>). You probably want to create a symlink
+<tt>luajit-2.0.0-beta9</tt>). You probably want to create a symlink
 for convenience, with a command like this:
 </p>
 <pre class="code" style="color: #c00000;">
-sudo ln -sf luajit-2.0.0-beta8&nbsp;/usr/local/bin/luajit
+sudo ln -sf luajit-2.0.0-beta9&nbsp;/usr/local/bin/luajit
 </pre>
 
 <h2 id="windows">Windows Systems</h2>
@@ -383,12 +390,18 @@ make HOST_CC="gcc -m32 -arch i386" CROSS=$ISDKP TARGET_FLAGS="$ISDKF" \
      TARGET=arm TARGET_SYS=iOS
 </pre>
 <p>
-You can cross-compile for a <b>PPC/e500v2 target</b> on an x86 or x64 host system
-using a standard GNU cross-compile toolchain (Binutils, GCC, EGLIBC).
+You can cross-compile for a <b id="ppc">PPC target</b> or a
+<b>PPC/e500v2 target</b> on x86 or x64 host systems using a standard
+GNU cross-compile toolchain (Binutils, GCC, EGLIBC).
 The <tt>CROSS</tt> prefix may vary depending on the <tt>--target</tt>
 of the toolchain:
 </p>
 <pre class="code">
+# PPC
+make HOST_CC="gcc -m32" CROSS=powerpc-linux-gnu- TARGET=ppc
+</pre>
+<pre class="code">
+# PPC/e500v2
 make HOST_CC="gcc -m32" CROSS=powerpc-e500v2-linux-gnuspe- TARGET=ppcspe
 </pre>
 <p>
diff --git a/third_party/luajit/doc/luajit.html b/third_party/luajit/doc/luajit.html
index 28ebff61d88cb2a57cd1191ae6d57e834679aa5f..9725f5c2a032bb7072330a3c537221c513dbe391 100644
--- a/third_party/luajit/doc/luajit.html
+++ b/third_party/luajit/doc/luajit.html
@@ -62,7 +62,7 @@ programming language.
 <p>
 LuaJIT is Copyright &copy; 2005-2011 Mike Pall.
 LuaJIT is open source software, released under the
-<a href="http://www.opensource.org/licenses/mit-license.php"><span class="ext">&raquo;</span>&nbsp;MIT/X license</a>.
+<a href="http://www.opensource.org/licenses/mit-license.php"><span class="ext">&raquo;</span>&nbsp;MIT license</a>.
 </p>
 <p class="indent" style="color: #606060;">
 * Lua is a powerful, dynamic and light-weight programming language
@@ -80,7 +80,7 @@ standard Lua interpreter and can be deployed as a drop-in replacement.
 LuaJIT offers more performance, at the expense of portability. It
 currently runs on all popular operating systems based on
 <b>x86</b> or <b>x64</b> CPUs (Linux, Windows, OSX etc.) or embedded
-systems based on <b>ARM</b> (Android, iOS) or <b>PPC/e500v2</b> CPUs.
+systems based on <b>ARM</b> (Android, iOS) or <b>PPC</b> CPUs.
 Other platforms will be supported in the future, based on user demand
 and sponsoring.
 </p>
diff --git a/third_party/luajit/doc/running.html b/third_party/luajit/doc/running.html
index cf1bdc45172469560a1bd68a856a0c21fb78f448..e2afdeef6751234f390edb015e8dab8b50adfd0a 100644
--- a/third_party/luajit/doc/running.html
+++ b/third_party/luajit/doc/running.html
@@ -85,11 +85,11 @@ interactive mode, too.
 <p class="indent" style="color: #c00000;">
 Note: the beta test releases only install under the versioned name on
 POSIX systems (to avoid overwriting a previous version). You either need
-to type <tt>luajit-2.0.0-beta8</tt> to start it or create a symlink
+to type <tt>luajit-2.0.0-beta9</tt> to start it or create a symlink
 with a command like this:
 </p>
 <pre class="code" style="color: #c00000;">
-sudo ln -sf luajit-2.0.0-beta8&nbsp;/usr/local/bin/luajit
+sudo ln -sf luajit-2.0.0-beta9&nbsp;/usr/local/bin/luajit
 </pre>
 <p>
 Unlike previous versions <b>optimization is turned on by default</b> in
@@ -118,28 +118,56 @@ are accepted:
 <li><tt>-l</tt> &mdash; Only list bytecode.</li>
 <li><tt>-s</tt> &mdash; Strip debug info (this is the default).</li>
 <li><tt>-g</tt> &mdash; Keep debug info.</li>
+<li><tt>-n name</tt> &mdash; Set module name (default: auto-detect from input name)</li>
+<li><tt>-t type</tt> &mdash; Set output file type (default: auto-detect from output name).</li>
+<li><tt>-a arch</tt> &mdash; Override architecture for object files (default: native).</li>
+<li><tt>-o os</tt> &mdash; Override OS for object files (default: native).</li>
 <li><tt>-e chunk</tt> &mdash; Use chunk string as input.</li>
 <li><tt>-</tt> (a single minus sign) &mdash; Use stdin as input and/or stdout as output.</li>
 </ul>
 <p>
+The output file type is auto-detected from the extension of the output
+file name:
+</p>
+<ul>
+<li><tt>c</tt> &mdash; C source file, exported bytecode data.</li>
+<li><tt>h</tt> &mdash; C header file, static bytecode data.</li>
+<li><tt>obj</tt> or <tt>o</tt> &mdash; Object file, exported bytecode data
+(OS- and architecture-specific).</li>
+<li><tt>raw</tt> or any other extension &mdash; Raw bytecode file (portable).
+</ul>
+<p>
+Notes:
+</p>
+<ul>
+<li>See also <a href="extensions.html#string_dump">string.dump()</a>
+for information on bytecode portability and compatibility.</li>
+<li>A file in raw bytecode format is auto-detected and can be loaded like
+any Lua source file. E.g. directly from the command line or with
+<tt>loadfile()</tt>, <tt>dofile()</tt> etc.</li>
+<li>To statically embed the bytecode of a module in your application,
+generate an object file and just link it with your application.</li>
+<li>On most ELF-based systems (e.g. Linux) you need to explicitly export the
+global symbols when linking your application, e.g. with: <tt>-Wl,-E</tt></li>
+<li><tt>require()</tt> tries to load embedded bytecode data from exported
+symbols (in <tt>*.exe</tt> or <tt>lua51.dll</tt> on Windows) and from
+shared libraries in <tt>package.cpath</tt>.</li>
+</ul>
+<p>
 Typical usage examples:
 </p>
 <pre class="code">
-luajit -b test.lua test.out                 # Save to test.out
+luajit -b test.lua test.out                 # Save bytecode to test.out
 luajit -bg test.lua test.out                # Keep debug info
 luajit -be "print('hello world')" test.out  # Save cmdline script
 
 luajit -bl test.lua                         # List to stdout
 luajit -bl test.lua test.txt                # List to test.txt
 luajit -ble "print('hello world')"          # List cmdline script
+
+luajit -b test.lua test.obj                 # Generate object file
+# Link test.obj with your application and load it with require("test")
 </pre>
-<p>
-Note: A file in bytecode format is auto-detected and can be loaded like
-any Lua source file. E.g. directly from the command line or with
-<tt>loadfile()</tt>, <tt>dofile()</tt> etc. See also
-<a href="extensions.html#string_dump">string.dump()</a> for information
-on bytecode portability and compatibility.
-</p>
 
 <h3 id="opt_j"><tt>-j cmd[=arg[,arg...]]</tt></h3>
 <p>
@@ -167,7 +195,7 @@ itself. For a description of their options and output format, please
 read the comment block at the start of their source.
 They can be found in the <tt>lib</tt> directory of the source
 distribution or installed under the <tt>jit</tt> directory. By default
-this is <tt>/usr/local/share/luajit-2.0.0-beta8/jit</tt> on POSIX
+this is <tt>/usr/local/share/luajit-2.0.0-beta9/jit</tt> on POSIX
 systems.
 </p>
 
diff --git a/third_party/luajit/doc/status.html b/third_party/luajit/doc/status.html
index d386e1aa5db6a2fa6f906c98a15f74418001d796..d9cffe0382e24b3f24d3ddb12d0e9c3c22eb50a7 100644
--- a/third_party/luajit/doc/status.html
+++ b/third_party/luajit/doc/status.html
@@ -148,18 +148,6 @@ with me, before writing major improvements, to avoid duplication of
 effort.
 </li>
 <li>
-The trace compiler currently doesn't back off specialization for
-function call dispatch. It should really fall back to specializing on
-the prototype, not the closure identity. This can lead to the so-called
-"trace explosion" problem with <b>closure-heavy programming</b>. The
-trace linking heuristics prevent this, but in the worst case this
-means the code always falls back to the interpreter.
-</li>
-<li>
-<b>Trace management</b> needs more tuning: less drastic countermeasures
-against trace explosion and better heuristics in general.
-</li>
-<li>
 Some checks are missing in the JIT-compiled code for obscure situations
 with <b>open upvalues aliasing</b> one of the SSA slots later on (or
 vice versa). Bonus points, if you can find a real world test case for
diff --git a/third_party/luajit/dynasm/dasm_arm.h b/third_party/luajit/dynasm/dasm_arm.h
index 87db7f000b01b4bfe975c5470fdc8cb0fbe5381f..43d2963379d996dc20fd1065226ac2b1be165576 100644
--- a/third_party/luajit/dynasm/dasm_arm.h
+++ b/third_party/luajit/dynasm/dasm_arm.h
@@ -1,7 +1,7 @@
 /*
 ** DynASM ARM encoding engine.
 ** Copyright (C) 2005-2011 Mike Pall. All rights reserved.
-** Released under the MIT/X license. See dynasm.lua for full copyright notice.
+** Released under the MIT license. See dynasm.lua for full copyright notice.
 */
 
 #include <stddef.h>
diff --git a/third_party/luajit/dynasm/dasm_ppc.h b/third_party/luajit/dynasm/dasm_ppc.h
index e928ffedd3882e33c61468913c07978c134ac543..645e06018059723fd12fb503d7a1d7412c436df1 100644
--- a/third_party/luajit/dynasm/dasm_ppc.h
+++ b/third_party/luajit/dynasm/dasm_ppc.h
@@ -1,7 +1,7 @@
 /*
 ** DynASM PPC encoding engine.
 ** Copyright (C) 2005-2011 Mike Pall. All rights reserved.
-** Released under the MIT/X license. See dynasm.lua for full copyright notice.
+** Released under the MIT license. See dynasm.lua for full copyright notice.
 */
 
 #include <stddef.h>
@@ -233,6 +233,9 @@ void dasm_put(Dst_DECL, int start, ...)
       case DASM_IMM:
 #ifdef DASM_CHECKS
 	CK((n & ((1<<((ins>>10)&31))-1)) == 0, RANGE_I);
+#endif
+	n >>= ((ins>>10)&31);
+#ifdef DASM_CHECKS
 	if (ins & 0x8000)
 	  CK(((n + (1<<(((ins>>5)&31)-1)))>>((ins>>5)&31)) == 0, RANGE_I);
 	else
@@ -339,7 +342,7 @@ int dasm_encode(Dst_DECL, void *buffer)
 	case DASM_STOP: case DASM_SECTION: goto stop;
 	case DASM_ESC: *cp++ = *p++; break;
 	case DASM_REL_EXT:
-	  n = DASM_EXTERN(Dst, (unsigned char *)cp, (ins & 2047), 1);
+	  n = DASM_EXTERN(Dst, (unsigned char *)cp, (ins & 2047), 1) - 4;
 	  goto patchrel;
 	case DASM_ALIGN:
 	  ins &= 255; while ((((char *)cp - base) & ins)) *cp++ = 0x60000000;
@@ -360,7 +363,7 @@ int dasm_encode(Dst_DECL, void *buffer)
 	  break;
 	case DASM_LABEL_PC: break;
 	case DASM_IMM:
-	  cp[-1] |= ((n>>((ins>>10)&31)) & ((1<<((ins>>5)&31))-1)) << (ins&31);
+	  cp[-1] |= (n & ((1<<((ins>>5)&31))-1)) << (ins&31);
 	  break;
 	default: *cp++ = ins; break;
 	}
diff --git a/third_party/luajit/dynasm/dasm_ppc.lua b/third_party/luajit/dynasm/dasm_ppc.lua
index bb6de01e2ba4fab0a71d4ecdf444d78ea06fe423..b2bee2cfd8ab3f2f01604d89f58d6ca478e77392 100644
--- a/third_party/luajit/dynasm/dasm_ppc.lua
+++ b/third_party/luajit/dynasm/dasm_ppc.lua
@@ -339,7 +339,8 @@ local map_op = {
   iselgt_3 =	"7c00005eRRR",
   iseleq_3 =	"7c00009eRRR",
   mfcr_1 =	"7c000026R",
-  -- NYI: mtcrf, mtocrf, mfocrf
+  mtcrf_2 =	"7c000120GR",
+  -- NYI: mtocrf, mfocrf
   lwarx_3 =	"7c000028RR0R",
   ldx_3 =	"7c00002aRR0R",
   lwzx_3 =	"7c00002eRR0R",
@@ -525,7 +526,7 @@ local map_op = {
   frip_2 =	"fc000390F-F.",
   frim_2 =	"fc0003d0F-F.",
   mffs_1 =	"fc00048eF.",
-  mtfsf_1 =	"fc00058eF.",
+  -- NYI: mtfsf, mtfsb0, mtfsb1.
   fctid_2 =	"fc00065cF-F.",
   fctidz_2 =	"fc00065eF-F.",
   fcfid_2 =	"fc00069cF-F.",
@@ -831,8 +832,10 @@ for cond,c in pairs(map_cond) do
   local c1 = (c%4)*0x00010000 + (c < 4 and 0x01000000 or 0)
   -- bX[l]
   map_op[b1.."_1"] = tohex(0x40800000 + c1).."K"
+  map_op[b1.."y_1"] = tohex(0x40a00000 + c1).."K"
   map_op[b1.."l_1"] = tohex(0x40800001 + c1).."K"
   map_op[b1.."_2"] = tohex(0x40800000 + c1).."-XK"
+  map_op[b1.."y_2"] = tohex(0x40a00000 + c1).."-XK"
   map_op[b1.."l_2"] = tohex(0x40800001 + c1).."-XK"
   -- bXlr[l]
   map_op[b1.."lr_0"] = tohex(0x4c800020 + c1)
@@ -1025,6 +1028,8 @@ map_op[".template__"] = function(params, template, nparams)
       rs = rs - 5; op = op + parse_cr(params[n]) * 2^(rs+2); n = n + 1
     elseif p == "W" then
       op = op + parse_cr(params[n]); n = n + 1
+    elseif p == "G" then
+      op = op + parse_imm(params[n], 8, 12, 0, false); n = n + 1
     elseif p == "J" or p == "K" then
       local mode, n, s = parse_label(params[n], false)
       if p == "K" then n = n + 2048 end
diff --git a/third_party/luajit/dynasm/dasm_proto.h b/third_party/luajit/dynasm/dasm_proto.h
index dc9ed51067fd30274ef7699a3f5962266834ff8a..3cc3af24a6bb3d6b111c2aeea8343c86bee53313 100644
--- a/third_party/luajit/dynasm/dasm_proto.h
+++ b/third_party/luajit/dynasm/dasm_proto.h
@@ -1,7 +1,7 @@
 /*
 ** DynASM encoding engine prototypes.
 ** Copyright (C) 2005-2011 Mike Pall. All rights reserved.
-** Released under the MIT/X license. See dynasm.lua for full copyright notice.
+** Released under the MIT license. See dynasm.lua for full copyright notice.
 */
 
 #ifndef _DASM_PROTO_H
diff --git a/third_party/luajit/dynasm/dasm_x86.h b/third_party/luajit/dynasm/dasm_x86.h
index 23e213cb6e66f7df7093a5b4590120fc70c86c40..8f2dd1cac0b28df2cd3150267fd01ace9f7c5e0b 100644
--- a/third_party/luajit/dynasm/dasm_x86.h
+++ b/third_party/luajit/dynasm/dasm_x86.h
@@ -1,7 +1,7 @@
 /*
 ** DynASM x86 encoding engine.
 ** Copyright (C) 2005-2011 Mike Pall. All rights reserved.
-** Released under the MIT/X license. See dynasm.lua for full copyright notice.
+** Released under the MIT license. See dynasm.lua for full copyright notice.
 */
 
 #include <stddef.h>
diff --git a/third_party/luajit/etc/luajit.1 b/third_party/luajit/etc/luajit.1
index b8713d4edb95e7128ce95a8946a1c6d96d5e294d..57080bceef4e981be8685e522667461ec8765a91 100644
--- a/third_party/luajit/etc/luajit.1
+++ b/third_party/luajit/etc/luajit.1
@@ -73,7 +73,7 @@ Runs some nested loops and shows the resulting traces.
 .PP
 \fBLuaJIT\fR is Copyright \(co 2005-2011 Mike Pall.
 .br
-\fBLuaJIT\fR is open source software, released under the MIT/X license.
+\fBLuaJIT\fR is open source software, released under the MIT license.
 .SH SEE ALSO
 .PP
 More details in the provided HTML docs or at:
diff --git a/third_party/luajit/etc/luajit.pc b/third_party/luajit/etc/luajit.pc
index 011b7365515032dbfbe5282fa73738deabde4c59..974abde4a564531d4d7b2e13572a83ffd321232b 100644
--- a/third_party/luajit/etc/luajit.pc
+++ b/third_party/luajit/etc/luajit.pc
@@ -2,7 +2,7 @@
 majver=2
 minver=0
 relver=0
-version=${majver}.${minver}.${relver}-beta8
+version=${majver}.${minver}.${relver}-beta9
 abiver=5.1
 
 prefix=/usr/local
diff --git a/third_party/luajit/etc/strict.lua b/third_party/luajit/etc/strict.lua
index 604619dd2ef2a8bf30a760e6d072263384f55d4d..e57b0cc182738b3ce9432f0b097b6295a259d64a 100644
--- a/third_party/luajit/etc/strict.lua
+++ b/third_party/luajit/etc/strict.lua
@@ -31,7 +31,7 @@ mt.__newindex = function (t, n, v)
   end
   rawset(t, n, v)
 end
-  
+
 mt.__index = function (t, n)
   if not mt.__declared[n] and what() ~= "C" then
     error("variable '"..n.."' is not declared", 2)
diff --git a/third_party/luajit/lib/bc.lua b/third_party/luajit/lib/bc.lua
index f4ee8e8ab35eb40689cf1b9f299e02e5c575ab30..c2c9502e4bce1337db59e97a380013ea09635699 100644
--- a/third_party/luajit/lib/bc.lua
+++ b/third_party/luajit/lib/bc.lua
@@ -2,7 +2,7 @@
 -- LuaJIT bytecode listing module.
 --
 -- Copyright (C) 2005-2011 Mike Pall. All rights reserved.
--- Released under the MIT/X license. See Copyright Notice in luajit.h
+-- Released under the MIT license. See Copyright Notice in luajit.h
 ----------------------------------------------------------------------------
 --
 -- This module lists the bytecode of a Lua function. If it's loaded by -jbc
diff --git a/third_party/luajit/lib/bcsave.lua b/third_party/luajit/lib/bcsave.lua
index c34bec8960df0876feb75ae1af17915601294a87..1783014fb21a85160a7eb155b747afb98181f526 100644
--- a/third_party/luajit/lib/bcsave.lua
+++ b/third_party/luajit/lib/bcsave.lua
@@ -2,7 +2,7 @@
 -- LuaJIT module to save/list bytecode.
 --
 -- Copyright (C) 2005-2011 Mike Pall. All rights reserved.
--- Released under the MIT/X license. See Copyright Notice in luajit.h
+-- Released under the MIT license. See Copyright Notice in luajit.h
 ----------------------------------------------------------------------------
 --
 -- This module saves or lists the bytecode for an input file.
@@ -10,10 +10,12 @@
 --
 ------------------------------------------------------------------------------
 
--- Cache some library functions and objects.
 local jit = require("jit")
 assert(jit.version_num == 20000, "LuaJIT core/library version mismatch")
 
+-- Symbol name prefix for LuaJIT bytecode.
+local LJBC_PREFIX = "luaJIT_BC_"
+
 ------------------------------------------------------------------------------
 
 local function usage()
@@ -22,41 +24,388 @@ Save LuaJIT bytecode: luajit -b[options] input output
   -l        Only list bytecode.
   -s        Strip debug info (default).
   -g        Keep debug info.
+  -n name   Set module name (default: auto-detect from input name).
+  -t type   Set output file type (default: auto-detect from output name).
+  -a arch   Override architecture for object files (default: native).
+  -o os     Override OS for object files (default: native).
   -e chunk  Use chunk string as input.
   --        Stop handling options.
   -         Use stdin as input and/or stdout as output.
+
+File types: c h obj o raw (default)
 ]]
   os.exit(1)
 end
 
+local function check(ok, ...)
+  if ok then return ok, ... end
+  io.stderr:write("luajit: ", ...)
+  io.stderr:write("\n")
+  os.exit(1)
+end
+
 local function readfile(input)
   if type(input) == "function" then return input end
   if input == "-" then input = nil end
-  local f, err = loadfile(input)
-  if not f then
-    io.stderr:write("luajit: ", err, "\n")
-    os.exit(1)
+  return check(loadfile(input))
+end
+
+local function savefile(name, mode)
+  if name == "-" then return io.stdout end
+  return check(io.open(name, mode))
+end
+
+------------------------------------------------------------------------------
+
+local map_type = {
+  raw = "raw", c = "c", h = "h", o = "obj", obj = "obj",
+}
+
+local map_arch = {
+  x86 = true, x64 = true, arm = true, ppc = true, ppcspe = true,
+}
+
+local map_os = {
+  linux = true, windows = true, osx = true, freebsd = true, netbsd = true,
+  openbsd = true, solaris = true,
+}
+
+local function checkarg(str, map, err)
+  str = string.lower(str)
+  local s = check(map[str], "unknown ", err)
+  return s == true and str or s
+end
+
+local function detecttype(str)
+  local ext = string.match(string.lower(str), "%.(%a+)$")
+  return map_type[ext] or "raw"
+end
+
+local function checkmodname(str)
+  check(string.match(str, "^[%w_.%-]+$"), "bad module name")
+  return string.gsub(str, "[%.%-]", "_")
+end
+
+local function detectmodname(str)
+  if type(str) == "string" then
+    local tail = string.match(str, "[^/\\]+$")
+    if tail then str = tail end
+    local head = string.match(str, "^(.*)%.[^.]*$")
+    if head then str = head end
+    str = string.match(str, "^[%w_.%-]+")
+  else
+    str = nil
   end
-  return f
+  check(str, "cannot derive module name, use -n name")
+  return string.gsub(str, "[%.%-]", "_")
+end
+
+------------------------------------------------------------------------------
+
+local function bcsave_tail(fp, output, s)
+  local ok, err = fp:write(s)
+  if ok and output ~= "-" then ok, err = fp:close() end
+  check(ok, "cannot write ", output, ": ", err)
 end
 
-local function readstring(input)
-  local f, err = loadstring(input)
-  if not f then
-    io.stderr:write("luajit: ", err, "\n")
-    os.exit(1)
+local function bcsave_raw(output, s)
+  local fp = savefile(output, "wb")
+  bcsave_tail(fp, output, s)
+end
+
+local function bcsave_c(ctx, output, s)
+  local fp = savefile(output, "w")
+  if ctx.type == "c" then
+    fp:write(string.format([[
+#ifdef _cplusplus
+extern "C"
+#endif
+#ifdef _WIN32
+__declspec(dllexport)
+#endif
+const char %s%s[] = {
+]], LJBC_PREFIX, ctx.modname))
+  else
+    fp:write(string.format([[
+#define %s%s_SIZE %d
+static const char %s%s[] = {
+]], LJBC_PREFIX, ctx.modname, #s, LJBC_PREFIX, ctx.modname))
   end
-  return f
+  local t, n, m = {}, 0, 0
+  for i=1,#s do
+    local b = tostring(string.byte(s, i))
+    m = m + #b + 1
+    if m > 78 then
+      fp:write(table.concat(t, ",", 1, n), ",\n")
+      n, m = 0, #b + 1
+    end
+    n = n + 1
+    t[n] = b
+  end
+  bcsave_tail(fp, output, table.concat(t, ",", 1, n).."\n};\n")
 end
 
-local function savefile(name, mode)
-  if name == "-" then return io.stdout end
-  local fp, err = io.open(name, mode)
-  if not fp then
-    io.stderr:write("luajit: cannot write ", err, "\n")
-    os.exit(1)
+local function bcsave_elfobj(ctx, output, s, ffi)
+  ffi.cdef[[
+typedef struct {
+  uint8_t emagic[4], eclass, eendian, eversion, eosabi, eabiversion, epad[7];
+  uint16_t type, machine;
+  uint32_t version;
+  uint32_t entry, phofs, shofs;
+  uint32_t flags;
+  uint16_t ehsize, phentsize, phnum, shentsize, shnum, shstridx;
+} ELF32header;
+typedef struct {
+  uint8_t emagic[4], eclass, eendian, eversion, eosabi, eabiversion, epad[7];
+  uint16_t type, machine;
+  uint32_t version;
+  uint64_t entry, phofs, shofs;
+  uint32_t flags;
+  uint16_t ehsize, phentsize, phnum, shentsize, shnum, shstridx;
+} ELF64header;
+typedef struct {
+  uint32_t name, type, flags, addr, ofs, size, link, info, align, entsize;
+} ELF32sectheader;
+typedef struct {
+  uint32_t name, type;
+  uint64_t flags, addr, ofs, size;
+  uint32_t link, info;
+  uint64_t align, entsize;
+} ELF64sectheader;
+typedef struct {
+  uint32_t name, value, size;
+  uint8_t info, other;
+  uint16_t sectidx;
+} ELF32symbol;
+typedef struct {
+  uint32_t name;
+  uint8_t info, other;
+  uint16_t sectidx;
+  uint64_t value, size;
+} ELF64symbol;
+typedef struct {
+  ELF32header hdr;
+  ELF32sectheader sect[6];
+  ELF32symbol sym[2];
+  uint8_t space[4096];
+} ELF32obj;
+typedef struct {
+  ELF64header hdr;
+  ELF64sectheader sect[6];
+  ELF64symbol sym[2];
+  uint8_t space[4096];
+} ELF64obj;
+]]
+  local symname = LJBC_PREFIX..ctx.modname
+  local is64, isbe = false, false
+  if ctx.arch == "x64" then
+    is64 = true
+  elseif ctx.arch == "ppc" or ctx.arch == "ppcspe" then
+    isbe = true
+  end
+
+  -- Handle different host/target endianess.
+  local function f32(x) return x end
+  local f16, fofs = f32, f32
+  if ffi.abi("be") ~= isbe then
+    f32 = bit.bswap
+    function f16(x) return bit.rshift(bit.bswap(x), 16) end
+    if is64 then
+      function fofs(x) return bit.bswap(x)*(2ll^32) end
+    else
+      fofs = f32
+    end
+  end
+
+  -- Create ELF object and fill in header.
+  local o = ffi.new(is64 and "ELF64obj" or "ELF32obj")
+  local hdr = o.hdr
+  if ctx.os == "bsd" or ctx.os == "other" then -- Determine native hdr.eosabi.
+    local bf = assert(io.open("/bin/ls", "rb"))
+    local bs = bf:read(9)
+    bf:close()
+    ffi.copy(o, bs, 9)
+    check(hdr.emagic[0] == 127, "no support for writing native object files")
+  else
+    hdr.emagic = "\127ELF"
+    hdr.eosabi = ({ freebsd=9, netbsd=2, openbsd=12, solaris=6 })[ctx.os] or 0
+  end
+  hdr.eclass = is64 and 2 or 1
+  hdr.eendian = isbe and 2 or 1
+  hdr.eversion = 1
+  hdr.type = f16(1)
+  hdr.machine = f16(({ x86=3, x64=62, arm=40, ppc=20, ppcspe=20 })[ctx.arch])
+  hdr.version = f32(1)
+  hdr.shofs = fofs(ffi.offsetof(o, "sect"))
+  hdr.ehsize = f16(ffi.sizeof(hdr))
+  hdr.shentsize = f16(ffi.sizeof(o.sect[0]))
+  hdr.shnum = f16(6)
+  hdr.shstridx = f16(2)
+
+  -- Fill in sections and symbols.
+  local sofs, ofs = ffi.offsetof(o, "space"), 1
+  for i,name in ipairs{
+      ".symtab", ".shstrtab", ".strtab", ".rodata", ".note.GNU-stack",
+    } do
+    local sect = o.sect[i]
+    sect.align = fofs(1)
+    sect.name = f32(ofs)
+    ffi.copy(o.space+ofs, name)
+    ofs = ofs + #name+1
+  end
+  o.sect[1].type = f32(2) -- .symtab
+  o.sect[1].link = f32(3)
+  o.sect[1].info = f32(1)
+  o.sect[1].align = fofs(8)
+  o.sect[1].ofs = fofs(ffi.offsetof(o, "sym"))
+  o.sect[1].entsize = fofs(ffi.sizeof(o.sym[0]))
+  o.sect[1].size = fofs(ffi.sizeof(o.sym))
+  o.sym[1].name = f32(1)
+  o.sym[1].sectidx = f16(4)
+  o.sym[1].size = fofs(#s)
+  o.sym[1].info = 17
+  o.sect[2].type = f32(3) -- .shstrtab
+  o.sect[2].ofs = fofs(sofs)
+  o.sect[2].size = fofs(ofs)
+  o.sect[3].type = f32(3) -- .strtab
+  o.sect[3].ofs = fofs(sofs + ofs)
+  o.sect[3].size = fofs(#symname+1)
+  ffi.copy(o.space+ofs+1, symname)
+  ofs = ofs + #symname + 2
+  o.sect[4].type = f32(1) -- .rodata
+  o.sect[4].flags = fofs(2)
+  o.sect[4].ofs = fofs(sofs + ofs)
+  o.sect[4].size = fofs(#s)
+  o.sect[5].type = f32(1) -- .note.GNU-stack
+  o.sect[5].ofs = fofs(sofs + ofs + #s)
+
+  -- Write ELF object file.
+  local fp = savefile(output, "wb")
+  fp:write(ffi.string(o, ffi.sizeof(o)-4096+ofs))
+  bcsave_tail(fp, output, s)
+end
+
+local function bcsave_peobj(ctx, output, s, ffi)
+  ffi.cdef[[
+typedef struct {
+  uint16_t arch, nsects;
+  uint32_t time, symtabofs, nsyms;
+  uint16_t opthdrsz, flags;
+} PEheader;
+typedef struct {
+  char name[8];
+  uint32_t vsize, vaddr, size, ofs, relocofs, lineofs;
+  uint16_t nreloc, nline;
+  uint32_t flags;
+} PEsection;
+typedef struct __attribute((packed)) {
+  union {
+    char name[8];
+    uint32_t nameref[2];
+  };
+  uint32_t value;
+  int16_t sect;
+  uint16_t type;
+  uint8_t scl, naux;
+} PEsym;
+typedef struct __attribute((packed)) {
+  uint32_t size;
+  uint16_t nreloc, nline;
+  uint32_t cksum;
+  uint16_t assoc;
+  uint8_t comdatsel, unused[3];
+} PEsymaux;
+typedef struct {
+  PEheader hdr;
+  PEsection sect[2];
+  // Must be an even number of symbol structs.
+  PEsym sym0;
+  PEsymaux sym0aux;
+  PEsym sym1;
+  PEsymaux sym1aux;
+  PEsym sym2;
+  PEsym sym3;
+  uint32_t strtabsize;
+  uint8_t space[4096];
+} PEobj;
+]]
+  local symname = LJBC_PREFIX..ctx.modname
+  local is64 = false
+  if ctx.arch == "x86" then
+    symname = "_"..symname
+  elseif ctx.arch == "x64" then
+    is64 = true
+  end
+  local symexport = "   /EXPORT:"..symname..",DATA "
+
+  -- The file format is always little-endian. Swap if the host is big-endian.
+  local function f32(x) return x end
+  local f16 = f32
+  if ffi.abi("be") then
+    f32 = bit.bswap
+    function f16(x) return bit.rshift(bit.bswap(x), 16) end
+  end
+
+  -- Create PE object and fill in header.
+  local o = ffi.new("PEobj")
+  local hdr = o.hdr
+  hdr.arch = f16(({ x86=0x14c, x64=0x8664, arm=0x1c0, ppc=0x1f2 })[ctx.arch])
+  hdr.nsects = f16(2)
+  hdr.symtabofs = f32(ffi.offsetof(o, "sym0"))
+  hdr.nsyms = f32(6)
+
+  -- Fill in sections and symbols.
+  o.sect[0].name = ".drectve"
+  o.sect[0].size = f32(#symexport)
+  o.sect[0].flags = f32(0x00100a00)
+  o.sym0.sect = f16(1)
+  o.sym0.scl = 3
+  o.sym0.name = ".drectve"
+  o.sym0.naux = 1
+  o.sym0aux.size = f32(#symexport)
+  o.sect[1].name = ".rdata"
+  o.sect[1].size = f32(#s)
+  o.sect[1].flags = f32(0x40300040)
+  o.sym1.sect = f16(2)
+  o.sym1.scl = 3
+  o.sym1.name = ".rdata"
+  o.sym1.naux = 1
+  o.sym1aux.size = f32(#s)
+  o.sym2.sect = f16(2)
+  o.sym2.scl = 2
+  o.sym2.nameref[1] = f32(4)
+  o.sym3.sect = f16(-1)
+  o.sym3.scl = 2
+  o.sym3.value = f32(1)
+  o.sym3.name = "@feat.00" -- Mark as SafeSEH compliant.
+  ffi.copy(o.space, symname)
+  local ofs = #symname + 1
+  o.strtabsize = f32(ofs + 4)
+  o.sect[0].ofs = f32(ffi.offsetof(o, "space") + ofs)
+  ffi.copy(o.space + ofs, symexport)
+  ofs = ofs + #symexport
+  o.sect[1].ofs = f32(ffi.offsetof(o, "space") + ofs)
+
+  -- Write PE object file.
+  local fp = savefile(output, "wb")
+  fp:write(ffi.string(o, ffi.sizeof(o)-4096+ofs))
+  bcsave_tail(fp, output, s)
+end
+
+local function bcsave_machobj(ctx, output, s, ffi)
+  check(false, "NYI: no support for writing OSX object files")
+end
+
+local function bcsave_obj(ctx, output, s)
+  local ok, ffi = pcall(require, "ffi")
+  check(ok, "FFI library required to write this file type")
+  if ctx.os == "windows" then
+    return bcsave_peobj(ctx, output, s, ffi)
+  elseif ctx.os == "osx" then
+    return bcsave_machobj(ctx, output, s, ffi)
+  else
+    return bcsave_elfobj(ctx, output, s, ffi)
   end
-  return fp
 end
 
 ------------------------------------------------------------------------------
@@ -66,15 +415,23 @@ local function bclist(input, output)
   require("jit.bc").dump(f, savefile(output, "w"), true)
 end
 
-local function bcsave(input, output, strip)
+local function bcsave(ctx, input, output)
   local f = readfile(input)
-  local s = string.dump(f, strip)
-  local fp = savefile(output, "wb")
-  local ok, err = fp:write(s)
-  if ok and output ~= "-" then ok, err = fp:close() end
-  if not ok then
-    io.stderr:write("luajit: cannot write ", arg[2], ": ", err, "\n")
-    os.exit(1)
+  local s = string.dump(f, ctx.strip)
+  local t = ctx.type
+  if not t then
+    t = detecttype(output)
+    ctx.type = t
+  end
+  if t == "raw" then
+    bcsave_raw(output, s)
+  else
+    if not ctx.modname then ctx.modname = detectmodname(input) end
+    if t == "obj" then
+      bcsave_obj(ctx, output, s)
+    else
+      bcsave_c(ctx, output, s)
+    end
   end
 end
 
@@ -82,27 +439,41 @@ local function docmd(...)
   local arg = {...}
   local n = 1
   local list = false
-  local strip = true
+  local ctx = {
+    strip = true, arch = jit.arch, os = string.lower(jit.os),
+    type = false, modname = false,
+  }
   while n <= #arg do
     local a = arg[n]
     if type(a) == "string" and string.sub(a, 1, 1) == "-" and a ~= "-" then
-      if a == "--" then table.remove(arg, n); break end
+      table.remove(arg, n)
+      if a == "--" then break end
       for m=2,#a do
 	local opt = string.sub(a, m, m)
 	if opt == "l" then
 	  list = true
 	elseif opt == "s" then
-	  strip = true
+	  ctx.strip = true
 	elseif opt == "g" then
-	  strip = false
-	elseif opt == "e" then
-	  if n ~= 1 or #arg < 2 or m ~= #a then usage() end
-	  arg[2] = readstring(arg[2])
+	  ctx.strip = false
 	else
-	  usage()
+	  if arg[n] == nil or m ~= #a then usage() end
+	  if opt == "e" then
+	    if n ~= 1 then usage() end
+	    arg[1] = check(loadstring(arg[1]))
+	  elseif opt == "n" then
+	    ctx.modname = checkmodname(table.remove(arg, n))
+	  elseif opt == "t" then
+	    ctx.type = checkarg(table.remove(arg, n), map_type, "file type")
+	  elseif opt == "a" then
+	    ctx.arch = checkarg(table.remove(arg, n), map_arch, "architecture")
+	  elseif opt == "o" then
+	    ctx.os = checkarg(table.remove(arg, n), map_os, "OS name")
+	  else
+	    usage()
+	  end
 	end
       end
-      table.remove(arg, n)
     else
       n = n + 1
     end
@@ -112,7 +483,7 @@ local function docmd(...)
     bclist(arg[1], arg[2] or "-")
   else
     if #arg ~= 2 then usage() end
-    bcsave(arg[1], arg[2], strip)
+    bcsave(ctx, arg[1], arg[2])
   end
 end
 
diff --git a/third_party/luajit/lib/dis_arm.lua b/third_party/luajit/lib/dis_arm.lua
index e4e98afc062c1c3f53c150640771f92fc7ee7e05..c2d1408fbc91841d4c4b92278160ed78fb8580f0 100644
--- a/third_party/luajit/lib/dis_arm.lua
+++ b/third_party/luajit/lib/dis_arm.lua
@@ -2,7 +2,7 @@
 -- LuaJIT ARM disassembler module.
 --
 -- Copyright (C) 2005-2010 Mike Pall. All rights reserved.
--- Released under the MIT/X license. See Copyright Notice in luajit.h
+-- Released under the MIT license. See Copyright Notice in luajit.h
 ----------------------------------------------------------------------------
 -- This is a helper module used by the LuaJIT machine code dumper module.
 --
diff --git a/third_party/luajit/lib/dis_ppc.lua b/third_party/luajit/lib/dis_ppc.lua
new file mode 100644
index 0000000000000000000000000000000000000000..79b306d5cccc1156e1c980ef40e954ac162a0c4a
--- /dev/null
+++ b/third_party/luajit/lib/dis_ppc.lua
@@ -0,0 +1,591 @@
+----------------------------------------------------------------------------
+-- LuaJIT PPC disassembler module.
+--
+-- Copyright (C) 2005-2010 Mike Pall. All rights reserved.
+-- Released under the MIT/X license. See Copyright Notice in luajit.h
+----------------------------------------------------------------------------
+-- This is a helper module used by the LuaJIT machine code dumper module.
+--
+-- It disassembles all common, non-privileged 32/64 bit PowerPC instructions
+-- plus the e500 SPE instructions and some Cell/Xenon extensions.
+--
+-- NYI: VMX, VMX128
+------------------------------------------------------------------------------
+
+local type = type
+local sub, byte, format = string.sub, string.byte, string.format
+local match, gmatch, gsub = string.match, string.gmatch, string.gsub
+local concat = table.concat
+local bit = require("bit")
+local band, bor, tohex = bit.band, bit.bor, bit.tohex
+local lshift, rshift, arshift = bit.lshift, bit.rshift, bit.arshift
+
+------------------------------------------------------------------------------
+-- Primary and extended opcode maps
+------------------------------------------------------------------------------
+
+local map_crops = {
+  shift = 1, mask = 1023,
+  [0] = "mcrfXX",
+  [33] = "crnor|crnotCCC=", [129] = "crandcCCC",
+  [193] = "crxor|crclrCCC%", [225] = "crnandCCC",
+  [257] = "crandCCC", [289] = "creqv|crsetCCC%",
+  [417] = "crorcCCC", [449] = "cror|crmoveCCC=",
+  [16] = "b_lrKB", [528] = "b_ctrKB",
+  [150] = "isync",
+}
+
+local map_rlwinm = setmetatable({
+  shift = 0, mask = -1,
+},
+{ __index = function(t, x)
+    local rot = band(rshift(x, 11), 31)
+    local mb = band(rshift(x, 6), 31)
+    local me = band(rshift(x, 1), 31)
+    if mb == 0 and me == 31-rot then
+      return "slwiRR~A."
+    elseif me == 31 and mb == 32-rot then
+      return "srwiRR~-A."
+    else
+      return "rlwinmRR~AAA."
+    end
+  end
+})
+
+local map_rld = {
+  shift = 2, mask = 7,
+  [0] = "rldiclRR~HM.", "rldicrRR~HM.", "rldicRR~HM.", "rldimiRR~HM.",
+  {
+    shift = 1, mask = 1,
+    [0] = "rldclRR~HM.", "rldcrRR~HM.",
+  },
+}
+
+local map_ext = setmetatable({
+  shift = 1, mask = 1023,
+
+  [0] = "cmp_YLRR", [32] = "cmpl_YLRR",
+  [4] = "twARR", [68] = "tdARR",
+
+  [8] = "subfcRRR.", [40] = "subfRRR.",
+  [104] = "negRR.", [136] = "subfeRRR.",
+  [200] = "subfzeRR.", [232] = "subfmeRR.",
+  [520] = "subfcoRRR.", [552] = "subfoRRR.",
+  [616] = "negoRR.", [648] = "subfeoRRR.",
+  [712] = "subfzeoRR.", [744] = "subfmeoRR.",
+
+  [9] = "mulhduRRR.", [73] = "mulhdRRR.", [233] = "mulldRRR.",
+  [457] = "divduRRR.", [489] = "divdRRR.",
+  [745] = "mulldoRRR.",
+  [969] = "divduoRRR.", [1001] = "divdoRRR.",
+
+  [10] = "addcRRR.", [138] = "addeRRR.",
+  [202] = "addzeRR.", [234] = "addmeRR.", [266] = "addRRR.",
+  [522] = "addcoRRR.", [650] = "addeoRRR.",
+  [714] = "addzeoRR.", [746] = "addmeoRR.", [778] = "addoRRR.",
+
+  [11] = "mulhwuRRR.", [75] = "mulhwRRR.", [235] = "mullwRRR.",
+  [459] = "divwuRRR.", [491] = "divwRRR.",
+  [747] = "mullwoRRR.",
+  [971] = "divwouRRR.", [1003] = "divwoRRR.",
+
+  [15] = "iselltRRR", [47] = "iselgtRRR", [79] = "iseleqRRR",
+
+  [144] = { shift = 20, mask = 1, [0] = "mtcrfRZ~", "mtocrfRZ~", },
+  [19] = { shift = 20, mask = 1, [0] = "mfcrR", "mfocrfRZ", },
+  [371] = { shift = 11, mask = 1023, [392] = "mftbR", [424] = "mftbuR", },
+  [339] = {
+    shift = 11, mask = 1023,
+    [32] = "mferR", [256] = "mflrR", [288] = "mfctrR", [16] = "mfspefscrR",
+  },
+  [467] = {
+    shift = 11, mask = 1023,
+    [32] = "mtxerR", [256] = "mtlrR", [288] = "mtctrR", [16] = "mtspefscrR",
+  },
+
+  [20] = "lwarxRR0R", [84] = "ldarxRR0R",
+
+  [21] = "ldxRR0R", [53] = "lduxRRR",
+  [149] = "stdxRR0R", [181] = "stduxRRR",
+  [341] = "lwaxRR0R", [373] = "lwauxRRR",
+
+  [23] = "lwzxRR0R", [55] = "lwzuxRRR",
+  [87] = "lbzxRR0R", [119] = "lbzuxRRR",
+  [151] = "stwxRR0R", [183] = "stwuxRRR",
+  [215] = "stbxRR0R", [247] = "stbuxRRR",
+  [279] = "lhzxRR0R", [311] = "lhzuxRRR",
+  [343] = "lhaxRR0R", [375] = "lhauxRRR",
+  [407] = "sthxRR0R", [439] = "sthuxRRR",
+
+  [54] = "dcbst-R0R", [86] = "dcbf-R0R",
+  [150] = "stwcxRR0R.", [214] = "stdcxRR0R.",
+  [246] = "dcbtst-R0R", [278] = "dcbt-R0R",
+  [310] = "eciwxRR0R", [438] = "ecowxRR0R",
+  [470] = "dcbi-RR",
+
+  [598] = {
+    shift = 21, mask = 3,
+    [0] = "sync", "lwsync", "ptesync",
+  },
+  [758] = "dcba-RR",
+  [854] = "eieio", [982] = "icbi-R0R", [1014] = "dcbz-R0R",
+
+  [26] = "cntlzwRR~", [58] = "cntlzdRR~",
+  [122] = "popcntbRR~",
+  [154] = "prtywRR~", [186] = "prtydRR~",
+
+  [28] = "andRR~R.", [60] = "andcRR~R.", [124] = "nor|notRR~R=.",
+  [284] = "eqvRR~R.", [316] = "xorRR~R.",
+  [412] = "orcRR~R.", [444] = "or|mrRR~R=.", [476] = "nandRR~R.",
+  [508] = "cmpbRR~R",
+
+  [512] = "mcrxrX",
+
+  [532] = "ldbrxRR0R", [660] = "stdbrxRR0R",
+
+  [533] = "lswxRR0R", [597] = "lswiRR0A",
+  [661] = "stswxRR0R", [725] = "stswiRR0A",
+
+  [534] = "lwbrxRR0R", [662] = "stwbrxRR0R",
+  [790] = "lhbrxRR0R", [918] = "sthbrxRR0R",
+
+  [535] = "lfsxFR0R", [567] = "lfsuxFRR",
+  [599] = "lfdxFR0R", [631] = "lfduxFRR",
+  [663] = "stfsxFR0R", [695] = "stfsuxFRR",
+  [727] = "stfdxFR0R", [759] = "stfduxFR0R",
+  [855] = "lfiwaxFR0R",
+  [983] = "stfiwxFR0R",
+
+  [24] = "slwRR~R.",
+
+  [27] = "sldRR~R.", [536] = "srwRR~R.",
+  [792] = "srawRR~R.", [824] = "srawiRR~A.",
+
+  [794] = "sradRR~R.", [826] = "sradiRR~H.", [827] = "sradiRR~H.",
+  [922] = "extshRR~.", [954] = "extsbRR~.", [986] = "extswRR~.",
+
+  [539] = "srdRR~R.",
+},
+{ __index = function(t, x)
+    if band(x, 31) == 15 then return "iselRRRC" end
+  end
+})
+
+local map_ld = {
+  shift = 0, mask = 3,
+  [0] = "ldRRE", "lduRRE", "lwaRRE",
+}
+
+local map_std = {
+  shift = 0, mask = 3,
+  [0] = "stdRRE", "stduRRE",
+}
+
+local map_fps = {
+  shift = 5, mask = 1,
+  {
+    shift = 1, mask = 15,
+    [0] = false, false, "fdivsFFF.", false,
+    "fsubsFFF.", "faddsFFF.", "fsqrtsF-F.", false,
+    "fresF-F.", "fmulsFF-F.", "frsqrtesF-F.", false,
+    "fmsubsFFFF~.", "fmaddsFFFF~.", "fnmsubsFFFF~.", "fnmaddsFFFF~.",
+  }
+}
+
+local map_fpd = {
+  shift = 5, mask = 1,
+  [0] = {
+    shift = 1, mask = 1023,
+    [0] = "fcmpuXFF", [32] = "fcmpoXFF", [64] = "mcrfsXX",
+    [38] = "mtfsb1A.", [70] = "mtfsb0A.", [134] = "mtfsfiA>>-A>",
+    [8] = "fcpsgnFFF.", [40] = "fnegF-F.", [72] = "fmrF-F.",
+    [136] = "fnabsF-F.", [264] = "fabsF-F.",
+    [12] = "frspF-F.",
+    [14] = "fctiwF-F.", [15] = "fctiwzF-F.",
+    [583] = "mffsF.", [711] = "mtfsfZF.",
+    [392] = "frinF-F.", [424] = "frizF-F.",
+    [456] = "fripF-F.", [488] = "frimF-F.",
+    [814] = "fctidF-F.", [815] = "fctidzF-F.", [846] = "fcfidF-F.",
+  },
+  {
+    shift = 1, mask = 15,
+    [0] = false, false, "fdivFFF.", false,
+    "fsubFFF.", "faddFFF.", "fsqrtF-F.", "fselFFFF~.",
+    "freF-F.", "fmulFF-F.", "frsqrteF-F.", false,
+    "fmsubFFFF~.", "fmaddFFFF~.", "fnmsubFFFF~.", "fnmaddFFFF~.",
+  }
+}
+
+local map_spe = {
+  shift = 0, mask = 2047,
+
+  [512] = "evaddwRRR", [514] = "evaddiwRAR~",
+  [516] = "evsubwRRR~", [518] = "evsubiwRAR~",
+  [520] = "evabsRR", [521] = "evnegRR",
+  [522] = "evextsbRR", [523] = "evextshRR", [524] = "evrndwRR",
+  [525] = "evcntlzwRR", [526] = "evcntlswRR",
+
+  [527] = "brincRRR",
+
+  [529] = "evandRRR", [530] = "evandcRRR", [534] = "evxorRRR",
+  [535] = "evor|evmrRRR=", [536] = "evnor|evnotRRR=",
+  [537] = "eveqvRRR", [539] = "evorcRRR", [542] = "evnandRRR",
+
+  [544] = "evsrwuRRR", [545] = "evsrwsRRR",
+  [546] = "evsrwiuRRA", [547] = "evsrwisRRA",
+  [548] = "evslwRRR", [550] = "evslwiRRA",
+  [552] = "evrlwRRR", [553] = "evsplatiRS",
+  [554] = "evrlwiRRA", [555] = "evsplatfiRS",
+  [556] = "evmergehiRRR", [557] = "evmergeloRRR",
+  [558] = "evmergehiloRRR", [559] = "evmergelohiRRR",
+
+  [560] = "evcmpgtuYRR", [561] = "evcmpgtsYRR",
+  [562] = "evcmpltuYRR", [563] = "evcmpltsYRR",
+  [564] = "evcmpeqYRR",
+
+  [632] = "evselRRR", [633] = "evselRRRW",
+  [634] = "evselRRRW", [635] = "evselRRRW",
+  [636] = "evselRRRW", [637] = "evselRRRW",
+  [638] = "evselRRRW", [639] = "evselRRRW",
+
+  [640] = "evfsaddRRR", [641] = "evfssubRRR",
+  [644] = "evfsabsRR", [645] = "evfsnabsRR", [646] = "evfsnegRR",
+  [648] = "evfsmulRRR", [649] = "evfsdivRRR",
+  [652] = "evfscmpgtYRR", [653] = "evfscmpltYRR", [654] = "evfscmpeqYRR",
+  [656] = "evfscfuiR-R", [657] = "evfscfsiR-R",
+  [658] = "evfscfufR-R", [659] = "evfscfsfR-R",
+  [660] = "evfsctuiR-R", [661] = "evfsctsiR-R",
+  [662] = "evfsctufR-R", [663] = "evfsctsfR-R",
+  [664] = "evfsctuizR-R", [666] = "evfsctsizR-R",
+  [668] = "evfststgtYRR", [669] = "evfststltYRR", [670] = "evfststeqYRR",
+
+  [704] = "efsaddRRR", [705] = "efssubRRR",
+  [708] = "efsabsRR", [709] = "efsnabsRR", [710] = "efsnegRR",
+  [712] = "efsmulRRR", [713] = "efsdivRRR",
+  [716] = "efscmpgtYRR", [717] = "efscmpltYRR", [718] = "efscmpeqYRR",
+  [719] = "efscfdR-R",
+  [720] = "efscfuiR-R", [721] = "efscfsiR-R",
+  [722] = "efscfufR-R", [723] = "efscfsfR-R",
+  [724] = "efsctuiR-R", [725] = "efsctsiR-R",
+  [726] = "efsctufR-R", [727] = "efsctsfR-R",
+  [728] = "efsctuizR-R", [730] = "efsctsizR-R",
+  [732] = "efststgtYRR", [733] = "efststltYRR", [734] = "efststeqYRR",
+
+  [736] = "efdaddRRR", [737] = "efdsubRRR",
+  [738] = "efdcfuidR-R", [739] = "efdcfsidR-R",
+  [740] = "efdabsRR", [741] = "efdnabsRR", [742] = "efdnegRR",
+  [744] = "efdmulRRR", [745] = "efddivRRR",
+  [746] = "efdctuidzR-R", [747] = "efdctsidzR-R",
+  [748] = "efdcmpgtYRR", [749] = "efdcmpltYRR", [750] = "efdcmpeqYRR",
+  [751] = "efdcfsR-R",
+  [752] = "efdcfuiR-R", [753] = "efdcfsiR-R",
+  [754] = "efdcfufR-R", [755] = "efdcfsfR-R",
+  [756] = "efdctuiR-R", [757] = "efdctsiR-R",
+  [758] = "efdctufR-R", [759] = "efdctsfR-R",
+  [760] = "efdctuizR-R", [762] = "efdctsizR-R",
+  [764] = "efdtstgtYRR", [765] = "efdtstltYRR", [766] = "efdtsteqYRR",
+
+  [768] = "evlddxRR0R", [769] = "evlddRR8",
+  [770] = "evldwxRR0R", [771] = "evldwRR8",
+  [772] = "evldhxRR0R", [773] = "evldhRR8",
+  [776] = "evlhhesplatxRR0R", [777] = "evlhhesplatRR2",
+  [780] = "evlhhousplatxRR0R", [781] = "evlhhousplatRR2",
+  [782] = "evlhhossplatxRR0R", [783] = "evlhhossplatRR2",
+  [784] = "evlwhexRR0R", [785] = "evlwheRR4",
+  [788] = "evlwhouxRR0R", [789] = "evlwhouRR4",
+  [790] = "evlwhosxRR0R", [791] = "evlwhosRR4",
+  [792] = "evlwwsplatxRR0R", [793] = "evlwwsplatRR4",
+  [796] = "evlwhsplatxRR0R", [797] = "evlwhsplatRR4",
+
+  [800] = "evstddxRR0R", [801] = "evstddRR8",
+  [802] = "evstdwxRR0R", [803] = "evstdwRR8",
+  [804] = "evstdhxRR0R", [805] = "evstdhRR8",
+  [816] = "evstwhexRR0R", [817] = "evstwheRR4",
+  [820] = "evstwhoxRR0R", [821] = "evstwhoRR4",
+  [824] = "evstwwexRR0R", [825] = "evstwweRR4",
+  [828] = "evstwwoxRR0R", [829] = "evstwwoRR4",
+
+  [1027] = "evmhessfRRR", [1031] = "evmhossfRRR", [1032] = "evmheumiRRR",
+  [1033] = "evmhesmiRRR", [1035] = "evmhesmfRRR", [1036] = "evmhoumiRRR",
+  [1037] = "evmhosmiRRR", [1039] = "evmhosmfRRR", [1059] = "evmhessfaRRR",
+  [1063] = "evmhossfaRRR", [1064] = "evmheumiaRRR", [1065] = "evmhesmiaRRR",
+  [1067] = "evmhesmfaRRR", [1068] = "evmhoumiaRRR", [1069] = "evmhosmiaRRR",
+  [1071] = "evmhosmfaRRR", [1095] = "evmwhssfRRR", [1096] = "evmwlumiRRR",
+  [1100] = "evmwhumiRRR", [1101] = "evmwhsmiRRR", [1103] = "evmwhsmfRRR",
+  [1107] = "evmwssfRRR", [1112] = "evmwumiRRR", [1113] = "evmwsmiRRR",
+  [1115] = "evmwsmfRRR", [1127] = "evmwhssfaRRR", [1128] = "evmwlumiaRRR",
+  [1132] = "evmwhumiaRRR", [1133] = "evmwhsmiaRRR", [1135] = "evmwhsmfaRRR",
+  [1139] = "evmwssfaRRR", [1144] = "evmwumiaRRR", [1145] = "evmwsmiaRRR",
+  [1147] = "evmwsmfaRRR",
+
+  [1216] = "evaddusiaawRR", [1217] = "evaddssiaawRR",
+  [1218] = "evsubfusiaawRR", [1219] = "evsubfssiaawRR",
+  [1220] = "evmraRR",
+  [1222] = "evdivwsRRR", [1223] = "evdivwuRRR",
+  [1224] = "evaddumiaawRR", [1225] = "evaddsmiaawRR",
+  [1226] = "evsubfumiaawRR", [1227] = "evsubfsmiaawRR",
+
+  [1280] = "evmheusiaawRRR", [1281] = "evmhessiaawRRR",
+  [1283] = "evmhessfaawRRR", [1284] = "evmhousiaawRRR",
+  [1285] = "evmhossiaawRRR", [1287] = "evmhossfaawRRR",
+  [1288] = "evmheumiaawRRR", [1289] = "evmhesmiaawRRR",
+  [1291] = "evmhesmfaawRRR", [1292] = "evmhoumiaawRRR",
+  [1293] = "evmhosmiaawRRR", [1295] = "evmhosmfaawRRR",
+  [1320] = "evmhegumiaaRRR", [1321] = "evmhegsmiaaRRR",
+  [1323] = "evmhegsmfaaRRR", [1324] = "evmhogumiaaRRR",
+  [1325] = "evmhogsmiaaRRR", [1327] = "evmhogsmfaaRRR",
+  [1344] = "evmwlusiaawRRR", [1345] = "evmwlssiaawRRR",
+  [1352] = "evmwlumiaawRRR", [1353] = "evmwlsmiaawRRR",
+  [1363] = "evmwssfaaRRR", [1368] = "evmwumiaaRRR",
+  [1369] = "evmwsmiaaRRR", [1371] = "evmwsmfaaRRR",
+  [1408] = "evmheusianwRRR", [1409] = "evmhessianwRRR",
+  [1411] = "evmhessfanwRRR", [1412] = "evmhousianwRRR",
+  [1413] = "evmhossianwRRR", [1415] = "evmhossfanwRRR",
+  [1416] = "evmheumianwRRR", [1417] = "evmhesmianwRRR",
+  [1419] = "evmhesmfanwRRR", [1420] = "evmhoumianwRRR",
+  [1421] = "evmhosmianwRRR", [1423] = "evmhosmfanwRRR",
+  [1448] = "evmhegumianRRR", [1449] = "evmhegsmianRRR",
+  [1451] = "evmhegsmfanRRR", [1452] = "evmhogumianRRR",
+  [1453] = "evmhogsmianRRR", [1455] = "evmhogsmfanRRR",
+  [1472] = "evmwlusianwRRR", [1473] = "evmwlssianwRRR",
+  [1480] = "evmwlumianwRRR", [1481] = "evmwlsmianwRRR",
+  [1491] = "evmwssfanRRR", [1496] = "evmwumianRRR",
+  [1497] = "evmwsmianRRR", [1499] = "evmwsmfanRRR",
+}
+
+local map_pri = {
+  [0] = false,	false,		"tdiARI",	"twiARI",
+  map_spe,	false,		false,		"mulliRRI",
+  "subficRRI",	false,		"cmpl_iYLRU",	"cmp_iYLRI",
+  "addicRRI",	"addic.RRI",	"addi|liRR0I",	"addis|lisRR0I",
+  "b_KBJ",	"sc",		 "bKJ",		map_crops,
+  "rlwimiRR~AAA.", map_rlwinm,	false,		"rlwnmRR~RAA.",
+  "oriNRR~U",	"orisRR~U",	"xoriRR~U",	"xorisRR~U",
+  "andi.RR~U",	"andis.RR~U",	map_rld,	map_ext,
+  "lwzRRD",	"lwzuRRD",	"lbzRRD",	"lbzuRRD",
+  "stwRRD",	"stwuRRD",	"stbRRD",	"stbuRRD",
+  "lhzRRD",	"lhzuRRD",	"lhaRRD",	"lhauRRD",
+  "sthRRD",	"sthuRRD",	"lmwRRD",	"stmwRRD",
+  "lfsFRD",	"lfsuFRD",	"lfdFRD",	"lfduFRD",
+  "stfsFRD",	"stfsuFRD",	"stfdFRD",	"stfduFRD",
+  false,	false,		map_ld,		map_fps,
+  false,	false,		map_std,	map_fpd,
+}
+
+------------------------------------------------------------------------------
+
+local map_gpr = {
+  [0] = "r0", "sp", "r2", "r3", "r4", "r5", "r6", "r7",
+  "r8", "r9", "r10", "r11", "r12", "r13", "r14", "r15",
+  "r16", "r17", "r18", "r19", "r20", "r21", "r22", "r23",
+  "r24", "r25", "r26", "r27", "r28", "r29", "r30", "r31",
+}
+
+local map_cond = { [0] = "lt", "gt", "eq", "so", "ge", "le", "ne", "ns", }
+
+-- Format a condition bit.
+local function condfmt(cond)
+  if cond <= 3 then
+    return map_cond[band(cond, 3)]
+  else
+    return format("4*cr%d+%s", rshift(cond, 2), map_cond[band(cond, 3)])
+  end
+end
+
+------------------------------------------------------------------------------
+
+-- Output a nicely formatted line with an opcode and operands.
+local function putop(ctx, text, operands)
+  local pos = ctx.pos
+  local extra = ""
+  if ctx.rel then
+    local sym = ctx.symtab[ctx.rel]
+    if sym then extra = "\t->"..sym end
+  end
+  if ctx.hexdump > 0 then
+    ctx.out(format("%08x  %s  %-7s %s%s\n",
+	    ctx.addr+pos, tohex(ctx.op), text, concat(operands, ", "), extra))
+  else
+    ctx.out(format("%08x  %-7s %s%s\n",
+	    ctx.addr+pos, text, concat(operands, ", "), extra))
+  end
+  ctx.pos = pos + 4
+end
+
+-- Fallback for unknown opcodes.
+local function unknown(ctx)
+  return putop(ctx, ".long", { "0x"..tohex(ctx.op) })
+end
+
+-- Disassemble a single instruction.
+local function disass_ins(ctx)
+  local pos = ctx.pos
+  local b0, b1, b2, b3 = byte(ctx.code, pos+1, pos+4)
+  local op = bor(lshift(b0, 24), lshift(b1, 16), lshift(b2, 8), b3)
+  local operands = {}
+  local last = nil
+  local rs = 21
+  ctx.op = op
+  ctx.rel = nil
+
+  local opat = map_pri[rshift(b0, 2)]
+  while type(opat) ~= "string" do
+    if not opat then return unknown(ctx) end
+    opat = opat[band(rshift(op, opat.shift), opat.mask)]
+  end
+  local name, pat = match(opat, "^([a-z0-9_.]*)(.*)")
+  local altname, pat2 = match(pat, "|([a-z0-9_.]*)(.*)")
+  if altname then pat = pat2 end
+
+  for p in gmatch(pat, ".") do
+    local x = nil
+    if p == "R" then
+      x = map_gpr[band(rshift(op, rs), 31)]
+      rs = rs - 5
+    elseif p == "F" then
+      x = "f"..band(rshift(op, rs), 31)
+      rs = rs - 5
+    elseif p == "A" then
+      x = band(rshift(op, rs), 31)
+      rs = rs - 5
+    elseif p == "S" then
+      x = arshift(lshift(op, 27-rs), 27)
+      rs = rs - 5
+    elseif p == "I" then
+      x = arshift(lshift(op, 16), 16)
+    elseif p == "U" then
+      x = band(op, 0xffff)
+    elseif p == "D" or p == "E" then
+      local disp = arshift(lshift(op, 16), 16)
+      if p == "E" then disp = band(disp, -4) end
+      if last == "r0" then last = "0" end
+      operands[#operands] = format("%d(%s)", disp, last)
+    elseif p >= "2" and p <= "8" then
+      local disp = band(rshift(op, rs), 31) * p
+      if last == "r0" then last = "0" end
+      operands[#operands] = format("%d(%s)", disp, last)
+    elseif p == "H" then
+      x = band(rshift(op, rs), 31) + lshift(band(op, 2), 4)
+      rs = rs - 5
+    elseif p == "M" then
+      x = band(rshift(op, rs), 31) + band(op, 0x20)
+    elseif p == "C" then
+      x = condfmt(band(rshift(op, rs), 31))
+      rs = rs - 5
+    elseif p == "B" then
+      local bo = rshift(op, 21)
+      local cond = band(rshift(op, 16), 31)
+      local cn = ""
+      rs = rs - 10
+      if band(bo, 4) == 0 then
+	cn = band(bo, 2) == 0 and "dnz" or "dz"
+	if band(bo, 0x10) == 0 then
+	  cn = cn..(band(bo, 8) == 0 and "f" or "t")
+	end
+	if band(bo, 0x10) == 0 then x = condfmt(cond) end
+	name = name..(band(bo, 1) == band(rshift(op, 15), 1) and "-" or "+")
+      elseif band(bo, 0x10) == 0 then
+	cn = map_cond[band(cond, 3) + (band(bo, 8) == 0 and 4 or 0)]
+	if cond > 3 then x = "cr"..rshift(cond, 2) end
+	name = name..(band(bo, 1) == band(rshift(op, 15), 1) and "-" or "+")
+      end
+      name = gsub(name, "_", cn)
+    elseif p == "J" then
+      x = arshift(lshift(op, 27-rs), 29-rs)*4
+      if band(op, 2) == 0 then x = ctx.addr + pos + x end
+      ctx.rel = x
+      x = "0x"..tohex(x)
+    elseif p == "K" then
+      if band(op, 1) ~= 0 then name = name.."l" end
+      if band(op, 2) ~= 0 then name = name.."a" end
+    elseif p == "X" or p == "Y" then
+      x = band(rshift(op, rs+2), 7)
+      if x == 0 and p == "Y" then x = nil else x = "cr"..x end
+      rs = rs - 5
+    elseif p == "W" then
+      x = "cr"..band(op, 7)
+    elseif p == "Z" then
+      x = band(rshift(op, rs-4), 255)
+      rs = rs - 10
+    elseif p == ">" then
+      operands[#operands] = rshift(operands[#operands], 1)
+    elseif p == "0" then
+      if last == "r0" then
+	operands[#operands] = nil
+	if altname then name = altname end
+      end
+    elseif p == "L" then
+      name = gsub(name, "_", band(op, 0x00200000) ~= 0 and "d" or "w")
+    elseif p == "." then
+      if band(op, 1) == 1 then name = name.."." end
+    elseif p == "N" then
+      if op == 0x60000000 then name = "nop"; break end
+    elseif p == "~" then
+      local n = #operands
+      operands[n-1],  operands[n] = operands[n], operands[n-1]
+    elseif p == "=" then
+      local n = #operands
+      if last == operands[n-1] then
+	operands[n] = nil
+	name = altname
+      end
+    elseif p == "%" then
+      local n = #operands
+      if last == operands[n-1] and last == operands[n-2] then
+	operands[n] = nil
+	operands[n-1] = nil
+	name = altname
+      end
+    elseif p == "-" then
+      rs = rs - 5
+    else
+      assert(false)
+    end
+    if x then operands[#operands+1] = x; last = x end
+  end
+
+  return putop(ctx, name, operands)
+end
+
+------------------------------------------------------------------------------
+
+-- Disassemble a block of code.
+local function disass_block(ctx, ofs, len)
+  if not ofs then ofs = 0 end
+  local stop = len and ofs+len or #ctx.code
+  stop = stop - stop % 4
+  ctx.pos = ofs - ofs % 4
+  ctx.rel = nil
+  while ctx.pos < stop do disass_ins(ctx) end
+end
+
+-- Extended API: create a disassembler context. Then call ctx:disass(ofs, len).
+local function create_(code, addr, out)
+  local ctx = {}
+  ctx.code = code
+  ctx.addr = addr or 0
+  ctx.out = out or io.write
+  ctx.symtab = {}
+  ctx.disass = disass_block
+  ctx.hexdump = 8
+  return ctx
+end
+
+-- Simple API: disassemble code (a string) at address and output via out.
+local function disass_(code, addr, out)
+  create_(code, addr, out):disass()
+end
+
+-- Return register name for RID.
+local function regname_(r)
+  if r < 32 then return map_gpr[r] end
+  return "f"..(r-32)
+end
+
+-- Public module functions.
+module(...)
+
+create = create_
+disass = disass_
+regname = regname_
+
diff --git a/third_party/luajit/lib/dis_x64.lua b/third_party/luajit/lib/dis_x64.lua
index 6ba4914306c692a6c789f45c8bb7b085c7238716..8c9cb4fa3b628b4637cedbcdc0699d3ed514ec8c 100644
--- a/third_party/luajit/lib/dis_x64.lua
+++ b/third_party/luajit/lib/dis_x64.lua
@@ -2,7 +2,7 @@
 -- LuaJIT x64 disassembler wrapper module.
 --
 -- Copyright (C) 2005-2011 Mike Pall. All rights reserved.
--- Released under the MIT/X license. See Copyright Notice in luajit.h
+-- Released under the MIT license. See Copyright Notice in luajit.h
 ----------------------------------------------------------------------------
 -- This module just exports the 64 bit functions from the combined
 -- x86/x64 disassembler module. All the interesting stuff is there.
diff --git a/third_party/luajit/lib/dis_x86.lua b/third_party/luajit/lib/dis_x86.lua
index f489a861238f054058e1e6cb8d4a8d73409e694a..d9a1f32134160bce7dbf783f9d63524351a15eaf 100644
--- a/third_party/luajit/lib/dis_x86.lua
+++ b/third_party/luajit/lib/dis_x86.lua
@@ -2,7 +2,7 @@
 -- LuaJIT x86/x64 disassembler module.
 --
 -- Copyright (C) 2005-2011 Mike Pall. All rights reserved.
--- Released under the MIT/X license. See Copyright Notice in luajit.h
+-- Released under the MIT license. See Copyright Notice in luajit.h
 ----------------------------------------------------------------------------
 -- This is a helper module used by the LuaJIT machine code dumper module.
 --
diff --git a/third_party/luajit/lib/dump.lua b/third_party/luajit/lib/dump.lua
index 5f32eb80f4457b399fe2d47b0c33db32c82b2874..0f0e9058e24e129a9f2c58b7e305adb749094292 100644
--- a/third_party/luajit/lib/dump.lua
+++ b/third_party/luajit/lib/dump.lua
@@ -2,7 +2,7 @@
 -- LuaJIT compiler dump module.
 --
 -- Copyright (C) 2005-2011 Mike Pall. All rights reserved.
--- Released under the MIT/X license. See Copyright Notice in luajit.h
+-- Released under the MIT license. See Copyright Notice in luajit.h
 ----------------------------------------------------------------------------
 --
 -- This module can be used to debug the JIT compiler itself. It dumps the
@@ -76,20 +76,43 @@ local active, out, dumpmode
 
 ------------------------------------------------------------------------------
 
+local symtabmt = { __index = false }
 local symtab = {}
 local nexitsym = 0
 
--- Fill symbol table with trace exit addresses.
-local function fillsymtab(nexit)
+-- Fill nested symbol table with per-trace exit stub addresses.
+local function fillsymtab_tr(tr, nexit)
+  local t = {}
+  symtabmt.__index = t
+  for i=0,nexit-1 do
+    local addr = traceexitstub(tr, i)
+    t[addr] = tostring(i)
+  end
+  local addr = traceexitstub(tr, nexit)
+  if addr then t[addr] = "stack_check" end
+end
+
+-- Fill symbol table with trace exit stub addresses.
+local function fillsymtab(tr, nexit)
   local t = symtab
   if nexitsym == 0 then
     local ircall = vmdef.ircall
-    for i=0,#ircall do t[ircalladdr(i)] = ircall[i] end
+    for i=0,#ircall do
+      local addr = ircalladdr(i)
+      if addr ~= 0 then t[addr] = ircall[i] end
+    end
   end
-  if nexit > nexitsym then
+  if nexitsym == 1000000 then -- Per-trace exit stubs.
+    fillsymtab_tr(tr, nexit)
+  elseif nexit > nexitsym then -- Shared exit stubs.
     for i=nexitsym,nexit-1 do
       local addr = traceexitstub(i)
-      if addr == nil then nexit = 1000000; break end
+      if addr == nil then -- Fall back to per-trace exit stubs.
+	fillsymtab_tr(tr, nexit)
+	setmetatable(symtab, symtabmt)
+	nexit = 1000000
+	break
+      end
       t[addr] = tostring(i)
     end
     nexitsym = nexit
@@ -111,7 +134,7 @@ local function dump_mcode(tr)
   out:write("---- TRACE ", tr, " mcode ", #mcode, "\n")
   local ctx = disass.create(mcode, addr, dumpwrite)
   ctx.hexdump = 0
-  ctx.symtab = fillsymtab(info.nexit)
+  ctx.symtab = fillsymtab(tr, info.nexit)
   if loop ~= 0 then
     symtab[addr+loop] = "LOOP"
     ctx:disass(0, loop)
@@ -355,6 +378,24 @@ local function ridsp_name(ridsp)
   return ""
 end
 
+-- Dump CALL* function ref and return optional ctype.
+local function dumpcallfunc(tr, ins)
+  local ctype
+  if ins > 0 then
+    local m, ot, op1, op2 = traceir(tr, ins)
+    if band(ot, 31) == 0 then -- nil type means CARG(func, ctype).
+      ins = op1
+      ctype = formatk(tr, op2)
+    end
+  end
+  if ins < 0 then
+    out:write(format("[0x%x](", tonumber((tracek(tr, ins)))))
+  else
+    out:write(format("%04d (", ins))
+  end
+  return ctype
+end
+
 -- Recursively gather CALL* args and dump them.
 local function dumpcallargs(tr, ins)
   if ins < 0 then
@@ -424,15 +465,15 @@ local function dump_ir(tr, dumpsnap, dumpreg)
 		       irtype[t], op))
       local m1, m2 = band(m, 3), band(m, 3*4)
       if sub(op, 1, 4) == "CALL" then
+	local ctype
 	if m2 == 1*4 then -- op2 == IRMlit
 	  out:write(format("%-10s  (", vmdef.ircall[op2]))
-	elseif op2 < 0 then
-	  out:write(format("[0x%x](", tonumber((tracek(tr, op2)))))
 	else
-	  out:write(format("%04d (", op2))
+	  ctype = dumpcallfunc(tr, op2)
 	end
 	if op1 ~= -1 then dumpcallargs(tr, op1) end
 	out:write(")")
+	if ctype then out:write(" ctype ", ctype) end
       elseif op == "CNEW  " and op2 == -1 then
 	out:write(formatk(tr, op1))
       elseif m1 ~= 3 then -- op1 != IRMnone
@@ -504,13 +545,15 @@ local function dump_trace(what, tr, func, pc, otr, oex)
     if what == "abort" then
       out:write(" ", fmtfunc(func, pc), " -- ", fmterr(otr, oex), "\n")
     else
-      local link = traceinfo(tr).link
-      if link == tr then
-	link = "loop"
-      elseif link == 0 then
-	link = "interpreter"
+      local info = traceinfo(tr)
+      local link, ltype = info.link, info.linktype
+      if link == tr or link == 0 then
+	out:write(" -> ", ltype, "\n")
+      elseif ltype == "root" then
+	out:write(" -> ", link, "\n")
+      else
+	out:write(" -> ", link, " ", ltype, "\n")
       end
-      out:write(" -> ", link, "\n")
     end
     if dumpmode.H then out:write("</pre>\n\n") else out:write("\n") end
   else
diff --git a/third_party/luajit/lib/v.lua b/third_party/luajit/lib/v.lua
index bf61f1253e3daee858ba8cf4a9d1433d3be083f2..ca9b4ac8c2e0a3c1d450e50bcf95d44504cddf8f 100644
--- a/third_party/luajit/lib/v.lua
+++ b/third_party/luajit/lib/v.lua
@@ -2,7 +2,7 @@
 -- Verbose mode of the LuaJIT compiler.
 --
 -- Copyright (C) 2005-2011 Mike Pall. All rights reserved.
--- Released under the MIT/X license. See Copyright Notice in luajit.h
+-- Released under the MIT license. See Copyright Notice in luajit.h
 ----------------------------------------------------------------------------
 --
 -- This module shows verbose information about the progress of the
@@ -22,7 +22,7 @@
 --
 -- The output from the first example should look like this:
 --
--- [TRACE   1 (command line):1]
+-- [TRACE   1 (command line):1 loop]
 -- [TRACE   2 (1/3) (command line):1 -> 1]
 --
 -- The first number in each line is the internal trace number. Next are
@@ -111,15 +111,20 @@ local function dump_trace(what, tr, func, pc, otr, oex)
 	  startex, startloc, fmterr(otr, oex)))
       end
     elseif what == "stop" then
-      local link = traceinfo(tr).link
-      if link == 0 then
+      local info = traceinfo(tr)
+      local link, ltype = info.link, info.linktype
+      if ltype == "interpreter" then
 	out:write(format("[TRACE %3s %s%s -- fallback to interpreter]\n",
 	  tr, startex, startloc))
-      elseif link == tr then
-	out:write(format("[TRACE %3s %s%s]\n", tr, startex, startloc))
-      else
+      elseif link == tr or link == 0 then
+	out:write(format("[TRACE %3s %s%s %s]\n",
+	  tr, startex, startloc, ltype))
+      elseif ltype == "root" then
 	out:write(format("[TRACE %3s %s%s -> %d]\n",
 	  tr, startex, startloc, link))
+      else
+	out:write(format("[TRACE %3s %s%s -> %d %s]\n",
+	  tr, startex, startloc, link, ltype))
       end
     else
       out:write(format("[TRACE %s]\n", what))
diff --git a/third_party/luajit/src/Makefile b/third_party/luajit/src/Makefile
index dcf553011e8c8ff632aacef90794c0d6534dc0f2..81043b877d65c772bd2e9f6372c26ce92f04d033 100644
--- a/third_party/luajit/src/Makefile
+++ b/third_party/luajit/src/Makefile
@@ -53,6 +53,7 @@ CCOPT= -O2 -fomit-frame-pointer
 CCOPT_X86= -march=i686
 CCOPT_X64=
 CCOPT_ARM=
+CCOPT_PPC=
 CCOPT_PPCSPE=
 #
 CCDEBUG=
@@ -72,7 +73,7 @@ CCWARN= -Wall
 # as dynamic mode.
 #
 # Mixed mode creates a static + dynamic library and a statically linked luajit.
-BUILDMODE= static
+BUILDMODE= mixed
 #
 # Static mode creates a static library and a statically linked luajit.
 #BUILDMODE= static
@@ -118,6 +119,12 @@ XCFLAGS=
 # interpreter. Don't bother if your OS wouldn't run on them, anyway.
 #XCFLAGS+= -DLUAJIT_CPU_NOCMOV
 #
+# Some architectures (e.g. PPC) can use either single-number (1) or
+# dual-number (2) mode. Uncomment one of these lines to override the
+# default mode. Please see LJ_ARCH_NUMMODE in lj_arch.h for details.
+#XCFLAGS+= -DLUAJIT_NUMMODE=1
+#XCFLAGS+= -DLUAJIT_NUMMODE=2
+#
 ##############################################################################
 
 ##############################################################################
@@ -199,7 +206,8 @@ TARGET_AR= $(CROSS)ar rcus
 TARGET_STRIP= $(CROSS)strip
 
 TARGET_SONAME= libluajit-$(ABIVER).so.$(MAJVER)
-TARGET_DYLIBNAME= libluajit-$(NODOTABIVER).$(MAJVER).$(MINVER).$(RELVER).dylib
+TARGET_DYLIBNAME= libluajit-$(NODOTABIVER).$(MAJVER).dylib
+TARGET_DYLIBPATH= $(or $(PREFIX),/usr/local)/lib/$(TARGET_DYLIBNAME)
 TARGET_DLLNAME= lua$(NODOTABIVER).dll
 TARGET_XSHLDFLAGS= -shared -fPIC -Wl,-soname,$(TARGET_SONAME)
 TARGET_DYNXLDOPTS=
@@ -229,6 +237,10 @@ ifneq (,$(findstring LJ_TARGET_ARM ,$(TARGET_TESTARCH)))
   TARGET_CCARCH= arm
   TARGET_XCFLAGS+= $(CCOPT_ARM)
 else
+ifneq (,$(findstring LJ_TARGET_PPC ,$(TARGET_TESTARCH)))
+  TARGET_CCARCH= ppc
+  TARGET_XCFLAGS+= $(CCOPT_PPC)
+else
 ifneq (,$(findstring LJ_TARGET_PPCSPE ,$(TARGET_TESTARCH)))
   TARGET_CCARCH= ppcspe
   TARGET_XCFLAGS+= $(CCOPT_PPCSPE)
@@ -238,6 +250,7 @@ endif
 endif
 endif
 endif
+endif
 
 ifneq (,$(PREFIX))
 ifneq (/usr/local,$(PREFIX))
@@ -275,10 +288,8 @@ ifeq (Darwin,$(TARGET_SYS))
   TARGET_STRIP+= -x
   TARGET_AR+= 2>/dev/null
   TARGET_XSHLDFLAGS= -dynamiclib -single_module -undefined dynamic_lookup -fPIC
-  ifneq (,$(TARGET_DYNXLDOPTS))
-    TARGET_DYNXLDOPTS=
-    TARGET_XSHLDFLAGS+= -install_name $(PREFIX)/lib/$(TARGET_DYLIBNAME)
-  endif
+  TARGET_DYNXLDOPTS=
+  TARGET_XSHLDFLAGS+= -install_name $(TARGET_DYLIBPATH) -compatibility_version $(MAJVER).$(MINVER) -current_version $(MAJVER).$(MINVER).$(RELVER)
   ifeq (x64,$(TARGET_CCARCH))
     TARGET_XLDFLAGS+= -pagezero_size 10000 -image_base 100000000
     TARGET_XSHLDFLAGS+= -image_base 7fff04c4a000
@@ -288,10 +299,8 @@ ifeq (iOS,$(TARGET_SYS))
   TARGET_STRIP+= -x
   TARGET_AR+= 2>/dev/null
   TARGET_XSHLDFLAGS= -dynamiclib -single_module -undefined dynamic_lookup -fPIC
-  ifneq (,$(TARGET_DYNXLDOPTS))
-    TARGET_DYNXLDOPTS=
-    TARGET_XSHLDFLAGS+= -install_name $(PREFIX)/lib/$(TARGET_DYLIBNAME)
-  endif
+  TARGET_DYNXLDOPTS=
+  TARGET_XSHLDFLAGS+= -install_name $(TARGET_DYLIBPATH) -compatibility_version $(MAJVER).$(MINVER) -current_version $(MAJVER).$(MINVER).$(RELVER)
 else
   ifneq (SunOS,$(TARGET_SYS))
     TARGET_XLDFLAGS+= -Wl,-E
@@ -342,7 +351,8 @@ DASM_FLAGS_X86=
 DASM_FLAGS_X64= -D X64
 DASM_FLAGS_X64WIN= -D X64 -D X64WIN
 DASM_FLAGS_ARM=
-DASM_FLAGS_PPCSPE= -D SPE
+DASM_FLAGS_PPC=
+DASM_FLAGS_PPCSPE=
 
 BUILDVM_O= buildvm.o buildvm_asm.o buildvm_peobj.o buildvm_lib.o buildvm_fold.o
 BUILDVM_T= buildvm
@@ -368,8 +378,8 @@ LJCORE_O= lj_gc.o lj_err.o lj_char.o lj_bc.o lj_obj.o \
 	  lj_opt_dce.o lj_opt_loop.o lj_opt_split.o \
 	  lj_mcode.o lj_snap.o lj_record.o lj_crecord.o lj_ffrecord.o \
 	  lj_asm.o lj_trace.o lj_gdbjit.o \
-	  lj_ctype.o lj_cdata.o lj_cconv.o lj_ccall.o lj_carith.o lj_clib.o \
-	  lj_cparse.o \
+	  lj_ctype.o lj_cdata.o lj_cconv.o lj_ccall.o lj_ccallback.o \
+	  lj_carith.o lj_clib.o lj_cparse.o \
 	  lj_lib.o lj_alloc.o lib_aux.o \
 	  $(LJLIB_O) lib_init.o
 
@@ -388,7 +398,7 @@ ALL_T= $(LUAJIT_T) $(LUAJIT_A) $(LUAJIT_SO) $(BUILDVM_T)
 ALL_HDRGEN= lj_bcdef.h lj_ffdef.h lj_libdef.h lj_recdef.h lj_folddef.h
 ALL_GEN= $(LJVM_S) $(ALL_HDRGEN) $(LIB_VMDEFP)
 ALL_DYNGEN= buildvm_x86.h buildvm_x64.h buildvm_x64win.h buildvm_arm.h \
-	    buildvm_ppcspe.h
+	    buildvm_ppc.h buildvm_ppcspe.h
 WIN_RM= *.obj *.lib *.exp *.dll *.exe *.manifest *.pdb *.ilk
 ALL_RM= $(ALL_T) $(ALL_GEN) *.o $(WIN_RM)
 
@@ -479,7 +489,8 @@ distclean:	clean
 	$(Q)$(DASM) $(DASM_DISTFLAGS) $(DASM_FLAGS_X64) -o buildvm_x64.h buildvm_x86.dasc
 	$(Q)$(DASM) $(DASM_DISTFLAGS) $(DASM_FLAGS_X64WIN) -o buildvm_x64win.h buildvm_x86.dasc
 	$(Q)$(DASM) $(DASM_DISTFLAGS) $(DASM_FLAGS_ARM) -o buildvm_arm.h buildvm_arm.dasc
-	$(Q)$(DASM) $(DASM_DISTFLAGS) $(DASM_FLAGS_PPCSPE) -o buildvm_ppcspe.h buildvm_ppc.dasc
+	$(Q)$(DASM) $(DASM_DISTFLAGS) $(DASM_FLAGS_PPC) -o buildvm_ppc.h buildvm_ppc.dasc
+	$(Q)$(DASM) $(DASM_DISTFLAGS) $(DASM_FLAGS_PPCSPE) -o buildvm_ppcspe.h buildvm_ppcspe.dasc
 
 depend:
 	@for file in $(ALL_HDRGEN) $(ALL_DYNGEN); do \
@@ -517,9 +528,13 @@ buildvm_arm.h: buildvm_arm.dasc
 	$(E) "DYNASM    $@"
 	$(Q)$(DASM) $(DASM_FLAGS) $(DASM_FLAGS_ARM) -o $@ buildvm_arm.dasc
 
-buildvm_ppcspe.h: buildvm_ppc.dasc
+buildvm_ppc.h: buildvm_ppc.dasc
+	$(E) "DYNASM    $@"
+	$(Q)$(DASM) $(DASM_FLAGS) $(DASM_FLAGS_PPC) -o $@ buildvm_ppc.dasc
+
+buildvm_ppcspe.h: buildvm_ppcspe.dasc
 	$(E) "DYNASM    $@"
-	$(Q)$(DASM) $(DASM_FLAGS) $(DASM_FLAGS_PPCSPE) -o $@ buildvm_ppc.dasc
+	$(Q)$(DASM) $(DASM_FLAGS) $(DASM_FLAGS_PPCSPE) -o $@ buildvm_ppcspe.dasc
 
 buildvm.o: $(ALL_DYNGEN) $(DASM_DIR)/dasm_*.h
 
diff --git a/third_party/luajit/src/Makefile.dep b/third_party/luajit/src/Makefile.dep
index 3a5667bcd967a9a9878f265ba29d3e01ac84ab94..add7508a4d799ffa7cd0a626937e6c148c522d80 100644
--- a/third_party/luajit/src/Makefile.dep
+++ b/third_party/luajit/src/Makefile.dep
@@ -1,6 +1,6 @@
 buildvm.o: buildvm.c buildvm.h lj_def.h lua.h luaconf.h lj_arch.h \
  lj_obj.h lj_gc.h lj_bc.h lj_ir.h lj_ircall.h lj_jit.h lj_frame.h \
- lj_dispatch.h lj_ccall.h luajit.h \
+ lj_dispatch.h lj_ctype.h lj_ccall.h luajit.h \
  lj_traceerr.h
 buildvm_asm.o: buildvm_asm.c buildvm.h lj_def.h lua.h luaconf.h lj_arch.h \
  lj_bc.h
@@ -23,7 +23,7 @@ lib_debug.o: lib_debug.c lua.h luaconf.h lauxlib.h lualib.h lj_obj.h \
 lib_ffi.o: lib_ffi.c lua.h luaconf.h lauxlib.h lualib.h lj_obj.h lj_def.h \
  lj_arch.h lj_gc.h lj_err.h lj_errmsg.h lj_str.h lj_tab.h lj_meta.h \
  lj_ctype.h lj_cparse.h lj_cdata.h lj_cconv.h lj_carith.h lj_ccall.h \
- lj_clib.h lj_ff.h lj_ffdef.h lj_lib.h lj_libdef.h
+ lj_ccallback.h lj_clib.h lj_ff.h lj_ffdef.h lj_lib.h lj_libdef.h
 lib_init.o: lib_init.c lua.h luaconf.h lauxlib.h lualib.h lj_arch.h
 lib_io.o: lib_io.c lua.h luaconf.h lauxlib.h lualib.h lj_obj.h lj_def.h \
  lj_arch.h lj_gc.h lj_err.h lj_errmsg.h lj_str.h lj_ff.h lj_ffdef.h \
@@ -69,11 +69,16 @@ lj_carith.o: lj_carith.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h \
  lj_gc.h lj_err.h lj_errmsg.h lj_tab.h lj_meta.h lj_ctype.h lj_cconv.h \
  lj_cdata.h lj_carith.h
 lj_ccall.o: lj_ccall.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h \
- lj_gc.h lj_err.h lj_errmsg.h lj_str.h lj_ctype.h lj_cconv.h lj_cdata.h \
- lj_ccall.h lj_trace.h lj_jit.h lj_ir.h lj_dispatch.h lj_bc.h \
+ lj_gc.h lj_err.h lj_errmsg.h lj_str.h lj_tab.h lj_ctype.h lj_cconv.h \
+ lj_cdata.h lj_ccall.h lj_trace.h lj_jit.h lj_ir.h lj_dispatch.h lj_bc.h \
  lj_traceerr.h
+lj_ccallback.o: lj_ccallback.c lj_obj.h lua.h luaconf.h lj_def.h \
+ lj_arch.h lj_gc.h lj_err.h lj_errmsg.h lj_tab.h lj_state.h lj_frame.h \
+ lj_bc.h lj_ctype.h lj_cconv.h lj_ccall.h lj_ccallback.h lj_target.h \
+ lj_target_*.h lj_mcode.h lj_jit.h lj_ir.h lj_vm.h
 lj_cconv.o: lj_cconv.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h \
- lj_err.h lj_errmsg.h lj_tab.h lj_ctype.h lj_gc.h lj_cdata.h lj_cconv.h
+ lj_err.h lj_errmsg.h lj_tab.h lj_ctype.h lj_gc.h lj_cdata.h lj_cconv.h \
+ lj_ccallback.h
 lj_cdata.o: lj_cdata.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h \
  lj_gc.h lj_err.h lj_errmsg.h lj_str.h lj_tab.h lj_ctype.h lj_cconv.h \
  lj_cdata.h
@@ -86,14 +91,14 @@ lj_cparse.o: lj_cparse.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h \
  lj_bc.h lj_vm.h lj_char.h
 lj_crecord.o: lj_crecord.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h \
  lj_err.h lj_errmsg.h lj_str.h lj_tab.h lj_frame.h lj_bc.h lj_ctype.h \
- lj_gc.h lj_cparse.h lj_cconv.h lj_clib.h lj_ir.h lj_jit.h lj_ircall.h \
- lj_iropt.h lj_trace.h lj_dispatch.h lj_traceerr.h lj_record.h \
- lj_ffrecord.h lj_crecord.h
+ lj_gc.h lj_cdata.h lj_cparse.h lj_cconv.h lj_clib.h lj_ccall.h lj_ir.h \
+ lj_jit.h lj_ircall.h lj_iropt.h lj_trace.h lj_dispatch.h lj_traceerr.h \
+ lj_record.h lj_ffrecord.h lj_snap.h lj_crecord.h
 lj_ctype.o: lj_ctype.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h \
- lj_gc.h lj_err.h lj_errmsg.h lj_str.h lj_tab.h lj_ctype.h
+ lj_gc.h lj_err.h lj_errmsg.h lj_str.h lj_tab.h lj_ctype.h lj_ccallback.h
 lj_debug.o: lj_debug.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h \
  lj_err.h lj_errmsg.h lj_debug.h lj_str.h lj_tab.h lj_state.h lj_frame.h \
- lj_bc.h
+ lj_bc.h lj_jit.h lj_ir.h
 lj_dispatch.o: lj_dispatch.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h \
  lj_err.h lj_errmsg.h lj_debug.h lj_state.h lj_frame.h lj_bc.h lj_ff.h \
  lj_ffdef.h lj_jit.h lj_ir.h lj_trace.h lj_dispatch.h lj_traceerr.h \
@@ -188,15 +193,15 @@ ljamalg.o: ljamalg.c lua.h luaconf.h lauxlib.h lj_gc.c lj_obj.h lj_def.h \
  lj_obj.c lj_str.c lj_tab.c lj_func.c lj_udata.c lj_meta.c lj_debug.c \
  lj_state.c lj_lex.h lj_alloc.h lj_dispatch.c luajit.h lj_vmevent.c \
  lj_vmevent.h lj_vmmath.c lj_api.c lj_bcdump.h lj_parse.h lj_lex.c \
- lualib.h lj_parse.c lj_bcread.c lj_bcwrite.c lj_ctype.c lj_cdata.c \
- lj_cconv.h lj_cconv.c lj_ccall.c lj_ccall.h lj_carith.c lj_carith.h \
- lj_clib.c lj_clib.h lj_cparse.c lj_cparse.h lj_lib.c lj_lib.h lj_ir.c \
- lj_ircall.h lj_iropt.h lj_opt_mem.c lj_opt_fold.c lj_folddef.h \
- lj_opt_narrow.c lj_opt_dce.c lj_opt_loop.c lj_snap.h lj_opt_split.c \
- lj_mcode.c lj_mcode.h lj_snap.c lj_target.h lj_target_*.h lj_record.c \
- lj_record.h lj_ffrecord.h lj_crecord.c lj_crecord.h lj_ffrecord.c \
- lj_recdef.h lj_asm.c lj_asm.h lj_emit_*.h lj_asm_*.h lj_trace.c \
- lj_gdbjit.h lj_gdbjit.c lj_alloc.c lib_aux.c lib_base.c lj_libdef.h \
- lib_math.c lib_string.c lib_table.c lib_io.c lib_os.c lib_package.c \
- lib_debug.c lib_bit.c lib_jit.c lib_ffi.c lib_init.c
+ lualib.h lj_parse.c lj_bcread.c lj_bcwrite.c lj_ctype.c lj_ccallback.h \
+ lj_cdata.c lj_cconv.h lj_cconv.c lj_ccall.c lj_ccall.h lj_ccallback.c \
+ lj_target.h lj_target_*.h lj_mcode.h lj_carith.c lj_carith.h lj_clib.c \
+ lj_clib.h lj_cparse.c lj_cparse.h lj_lib.c lj_lib.h lj_ir.c lj_ircall.h \
+ lj_iropt.h lj_opt_mem.c lj_opt_fold.c lj_folddef.h lj_opt_narrow.c \
+ lj_opt_dce.c lj_opt_loop.c lj_snap.h lj_opt_split.c lj_mcode.c lj_snap.c \
+ lj_record.c lj_record.h lj_ffrecord.h lj_crecord.c lj_crecord.h \
+ lj_ffrecord.c lj_recdef.h lj_asm.c lj_asm.h lj_emit_*.h lj_asm_*.h \
+ lj_trace.c lj_gdbjit.h lj_gdbjit.c lj_alloc.c lib_aux.c lib_base.c \
+ lj_libdef.h lib_math.c lib_string.c lib_table.c lib_io.c lib_os.c \
+ lib_package.c lib_debug.c lib_bit.c lib_jit.c lib_ffi.c lib_init.c
 luajit.o: luajit.c lua.h luaconf.h lauxlib.h lualib.h luajit.h lj_arch.h
diff --git a/third_party/luajit/src/buildvm.c b/third_party/luajit/src/buildvm.c
index 33f87a4b37ee95910c44e797a5eb45983357bb6e..3e5d7b1c0ea4abbc1cda3025890c49f7760f71cf 100644
--- a/third_party/luajit/src/buildvm.c
+++ b/third_party/luajit/src/buildvm.c
@@ -23,6 +23,7 @@
 #include "lj_frame.h"
 #include "lj_dispatch.h"
 #if LJ_HASFFI
+#include "lj_ctype.h"
 #include "lj_ccall.h"
 #endif
 #include "luajit.h"
@@ -67,6 +68,9 @@ static int collect_reloc(BuildCtx *ctx, uint8_t *addr, int idx, int type);
 #elif LJ_TARGET_ARM
 #include "../dynasm/dasm_arm.h"
 #include "buildvm_arm.h"
+#elif LJ_TARGET_PPC
+#include "../dynasm/dasm_ppc.h"
+#include "buildvm_ppc.h"
 #elif LJ_TARGET_PPCSPE
 #include "../dynasm/dasm_ppc.h"
 #include "buildvm_ppcspe.h"
@@ -268,7 +272,7 @@ IRFLDEF(FLNAME)
 };
 
 const char *const ircall_names[] = {
-#define IRCALLNAME(name, nargs, kind, type, flags)	#name,
+#define IRCALLNAME(cond, name, nargs, kind, type, flags)	#name,
 IRCALLDEF(IRCALLNAME)
 #undef IRCALLNAME
   NULL
diff --git a/third_party/luajit/src/buildvm_arm.dasc b/third_party/luajit/src/buildvm_arm.dasc
index fd7c7b8117f99d8c7037752ab0fc4755cbac9ef3..60857c08adab76e83d987e46a58fefbcd0bbbae7 100644
--- a/third_party/luajit/src/buildvm_arm.dasc
+++ b/third_party/luajit/src/buildvm_arm.dasc
@@ -185,23 +185,23 @@
 |
 #define PC2PROTO(field)  ((int)offsetof(GCproto, field)-(int)sizeof(GCproto))
 |
-|.macro hotcheck
+|.macro hotcheck, delta
 |  lsr CARG1, PC, #1
 |  and CARG1, CARG1, #126
 |  sub CARG1, CARG1, #-GG_DISP2HOT
 |  ldrh CARG2, [DISPATCH, CARG1]
-|  subs CARG2, CARG2, #1
+|  subs CARG2, CARG2, #delta
 |  strh CARG2, [DISPATCH, CARG1]
 |.endmacro
 |
 |.macro hotloop
-|  hotcheck
-|  beq ->vm_hotloop
+|  hotcheck HOTCOUNT_LOOP
+|  blo ->vm_hotloop
 |.endmacro
 |
 |.macro hotcall
-|  hotcheck
-|  beq ->vm_hotcall
+|  hotcheck HOTCOUNT_CALL
+|  blo ->vm_hotcall
 |.endmacro
 |
 |// Set current VM state.
@@ -502,22 +502,30 @@ static void build_subroutines(BuildCtx *ctx)
   |    ldr CARG1, [BASE, #-16]		// Get continuation.
   |   mov CARG4, BASE
   |   mov BASE, RB			// Restore caller BASE.
-  |    cmp CARG1, #0
+#if LJ_HASFFI
+  |    cmp CARG1, #1
+#endif
   |   ldr PC, [CARG4, #-12]		// Restore PC from [cont|PC].
-  |    beq >1
   |  ldr CARG3, LFUNC:CARG3->field_pc
   |    mvn INS, #~LJ_TNIL
   |    add CARG2, RA, RC
   |    str INS, [CARG2, #-4]		// Ensure one valid arg.
+#if LJ_HASFFI
+  |    bls >1
+#endif
   |  ldr KBASE, [CARG3, #PC2PROTO(k)]
   |  // BASE = base, RA = resultptr, CARG4 = meta base
-  |   bx CARG1
+  |    bx CARG1
   |
-  |1:  // Tail call from C function.
+#if LJ_HASFFI
+  |1:
+  |  beq ->cont_ffi_callback		// cont = 1: return from FFI callback.
+  |  // cont = 0: tailcall from C function.
   |  ldr CARG3, [BASE, FRAME_FUNC]
   |   sub CARG4, CARG4, #16
   |   sub RC, CARG4, BASE
   |  b ->vm_call_tail
+#endif
   |
   |->cont_cat:				// RA = resultptr, CARG4 = meta base
   |  ldr INS, [PC, #-4]
@@ -2178,7 +2186,52 @@ static void build_subroutines(BuildCtx *ctx)
   |//-- FFI helper functions -----------------------------------------------
   |//-----------------------------------------------------------------------
   |
-  |->vm_ffi_call:
+  |// Handler for callback functions.
+  |// Saveregs already performed. Callback slot number in [sp], g in r12.
+  |->vm_ffi_callback:
+#if LJ_HASFFI
+  |.type CTSTATE, CTState, PC
+  |  ldr CTSTATE, GL:r12->ctype_state
+  |   add DISPATCH, r12, #GG_G2DISP
+  |  strd CARG12, CTSTATE->cb.gpr[0]
+  |  strd CARG34, CTSTATE->cb.gpr[2]
+  |  ldr CARG4, [sp]
+  |   add CARG3, sp, #CFRAME_SIZE
+  |    mov CARG1, CTSTATE
+  |  lsr CARG4, CARG4, #3
+  |   str CARG3, CTSTATE->cb.stack
+  |    mov CARG2, sp
+  |  str CARG4, CTSTATE->cb.slot
+  |  str CTSTATE, SAVE_PC		// Any value outside of bytecode is ok.
+  |  bl extern lj_ccallback_enter	// (CTState *cts, void *cf)
+  |  // Returns lua_State *.
+  |  ldr BASE, L:CRET1->base
+  |    mv_vmstate CARG2, INTERP
+  |  ldr RC, L:CRET1->top
+  |    mov MASKR8, #255
+  |   ldr LFUNC:CARG3, [BASE, FRAME_FUNC]
+  |    mov L, CRET1
+  |  sub RC, RC, BASE
+  |    lsl MASKR8, MASKR8, #3		// MASKR8 = 255*8.
+  |    st_vmstate CARG2
+  |  ins_callt
+#endif
+  |
+  |->cont_ffi_callback:                 // Return from FFI callback.
+#if LJ_HASFFI
+  |  ldr CTSTATE, [DISPATCH, #DISPATCH_GL(ctype_state)]
+  |   str BASE, L->base
+  |   str CARG4, L->top
+  |  str L, CTSTATE->L
+  |  mov CARG1, CTSTATE
+  |  mov CARG2, RA
+  |  bl extern lj_ccallback_leave	// (CTState *cts, TValue *o)
+  |  ldrd CARG12, CTSTATE->cb.gpr[0]
+  |  b ->vm_leave_unw
+#endif
+  |
+  |->vm_ffi_call:			// Call C function via FFI.
+  |  // Caveat: needs special frame unwinding, see below.
 #if LJ_HASFFI
   |  .type CCSTATE, CCallState, r4
   |  push {CCSTATE, r5, r11, lr}
@@ -2207,6 +2260,7 @@ static void build_subroutines(BuildCtx *ctx)
   |  str CRET2, CCSTATE->gpr[1]
   |  pop {CCSTATE, r5, r11, pc}
 #endif
+  |// Note: vm_ffi_call must be the last function in this object file!
   |
   |//-----------------------------------------------------------------------
 }
@@ -3321,7 +3375,7 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |  b <1
     |
     |7:  // Possible table write barrier for any value. Skip valiswhite check.
-    |  barrierback TAB:RB, CARG1, CARG2
+    |  barrierback TAB:CARG2, CARG1, CARG3
     |  b <4
     break;
 
@@ -4003,6 +4057,7 @@ static int build_backend(BuildCtx *ctx)
 /* Emit pseudo frame-info for all assembler functions. */
 static void emit_asm_debug(BuildCtx *ctx)
 {
+  int fcofs = (int)((uint8_t *)ctx->glob[GLOB_vm_ffi_call] - ctx->code);
   int i;
   switch (ctx->mode) {
   case BUILD_elfasm:
@@ -4028,13 +4083,30 @@ static void emit_asm_debug(BuildCtx *ctx)
 	"\t.long .Lbegin\n"
 	"\t.long %d\n"
 	"\t.byte 0xe\n\t.uleb128 %d\n"		/* def_cfa_offset */
-	"\t.byte 0x8e\n\t.uleb128 1\n",		/* Restore lr. */
-	(int)ctx->codesz, CFRAME_SIZE);
-    for (i = 11; i >= 4; i--)  /* Restore r4-r11. */
+	"\t.byte 0x8e\n\t.uleb128 1\n",		/* offset lr */
+	fcofs, CFRAME_SIZE);
+    for (i = 11; i >= 4; i--)  /* offset r4-r11 */
       fprintf(ctx->fp, "\t.byte %d\n\t.uleb128 %d\n", 0x80+i, 2+(11-i));
     fprintf(ctx->fp,
 	"\t.align 2\n"
 	".LEFDE0:\n\n");
+#if LJ_HASFFI
+    fprintf(ctx->fp,
+	".LSFDE1:\n"
+	"\t.long .LEFDE1-.LASFDE1\n"
+	".LASFDE1:\n"
+	"\t.long .Lframe0\n"
+	"\t.long lj_vm_ffi_call\n"
+	"\t.long %d\n"
+	"\t.byte 0xe\n\t.uleb128 16\n"		/* def_cfa_offset */
+	"\t.byte 0x8e\n\t.uleb128 1\n"		/* offset lr */
+	"\t.byte 0x8b\n\t.uleb128 2\n"		/* offset r11 */
+	"\t.byte 0x85\n\t.uleb128 3\n"		/* offset r5 */
+	"\t.byte 0x84\n\t.uleb128 4\n"		/* offset r4 */
+	"\t.byte 0xd\n\t.uleb128 0xb\n"		/* def_cfa_register r11 */
+	"\t.align 2\n"
+	".LEFDE1:\n\n", (int)ctx->codesz - fcofs);
+#endif
     break;
   default:
     break;
diff --git a/third_party/luajit/src/buildvm_arm.h b/third_party/luajit/src/buildvm_arm.h
index 505048bd91c7db2970fa8c602b899d934558c144..9d26dd8ed908565e61c82264c8b666374ad6bbd9 100644
--- a/third_party/luajit/src/buildvm_arm.h
+++ b/third_party/luajit/src/buildvm_arm.h
@@ -12,7 +12,7 @@
 #define DASM_SECTION_CODE_OP	0
 #define DASM_SECTION_CODE_SUB	1
 #define DASM_MAXSECTION		2
-static const unsigned int build_actionlist[5702] = {
+static const unsigned int build_actionlist[5777] = {
 0x00010001,
 0x00060014,
 0xe3160000,
@@ -324,26 +324,34 @@ static const unsigned int build_actionlist[5702] = {
 0xe5190010,
 0xe1a03009,
 0xe1a0900c,
-0xe3500000,
+0x00000000,
+0xe3500001,
+0x00000000,
 0xe513600c,
-0x0a000000,
-0x00050001,
 0xe5122000,
 0x000d8180,
 0xe3e0e000,
 0x000a0000,
 0xe08a100b,
 0xe501e004,
+0x00000000,
+0x9a000000,
+0x00050001,
+0x00000000,
 0xe5125000,
 0x000d8180,
 0xe12fff10,
+0x00000000,
 0x0006000b,
+0x0a000000,
+0x00050028,
 0xe5192008,
 0xe2433010,
 0xe043b009,
 0xea000000,
-0x00050028,
-0x00060029,
+0x00050029,
+0x00000000,
+0x0006002a,
 0xe516e004,
 0xe2431010,
 0xe1ca20d0,
@@ -356,15 +364,15 @@ static const unsigned int build_actionlist[5702] = {
 0x11c120f0,
 0x11a02000,
 0x1a000000,
-0x0005002a,
+0x0005002b,
 0xe18920fa,
 0xea000000,
-0x0005002b,
-0x0006002c,
+0x0005002c,
+0x0006002d,
 0xe089100c,
 0xea000000,
 0x00050002,
-0x0006002d,
+0x0006002e,
 0xe2471000,
 0x000a0000,
 0xe3e03000,
@@ -379,7 +387,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0200d,
 0xea000000,
 0x00050001,
-0x0006002e,
+0x0006002f,
 0xe004caae,
 0xe58db000,
 0xe3e03000,
@@ -389,8 +397,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0200d,
 0xea000000,
 0x00050001,
-0x0006002f,
-0x00000000,
+0x00060030,
 0xe089100c,
 0xe089200b,
 0x0006000b,
@@ -426,11 +433,11 @@ static const unsigned int build_actionlist[5702] = {
 0xe5192008,
 0xea000000,
 0x00050026,
-0x00060030,
+0x00060031,
 0xe089100c,
 0xea000000,
 0x00050002,
-0x00060031,
+0x00060032,
 0xe2471000,
 0x000a0000,
 0xe3e03000,
@@ -445,7 +452,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0200d,
 0xea000000,
 0x00050001,
-0x00060032,
+0x00060033,
 0xe004caae,
 0xe58db000,
 0xe3e03000,
@@ -455,7 +462,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0200d,
 0xea000000,
 0x00050001,
-0x00060033,
+0x00060034,
 0xe089100c,
 0xe089200b,
 0x0006000b,
@@ -492,7 +499,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe5192008,
 0xea000000,
 0x00050026,
-0x00060034,
+0x00060035,
 0xe1a00008,
 0xe2466004,
 0xe1a0100a,
@@ -510,40 +517,40 @@ static const unsigned int build_actionlist[5702] = {
 0x00000000,
 0xe3500001,
 0x8a000000,
-0x00050035,
+0x00050036,
 0x0006000e,
 0xe1d6c0b2,
 0xe2866004,
 0xe086c10c,
 0x224c6b80,
-0x0006002b,
+0x0006002c,
 0xe5d6c000,
 0xe496e004,
 0xe797c10c,
 0xe004a2ae,
 0xe1a0b82e,
 0xe12fff1c,
-0x00060036,
+0x00060037,
 0xe516e004,
 0xe1ca00d0,
 0xe00422ae,
 0xe18900f2,
 0xea000000,
-0x0005002b,
-0x00060037,
+0x0005002c,
+0x00060038,
 0xe59a1004,
 0xe3e00000,
 0x000a0000,
 0xe1500001,
 0xea000000,
 0x0005000e,
-0x00060038,
+0x00060039,
 0xe59a1004,
 0xe3710000,
 0x000a0000,
 0xea000000,
 0x0005000e,
-0x00060039,
+0x0006003a,
 0xe2466004,
 0xe5089000,
 0x000d8180,
@@ -553,7 +560,7 @@ static const unsigned int build_actionlist[5702] = {
 0x00030004,
 0xea000000,
 0x0005000d,
-0x0006003a,
+0x0006003b,
 0x00000000,
 0xe2466004,
 0xe5089000,
@@ -566,28 +573,28 @@ static const unsigned int build_actionlist[5702] = {
 0xea000000,
 0x0005000d,
 0x00000000,
-0x0006003b,
+0x0006003c,
 0xe004caae,
 0xe004b6ae,
 0xe089200c,
 0xe085300b,
 0xea000000,
 0x00050001,
-0x0006003c,
+0x0006003d,
 0xe004caae,
 0xe004b6ae,
 0xe089300c,
 0xe085200b,
 0xea000000,
 0x00050001,
-0x0006003d,
+0x0006003e,
 0xe516e008,
 0xe2466004,
 0xe089200b,
 0xe089300b,
 0xea000000,
 0x00050001,
-0x0006003e,
+0x0006003f,
 0xe004caae,
 0xe004b6ae,
 0xe089200c,
@@ -608,8 +615,8 @@ static const unsigned int build_actionlist[5702] = {
 0x00000000,
 0xe3500000,
 0x0a000000,
-0x0005002b,
-0x00060035,
+0x0005002c,
+0x00060036,
 0xe0401009,
 0xe500600c,
 0xe2816000,
@@ -618,7 +625,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe3a0b010,
 0xea000000,
 0x00050024,
-0x0006003f,
+0x00060040,
 0xe089100b,
 0xe5089000,
 0x000d8180,
@@ -632,13 +639,13 @@ static const unsigned int build_actionlist[5702] = {
 0x00000000,
 0xe3500000,
 0x1a000000,
-0x00050035,
+0x00050036,
 0xe799000b,
 0xea000000,
-0x00050040,
+0x00050041,
 0x00000000,
 0xea000000,
-0x00050035,
+0x00050036,
 0x00000000,
 0x00060025,
 0xe1a00008,
@@ -666,7 +673,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe004a2ae,
 0xe08aa009,
 0xe12fff1c,
-0x00060041,
+0x00060042,
 0xe1a00008,
 0xe5089000,
 0x000d8180,
@@ -683,8 +690,8 @@ static const unsigned int build_actionlist[5702] = {
 0xe5196004,
 0xe28bb008,
 0xea000000,
-0x00050042,
-0x00060043,
+0x00050043,
+0x00060044,
 0xe1a00008,
 0xe5089000,
 0x000d8180,
@@ -711,22 +718,22 @@ static const unsigned int build_actionlist[5702] = {
 0x00000000,
 0xea000000,
 0x00070000,
-0x00060044,
+0x00060045,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x8a000000,
-0x00050045,
+0x00050046,
 0xe5196004,
 0xe14900f8,
 0xe1a0c009,
 0xe25ba008,
 0xe28bb008,
 0x0a000000,
-0x00050046,
+0x00050047,
 0x0006000b,
 0xe1cc00d8,
 0xe25aa008,
@@ -734,12 +741,12 @@ static const unsigned int build_actionlist[5702] = {
 0x1a000000,
 0x0005000b,
 0xea000000,
-0x00050046,
-0x00060047,
+0x00050047,
+0x00060048,
 0xe5991004,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x33e01000,
@@ -749,12 +756,12 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a03183,
 0xe18200d3,
 0xea000000,
-0x00050048,
-0x00060049,
+0x00050049,
+0x0006004a,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x13710000,
@@ -772,7 +779,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000d8180,
 0xe35c0000,
 0x0a000000,
-0x00050048,
+0x00050049,
 0xe51c2000,
 0x000d8180,
 0xe51b3000,
@@ -802,12 +809,12 @@ static const unsigned int build_actionlist[5702] = {
 0xe3e01000,
 0x000a0000,
 0xea000000,
-0x00050048,
+0x00050049,
 0x0006000f,
 0xe3710000,
 0x000a0000,
 0x1a000000,
-0x00050048,
+0x00050049,
 0xea000000,
 0x0005000e,
 0x00060010,
@@ -822,12 +829,12 @@ static const unsigned int build_actionlist[5702] = {
 0x000d8180,
 0xea000000,
 0x0005000c,
-0x0006004a,
+0x0006004b,
 0xe1c900d0,
 0xe1c920d8,
 0xe35b0010,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x0510c000,
@@ -838,13 +845,13 @@ static const unsigned int build_actionlist[5702] = {
 0x000d8180,
 0x035c0000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0xe3130000,
 0x000a0000,
 0xe5002000,
 0x000d8180,
 0x0a000000,
-0x00050048,
+0x00050049,
 0xe5172000,
 0x000d8180,
 0xe3c33000,
@@ -856,18 +863,18 @@ static const unsigned int build_actionlist[5702] = {
 0xe5002000,
 0x000d8180,
 0xea000000,
-0x00050048,
-0x0006004b,
+0x00050049,
+0x0006004c,
 0xe1c920d0,
 0xe35b0010,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe1a01002,
 0xe3730000,
 0x000a0000,
 0x00000000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0xe1a00008,
 0xe2892008,
 0x00000000,
@@ -880,27 +887,27 @@ static const unsigned int build_actionlist[5702] = {
 0x00000000,
 0xe1c000d0,
 0xea000000,
-0x00050048,
-0x0006004c,
+0x00050049,
+0x0006004d,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x9a000000,
-0x00050048,
+0x00050049,
 0xea000000,
-0x00050045,
-0x0006004d,
+0x00050046,
+0x0006004e,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x0a000000,
-0x00050048,
+0x00050049,
 0xe5173000,
 0x000d8180,
 0xe5089000,
@@ -910,14 +917,14 @@ static const unsigned int build_actionlist[5702] = {
 0x93530000,
 0xe58d6008,
 0x8a000000,
-0x00050045,
+0x00050046,
 0xe5170000,
 0x000d8180,
 0xe5171000,
 0x000d8180,
 0xe1500001,
 0xab000000,
-0x0005004e,
+0x0005004f,
 0xe1a00008,
 0xe1a01009,
 0xeb000000,
@@ -927,19 +934,19 @@ static const unsigned int build_actionlist[5702] = {
 0xe3e01000,
 0x000a0000,
 0xea000000,
-0x00050048,
-0x0006004f,
+0x00050049,
+0x00060050,
 0x00000000,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3e03000,
 0x000a0000,
 0xe3710000,
 0x000a0000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0xe18920fb,
 0xe5196004,
 0xe1a01000,
@@ -960,7 +967,7 @@ static const unsigned int build_actionlist[5702] = {
 0x03e01000,
 0x000a0000,
 0x0a000000,
-0x00050048,
+0x00050049,
 0xe1c900d8,
 0xe1c921d0,
 0xe3a0b000,
@@ -968,16 +975,16 @@ static const unsigned int build_actionlist[5702] = {
 0xe14900f8,
 0xe1c920f0,
 0xea000000,
-0x00050046,
-0x00060050,
+0x00050047,
+0x00060051,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe510c000,
 0x000d8180,
@@ -988,7 +995,7 @@ static const unsigned int build_actionlist[5702] = {
 0x00000000,
 0xe35c0000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe3e01000,
 0x000a0000,
@@ -997,19 +1004,19 @@ static const unsigned int build_actionlist[5702] = {
 0xe14920f8,
 0xe589100c,
 0xea000000,
-0x00050046,
-0x00060051,
+0x00050047,
+0x00060052,
 0xe1c900d0,
 0xe1c920d8,
 0xe35b0010,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x03730000,
 0x000a0000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0xe510c000,
 0x000d8180,
 0xe510b000,
@@ -1031,14 +1038,14 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x11c900f0,
 0xea000000,
-0x00050046,
+0x00050047,
 0x0006000c,
 0xe510c000,
 0x000d8180,
 0xe1a01002,
 0xe35c0000,
 0x0a000000,
-0x00050046,
+0x00050047,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -1049,19 +1056,19 @@ static const unsigned int build_actionlist[5702] = {
 0x00000000,
 0xe3500000,
 0x0a000000,
-0x00050046,
+0x00050047,
 0xe1c000d0,
 0xea000000,
 0x0005000b,
-0x00060052,
+0x00060053,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe510c000,
 0x000d8180,
@@ -1072,7 +1079,7 @@ static const unsigned int build_actionlist[5702] = {
 0x00000000,
 0xe35c0000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe3a00000,
 0xe3e01000,
@@ -1082,13 +1089,13 @@ static const unsigned int build_actionlist[5702] = {
 0xe14920f8,
 0xe1c900f8,
 0xea000000,
-0x00050046,
-0x00060053,
+0x00050047,
+0x00060054,
 0xe557a000,
 0x000d8180,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe31a0000,
 0x000a0000,
 0xe1a0c009,
@@ -1100,18 +1107,18 @@ static const unsigned int build_actionlist[5702] = {
 0xe24bb008,
 0xea000000,
 0x00050024,
-0x00060054,
+0x00060055,
 0xe1c900d0,
 0xe1c920d8,
 0xe35b0010,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe557a000,
 0x000d8180,
 0xe3730000,
 0x000a0000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0xe1a0c009,
 0xe1c900f8,
 0xe1c920f0,
@@ -1125,16 +1132,16 @@ static const unsigned int build_actionlist[5702] = {
 0xe24bb010,
 0xea000000,
 0x00050024,
-0x00060055,
+0x00060056,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x00000000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0xe5196004,
 0xe5089000,
 0x000d8180,
@@ -1149,7 +1156,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe58d6008,
 0xe153000c,
 0x0a000000,
-0x00050045,
+0x00050046,
 0xe5103000,
 0x000d8180,
 0xe510c000,
@@ -1159,7 +1166,7 @@ static const unsigned int build_actionlist[5702] = {
 0x91520003,
 0x935c0000,
 0x8a000000,
-0x00050045,
+0x00050046,
 0x0006000b,
 0xe2422008,
 0xe2899008,
@@ -1250,7 +1257,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe3a00000,
 0xea000000,
 0x0005000e,
-0x00060056,
+0x00060057,
 0x00000000,
 0xe5120000,
 0x000d8180,
@@ -1268,7 +1275,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe58d6008,
 0xe153000c,
 0x0a000000,
-0x00050045,
+0x00050046,
 0xe5103000,
 0x000d8180,
 0xe510c000,
@@ -1278,7 +1285,7 @@ static const unsigned int build_actionlist[5702] = {
 0x91520003,
 0x935c0000,
 0x8a000000,
-0x00050045,
+0x00050046,
 0x0006000b,
 0xe5002000,
 0x000d8180,
@@ -1356,7 +1363,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe3a00000,
 0xea000000,
 0x0005000e,
-0x00060057,
+0x00060058,
 0xe5180000,
 0x000d8180,
 0xe089100b,
@@ -1371,24 +1378,24 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0xe3a02000,
 0x0a000000,
-0x00050045,
+0x00050046,
 0xe5082000,
 0x000d8180,
 0xe5480000,
 0x000d8180,
 0xea000000,
 0x0005001a,
-0x00060058,
+0x00060059,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x0a000000,
-0x00050048,
+0x00050049,
 0x8a000000,
-0x00050045,
+0x00050046,
 0xe1a02081,
 0xe292c980,
 0x5a000000,
@@ -1412,7 +1419,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe3e01000,
 0x000a0000,
 0xea000000,
-0x00050048,
+0x00050049,
 0x0006000c,
 0xe1822000,
 0xe1120fc1,
@@ -1421,7 +1428,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe3e01000,
 0x000a0000,
 0xea000000,
-0x00050048,
+0x00050049,
 0x0006000d,
 0x03530480,
 0x03520000,
@@ -1434,20 +1441,20 @@ static const unsigned int build_actionlist[5702] = {
 0x0006000e,
 0x00000000,
 0xeb000000,
-0x00050059,
+0x0005005a,
 0xea000000,
-0x00050048,
-0x0006005a,
+0x00050049,
+0x0006005b,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x0a000000,
-0x00050048,
+0x00050049,
 0x8a000000,
-0x00050045,
+0x00050046,
 0xe1a02081,
 0xe292c980,
 0x5a000000,
@@ -1468,14 +1475,14 @@ static const unsigned int build_actionlist[5702] = {
 0x614f00d0,
 0x00051809,
 0x6a000000,
-0x00050048,
+0x00050049,
 0xe3510000,
 0xb2600000,
 0x0006000b,
 0xe3e01000,
 0x000a0000,
 0xea000000,
-0x00050048,
+0x00050049,
 0x0006000c,
 0xe1822000,
 0xe1d22fc1,
@@ -1484,7 +1491,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe3e01000,
 0x000a0000,
 0xea000000,
-0x00050048,
+0x00050049,
 0x0006000d,
 0x03530480,
 0x1a000000,
@@ -1495,38 +1502,38 @@ static const unsigned int build_actionlist[5702] = {
 0x0005000b,
 0x0006000e,
 0xeb000000,
-0x0005005b,
+0x0005005c,
 0x00000000,
 0xea000000,
-0x00050048,
+0x00050049,
 0x00040007,
 0x00060013,
 0x00020000,
 0x00000000,
 0x41e00000,
-0x0006005c,
+0x0006005d,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x8a000000,
-0x00050045,
+0x00050046,
 0x13c11480,
 0x1a000000,
-0x00050048,
+0x00050049,
 0xe3500000,
 0xb2700000,
 0x614f00d0,
 0x00051813,
-0x00060048,
+0x00060049,
 0xe5196004,
 0xe14900f8,
-0x0006005d,
+0x0006005e,
 0xe3a0b000,
 0x000a0000,
-0x00060046,
+0x00060047,
 0xe2160000,
 0x000a0000,
 0x0516e004,
@@ -1555,16 +1562,16 @@ static const unsigned int build_actionlist[5702] = {
 0xe5010004,
 0xea000000,
 0x0005000f,
-0x0006005e,
+0x0006005f,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe3710000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -1574,16 +1581,16 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0900a,
 0x00000000,
 0xea000000,
-0x00050048,
-0x0006005f,
+0x00050049,
+0x00060060,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -1593,16 +1600,16 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0900a,
 0x00000000,
 0xea000000,
-0x00050048,
-0x00060060,
+0x00050049,
+0x00060061,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -1612,16 +1619,16 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0900a,
 0x00000000,
 0xea000000,
-0x00050048,
-0x00060061,
+0x00050049,
+0x00060062,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -1631,16 +1638,16 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0900a,
 0x00000000,
 0xea000000,
-0x00050048,
-0x00060062,
+0x00050049,
+0x00060063,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -1650,16 +1657,16 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0900a,
 0x00000000,
 0xea000000,
-0x00050048,
-0x00060063,
+0x00050049,
+0x00060064,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -1669,16 +1676,16 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0900a,
 0x00000000,
 0xea000000,
-0x00050048,
-0x00060064,
+0x00050049,
+0x00060065,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -1688,16 +1695,16 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0900a,
 0x00000000,
 0xea000000,
-0x00050048,
-0x00060065,
+0x00050049,
+0x00060066,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -1707,16 +1714,16 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0900a,
 0x00000000,
 0xea000000,
-0x00050048,
-0x00060066,
+0x00050049,
+0x00060067,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -1726,16 +1733,16 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0900a,
 0x00000000,
 0xea000000,
-0x00050048,
-0x00060067,
+0x00050049,
+0x00060068,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -1745,16 +1752,16 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0900a,
 0x00000000,
 0xea000000,
-0x00050048,
-0x00060068,
+0x00050049,
+0x00060069,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -1764,16 +1771,16 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0900a,
 0x00000000,
 0xea000000,
-0x00050048,
-0x00060069,
+0x00050049,
+0x0006006a,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -1783,16 +1790,16 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0900a,
 0x00000000,
 0xea000000,
-0x00050048,
-0x0006006a,
+0x00050049,
+0x0006006b,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -1802,19 +1809,19 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0900a,
 0x00000000,
 0xea000000,
-0x00050048,
-0x0006006b,
+0x00050049,
+0x0006006c,
 0xe1c900d0,
 0xe1c920d8,
 0xe35b0010,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x33730000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -1824,19 +1831,19 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0900a,
 0x00000000,
 0xea000000,
-0x00050048,
-0x0006006c,
+0x00050049,
+0x0006006d,
 0xe1c900d0,
 0xe1c920d8,
 0xe35b0010,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x33730000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -1846,19 +1853,19 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0900a,
 0x00000000,
 0xea000000,
-0x00050048,
-0x0006006d,
+0x00050049,
+0x0006006e,
 0xe1c900d0,
 0xe1c920d8,
 0xe35b0010,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x33730000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -1868,37 +1875,37 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0900a,
 0x00000000,
 0xea000000,
-0x00050048,
-0x0006006e,
+0x00050049,
 0x0006006f,
+0x00060070,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0xe14220d0,
 0x000c8100,
 0xeb000000,
 0x0003001f,
 0xea000000,
-0x00050048,
-0x00060070,
+0x00050049,
+0x00060071,
 0xe1c900d0,
 0xe1c920d8,
 0xe35b0010,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0xe3730000,
 0x000a0000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -1908,16 +1915,16 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0900a,
 0x00000000,
 0xea000000,
-0x00050048,
-0x00060071,
+0x00050049,
+0x00060072,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0xe1a0200d,
 0x00000000,
 0xe1a0a009,
@@ -1936,16 +1943,16 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0xe1c920f0,
 0xea000000,
-0x00050046,
-0x00060072,
+0x00050047,
+0x00060073,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x2a000000,
-0x00050045,
+0x00050046,
 0xe2492008,
 0xe5196004,
 0x00000000,
@@ -1960,12 +1967,12 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0xe1c900f0,
 0xea000000,
-0x00050046,
-0x00060073,
+0x00050047,
+0x00060074,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0xe3a0a008,
@@ -1975,7 +1982,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe18920da,
 0xe15a000b,
 0x2a000000,
-0x00050048,
+0x00050049,
 0xe3730000,
 0x000a0000,
 0x1a000000,
@@ -1987,7 +1994,7 @@ static const unsigned int build_actionlist[5702] = {
 0x0005000b,
 0x0006000d,
 0x8a000000,
-0x00050045,
+0x00050046,
 0xeb000000,
 0x00030023,
 0xe18920da,
@@ -1995,12 +2002,12 @@ static const unsigned int build_actionlist[5702] = {
 0x00050006,
 0x0006000e,
 0x8a000000,
-0x00050045,
+0x00050046,
 0x0006000f,
 0xe18920da,
 0xe15a000b,
 0x2a000000,
-0x00050048,
+0x00050049,
 0xe3730000,
 0x000a0000,
 0x2a000000,
@@ -2016,7 +2023,7 @@ static const unsigned int build_actionlist[5702] = {
 0x0005000f,
 0x00060011,
 0x8a000000,
-0x00050045,
+0x00050046,
 0xe1cd00f0,
 0xe1a00002,
 0xeb000000,
@@ -2024,11 +2031,11 @@ static const unsigned int build_actionlist[5702] = {
 0xe1cd20d0,
 0xea000000,
 0x00050010,
-0x00060074,
+0x00060075,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0xe3a0a008,
@@ -2038,7 +2045,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe18920da,
 0xe15a000b,
 0x2a000000,
-0x00050048,
+0x00050049,
 0xe3730000,
 0x000a0000,
 0x1a000000,
@@ -2050,7 +2057,7 @@ static const unsigned int build_actionlist[5702] = {
 0x0005000b,
 0x0006000d,
 0x8a000000,
-0x00050045,
+0x00050046,
 0xeb000000,
 0x00030023,
 0xe18920da,
@@ -2058,13 +2065,13 @@ static const unsigned int build_actionlist[5702] = {
 0x00050006,
 0x0006000e,
 0x8a000000,
-0x00050045,
+0x00050046,
 0x0006000f,
 0x00000000,
 0xe18920da,
 0xe15a000b,
 0x2a000000,
-0x00050048,
+0x00050049,
 0xe3730000,
 0x000a0000,
 0x2a000000,
@@ -2079,7 +2086,7 @@ static const unsigned int build_actionlist[5702] = {
 0x0005000f,
 0x00060011,
 0x8a000000,
-0x00050045,
+0x00050046,
 0xe1cd00f0,
 0xe1a00002,
 0xeb000000,
@@ -2087,29 +2094,29 @@ static const unsigned int build_actionlist[5702] = {
 0xe1cd20d0,
 0xea000000,
 0x00050010,
-0x00060075,
+0x00060076,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0xe5100000,
 0x000d8180,
 0xe3e01000,
 0x000a0000,
 0xea000000,
-0x00050048,
-0x00060076,
+0x00050049,
+0x00060077,
 0xe1c900d0,
 0xe5196004,
 0xe35b0008,
 0x03710000,
 0x000a0000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0xe5102000,
 0x000d8180,
 0xe5500000,
@@ -2124,15 +2131,15 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0xe14900f8,
 0xea000000,
-0x00050046,
-0x00060077,
+0x00050047,
+0x00060078,
 0xe5170000,
 0x000d8180,
 0xe5171000,
 0x000d8180,
 0xe1500001,
 0xab000000,
-0x0005004e,
+0x0005004f,
 0xe1c900d0,
 0xe5196004,
 0xe35b0008,
@@ -2141,10 +2148,10 @@ static const unsigned int build_actionlist[5702] = {
 0x03d030ff,
 0xe3a02001,
 0x1a000000,
-0x00050045,
+0x00050046,
 0xe58d0000,
 0xe1a0100d,
-0x00060078,
+0x00060079,
 0xe5089000,
 0x000d8180,
 0xe1a00008,
@@ -2156,15 +2163,15 @@ static const unsigned int build_actionlist[5702] = {
 0xe3e01000,
 0x000a0000,
 0xea000000,
-0x00050048,
-0x00060079,
+0x00050049,
+0x0006007a,
 0xe5170000,
 0x000d8180,
 0xe5171000,
 0x000d8180,
 0xe1500001,
 0xab000000,
-0x0005004e,
+0x0005004f,
 0xe1c900d0,
 0xe1c921d0,
 0xe35b0010,
@@ -2172,13 +2179,13 @@ static const unsigned int build_actionlist[5702] = {
 0x0a000000,
 0x00050001,
 0x3a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe3730000,
 0x000a0000,
 0xe1a0c002,
 0x1a000000,
-0x00050045,
+0x00050046,
 0x0006000b,
 0xe1c920d8,
 0xe3710000,
@@ -2188,7 +2195,7 @@ static const unsigned int build_actionlist[5702] = {
 0x03730000,
 0x000a0000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0xe2813001,
 0xe3520000,
 0xb0822003,
@@ -2205,44 +2212,44 @@ static const unsigned int build_actionlist[5702] = {
 0xe05c2002,
 0xe2822001,
 0xaa000000,
-0x00050078,
-0x0006007a,
+0x00050079,
+0x0006007b,
 0xe2470000,
 0x000a0000,
 0xe3e01000,
 0x000a0000,
 0xea000000,
-0x00050048,
-0x0006007b,
+0x00050049,
+0x0006007c,
 0xe5170000,
 0x000d8180,
 0xe5171000,
 0x000d8180,
 0xe1500001,
 0xab000000,
-0x0005004e,
+0x0005004f,
 0xe1c900d0,
 0xe1c920d8,
 0xe35b0010,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x03730000,
 0x000a0000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0xe2523001,
 0xe5101000,
 0x000d8180,
 0x00000000,
 0xba000000,
-0x0005007a,
+0x0005007b,
 0xe3510001,
 0x3a000000,
-0x0005007a,
+0x0005007b,
 0x1a000000,
-0x00050045,
+0x00050046,
 0xe517c000,
 0x000d8180,
 0xe5171000,
@@ -2251,30 +2258,30 @@ static const unsigned int build_actionlist[5702] = {
 0x000d8180,
 0xe15c0002,
 0x3a000000,
-0x00050045,
+0x00050046,
 0x0006000b,
 0xe7c10003,
 0xe2533001,
 0xaa000000,
 0x0005000b,
 0xea000000,
-0x00050078,
-0x0006007c,
+0x00050079,
+0x0006007d,
 0xe5170000,
 0x000d8180,
 0xe5171000,
 0x000d8180,
 0xe1500001,
 0xab000000,
-0x0005004e,
+0x0005004f,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0xe5102000,
 0x000d8180,
 0xe517c000,
@@ -2286,32 +2293,32 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0xe15c0002,
 0x3a000000,
-0x00050045,
+0x00050046,
 0x0006000b,
 0x00000000,
 0xe4d0c001,
 0xe2533001,
 0xba000000,
-0x00050078,
+0x00050079,
 0xe7c1c003,
 0xea000000,
 0x0005000b,
-0x0006007d,
+0x0006007e,
 0xe5170000,
 0x000d8180,
 0xe5171000,
 0x000d8180,
 0xe1500001,
 0xab000000,
-0x0005004e,
+0x0005004f,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0xe5102000,
 0x000d8180,
 0xe517c000,
@@ -2323,12 +2330,12 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0xe15c0002,
 0x3a000000,
-0x00050045,
+0x00050046,
 0x0006000b,
 0xe7d0c003,
 0xe1530002,
 0x2a000000,
-0x00050078,
+0x00050079,
 0xe24cb041,
 0xe35b001a,
 0x322cc020,
@@ -2336,23 +2343,23 @@ static const unsigned int build_actionlist[5702] = {
 0xe2833001,
 0xea000000,
 0x0005000b,
-0x0006007e,
+0x0006007f,
 0xe5170000,
 0x000d8180,
 0xe5171000,
 0x000d8180,
 0xe1500001,
 0xab000000,
-0x0005004e,
+0x0005004f,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe3710000,
 0x000a0000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0xe5102000,
 0x000d8180,
 0xe517c000,
@@ -2364,12 +2371,12 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0xe15c0002,
 0x3a000000,
-0x00050045,
+0x00050046,
 0x0006000b,
 0xe7d0c003,
 0xe1530002,
 0x2a000000,
-0x00050078,
+0x00050079,
 0xe24cb061,
 0xe35b001a,
 0x322cc020,
@@ -2377,15 +2384,15 @@ static const unsigned int build_actionlist[5702] = {
 0xe2833001,
 0xea000000,
 0x0005000b,
-0x0006007f,
+0x00060080,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x1a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe1a0a009,
 0x00000000,
@@ -2397,11 +2404,11 @@ static const unsigned int build_actionlist[5702] = {
 0xe3e01000,
 0x000a0000,
 0xea000000,
-0x00050048,
-0x00060080,
-0x8a000000,
-0x00050045,
+0x00050049,
 0x00060081,
+0x8a000000,
+0x00050046,
+0x00060082,
 0xe1a0c081,
 0xe29cc980,
 0x53a00000,
@@ -2426,28 +2433,28 @@ static const unsigned int build_actionlist[5702] = {
 0xe1830c10,
 0xb2600000,
 0xe12fff1e,
-0x00060082,
+0x00060083,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0xe3e01000,
 0x000a0000,
 0xea000000,
-0x00050048,
-0x00060083,
+0x00050049,
+0x00060084,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0xe1a02000,
 0xe3a0a008,
 0x0006000b,
@@ -2459,20 +2466,20 @@ static const unsigned int build_actionlist[5702] = {
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0xe0022000,
 0xea000000,
 0x0005000b,
-0x00060084,
+0x00060085,
 0x00000000,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0xe1a02000,
 0xe3a0a008,
 0x0006000b,
@@ -2484,19 +2491,19 @@ static const unsigned int build_actionlist[5702] = {
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0xe1822000,
 0xea000000,
 0x0005000b,
-0x00060085,
+0x00060086,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0xe1a02000,
 0xe3a0a008,
 0x0006000b,
@@ -2508,7 +2515,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0xe0222000,
 0xea000000,
 0x0005000b,
@@ -2518,17 +2525,17 @@ static const unsigned int build_actionlist[5702] = {
 0xe5196004,
 0xe14920f8,
 0xea000000,
-0x0005005d,
-0x00060086,
+0x0005005e,
+0x00060087,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0xe0202860,
 0xe3c228ff,
 0xe1a00460,
@@ -2536,124 +2543,124 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0xe0200422,
 0xea000000,
-0x00050048,
-0x00060087,
+0x00050049,
+0x00060088,
 0xe1c900d0,
 0xe35b0008,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0xe1e00000,
 0xe3e01000,
 0x000a0000,
 0xea000000,
-0x00050048,
-0x00060088,
+0x00050049,
+0x00060089,
 0xe1c900d8,
 0xe35b0010,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0xe200a01f,
 0xe1c900d0,
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0xe1a00a10,
 0xe3e01000,
 0x000a0000,
 0xea000000,
-0x00050048,
-0x00060089,
+0x00050049,
+0x0006008a,
 0xe1c900d8,
 0xe35b0010,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0x00000000,
 0xe200a01f,
 0xe1c900d0,
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0xe1a00a30,
 0xe3e01000,
 0x000a0000,
 0xea000000,
-0x00050048,
-0x0006008a,
+0x00050049,
+0x0006008b,
 0xe1c900d8,
 0xe35b0010,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0xe200a01f,
 0xe1c900d0,
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0xe1a00a50,
 0xe3e01000,
 0x000a0000,
 0xea000000,
-0x00050048,
-0x0006008b,
+0x00050049,
+0x0006008c,
 0xe1c900d8,
 0xe35b0010,
 0x3a000000,
-0x00050045,
+0x00050046,
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0xe260a000,
 0xe1c900d0,
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0xe1a00a70,
 0xe3e01000,
 0x000a0000,
 0xea000000,
-0x00050048,
-0x0006008c,
+0x00050049,
+0x0006008d,
 0xe1c900d8,
 0xe35b0010,
 0x3a000000,
-0x00050045,
+0x00050046,
 0x00000000,
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0xe200a01f,
 0xe1c900d0,
 0xe3710000,
 0x000a0000,
 0x1b000000,
-0x00050080,
+0x00050081,
 0xe1a00a70,
 0xe3e01000,
 0x000a0000,
 0xea000000,
-0x00050048,
-0x00060045,
+0x00050049,
+0x00060046,
 0xe5192008,
 0xe5181000,
 0x000d8180,
@@ -2679,14 +2686,14 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0b180,
 0xe249a008,
 0xca000000,
-0x00050046,
+0x00050047,
 0x0006000b,
 0xe5180000,
 0x000d8180,
 0xe5192008,
 0xe040b009,
 0x1a000000,
-0x00050028,
+0x00050029,
 0xe5126000,
 0x000d8180,
 0xe5d6c000,
@@ -2695,7 +2702,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe004a2ae,
 0xe08aa009,
 0xe12fff1c,
-0x00060028,
+0x00060029,
 0xe2160000,
 0x000a0000,
 0xe3c61000,
@@ -2717,7 +2724,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe1500000,
 0xea000000,
 0x0005000b,
-0x0006004e,
+0x0006004f,
 0xe1a0a00e,
 0xe5089000,
 0x000d8180,
@@ -2733,7 +2740,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0e00a,
 0xe5192008,
 0xe12fff1e,
-0x0006008d,
+0x0006008e,
 0x00000000,
 0xe5570000,
 0x000d8180,
@@ -2755,7 +2762,7 @@ static const unsigned int build_actionlist[5702] = {
 0xea000000,
 0x00050001,
 0x00000000,
-0x0006008e,
+0x0006008f,
 0xe5570000,
 0x000d8180,
 0xe3100000,
@@ -2767,7 +2774,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe087c10c,
 0xe51cf000,
 0x000d8180,
-0x0006008f,
+0x00060090,
 0xe5570000,
 0x000d8180,
 0xe5171000,
@@ -2809,13 +2816,13 @@ static const unsigned int build_actionlist[5702] = {
 0xe004a2ae,
 0xe1a0b82e,
 0xe12fff1c,
-0x00060090,
+0x00060091,
 0xe5130018,
 0xe2866004,
 0xe58d0004,
 0xea000000,
 0x0005000e,
-0x00060091,
+0x00060092,
 0x00000000,
 0xe5192008,
 0xe2470000,
@@ -2838,13 +2845,13 @@ static const unsigned int build_actionlist[5702] = {
 0xea000000,
 0x0005000d,
 0x00000000,
-0x00060092,
+0x00060093,
 0xe1a01006,
 0x00000000,
 0xea000000,
 0x00050001,
 0x00000000,
-0x00060093,
+0x00060094,
 0x00000000,
 0xe3861001,
 0x0006000b,
@@ -2870,7 +2877,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe5192008,
 0xe516e004,
 0xe12fff10,
-0x00060094,
+0x00060095,
 0x00000000,
 0xe24dd00c,
 0xe92d1fff,
@@ -2920,7 +2927,7 @@ static const unsigned int build_actionlist[5702] = {
 0xea000000,
 0x00050001,
 0x00000000,
-0x00060095,
+0x00060096,
 0x00000000,
 0xe59d800c,
 0x0006000b,
@@ -2961,7 +2968,7 @@ static const unsigned int build_actionlist[5702] = {
 0x00000000,
 0x00060013,
 0x3ff00000,
-0x00060059,
+0x0006005a,
 0xe1a02081,
 0xe292c980,
 0x5a000000,
@@ -2996,7 +3003,7 @@ static const unsigned int build_actionlist[5702] = {
 0x00050813,
 0x11811003,
 0xe12fff1e,
-0x0006005b,
+0x0006005c,
 0xe1a02081,
 0xe292c980,
 0x5a000000,
@@ -3031,7 +3038,7 @@ static const unsigned int build_actionlist[5702] = {
 0x00050813,
 0x11811003,
 0xe12fff1e,
-0x00060096,
+0x00060097,
 0x00000000,
 0xe1a02081,
 0xe292c980,
@@ -3047,12 +3054,12 @@ static const unsigned int build_actionlist[5702] = {
 0x50011c13,
 0xe12fff1e,
 0x00000000,
-0x00060097,
+0x00060098,
 0xe92d401f,
 0xeb000000,
 0x0003002d,
 0xeb000000,
-0x00050059,
+0x0005005a,
 0xe1cd20d8,
 0xeb000000,
 0x0003001f,
@@ -3062,7 +3069,7 @@ static const unsigned int build_actionlist[5702] = {
 0x0003002e,
 0xe28dd014,
 0xe8bd8000,
-0x00060098,
+0x00060099,
 0xe210c480,
 0x42600000,
 0xe02cc0c1,
@@ -3095,7 +3102,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe030108c,
 0x42600000,
 0xe12fff1e,
-0x00060099,
+0x0006009a,
 0xe59dc000,
 0xe35c0001,
 0x3a000000,
@@ -3109,7 +3116,7 @@ static const unsigned int build_actionlist[5702] = {
 0x0003002d,
 0xe35c0005,
 0x3a000000,
-0x00050097,
+0x00050098,
 0x0a000000,
 0x0003001c,
 0xe35c0007,
@@ -3144,7 +3151,71 @@ static const unsigned int build_actionlist[5702] = {
 0x00000000,
 0xe7f001f0,
 0x00000000,
-0x0006009a,
+0x0006009b,
+0x00000000,
+0xe51c6000,
+0x000d8180,
+0xe28c7000,
+0x000a0000,
+0xe14600f0,
+0x000c8100,
+0xe14620f0,
+0x000c8100,
+0xe59d3000,
+0xe28d2000,
+0x000a0000,
+0xe1a00006,
+0xe1a031a3,
+0xe5062000,
+0x000d8180,
+0xe1a0100d,
+0xe5063000,
+0x000d8180,
+0xe58d6008,
+0xeb000000,
+0x00030030,
+0xe5109000,
+0x000d8180,
+0xe3e01000,
+0x000a0000,
+0xe510b000,
+0x000d8180,
+0xe3a040ff,
+0xe5192008,
+0xe1a08000,
+0xe04bb009,
+0xe1a04184,
+0xe5071000,
+0x000d8180,
+0xe5126000,
+0x000d8180,
+0xe5d6c000,
+0xe496e004,
+0xe797c10c,
+0xe004a2ae,
+0xe08aa009,
+0xe12fff1c,
+0x00000000,
+0x00060028,
+0x00000000,
+0xe5176000,
+0x000d8180,
+0xe5089000,
+0x000d8180,
+0xe5083000,
+0x000d8180,
+0xe5068000,
+0x000d8180,
+0xe1a00006,
+0xe1a0100a,
+0xeb000000,
+0x00030031,
+0xe14600d0,
+0x000c8100,
+0xea000000,
+0x0005001a,
+0x00000000,
+0x0006009c,
 0x00000000,
 0xe92d4830,
 0xe1a04000,
@@ -3219,7 +3290,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe12fff1c,
 0x0006000d,
 0x8a000000,
-0x00050034,
+0x00050035,
 0xe3730000,
 0x000a0000,
 0x31a0a00c,
@@ -3237,7 +3308,7 @@ static const unsigned int build_actionlist[5702] = {
 0x00050005,
 0x0006000e,
 0x8a000000,
-0x00050034,
+0x00050035,
 0xe1a0a00c,
 0xeb000000,
 0x00030023,
@@ -3269,17 +3340,17 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x9a000000,
-0x0005009b,
+0x0005009d,
 0x00000000,
 0x9a000000,
-0x0005009c,
+0x0005009e,
 0x00000000,
 0xe3710000,
 0x000a0000,
 0x13730000,
 0x000a0000,
 0x0a000000,
-0x0005003a,
+0x0005003b,
 0x00000000,
 0xe1510003,
 0x1a000000,
@@ -3332,7 +3403,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe31a0000,
 0x000a0000,
 0x0a000000,
-0x00050039,
+0x0005003a,
 0x00000000,
 0xea000000,
 0x0005000c,
@@ -3381,7 +3452,7 @@ static const unsigned int build_actionlist[5702] = {
 0x1a000000,
 0x0005000b,
 0xea000000,
-0x0005003a,
+0x0005003b,
 0x00000000,
 0xe1a0b18b,
 0xe1aa00d9,
@@ -3390,9 +3461,9 @@ static const unsigned int build_actionlist[5702] = {
 0xe2866004,
 0xe086c10c,
 0x00000000,
-0x0006009b,
+0x0006009d,
 0x00000000,
-0x0006009c,
+0x0006009e,
 0x00000000,
 0xe3710000,
 0x000a0000,
@@ -3441,7 +3512,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe1cb20d0,
 0x0006000f,
 0xeb000000,
-0x00030030,
+0x00030032,
 0x00000000,
 0x024a6b80,
 0x00000000,
@@ -3456,7 +3527,7 @@ static const unsigned int build_actionlist[5702] = {
 0x1a000000,
 0x0005000b,
 0xea000000,
-0x0005003a,
+0x0005003b,
 0x00000000,
 0xe18900da,
 0xe1d6c0b2,
@@ -3467,7 +3538,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe3710000,
 0x000a0000,
 0x0a000000,
-0x0005003a,
+0x0005003b,
 0x00000000,
 0xe151000b,
 0x00000000,
@@ -3539,7 +3610,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe3710000,
 0x000a0000,
 0x8a000000,
-0x0005003d,
+0x0005003e,
 0x12211480,
 0x1a000000,
 0x00050005,
@@ -3580,7 +3651,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe3710000,
 0x000a0000,
 0x1a000000,
-0x0005003f,
+0x00050040,
 0x00000000,
 0xe5102000,
 0x000d8180,
@@ -3589,7 +3660,7 @@ static const unsigned int build_actionlist[5702] = {
 0x00050009,
 0x0006000d,
 0x00000000,
-0x00060040,
+0x00060041,
 0x00000000,
 0xe1a0b009,
 0x00000000,
@@ -3609,7 +3680,7 @@ static const unsigned int build_actionlist[5702] = {
 0x1a000000,
 0x0005000d,
 0xea000000,
-0x0005003f,
+0x00050040,
 0x00000000,
 0xe004caae,
 0xe004b6ae,
@@ -3640,13 +3711,13 @@ static const unsigned int build_actionlist[5702] = {
 0xe0900002,
 0x00000000,
 0x6a000000,
-0x0005003b,
+0x0005003c,
 0x00000000,
 0x6a000000,
-0x0005003c,
+0x0005003d,
 0x00000000,
 0x6a000000,
-0x0005003e,
+0x0005003f,
 0x00000000,
 0x0006000e,
 0xe496e004,
@@ -3668,7 +3739,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x2a000000,
-0x0005003b,
+0x0005003c,
 0x00000000,
 0xe3730000,
 0x000a0000,
@@ -3681,7 +3752,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x2a000000,
-0x0005003c,
+0x0005003d,
 0x00000000,
 0xe3730000,
 0x000a0000,
@@ -3694,7 +3765,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x2a000000,
-0x0005003e,
+0x0005003f,
 0x00000000,
 0xeb000000,
 0x0003002e,
@@ -3731,13 +3802,13 @@ static const unsigned int build_actionlist[5702] = {
 0xe0500002,
 0x00000000,
 0x6a000000,
-0x0005003b,
+0x0005003c,
 0x00000000,
 0x6a000000,
-0x0005003c,
+0x0005003d,
 0x00000000,
 0x6a000000,
-0x0005003e,
+0x0005003f,
 0x00000000,
 0x0006000e,
 0xe496e004,
@@ -3759,7 +3830,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x2a000000,
-0x0005003b,
+0x0005003c,
 0x00000000,
 0xe3730000,
 0x000a0000,
@@ -3772,7 +3843,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x2a000000,
-0x0005003c,
+0x0005003d,
 0x00000000,
 0xe3730000,
 0x000a0000,
@@ -3785,7 +3856,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x2a000000,
-0x0005003e,
+0x0005003f,
 0x00000000,
 0xeb000000,
 0x0003002f,
@@ -3823,13 +3894,13 @@ static const unsigned int build_actionlist[5702] = {
 0xe15b0fc0,
 0x00000000,
 0x1a000000,
-0x0005003b,
+0x0005003c,
 0x00000000,
 0x1a000000,
-0x0005003c,
+0x0005003d,
 0x00000000,
 0x1a000000,
-0x0005003e,
+0x0005003f,
 0x00000000,
 0x0006000e,
 0xe496e004,
@@ -3851,7 +3922,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x2a000000,
-0x0005003b,
+0x0005003c,
 0x00000000,
 0xe3730000,
 0x000a0000,
@@ -3864,7 +3935,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x2a000000,
-0x0005003c,
+0x0005003d,
 0x00000000,
 0xe3730000,
 0x000a0000,
@@ -3877,7 +3948,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x2a000000,
-0x0005003e,
+0x0005003f,
 0x00000000,
 0xeb000000,
 0x0003001f,
@@ -3908,7 +3979,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x2a000000,
-0x0005003b,
+0x0005003c,
 0x00000000,
 0xe3730000,
 0x000a0000,
@@ -3921,7 +3992,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x2a000000,
-0x0005003c,
+0x0005003d,
 0x00000000,
 0xe3730000,
 0x000a0000,
@@ -3934,7 +4005,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x2a000000,
-0x0005003e,
+0x0005003f,
 0x00000000,
 0xeb000000,
 0x0003002d,
@@ -3973,16 +4044,16 @@ static const unsigned int build_actionlist[5702] = {
 0xe1b01002,
 0x00000000,
 0x0a000000,
-0x0005003b,
+0x0005003c,
 0x00000000,
 0x0a000000,
-0x0005003c,
+0x0005003d,
 0x00000000,
 0x0a000000,
-0x0005003e,
+0x0005003f,
 0x00000000,
 0xeb000000,
-0x00050098,
+0x00050099,
 0xe3e01000,
 0x000a0000,
 0x0006000e,
@@ -4006,7 +4077,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x2a000000,
-0x0005003b,
+0x0005003c,
 0x00000000,
 0xe3730000,
 0x000a0000,
@@ -4019,7 +4090,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x2a000000,
-0x0005003c,
+0x0005003d,
 0x00000000,
 0xe3730000,
 0x000a0000,
@@ -4032,10 +4103,10 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x2a000000,
-0x0005003e,
+0x0005003f,
 0x00000000,
 0xeb000000,
-0x00050097,
+0x00050098,
 0xea000000,
 0x0005000e,
 0x00000000,
@@ -4062,7 +4133,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x2a000000,
-0x0005003b,
+0x0005003c,
 0x00000000,
 0xe3730000,
 0x000a0000,
@@ -4075,7 +4146,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x2a000000,
-0x0005003c,
+0x0005003d,
 0x00000000,
 0xe3730000,
 0x000a0000,
@@ -4088,7 +4159,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x00000000,
 0x2a000000,
-0x0005003e,
+0x0005003f,
 0x00000000,
 0xe1a0b009,
 0x00000000,
@@ -4111,17 +4182,17 @@ static const unsigned int build_actionlist[5702] = {
 0xe5089000,
 0x000d8180,
 0xe089100c,
-0x0006002a,
+0x0006002b,
 0xe1a00008,
 0xe58d6008,
 0xe1a021a2,
 0xeb000000,
-0x00030031,
+0x00030033,
 0xe5189000,
 0x000d8180,
 0xe3500000,
 0x1a000000,
-0x00050035,
+0x00050036,
 0xe18920db,
 0xe5d6c000,
 0xe496e004,
@@ -4265,11 +4336,11 @@ static const unsigned int build_actionlist[5702] = {
 0x0005000b,
 0xe1a0b009,
 0xeb000000,
-0x00030032,
+0x00030034,
 0xe1a0900b,
 0x00000000,
 0x1b000000,
-0x00030032,
+0x00030034,
 0x00000000,
 0xea000000,
 0x0005000b,
@@ -4314,11 +4385,11 @@ static const unsigned int build_actionlist[5702] = {
 0x0005000b,
 0xe1a0b009,
 0xeb000000,
-0x00030032,
+0x00030034,
 0xe1a0900b,
 0x00000000,
 0x1b000000,
-0x00030032,
+0x00030034,
 0x00000000,
 0xea000000,
 0x0005000b,
@@ -4368,7 +4439,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a00008,
 0xe089100a,
 0xeb000000,
-0x00030033,
+0x00030035,
 0xe5189000,
 0x000d8180,
 0x0006000b,
@@ -4387,7 +4458,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe5192008,
 0xe1a00008,
 0xeb000000,
-0x00030034,
+0x00030036,
 0xe5189000,
 0x000d8180,
 0xe3e01000,
@@ -4422,11 +4493,11 @@ static const unsigned int build_actionlist[5702] = {
 0xe37b0001,
 0x02811002,
 0xeb000000,
-0x00030035,
+0x00030037,
 0x00000000,
 0xe795110b,
 0xeb000000,
-0x00030036,
+0x00030038,
 0x00000000,
 0xe5189000,
 0x000d8180,
@@ -4441,7 +4512,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe12fff1c,
 0x0006000f,
 0xeb000000,
-0x00030037,
+0x00030039,
 0xe1a00008,
 0xea000000,
 0x0005000b,
@@ -4453,10 +4524,10 @@ static const unsigned int build_actionlist[5702] = {
 0xe795b10b,
 0x00000000,
 0xea000000,
-0x0005009d,
+0x0005009f,
 0x00000000,
 0xea000000,
-0x0005009e,
+0x000500a0,
 0x00000000,
 0xe004caae,
 0xe004b6ae,
@@ -4465,7 +4536,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe3710000,
 0x000a0000,
 0x1a000000,
-0x0005002f,
+0x00050030,
 0xe3730000,
 0x000a0000,
 0x05103000,
@@ -4478,7 +4549,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe1520001,
 0x31c320d0,
 0x2a000000,
-0x0005002f,
+0x00050030,
 0xe5d6c000,
 0xe3730000,
 0x000a0000,
@@ -4505,15 +4576,15 @@ static const unsigned int build_actionlist[5702] = {
 0x0005000b,
 0xe004caae,
 0xea000000,
-0x0005002f,
+0x00050030,
 0x00060013,
 0xe3730000,
 0x000a0000,
 0x01a0b002,
 0x0a000000,
-0x0005009d,
+0x0005009f,
 0xea000000,
-0x0005002f,
+0x00050030,
 0x00000000,
 0xe004caae,
 0xe20bb0ff,
@@ -4523,8 +4594,8 @@ static const unsigned int build_actionlist[5702] = {
 0xe3710000,
 0x000a0000,
 0x1a000000,
-0x0005002c,
-0x0006009d,
+0x0005002d,
+0x0006009f,
 0xe5102000,
 0x000d8180,
 0xe51b3000,
@@ -4580,7 +4651,7 @@ static const unsigned int build_actionlist[5702] = {
 0x1a000000,
 0x0005000d,
 0xea000000,
-0x0005002d,
+0x0005002e,
 0x00000000,
 0xe004caae,
 0xe20bb0ff,
@@ -4588,7 +4659,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe3710000,
 0x000a0000,
 0x1a000000,
-0x0005002e,
+0x0005002f,
 0xe5102000,
 0x000d8180,
 0xe5103000,
@@ -4597,7 +4668,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe15b0002,
 0x318320d1,
 0x2a000000,
-0x0005002e,
+0x0005002f,
 0xe5d6c000,
 0xe3730000,
 0x000a0000,
@@ -4623,7 +4694,7 @@ static const unsigned int build_actionlist[5702] = {
 0x1a000000,
 0x0005000b,
 0xea000000,
-0x0005002e,
+0x0005002f,
 0x00000000,
 0xe004caae,
 0xe004b6ae,
@@ -4632,7 +4703,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe3710000,
 0x000a0000,
 0x1a000000,
-0x00050033,
+0x00050034,
 0xe3730000,
 0x000a0000,
 0x05101000,
@@ -4645,7 +4716,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe1520003,
 0x3591e004,
 0x2a000000,
-0x00050033,
+0x00050034,
 0xe5d6c000,
 0xe37e0000,
 0x000a0000,
@@ -4682,7 +4753,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe004caae,
 0xe004a2ae,
 0xea000000,
-0x00050033,
+0x00050034,
 0x00060011,
 0x00000000,
 0xe5172000,
@@ -4702,9 +4773,9 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x01a0b002,
 0x0a000000,
-0x0005009e,
+0x000500a0,
 0xea000000,
-0x00050033,
+0x00050034,
 0x00000000,
 0xe004caae,
 0xe20bb0ff,
@@ -4714,8 +4785,8 @@ static const unsigned int build_actionlist[5702] = {
 0xe3710000,
 0x000a0000,
 0x1a000000,
-0x00050030,
-0x0006009e,
+0x00050031,
+0x000600a0,
 0xe5102000,
 0x000d8180,
 0xe51b3000,
@@ -4776,7 +4847,7 @@ static const unsigned int build_actionlist[5702] = {
 0x1a000000,
 0x0005000c,
 0xea000000,
-0x00050031,
+0x00050032,
 0x0006000f,
 0xe1b0e002,
 0x1a000000,
@@ -4796,7 +4867,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe3110000,
 0x000a0000,
 0x0a000000,
-0x00050031,
+0x00050032,
 0x00060010,
 0xe3e03000,
 0x000a0000,
@@ -4804,7 +4875,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a0100c,
 0xe58d3004,
 0xeb000000,
-0x00030038,
+0x0003003a,
 0xe5189000,
 0x000d8180,
 0xe18920da,
@@ -4832,7 +4903,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe3710000,
 0x000a0000,
 0x1a000000,
-0x00050032,
+0x00050033,
 0xe5102000,
 0x000d8180,
 0xe510c000,
@@ -4841,7 +4912,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe15b0002,
 0x31a120dc,
 0x2a000000,
-0x00050032,
+0x00050033,
 0xe5d6c000,
 0xe3730000,
 0x000a0000,
@@ -4877,7 +4948,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe516e004,
 0xe004a2ae,
 0xea000000,
-0x00050032,
+0x00050033,
 0x00060011,
 0xe5172000,
 0x000d8180,
@@ -4936,7 +5007,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe1a00008,
 0xe58d6008,
 0xeb000000,
-0x00030039,
+0x0003003b,
 0x00000000,
 0xe5189000,
 0x000d8180,
@@ -4944,15 +5015,15 @@ static const unsigned int build_actionlist[5702] = {
 0xea000000,
 0x0005000b,
 0x00060011,
-0xe5171000,
+0xe5172000,
 0x000d8180,
 0xe3c00000,
 0x000a0000,
-0xe507c000,
+0xe5071000,
 0x000d8180,
-0xe54c0000,
+0xe5410000,
 0x000d8180,
-0xe50c1000,
+0xe5012000,
 0x000d8180,
 0xea000000,
 0x0005000e,
@@ -4961,10 +5032,10 @@ static const unsigned int build_actionlist[5702] = {
 0xe004b6ae,
 0xe08bb000,
 0xea000000,
-0x0005009f,
+0x000500a1,
 0x00000000,
 0xe004b6ae,
-0x0006009f,
+0x000600a1,
 0xe1a0c009,
 0xe1a920da,
 0xe24bb008,
@@ -4986,19 +5057,19 @@ static const unsigned int build_actionlist[5702] = {
 0xe59d0004,
 0xe080b18b,
 0xea000000,
-0x000500a0,
+0x000500a2,
 0x00000000,
 0xe1a0b18b,
-0x000600a0,
+0x000600a2,
 0xe1aa20d9,
 0xe24bb008,
 0xe28aa008,
 0xe3730000,
 0x000a0000,
 0x1a000000,
-0x00050041,
+0x00050042,
 0xe5196004,
-0x00060042,
+0x00060043,
 0xe3a0c000,
 0xe5523000,
 0x000d8180,
@@ -5265,12 +5336,12 @@ static const unsigned int build_actionlist[5702] = {
 0xe089a00a,
 0xe080b18b,
 0xea000000,
-0x000500a1,
+0x000500a3,
 0x00000000,
 0xe5196004,
 0xe1a0b18b,
 0xe089a00a,
-0x000600a1,
+0x000600a3,
 0xe58db004,
 0x0006000b,
 0xe2160000,
@@ -5278,7 +5349,7 @@ static const unsigned int build_actionlist[5702] = {
 0xe2261000,
 0x000a0000,
 0x1a000000,
-0x000500a2,
+0x000500a4,
 0x00060017,
 0xe516e004,
 0xe25b3008,
@@ -5320,9 +5391,9 @@ static const unsigned int build_actionlist[5702] = {
 0xe509100c,
 0xea000000,
 0x0005000f,
-0x000600a3,
+0x000600a5,
 0xe089a00a,
-0x000600a2,
+0x000600a4,
 0xe3110000,
 0x000a0000,
 0x1a000000,
@@ -5341,7 +5412,7 @@ static const unsigned int build_actionlist[5702] = {
 0x000a0000,
 0x0516e004,
 0x1a000000,
-0x000500a3,
+0x000500a5,
 0x00000000,
 0xe18900da,
 0x00000000,
@@ -5381,10 +5452,11 @@ static const unsigned int build_actionlist[5702] = {
 0xe2400000,
 0x000a0000,
 0xe19710b0,
-0xe2511001,
+0xe2511000,
+0x000a0000,
 0xe18710b0,
-0x0a000000,
-0x00050091,
+0x3a000000,
+0x00050092,
 0x00000000,
 0xe1aa00d9,
 0x00000000,
@@ -5402,7 +5474,7 @@ static const unsigned int build_actionlist[5702] = {
 0x037c0000,
 0x000a0000,
 0x1a000000,
-0x00050043,
+0x00050044,
 0xe3530000,
 0xba000000,
 0x00050004,
@@ -5465,7 +5537,7 @@ static const unsigned int build_actionlist[5702] = {
 0x337c0000,
 0x000a0000,
 0x2a000000,
-0x00050043,
+0x00050044,
 0xe35c0000,
 0xe1ca00f0,
 0xe1ca01f8,
@@ -5519,10 +5591,11 @@ static const unsigned int build_actionlist[5702] = {
 0xe2400000,
 0x000a0000,
 0xe19710b0,
-0xe2511001,
+0xe2511000,
+0x000a0000,
 0xe18710b0,
-0x0a000000,
-0x00050091,
+0x3a000000,
+0x00050092,
 0x00000000,
 0xe1aa00d9,
 0x00000000,
@@ -5550,10 +5623,11 @@ static const unsigned int build_actionlist[5702] = {
 0xe2400000,
 0x000a0000,
 0xe19710b0,
-0xe2511001,
+0xe2511000,
+0x000a0000,
 0xe18710b0,
-0x0a000000,
-0x00050091,
+0x3a000000,
+0x00050092,
 0x00000000,
 0xe5d6c000,
 0xe496e004,
@@ -5590,10 +5664,11 @@ static const unsigned int build_actionlist[5702] = {
 0xe2400000,
 0x000a0000,
 0xe19710b0,
-0xe2511001,
+0xe2511000,
+0x000a0000,
 0xe18710b0,
-0x0a000000,
-0x00050093,
+0x3a000000,
+0x00050094,
 0x00000000,
 0xe5180000,
 0x000d8180,
@@ -5738,6 +5813,7 @@ enum {
   GLOB_vmeta_call,
   GLOB_vm_call_dispatch_f,
   GLOB_vm_cpcall,
+  GLOB_cont_ffi_callback,
   GLOB_vm_call_tail,
   GLOB_cont_cat,
   GLOB_BC_CAT_Z,
@@ -5852,6 +5928,7 @@ enum {
   GLOB_vm_mod,
   GLOB_vm_modi,
   GLOB_vm_foldarith,
+  GLOB_vm_ffi_callback,
   GLOB_vm_ffi_call,
   GLOB_BC_ISEQN_Z,
   GLOB_BC_ISNEN_Z,
@@ -5885,6 +5962,7 @@ static const char *const globnames[] = {
   "vmeta_call",
   "vm_call_dispatch_f",
   "vm_cpcall",
+  "cont_ffi_callback",
   "vm_call_tail",
   "cont_cat",
   "BC_CAT_Z",
@@ -5999,6 +6077,7 @@ static const char *const globnames[] = {
   "vm_mod",
   "vm_modi",
   "vm_foldarith",
+  "vm_ffi_callback",
   "vm_ffi_call",
   "BC_ISEQN_Z",
   "BC_ISNEN_Z",
@@ -6060,6 +6139,8 @@ static const char *const extnames[] = {
   "__aeabi_ddiv",
   "__aeabi_dadd",
   "__aeabi_dsub",
+  "lj_ccallback_enter",
+  "lj_ccallback_leave",
   "__aeabi_cdcmpeq",
   "lj_meta_cat",
   "lj_gc_barrieruv",
@@ -6104,329 +6185,349 @@ static void build_subroutines(BuildCtx *ctx)
   dasm_put(Dst, 108, ~CFRAME_RAWMASK, Dt1(->base), Dt1(->glref), ~LJ_TFALSE, GG_G2DISP, LJ_VMST_INTERP, DISPATCH_GL(vmstate), LUA_MINSTACK, Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top), Dt7(->field_pc), Dt1(->glref));
   dasm_put(Dst, 173, GG_G2DISP, FRAME_CP, CFRAME_RESUME, Dt1(->status), Dt1(->cframe), Dt1(->base), Dt1(->top), Dt1(->status), LJ_VMST_INTERP, FRAME_TYPE, DISPATCH_GL(vmstate), FRAME_CP, FRAME_C, Dt1(->cframe), Dt1(->cframe));
   dasm_put(Dst, 238, Dt1(->glref), GG_G2DISP, Dt1(->base), Dt1(->top), LJ_VMST_INTERP, DISPATCH_GL(vmstate), -LJ_TFUNC, Dt7(->field_pc), Dt1(->stack), Dt1(->top), Dt1(->cframe), Dt1(->cframe), Dt1(->glref), FRAME_CP, GG_G2DISP);
-  dasm_put(Dst, 307, Dt7(->field_pc), ~LJ_TNIL, PC2PROTO(k), Dt1(->base), -DISPATCH_GL(tmptv), ~LJ_TTAB, ~LJ_TSTR, ~LJ_TISNUM);
-  dasm_put(Dst, 378, Dt1(->base));
+  dasm_put(Dst, 307);
+#if LJ_HASFFI
+  dasm_put(Dst, 312);
+#endif
+  dasm_put(Dst, 314, Dt7(->field_pc), ~LJ_TNIL);
+#if LJ_HASFFI
+  dasm_put(Dst, 322);
+#endif
+  dasm_put(Dst, 325, PC2PROTO(k));
+#if LJ_HASFFI
+  dasm_put(Dst, 329);
+#endif
+  dasm_put(Dst, 338, Dt1(->base), -DISPATCH_GL(tmptv), ~LJ_TTAB, ~LJ_TSTR, ~LJ_TISNUM, Dt1(->base));
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 388, Dt1(->base));
+  dasm_put(Dst, 395, Dt1(->base));
   }
-  dasm_put(Dst, 391, FRAME_CONT, Dt1(->top), -DISPATCH_GL(tmptv), ~LJ_TTAB, ~LJ_TSTR, ~LJ_TISNUM, Dt1(->base));
+  dasm_put(Dst, 398, FRAME_CONT, Dt1(->top), -DISPATCH_GL(tmptv), ~LJ_TTAB, ~LJ_TSTR, ~LJ_TISNUM, Dt1(->base));
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 453, Dt1(->base));
+  dasm_put(Dst, 460, Dt1(->base));
   }
-  dasm_put(Dst, 456, FRAME_CONT, Dt1(->top), Dt1(->base));
+  dasm_put(Dst, 463, FRAME_CONT, Dt1(->top), Dt1(->base));
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 492, Dt1(->base));
+  dasm_put(Dst, 499, Dt1(->base));
   }
-  dasm_put(Dst, 495, ~LJ_TTRUE, -LJ_TFALSE, Dt1(->base));
+  dasm_put(Dst, 502, ~LJ_TTRUE, -LJ_TFALSE, Dt1(->base));
 #if LJ_HASFFI
-  dasm_put(Dst, 542, Dt1(->base));
+  dasm_put(Dst, 549, Dt1(->base));
 #endif
-  dasm_put(Dst, 553, Dt1(->base));
+  dasm_put(Dst, 560, Dt1(->base));
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 590, Dt1(->base));
+  dasm_put(Dst, 597, Dt1(->base));
   }
-  dasm_put(Dst, 593, FRAME_CONT, Dt1(->base));
+  dasm_put(Dst, 600, FRAME_CONT, Dt1(->base));
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 614, Dt1(->base));
+  dasm_put(Dst, 621, Dt1(->base));
   }
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-  dasm_put(Dst, 617);
-#else
   dasm_put(Dst, 624);
+#else
+  dasm_put(Dst, 631);
 #endif
-  dasm_put(Dst, 627, Dt1(->base));
+  dasm_put(Dst, 634, Dt1(->base));
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 635);
+  dasm_put(Dst, 642);
   }
-  dasm_put(Dst, 637);
+  dasm_put(Dst, 644);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 640);
+  dasm_put(Dst, 647);
   }
-  dasm_put(Dst, 642, Dt7(->field_pc), Dt1(->base));
+  dasm_put(Dst, 649, Dt7(->field_pc), Dt1(->base));
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 663, Dt1(->base));
+  dasm_put(Dst, 670, Dt1(->base));
   }
-  dasm_put(Dst, 666, Dt1(->base));
+  dasm_put(Dst, 673, Dt1(->base));
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 680, Dt1(->base));
+  dasm_put(Dst, 687, Dt1(->base));
   }
 #if LJ_HASJIT
-  dasm_put(Dst, 683);
+  dasm_put(Dst, 690);
 #endif
-  dasm_put(Dst, 685);
+  dasm_put(Dst, 692);
 #if LJ_HASJIT
-  dasm_put(Dst, 687, BC_JFORI);
+  dasm_put(Dst, 694, BC_JFORI);
 #endif
-  dasm_put(Dst, 690);
+  dasm_put(Dst, 697);
 #if LJ_HASJIT
-  dasm_put(Dst, 693, BC_JFORI);
+  dasm_put(Dst, 700, BC_JFORI);
 #endif
-  dasm_put(Dst, 696, BC_FORI, -LJ_TTRUE, -LJ_TISNUM, ~LJ_TISNUM, (int)(offsetof(GCfuncC, upvalue)>>3)-1, -LJ_TTAB, -LJ_TUDATA, Dt6(->metatable));
-  dasm_put(Dst, 753, ~LJ_TNIL, DISPATCH_GL(gcroot[GCROOT_MMNAME+MM_metatable]), Dt6(->hmask), Dt5(->hash), Dt6(->node), DtB(->key), DtB(->val), DtB(->next), -LJ_TSTR, ~LJ_TTAB, -LJ_TNIL, -LJ_TISNUM);
-  dasm_put(Dst, 801, ~LJ_TISNUM, DISPATCH_GL(gcroot[GCROOT_BASEMT]), -LJ_TTAB, Dt6(->metatable), -LJ_TTAB, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), DISPATCH_GL(gc.grayagain), LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist), -LJ_TTAB);
-  dasm_put(Dst, 853);
+  dasm_put(Dst, 703, BC_FORI, -LJ_TTRUE, -LJ_TISNUM, ~LJ_TISNUM, (int)(offsetof(GCfuncC, upvalue)>>3)-1, -LJ_TTAB, -LJ_TUDATA, Dt6(->metatable));
+  dasm_put(Dst, 760, ~LJ_TNIL, DISPATCH_GL(gcroot[GCROOT_MMNAME+MM_metatable]), Dt6(->hmask), Dt5(->hash), Dt6(->node), DtB(->key), DtB(->val), DtB(->next), -LJ_TSTR, ~LJ_TTAB, -LJ_TNIL, -LJ_TISNUM);
+  dasm_put(Dst, 808, ~LJ_TISNUM, DISPATCH_GL(gcroot[GCROOT_BASEMT]), -LJ_TTAB, Dt6(->metatable), -LJ_TTAB, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), DISPATCH_GL(gc.grayagain), LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist), -LJ_TTAB);
+  dasm_put(Dst, 860);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 858);
+  dasm_put(Dst, 865);
   }
-  dasm_put(Dst, 860);
+  dasm_put(Dst, 867);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 863);
+  dasm_put(Dst, 870);
   }
-  dasm_put(Dst, 865, -LJ_TISNUM, -LJ_TSTR, DISPATCH_GL(gcroot[GCROOT_BASEMT_NUM]), Dt1(->base), -LJ_TISNUM, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), ~LJ_TSTR);
-  dasm_put(Dst, 917, ~LJ_TNIL, -LJ_TTAB, Dt1(->base), Dt1(->top));
+  dasm_put(Dst, 872, -LJ_TISNUM, -LJ_TSTR, DISPATCH_GL(gcroot[GCROOT_BASEMT_NUM]), Dt1(->base), -LJ_TISNUM, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), ~LJ_TSTR);
+  dasm_put(Dst, 924, ~LJ_TNIL, -LJ_TTAB, Dt1(->base), Dt1(->top));
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 940, Dt1(->base));
+  dasm_put(Dst, 947, Dt1(->base));
   }
-  dasm_put(Dst, 943, ~LJ_TNIL, (2+1)*8, -LJ_TTAB);
+  dasm_put(Dst, 950, ~LJ_TNIL, (2+1)*8, -LJ_TTAB);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-  dasm_put(Dst, 966, Dt6(->metatable));
+  dasm_put(Dst, 973, Dt6(->metatable));
 #endif
-  dasm_put(Dst, 969, Dt8(->upvalue[0]));
+  dasm_put(Dst, 976, Dt8(->upvalue[0]));
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-  dasm_put(Dst, 973);
+  dasm_put(Dst, 980);
 #endif
-  dasm_put(Dst, 977, ~LJ_TNIL, (3+1)*8, -LJ_TTAB, -LJ_TISNUM, Dt6(->asize), Dt6(->array), (0+1)*8, -LJ_TNIL, (2+1)*8, Dt6(->hmask));
+  dasm_put(Dst, 984, ~LJ_TNIL, (3+1)*8, -LJ_TTAB, -LJ_TISNUM, Dt6(->asize), Dt6(->array), (0+1)*8, -LJ_TNIL, (2+1)*8, Dt6(->hmask));
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1027);
+  dasm_put(Dst, 1034);
   }
-  dasm_put(Dst, 1029);
+  dasm_put(Dst, 1036);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1032);
+  dasm_put(Dst, 1039);
   }
-  dasm_put(Dst, 1034, -LJ_TTAB);
+  dasm_put(Dst, 1041, -LJ_TTAB);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-  dasm_put(Dst, 1050, Dt6(->metatable));
+  dasm_put(Dst, 1057, Dt6(->metatable));
 #endif
-  dasm_put(Dst, 1053, Dt8(->upvalue[0]));
+  dasm_put(Dst, 1060, Dt8(->upvalue[0]));
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-  dasm_put(Dst, 1057);
+  dasm_put(Dst, 1064);
 #endif
-  dasm_put(Dst, 1061, ~LJ_TISNUM, (3+1)*8, DISPATCH_GL(hookmask), HOOK_ACTIVE, 8+FRAME_PCALL, 8+FRAME_PCALLH, DISPATCH_GL(hookmask), -LJ_TFUNC, HOOK_ACTIVE, 16+FRAME_PCALL, 16+FRAME_PCALLH, -LJ_TTHREAD);
-  dasm_put(Dst, 1120, Dt1(->base), Dt1(->top), Dt1(->status), Dt1(->base), Dt1(->maxstack), Dt1(->cframe), LUA_YIELD, Dt1(->top), Dt1(->top), Dt1(->base), LJ_VMST_INTERP, Dt1(->top), DISPATCH_GL(vmstate), LUA_YIELD);
-  dasm_put(Dst, 1179, Dt1(->base), Dt1(->maxstack), Dt1(->top), ~LJ_TTRUE, FRAME_TYPE, ~LJ_TFALSE, (2+1)*8, Dt1(->top));
-  dasm_put(Dst, 1239, Dt8(->upvalue[0].gcr), Dt1(->base), Dt1(->top), Dt1(->status), Dt1(->base), Dt1(->maxstack), Dt1(->cframe), LUA_YIELD, Dt1(->top), Dt1(->top), Dt1(->base), LJ_VMST_INTERP, Dt1(->top), DISPATCH_GL(vmstate), LUA_YIELD);
-  dasm_put(Dst, 1295, Dt1(->base), Dt1(->maxstack), Dt1(->top), FRAME_TYPE, Dt1(->cframe), Dt1(->base), CFRAME_RESUME, Dt1(->top));
-  dasm_put(Dst, 1354, LUA_YIELD, Dt1(->cframe), Dt1(->status), -LJ_TISNUM, ~LJ_TISNUM, ~LJ_TISNUM);
-  dasm_put(Dst, 1420, -LJ_TISNUM, ~LJ_TISNUM, ~LJ_TISNUM);
-  dasm_put(Dst, 1484, -LJ_TISNUM, (1+1)*8, FRAME_TYPE, ~LJ_TNIL);
-  dasm_put(Dst, 1548, -LJ_TISNUM);
+  dasm_put(Dst, 1068, ~LJ_TISNUM, (3+1)*8, DISPATCH_GL(hookmask), HOOK_ACTIVE, 8+FRAME_PCALL, 8+FRAME_PCALLH, DISPATCH_GL(hookmask), -LJ_TFUNC, HOOK_ACTIVE, 16+FRAME_PCALL, 16+FRAME_PCALLH, -LJ_TTHREAD);
+  dasm_put(Dst, 1127, Dt1(->base), Dt1(->top), Dt1(->status), Dt1(->base), Dt1(->maxstack), Dt1(->cframe), LUA_YIELD, Dt1(->top), Dt1(->top), Dt1(->base), LJ_VMST_INTERP, Dt1(->top), DISPATCH_GL(vmstate), LUA_YIELD);
+  dasm_put(Dst, 1186, Dt1(->base), Dt1(->maxstack), Dt1(->top), ~LJ_TTRUE, FRAME_TYPE, ~LJ_TFALSE, (2+1)*8, Dt1(->top));
+  dasm_put(Dst, 1246, Dt8(->upvalue[0].gcr), Dt1(->base), Dt1(->top), Dt1(->status), Dt1(->base), Dt1(->maxstack), Dt1(->cframe), LUA_YIELD, Dt1(->top), Dt1(->top), Dt1(->base), LJ_VMST_INTERP, Dt1(->top), DISPATCH_GL(vmstate), LUA_YIELD);
+  dasm_put(Dst, 1302, Dt1(->base), Dt1(->maxstack), Dt1(->top), FRAME_TYPE, Dt1(->cframe), Dt1(->base), CFRAME_RESUME, Dt1(->top));
+  dasm_put(Dst, 1361, LUA_YIELD, Dt1(->cframe), Dt1(->status), -LJ_TISNUM, ~LJ_TISNUM, ~LJ_TISNUM);
+  dasm_put(Dst, 1427, -LJ_TISNUM, ~LJ_TISNUM, ~LJ_TISNUM);
+  dasm_put(Dst, 1491, -LJ_TISNUM, (1+1)*8, FRAME_TYPE, ~LJ_TNIL);
+  dasm_put(Dst, 1555, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1553);
+  dasm_put(Dst, 1560);
   }
-  dasm_put(Dst, 1555);
+  dasm_put(Dst, 1562);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1558);
+  dasm_put(Dst, 1565);
   }
-  dasm_put(Dst, 1560, -LJ_TISNUM);
+  dasm_put(Dst, 1567, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1572);
+  dasm_put(Dst, 1579);
   }
-  dasm_put(Dst, 1574);
+  dasm_put(Dst, 1581);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1577);
+  dasm_put(Dst, 1584);
   }
-  dasm_put(Dst, 1579, -LJ_TISNUM);
+  dasm_put(Dst, 1586, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1591);
+  dasm_put(Dst, 1598);
   }
-  dasm_put(Dst, 1593);
+  dasm_put(Dst, 1600);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1596);
+  dasm_put(Dst, 1603);
   }
-  dasm_put(Dst, 1598, -LJ_TISNUM);
+  dasm_put(Dst, 1605, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1610);
+  dasm_put(Dst, 1617);
   }
-  dasm_put(Dst, 1612);
+  dasm_put(Dst, 1619);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1615);
+  dasm_put(Dst, 1622);
   }
-  dasm_put(Dst, 1617, -LJ_TISNUM);
+  dasm_put(Dst, 1624, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1629);
+  dasm_put(Dst, 1636);
   }
-  dasm_put(Dst, 1631);
+  dasm_put(Dst, 1638);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1634);
+  dasm_put(Dst, 1641);
   }
-  dasm_put(Dst, 1636, -LJ_TISNUM);
+  dasm_put(Dst, 1643, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1648);
+  dasm_put(Dst, 1655);
   }
-  dasm_put(Dst, 1650);
+  dasm_put(Dst, 1657);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1653);
+  dasm_put(Dst, 1660);
   }
-  dasm_put(Dst, 1655, -LJ_TISNUM);
+  dasm_put(Dst, 1662, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1667);
+  dasm_put(Dst, 1674);
   }
-  dasm_put(Dst, 1669);
+  dasm_put(Dst, 1676);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1672);
+  dasm_put(Dst, 1679);
   }
-  dasm_put(Dst, 1674, -LJ_TISNUM);
+  dasm_put(Dst, 1681, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1686);
+  dasm_put(Dst, 1693);
   }
-  dasm_put(Dst, 1688);
+  dasm_put(Dst, 1695);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1691);
+  dasm_put(Dst, 1698);
   }
-  dasm_put(Dst, 1693, -LJ_TISNUM);
+  dasm_put(Dst, 1700, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1705);
+  dasm_put(Dst, 1712);
   }
-  dasm_put(Dst, 1707);
+  dasm_put(Dst, 1714);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1710);
+  dasm_put(Dst, 1717);
   }
-  dasm_put(Dst, 1712, -LJ_TISNUM);
+  dasm_put(Dst, 1719, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1724);
+  dasm_put(Dst, 1731);
   }
-  dasm_put(Dst, 1726);
+  dasm_put(Dst, 1733);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1729);
+  dasm_put(Dst, 1736);
   }
-  dasm_put(Dst, 1731, -LJ_TISNUM);
+  dasm_put(Dst, 1738, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1743);
+  dasm_put(Dst, 1750);
   }
-  dasm_put(Dst, 1745);
+  dasm_put(Dst, 1752);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1748);
+  dasm_put(Dst, 1755);
   }
-  dasm_put(Dst, 1750, -LJ_TISNUM);
+  dasm_put(Dst, 1757, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1762);
+  dasm_put(Dst, 1769);
   }
-  dasm_put(Dst, 1764);
+  dasm_put(Dst, 1771);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1767);
+  dasm_put(Dst, 1774);
   }
-  dasm_put(Dst, 1769, -LJ_TISNUM);
+  dasm_put(Dst, 1776, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1781);
+  dasm_put(Dst, 1788);
   }
-  dasm_put(Dst, 1783);
+  dasm_put(Dst, 1790);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1786);
+  dasm_put(Dst, 1793);
   }
-  dasm_put(Dst, 1788, -LJ_TISNUM, -LJ_TISNUM);
+  dasm_put(Dst, 1795, -LJ_TISNUM, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1803);
+  dasm_put(Dst, 1810);
   }
-  dasm_put(Dst, 1805);
+  dasm_put(Dst, 1812);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1808);
+  dasm_put(Dst, 1815);
   }
-  dasm_put(Dst, 1810, -LJ_TISNUM, -LJ_TISNUM);
+  dasm_put(Dst, 1817, -LJ_TISNUM, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1825);
+  dasm_put(Dst, 1832);
   }
-  dasm_put(Dst, 1827);
+  dasm_put(Dst, 1834);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1830);
+  dasm_put(Dst, 1837);
   }
-  dasm_put(Dst, 1832, -LJ_TISNUM, -LJ_TISNUM);
+  dasm_put(Dst, 1839, -LJ_TISNUM, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1847);
+  dasm_put(Dst, 1854);
   }
-  dasm_put(Dst, 1849);
+  dasm_put(Dst, 1856);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1852);
+  dasm_put(Dst, 1859);
   }
-  dasm_put(Dst, 1854, -LJ_TISNUM, Dt8(->upvalue[0]), -LJ_TISNUM, -LJ_TISNUM);
+  dasm_put(Dst, 1861, -LJ_TISNUM, Dt8(->upvalue[0]), -LJ_TISNUM, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1887);
+  dasm_put(Dst, 1894);
   }
-  dasm_put(Dst, 1889);
+  dasm_put(Dst, 1896);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1892);
+  dasm_put(Dst, 1899);
   }
-  dasm_put(Dst, 1894, -LJ_TISNUM);
+  dasm_put(Dst, 1901, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1907);
+  dasm_put(Dst, 1914);
   }
-  dasm_put(Dst, 1909);
+  dasm_put(Dst, 1916);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1912);
+  dasm_put(Dst, 1919);
   }
-  dasm_put(Dst, 1914, ~LJ_TISNUM, (2+1)*8, -LJ_TISNUM);
+  dasm_put(Dst, 1921, ~LJ_TISNUM, (2+1)*8, -LJ_TISNUM);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1936);
+  dasm_put(Dst, 1943);
   }
-  dasm_put(Dst, 1938);
+  dasm_put(Dst, 1945);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 1941);
+  dasm_put(Dst, 1948);
   }
-  dasm_put(Dst, 1943, (2+1)*8, -LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM);
-  dasm_put(Dst, 1994, -LJ_TISNUM, -LJ_TISNUM);
-  dasm_put(Dst, 2048, -LJ_TISNUM, -LJ_TSTR, Dt5(->len), ~LJ_TISNUM, -LJ_TSTR, Dt5(->len), Dt5([1]));
-  dasm_put(Dst, 2102, ~LJ_TISNUM, (0+1)*8, (1+1)*8, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), -LJ_TISNUM, Dt1(->base), Dt1(->base), ~LJ_TSTR, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
-  dasm_put(Dst, 2161, -LJ_TISNUM, -LJ_TSTR, Dt5(->len), -LJ_TISNUM, sizeof(GCstr)-1, -DISPATCH_GL(strempty), ~LJ_TSTR, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), -LJ_TSTR, -LJ_TISNUM, Dt5(->len));
-  dasm_put(Dst, 2223, DISPATCH_GL(tmpbuf.sz), DISPATCH_GL(tmpbuf.buf), Dt5([1]), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), -LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), DISPATCH_GL(tmpbuf.buf), sizeof(GCstr));
-  dasm_put(Dst, 2276, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), -LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), DISPATCH_GL(tmpbuf.buf), sizeof(GCstr), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
-  dasm_put(Dst, 2336, -LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), DISPATCH_GL(tmpbuf.buf), sizeof(GCstr), -LJ_TTAB);
+  dasm_put(Dst, 1950, (2+1)*8, -LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM);
+  dasm_put(Dst, 2001, -LJ_TISNUM, -LJ_TISNUM);
+  dasm_put(Dst, 2055, -LJ_TISNUM, -LJ_TSTR, Dt5(->len), ~LJ_TISNUM, -LJ_TSTR, Dt5(->len), Dt5([1]));
+  dasm_put(Dst, 2109, ~LJ_TISNUM, (0+1)*8, (1+1)*8, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), -LJ_TISNUM, Dt1(->base), Dt1(->base), ~LJ_TSTR, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
+  dasm_put(Dst, 2168, -LJ_TISNUM, -LJ_TSTR, Dt5(->len), -LJ_TISNUM, sizeof(GCstr)-1, -DISPATCH_GL(strempty), ~LJ_TSTR, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), -LJ_TSTR, -LJ_TISNUM, Dt5(->len));
+  dasm_put(Dst, 2230, DISPATCH_GL(tmpbuf.sz), DISPATCH_GL(tmpbuf.buf), Dt5([1]), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), -LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), DISPATCH_GL(tmpbuf.buf), sizeof(GCstr));
+  dasm_put(Dst, 2283, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), -LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), DISPATCH_GL(tmpbuf.buf), sizeof(GCstr), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
+  dasm_put(Dst, 2343, -LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), DISPATCH_GL(tmpbuf.buf), sizeof(GCstr), -LJ_TTAB);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 2374);
+  dasm_put(Dst, 2381);
   }
-  dasm_put(Dst, 2376);
+  dasm_put(Dst, 2383);
   if (LJ_TARGET_OSX) {
-  dasm_put(Dst, 2379);
+  dasm_put(Dst, 2386);
   }
-  dasm_put(Dst, 2381, ~LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM);
-  dasm_put(Dst, 2452, -LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM);
-  dasm_put(Dst, 2512, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM);
-  dasm_put(Dst, 2568, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM);
-  dasm_put(Dst, 2625, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, Dt1(->maxstack), Dt1(->top), Dt8(->f), Dt1(->base), 8*LUA_MINSTACK, Dt1(->base), Dt1(->top), Dt7(->field_pc), FRAME_TYPE, FRAME_TYPEP);
-  dasm_put(Dst, 2688, LUA_MINSTACK, Dt1(->base), Dt1(->base), Dt1(->top), Dt1(->base));
+  dasm_put(Dst, 2388, ~LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM);
+  dasm_put(Dst, 2459, -LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM);
+  dasm_put(Dst, 2519, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM);
+  dasm_put(Dst, 2575, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM);
+  dasm_put(Dst, 2632, -LJ_TISNUM, -LJ_TISNUM, ~LJ_TISNUM, Dt1(->maxstack), Dt1(->top), Dt8(->f), Dt1(->base), 8*LUA_MINSTACK, Dt1(->base), Dt1(->top), Dt7(->field_pc), FRAME_TYPE, FRAME_TYPEP);
+  dasm_put(Dst, 2695, LUA_MINSTACK, Dt1(->base), Dt1(->base), Dt1(->top), Dt1(->base));
 #if LJ_HASJIT
-  dasm_put(Dst, 2722, DISPATCH_GL(hookmask), HOOK_VMEVENT, DISPATCH_GL(hookcount), HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount));
+  dasm_put(Dst, 2729, DISPATCH_GL(hookmask), HOOK_VMEVENT, DISPATCH_GL(hookcount), HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount));
 #endif
-  dasm_put(Dst, 2742, DISPATCH_GL(hookmask), HOOK_ACTIVE, GG_DISP2STATIC, DISPATCH_GL(hookmask), DISPATCH_GL(hookcount), HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount), LUA_MASKLINE, Dt1(->base), Dt1(->base));
-  dasm_put(Dst, 2788, GG_DISP2STATIC);
+  dasm_put(Dst, 2749, DISPATCH_GL(hookmask), HOOK_ACTIVE, GG_DISP2STATIC, DISPATCH_GL(hookmask), DISPATCH_GL(hookcount), HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount), LUA_MASKLINE, Dt1(->base), Dt1(->base));
+  dasm_put(Dst, 2795, GG_DISP2STATIC);
 #if LJ_HASJIT
-  dasm_put(Dst, 2804, -GG_DISP2J, Dt7(->field_pc), DISPATCH_J(L), PC2PROTO(framesize), Dt1(->base), Dt1(->top));
+  dasm_put(Dst, 2811, -GG_DISP2J, Dt7(->field_pc), DISPATCH_J(L), PC2PROTO(framesize), Dt1(->base), Dt1(->top));
 #endif
-  dasm_put(Dst, 2825);
+  dasm_put(Dst, 2832);
 #if LJ_HASJIT
-  dasm_put(Dst, 2828);
+  dasm_put(Dst, 2835);
 #endif
-  dasm_put(Dst, 2831);
+  dasm_put(Dst, 2838);
 #if LJ_HASJIT
-  dasm_put(Dst, 2833);
+  dasm_put(Dst, 2840);
 #endif
-  dasm_put(Dst, 2836, Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top));
+  dasm_put(Dst, 2843, Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top));
 #if LJ_HASJIT
-  dasm_put(Dst, 2859, LJ_VMST_EXIT, DISPATCH_GL(vmstate), DISPATCH_GL(jit_L), DISPATCH_GL(jit_base), DISPATCH_J(exitno), DISPATCH_J(L), Dt1(->base), DISPATCH_GL(jit_L), -GG_DISP2J, Dt1(->cframe), Dt1(->base), ~CFRAME_RAWMASK);
+  dasm_put(Dst, 2866, LJ_VMST_EXIT, DISPATCH_GL(vmstate), DISPATCH_GL(jit_L), DISPATCH_GL(jit_base), DISPATCH_J(exitno), DISPATCH_J(L), Dt1(->base), DISPATCH_GL(jit_L), -GG_DISP2J, Dt1(->cframe), Dt1(->base), ~CFRAME_RAWMASK);
 #endif
-  dasm_put(Dst, 2907);
+  dasm_put(Dst, 2914);
 #if LJ_HASJIT
-  dasm_put(Dst, 2909, Dt7(->field_pc), DISPATCH_GL(jit_L), LJ_VMST_INTERP, PC2PROTO(k), DISPATCH_GL(vmstate), BC_FUNCF);
+  dasm_put(Dst, 2916, Dt7(->field_pc), DISPATCH_GL(jit_L), LJ_VMST_INTERP, PC2PROTO(k), DISPATCH_GL(vmstate), BC_FUNCF);
 #endif
-  dasm_put(Dst, 2946);
+  dasm_put(Dst, 2953);
 #if LJ_HASJIT
-  dasm_put(Dst, 3020);
+  dasm_put(Dst, 3027);
 #endif
-  dasm_put(Dst, 3034);
+  dasm_put(Dst, 3041);
   {
     int i;
     for (i = 31; i >= 0; i--) {
-      dasm_put(Dst, 3070, i, i);
+      dasm_put(Dst, 3077, i, i);
     }
   }
-  dasm_put(Dst, 3075);
+  dasm_put(Dst, 3082);
 #if LJ_HASJIT
-  dasm_put(Dst, 3104);
+  dasm_put(Dst, 3111);
 #else
-  dasm_put(Dst, 3129);
+  dasm_put(Dst, 3136);
 #endif
-  dasm_put(Dst, 3131);
+  dasm_put(Dst, 3138);
 #if LJ_HASFFI
-#define DtE(_V) (int)(ptrdiff_t)&(((CCallState *)0)_V)
-  dasm_put(Dst, 3133, DtE(->spadj), DtE(->nsp), offsetof(CCallState, stack), DtE(->func), DtE(->gpr[0]), DtE(->gpr[1]), DtE(->gpr[2]), DtE(->gpr[3]), DtE(->gpr[0]), DtE(->gpr[1]));
+#define DtE(_V) (int)(ptrdiff_t)&(((CTState *)0)_V)
+  dasm_put(Dst, 3140, Dt2(->ctype_state), GG_G2DISP, DtE(->cb.gpr[0]), DtE(->cb.gpr[2]), CFRAME_SIZE, DtE(->cb.stack), DtE(->cb.slot), Dt1(->base), LJ_VMST_INTERP, Dt1(->top), DISPATCH_GL(vmstate), Dt7(->field_pc));
+#endif
+  dasm_put(Dst, 3183);
+#if LJ_HASFFI
+  dasm_put(Dst, 3185, DISPATCH_GL(ctype_state), Dt1(->base), Dt1(->top), DtE(->L), DtE(->cb.gpr[0]));
+#endif
+  dasm_put(Dst, 3202);
+#if LJ_HASFFI
+#define DtF(_V) (int)(ptrdiff_t)&(((CCallState *)0)_V)
+  dasm_put(Dst, 3204, DtF(->spadj), DtF(->nsp), offsetof(CCallState, stack), DtF(->func), DtF(->gpr[0]), DtF(->gpr[1]), DtF(->gpr[2]), DtF(->gpr[3]), DtF(->gpr[0]), DtF(->gpr[1]));
 #endif
 }
 
@@ -6434,7 +6535,7 @@ static void build_subroutines(BuildCtx *ctx)
 static void build_ins(BuildCtx *ctx, BCOp op, int defop)
 {
   int vk = 0;
-  dasm_put(Dst, 3171, defop);
+  dasm_put(Dst, 3242, defop);
 
   switch (op) {
 
@@ -6443,174 +6544,174 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
   /* Remember: all ops branch for a true comparison, fall through otherwise. */
 
   case BC_ISLT: case BC_ISGE: case BC_ISLE: case BC_ISGT:
-    dasm_put(Dst, 3173, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3244, -LJ_TISNUM, -LJ_TISNUM);
     if (op == BC_ISLT) {
-      dasm_put(Dst, 3189);
+      dasm_put(Dst, 3260);
     } else if (op == BC_ISGE) {
-      dasm_put(Dst, 3191);
+      dasm_put(Dst, 3262);
     } else if (op == BC_ISLE) {
-      dasm_put(Dst, 3193);
+      dasm_put(Dst, 3264);
     } else {
-      dasm_put(Dst, 3195);
+      dasm_put(Dst, 3266);
     }
-    dasm_put(Dst, 3197, -LJ_TISNUM);
+    dasm_put(Dst, 3268, -LJ_TISNUM);
     if (op == BC_ISLT) {
-      dasm_put(Dst, 3233);
+      dasm_put(Dst, 3304);
     } else if (op == BC_ISGE) {
-      dasm_put(Dst, 3235);
+      dasm_put(Dst, 3306);
     } else if (op == BC_ISLE) {
-      dasm_put(Dst, 3237);
+      dasm_put(Dst, 3308);
     } else {
-      dasm_put(Dst, 3239);
+      dasm_put(Dst, 3310);
     }
-    dasm_put(Dst, 3241);
+    dasm_put(Dst, 3312);
     break;
 
   case BC_ISEQV: case BC_ISNEV:
     vk = op == BC_ISEQV;
-    dasm_put(Dst, 3244, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3315, -LJ_TISNUM, -LJ_TISNUM);
     if (vk) {
-      dasm_put(Dst, 3255);
+      dasm_put(Dst, 3326);
     } else {
-      dasm_put(Dst, 3258);
+      dasm_put(Dst, 3329);
     }
     if (LJ_HASFFI) {
-      dasm_put(Dst, 3261, -LJ_TCDATA, -LJ_TCDATA);
+      dasm_put(Dst, 3332, -LJ_TCDATA, -LJ_TCDATA);
     }
-    dasm_put(Dst, 3268, -LJ_TISPRI);
+    dasm_put(Dst, 3339, -LJ_TISPRI);
     if (vk) {
-      dasm_put(Dst, 3277, -LJ_TISTABUD);
+      dasm_put(Dst, 3348, -LJ_TISTABUD);
     } else {
-      dasm_put(Dst, 3294, -LJ_TISTABUD);
+      dasm_put(Dst, 3365, -LJ_TISTABUD);
     }
-    dasm_put(Dst, 3301, Dt6(->metatable));
+    dasm_put(Dst, 3372, Dt6(->metatable));
     if (vk) {
-      dasm_put(Dst, 3305);
+      dasm_put(Dst, 3376);
     } else {
-      dasm_put(Dst, 3308);
+      dasm_put(Dst, 3379);
     }
-    dasm_put(Dst, 3311, Dt6(->nomm), 1-vk, 1<<MM_eq);
+    dasm_put(Dst, 3382, Dt6(->nomm), 1-vk, 1<<MM_eq);
     if (vk) {
-      dasm_put(Dst, 3321);
+      dasm_put(Dst, 3392);
     } else {
-      dasm_put(Dst, 3324);
+      dasm_put(Dst, 3395);
     }
     break;
 
   case BC_ISEQS: case BC_ISNES:
     vk = op == BC_ISEQS;
-    dasm_put(Dst, 3334, -LJ_TSTR);
+    dasm_put(Dst, 3405, -LJ_TSTR);
     if (LJ_HASFFI) {
-      dasm_put(Dst, 3343);
+      dasm_put(Dst, 3414);
     } else {
-      dasm_put(Dst, 3347);
+      dasm_put(Dst, 3418);
     }
     if (vk) {
-      dasm_put(Dst, 3349);
+      dasm_put(Dst, 3420);
     } else {
-      dasm_put(Dst, 3352);
+      dasm_put(Dst, 3423);
     }
-    dasm_put(Dst, 3355);
+    dasm_put(Dst, 3426);
     if (LJ_HASFFI) {
-      dasm_put(Dst, 3362, -LJ_TCDATA);
+      dasm_put(Dst, 3433, -LJ_TCDATA);
     }
     break;
 
   case BC_ISEQN: case BC_ISNEN:
     vk = op == BC_ISEQN;
-    dasm_put(Dst, 3370);
+    dasm_put(Dst, 3441);
     if (vk) {
-      dasm_put(Dst, 3377);
+      dasm_put(Dst, 3448);
     } else {
-      dasm_put(Dst, 3379);
+      dasm_put(Dst, 3450);
     }
-    dasm_put(Dst, 3381, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3452, -LJ_TISNUM, -LJ_TISNUM);
     if (vk) {
-      dasm_put(Dst, 3391);
+      dasm_put(Dst, 3462);
     } else {
-      dasm_put(Dst, 3394);
+      dasm_put(Dst, 3465);
     }
-    dasm_put(Dst, 3397);
+    dasm_put(Dst, 3468);
     if (LJ_HASFFI) {
-      dasm_put(Dst, 3406);
+      dasm_put(Dst, 3477);
     } else {
       if (!vk) {
-	dasm_put(Dst, 3409);
+	dasm_put(Dst, 3480);
       }
-      dasm_put(Dst, 3411);
+      dasm_put(Dst, 3482);
     }
-    dasm_put(Dst, 3414, -LJ_TISNUM);
+    dasm_put(Dst, 3485, -LJ_TISNUM);
     if (vk) {
-      dasm_put(Dst, 3430);
+      dasm_put(Dst, 3501);
     } else {
-      dasm_put(Dst, 3432);
+      dasm_put(Dst, 3503);
     }
-    dasm_put(Dst, 3434);
+    dasm_put(Dst, 3505);
     if (LJ_HASFFI) {
-      dasm_put(Dst, 3437, -LJ_TCDATA);
+      dasm_put(Dst, 3508, -LJ_TCDATA);
     }
     break;
 
   case BC_ISEQP: case BC_ISNEP:
     vk = op == BC_ISEQP;
-    dasm_put(Dst, 3445);
+    dasm_put(Dst, 3516);
     if (LJ_HASFFI) {
-      dasm_put(Dst, 3451, -LJ_TCDATA);
+      dasm_put(Dst, 3522, -LJ_TCDATA);
     }
-    dasm_put(Dst, 3456);
+    dasm_put(Dst, 3527);
     if (vk) {
-      dasm_put(Dst, 3458);
+      dasm_put(Dst, 3529);
     } else {
-      dasm_put(Dst, 3460);
+      dasm_put(Dst, 3531);
     }
-    dasm_put(Dst, 3462);
+    dasm_put(Dst, 3533);
     break;
 
   /* -- Unary test and copy ops ------------------------------------------- */
 
   case BC_ISTC: case BC_ISFC: case BC_IST: case BC_ISF:
-    dasm_put(Dst, 3469, -LJ_TTRUE);
+    dasm_put(Dst, 3540, -LJ_TTRUE);
     if (op == BC_ISTC || op == BC_IST) {
-      dasm_put(Dst, 3477);
+      dasm_put(Dst, 3548);
       if (op == BC_ISTC) {
-	dasm_put(Dst, 3479);
+	dasm_put(Dst, 3550);
       }
     } else {
-      dasm_put(Dst, 3481);
+      dasm_put(Dst, 3552);
       if (op == BC_ISFC) {
-	dasm_put(Dst, 3483);
+	dasm_put(Dst, 3554);
       }
     }
-    dasm_put(Dst, 3485);
+    dasm_put(Dst, 3556);
     break;
 
   /* -- Unary ops --------------------------------------------------------- */
 
   case BC_MOV:
-    dasm_put(Dst, 3492);
+    dasm_put(Dst, 3563);
     break;
   case BC_NOT:
-    dasm_put(Dst, 3502, -LJ_TTRUE, ~LJ_TFALSE, ~LJ_TTRUE);
+    dasm_put(Dst, 3573, -LJ_TTRUE, ~LJ_TFALSE, ~LJ_TTRUE);
     break;
   case BC_UNM:
-    dasm_put(Dst, 3519, -LJ_TISNUM);
+    dasm_put(Dst, 3590, -LJ_TISNUM);
     break;
   case BC_LEN:
-    dasm_put(Dst, 3545, -LJ_TSTR, Dt5(->len), ~LJ_TISNUM, -LJ_TTAB);
+    dasm_put(Dst, 3616, -LJ_TSTR, Dt5(->len), ~LJ_TISNUM, -LJ_TTAB);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-    dasm_put(Dst, 3569, Dt6(->metatable));
+    dasm_put(Dst, 3640, Dt6(->metatable));
 #endif
-    dasm_put(Dst, 3576);
+    dasm_put(Dst, 3647);
     if (LJ_TARGET_OSX) {
-    dasm_put(Dst, 3578);
+    dasm_put(Dst, 3649);
     }
-    dasm_put(Dst, 3580);
+    dasm_put(Dst, 3651);
     if (LJ_TARGET_OSX) {
-    dasm_put(Dst, 3583);
+    dasm_put(Dst, 3654);
     }
-    dasm_put(Dst, 3585);
+    dasm_put(Dst, 3656);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-    dasm_put(Dst, 3588, Dt6(->nomm), 1<<MM_len);
+    dasm_put(Dst, 3659, Dt6(->nomm), 1<<MM_len);
 #endif
     break;
 
@@ -6618,403 +6719,403 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
 
 
   case BC_ADDVN: case BC_ADDNV: case BC_ADDVV:
-    dasm_put(Dst, 3598);
+    dasm_put(Dst, 3669);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 3601);
+    dasm_put(Dst, 3672);
       break;
     case 1:
-    dasm_put(Dst, 3604);
+    dasm_put(Dst, 3675);
       break;
     default:
-    dasm_put(Dst, 3607);
+    dasm_put(Dst, 3678);
       break;
     }
-    dasm_put(Dst, 3610);
+    dasm_put(Dst, 3681);
     if (vk == 1) {
-    dasm_put(Dst, 3612, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3683, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 3617, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3688, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 3622);
+    dasm_put(Dst, 3693);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 3626);
+    dasm_put(Dst, 3697);
       break;
     case 1:
-    dasm_put(Dst, 3629);
+    dasm_put(Dst, 3700);
       break;
     default:
-    dasm_put(Dst, 3632);
+    dasm_put(Dst, 3703);
       break;
     }
-    dasm_put(Dst, 3635);
+    dasm_put(Dst, 3706);
     switch (vk) {
     case 0:
     if (vk == 1) {
-    dasm_put(Dst, 3644, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3715, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 3649, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3720, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 3654);
+    dasm_put(Dst, 3725);
       break;
     case 1:
     if (vk == 1) {
-    dasm_put(Dst, 3657, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3728, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 3662, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3733, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 3667);
+    dasm_put(Dst, 3738);
       break;
     default:
     if (vk == 1) {
-    dasm_put(Dst, 3670, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3741, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 3675, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3746, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 3680);
+    dasm_put(Dst, 3751);
       break;
     }
-    dasm_put(Dst, 3683);
+    dasm_put(Dst, 3754);
     break;
   case BC_SUBVN: case BC_SUBNV: case BC_SUBVV:
-    dasm_put(Dst, 3689);
+    dasm_put(Dst, 3760);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 3692);
+    dasm_put(Dst, 3763);
       break;
     case 1:
-    dasm_put(Dst, 3695);
+    dasm_put(Dst, 3766);
       break;
     default:
-    dasm_put(Dst, 3698);
+    dasm_put(Dst, 3769);
       break;
     }
-    dasm_put(Dst, 3701);
+    dasm_put(Dst, 3772);
     if (vk == 1) {
-    dasm_put(Dst, 3703, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3774, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 3708, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3779, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 3713);
+    dasm_put(Dst, 3784);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 3717);
+    dasm_put(Dst, 3788);
       break;
     case 1:
-    dasm_put(Dst, 3720);
+    dasm_put(Dst, 3791);
       break;
     default:
-    dasm_put(Dst, 3723);
+    dasm_put(Dst, 3794);
       break;
     }
-    dasm_put(Dst, 3726);
+    dasm_put(Dst, 3797);
     switch (vk) {
     case 0:
     if (vk == 1) {
-    dasm_put(Dst, 3735, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3806, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 3740, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3811, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 3745);
+    dasm_put(Dst, 3816);
       break;
     case 1:
     if (vk == 1) {
-    dasm_put(Dst, 3748, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3819, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 3753, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3824, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 3758);
+    dasm_put(Dst, 3829);
       break;
     default:
     if (vk == 1) {
-    dasm_put(Dst, 3761, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3832, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 3766, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3837, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 3771);
+    dasm_put(Dst, 3842);
       break;
     }
-    dasm_put(Dst, 3774);
+    dasm_put(Dst, 3845);
     break;
   case BC_MULVN: case BC_MULNV: case BC_MULVV:
-    dasm_put(Dst, 3780);
+    dasm_put(Dst, 3851);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 3783);
+    dasm_put(Dst, 3854);
       break;
     case 1:
-    dasm_put(Dst, 3786);
+    dasm_put(Dst, 3857);
       break;
     default:
-    dasm_put(Dst, 3789);
+    dasm_put(Dst, 3860);
       break;
     }
-    dasm_put(Dst, 3792);
+    dasm_put(Dst, 3863);
     if (vk == 1) {
-    dasm_put(Dst, 3794, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3865, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 3799, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3870, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 3804);
+    dasm_put(Dst, 3875);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 3809);
+    dasm_put(Dst, 3880);
       break;
     case 1:
-    dasm_put(Dst, 3812);
+    dasm_put(Dst, 3883);
       break;
     default:
-    dasm_put(Dst, 3815);
+    dasm_put(Dst, 3886);
       break;
     }
-    dasm_put(Dst, 3818);
+    dasm_put(Dst, 3889);
     switch (vk) {
     case 0:
     if (vk == 1) {
-    dasm_put(Dst, 3827, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3898, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 3832, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3903, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 3837);
+    dasm_put(Dst, 3908);
       break;
     case 1:
     if (vk == 1) {
-    dasm_put(Dst, 3840, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3911, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 3845, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3916, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 3850);
+    dasm_put(Dst, 3921);
       break;
     default:
     if (vk == 1) {
-    dasm_put(Dst, 3853, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3924, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 3858, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3929, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 3863);
+    dasm_put(Dst, 3934);
       break;
     }
-    dasm_put(Dst, 3866);
+    dasm_put(Dst, 3937);
     break;
   case BC_DIVVN: case BC_DIVNV: case BC_DIVVV:
-    dasm_put(Dst, 3872);
+    dasm_put(Dst, 3943);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 3875);
+    dasm_put(Dst, 3946);
       break;
     case 1:
-    dasm_put(Dst, 3878);
+    dasm_put(Dst, 3949);
       break;
     default:
-    dasm_put(Dst, 3881);
+    dasm_put(Dst, 3952);
       break;
     }
     switch (vk) {
     case 0:
     if (vk == 1) {
-    dasm_put(Dst, 3884, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3955, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 3889, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3960, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 3894);
+    dasm_put(Dst, 3965);
       break;
     case 1:
     if (vk == 1) {
-    dasm_put(Dst, 3897, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3968, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 3902, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3973, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 3907);
+    dasm_put(Dst, 3978);
       break;
     default:
     if (vk == 1) {
-    dasm_put(Dst, 3910, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3981, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 3915, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 3986, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 3920);
+    dasm_put(Dst, 3991);
       break;
     }
-    dasm_put(Dst, 3923);
+    dasm_put(Dst, 3994);
     break;
   case BC_MODVN: case BC_MODNV: case BC_MODVV:
-    dasm_put(Dst, 3933);
+    dasm_put(Dst, 4004);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 3936);
+    dasm_put(Dst, 4007);
       break;
     case 1:
-    dasm_put(Dst, 3939);
+    dasm_put(Dst, 4010);
       break;
     default:
-    dasm_put(Dst, 3942);
+    dasm_put(Dst, 4013);
       break;
     }
     if (vk == 1) {
-    dasm_put(Dst, 3945, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 4016, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 3950, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 4021, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 3955);
+    dasm_put(Dst, 4026);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 3959);
+    dasm_put(Dst, 4030);
       break;
     case 1:
-    dasm_put(Dst, 3962);
+    dasm_put(Dst, 4033);
       break;
     default:
-    dasm_put(Dst, 3965);
+    dasm_put(Dst, 4036);
       break;
     }
-    dasm_put(Dst, 3968, ~LJ_TISNUM);
+    dasm_put(Dst, 4039, ~LJ_TISNUM);
     switch (vk) {
     case 0:
     if (vk == 1) {
-    dasm_put(Dst, 3982, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 4053, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 3987, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 4058, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 3992);
+    dasm_put(Dst, 4063);
       break;
     case 1:
     if (vk == 1) {
-    dasm_put(Dst, 3995, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 4066, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 4000, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 4071, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 4005);
+    dasm_put(Dst, 4076);
       break;
     default:
     if (vk == 1) {
-    dasm_put(Dst, 4008, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 4079, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 4013, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 4084, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 4018);
+    dasm_put(Dst, 4089);
       break;
     }
-    dasm_put(Dst, 4021);
+    dasm_put(Dst, 4092);
     break;
   case BC_POW:
-    dasm_put(Dst, 4026);
+    dasm_put(Dst, 4097);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 4029);
+    dasm_put(Dst, 4100);
       break;
     case 1:
-    dasm_put(Dst, 4032);
+    dasm_put(Dst, 4103);
       break;
     default:
-    dasm_put(Dst, 4035);
+    dasm_put(Dst, 4106);
       break;
     }
     switch (vk) {
     case 0:
     if (vk == 1) {
-    dasm_put(Dst, 4038, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 4109, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 4043, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 4114, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 4048);
+    dasm_put(Dst, 4119);
       break;
     case 1:
     if (vk == 1) {
-    dasm_put(Dst, 4051, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 4122, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 4056, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 4127, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 4061);
+    dasm_put(Dst, 4132);
       break;
     default:
     if (vk == 1) {
-    dasm_put(Dst, 4064, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 4135, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-    dasm_put(Dst, 4069, -LJ_TISNUM, -LJ_TISNUM);
+    dasm_put(Dst, 4140, -LJ_TISNUM, -LJ_TISNUM);
     }
-    dasm_put(Dst, 4074);
+    dasm_put(Dst, 4145);
       break;
     }
     if (LJ_TARGET_OSX) {
-    dasm_put(Dst, 4077);
+    dasm_put(Dst, 4148);
     }
-    dasm_put(Dst, 4079);
+    dasm_put(Dst, 4150);
     if (LJ_TARGET_OSX) {
-    dasm_put(Dst, 4082);
+    dasm_put(Dst, 4153);
     }
-    dasm_put(Dst, 4084);
+    dasm_put(Dst, 4155);
     break;
 
   case BC_CAT:
-    dasm_put(Dst, 4092, Dt1(->base), Dt1(->base));
+    dasm_put(Dst, 4163, Dt1(->base), Dt1(->base));
     break;
 
   /* -- Constant ops ------------------------------------------------------ */
 
   case BC_KSTR:
-    dasm_put(Dst, 4118, ~LJ_TSTR);
+    dasm_put(Dst, 4189, ~LJ_TSTR);
     break;
   case BC_KCDATA:
 #if LJ_HASFFI
-    dasm_put(Dst, 4130, ~LJ_TCDATA);
+    dasm_put(Dst, 4201, ~LJ_TCDATA);
 #endif
     break;
   case BC_KSHORT:
-    dasm_put(Dst, 4142, ~LJ_TISNUM);
+    dasm_put(Dst, 4213, ~LJ_TISNUM);
     break;
   case BC_KNUM:
-    dasm_put(Dst, 4153);
+    dasm_put(Dst, 4224);
     break;
   case BC_KPRI:
-    dasm_put(Dst, 4163);
+    dasm_put(Dst, 4234);
     break;
   case BC_KNIL:
-    dasm_put(Dst, 4173, ~LJ_TNIL);
+    dasm_put(Dst, 4244, ~LJ_TNIL);
     break;
 
   /* -- Upvalue and function ops ------------------------------------------ */
 
   case BC_UGET:
-    dasm_put(Dst, 4192, offsetof(GCfuncL, uvptr), DtA(->v));
+    dasm_put(Dst, 4263, offsetof(GCfuncL, uvptr), DtA(->v));
     break;
   case BC_USETV:
-    dasm_put(Dst, 4208, offsetof(GCfuncL, uvptr), DtA(->marked), DtA(->closed), DtA(->v), LJ_GC_BLACK, -LJ_TISGCV, -(LJ_TISNUM - LJ_TISGCV), Dt4(->gch.marked), -GG_DISP2G, LJ_GC_WHITES);
+    dasm_put(Dst, 4279, offsetof(GCfuncL, uvptr), DtA(->marked), DtA(->closed), DtA(->v), LJ_GC_BLACK, -LJ_TISGCV, -(LJ_TISNUM - LJ_TISGCV), Dt4(->gch.marked), -GG_DISP2G, LJ_GC_WHITES);
     if (LJ_TARGET_OSX) {
-      dasm_put(Dst, 4248);
+      dasm_put(Dst, 4319);
     } else {
-      dasm_put(Dst, 4255);
+      dasm_put(Dst, 4326);
     }
-    dasm_put(Dst, 4258);
+    dasm_put(Dst, 4329);
     break;
   case BC_USETS:
-    dasm_put(Dst, 4261, offsetof(GCfuncL, uvptr), ~LJ_TSTR, DtA(->marked), DtA(->v), DtA(->closed), LJ_GC_BLACK, Dt5(->marked), LJ_GC_WHITES, -GG_DISP2G);
+    dasm_put(Dst, 4332, offsetof(GCfuncL, uvptr), ~LJ_TSTR, DtA(->marked), DtA(->v), DtA(->closed), LJ_GC_BLACK, Dt5(->marked), LJ_GC_WHITES, -GG_DISP2G);
     if (LJ_TARGET_OSX) {
-      dasm_put(Dst, 4297);
+      dasm_put(Dst, 4368);
     } else {
-      dasm_put(Dst, 4304);
+      dasm_put(Dst, 4375);
     }
-    dasm_put(Dst, 4307);
+    dasm_put(Dst, 4378);
     break;
   case BC_USETN:
-    dasm_put(Dst, 4310, offsetof(GCfuncL, uvptr), DtA(->v));
+    dasm_put(Dst, 4381, offsetof(GCfuncL, uvptr), DtA(->v));
     break;
   case BC_USETP:
-    dasm_put(Dst, 4327, offsetof(GCfuncL, uvptr), DtA(->v));
+    dasm_put(Dst, 4398, offsetof(GCfuncL, uvptr), DtA(->v));
     break;
 
   case BC_UCLO:
-    dasm_put(Dst, 4343, Dt1(->openupval), Dt1(->base), Dt1(->base));
+    dasm_put(Dst, 4414, Dt1(->openupval), Dt1(->base), Dt1(->base));
     break;
 
   case BC_FNEW:
-    dasm_put(Dst, 4366, Dt1(->base), Dt1(->base), ~LJ_TFUNC);
+    dasm_put(Dst, 4437, Dt1(->base), Dt1(->base), ~LJ_TFUNC);
     break;
 
   /* -- Table ops --------------------------------------------------------- */
@@ -7022,115 +7123,115 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
   case BC_TNEW:
   case BC_TDUP:
     if (op == BC_TDUP) {
-      dasm_put(Dst, 4387);
+      dasm_put(Dst, 4458);
     }
-    dasm_put(Dst, 4389, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base));
+    dasm_put(Dst, 4460, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base));
     if (op == BC_TNEW) {
-      dasm_put(Dst, 4402);
+      dasm_put(Dst, 4473);
     } else {
-      dasm_put(Dst, 4411);
+      dasm_put(Dst, 4482);
     }
-    dasm_put(Dst, 4415, Dt1(->base), ~LJ_TTAB);
+    dasm_put(Dst, 4486, Dt1(->base), ~LJ_TTAB);
     break;
 
   case BC_GGET:
   case BC_GSET:
-    dasm_put(Dst, 4433, Dt7(->env));
+    dasm_put(Dst, 4504, Dt7(->env));
     if (op == BC_GGET) {
-      dasm_put(Dst, 4439);
+      dasm_put(Dst, 4510);
     } else {
-      dasm_put(Dst, 4442);
+      dasm_put(Dst, 4513);
     }
     break;
 
   case BC_TGETV:
-    dasm_put(Dst, 4445, -LJ_TTAB, -LJ_TISNUM, Dt6(->array), Dt6(->asize), -LJ_TNIL, Dt6(->metatable), Dt6(->nomm), 1<<MM_index, -LJ_TSTR);
+    dasm_put(Dst, 4516, -LJ_TTAB, -LJ_TISNUM, Dt6(->array), Dt6(->asize), -LJ_TNIL, Dt6(->metatable), Dt6(->nomm), 1<<MM_index, -LJ_TSTR);
     break;
   case BC_TGETS:
-    dasm_put(Dst, 4502, -LJ_TTAB, Dt6(->hmask), Dt5(->hash), Dt6(->node), DtB(->key), DtB(->val), DtB(->next), -LJ_TSTR, -LJ_TNIL, Dt6(->metatable), ~LJ_TNIL, Dt6(->nomm));
-    dasm_put(Dst, 4562, 1<<MM_index);
+    dasm_put(Dst, 4573, -LJ_TTAB, Dt6(->hmask), Dt5(->hash), Dt6(->node), DtB(->key), DtB(->val), DtB(->next), -LJ_TSTR, -LJ_TNIL, Dt6(->metatable), ~LJ_TNIL, Dt6(->nomm));
+    dasm_put(Dst, 4633, 1<<MM_index);
     break;
   case BC_TGETB:
-    dasm_put(Dst, 4569, -LJ_TTAB, Dt6(->asize), Dt6(->array), -LJ_TNIL, Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
+    dasm_put(Dst, 4640, -LJ_TTAB, Dt6(->asize), Dt6(->array), -LJ_TNIL, Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
     break;
 
   case BC_TSETV:
-    dasm_put(Dst, 4612, -LJ_TTAB, -LJ_TISNUM, Dt6(->array), Dt6(->asize), -LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex);
-    dasm_put(Dst, 4672, DISPATCH_GL(gc.grayagain), LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist), -LJ_TSTR);
+    dasm_put(Dst, 4683, -LJ_TTAB, -LJ_TISNUM, Dt6(->array), Dt6(->asize), -LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex);
+    dasm_put(Dst, 4743, DISPATCH_GL(gc.grayagain), LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist), -LJ_TSTR);
     break;
   case BC_TSETS:
-    dasm_put(Dst, 4693, -LJ_TTAB, Dt6(->hmask), Dt5(->hash), Dt6(->node), Dt6(->nomm), DtB(->key), DtB(->val.it), DtB(->next), -LJ_TSTR, Dt6(->marked), -LJ_TNIL, LJ_GC_BLACK, DtB(->val));
-    dasm_put(Dst, 4751, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, Dt6(->metatable), Dt1(->base), Dt6(->nomm), 1<<MM_newindex, ~LJ_TSTR, Dt1(->base), DISPATCH_GL(gc.grayagain), LJ_GC_BLACK);
-    dasm_put(Dst, 4804, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
+    dasm_put(Dst, 4764, -LJ_TTAB, Dt6(->hmask), Dt5(->hash), Dt6(->node), Dt6(->nomm), DtB(->key), DtB(->val.it), DtB(->next), -LJ_TSTR, Dt6(->marked), -LJ_TNIL, LJ_GC_BLACK, DtB(->val));
+    dasm_put(Dst, 4822, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, Dt6(->metatable), Dt1(->base), Dt6(->nomm), 1<<MM_newindex, ~LJ_TSTR, Dt1(->base), DISPATCH_GL(gc.grayagain), LJ_GC_BLACK);
+    dasm_put(Dst, 4875, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
     break;
   case BC_TSETB:
-    dasm_put(Dst, 4813, -LJ_TTAB, Dt6(->asize), Dt6(->array), -LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, DISPATCH_GL(gc.grayagain), LJ_GC_BLACK);
-    dasm_put(Dst, 4871, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
+    dasm_put(Dst, 4884, -LJ_TTAB, Dt6(->asize), Dt6(->array), -LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, DISPATCH_GL(gc.grayagain), LJ_GC_BLACK);
+    dasm_put(Dst, 4942, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
     break;
 
   case BC_TSETM:
-    dasm_put(Dst, 4880, Dt6(->asize), Dt6(->array), Dt6(->marked), LJ_GC_BLACK, Dt1(->base));
+    dasm_put(Dst, 4951, Dt6(->asize), Dt6(->array), Dt6(->marked), LJ_GC_BLACK, Dt1(->base));
     if (LJ_TARGET_OSX) {
-    dasm_put(Dst, 4925, Dt1(->base));
+    dasm_put(Dst, 4996, Dt1(->base));
     }
-    dasm_put(Dst, 4928, DISPATCH_GL(gc.grayagain), LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
+    dasm_put(Dst, 4999, DISPATCH_GL(gc.grayagain), LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
     break;
 
   /* -- Calls and vararg handling ----------------------------------------- */
 
   case BC_CALLM:
-    dasm_put(Dst, 4944);
+    dasm_put(Dst, 5015);
     break;
   case BC_CALL:
-    dasm_put(Dst, 4950, -LJ_TFUNC, Dt7(->field_pc));
+    dasm_put(Dst, 5021, -LJ_TFUNC, Dt7(->field_pc));
     break;
 
   case BC_CALLMT:
-    dasm_put(Dst, 4970);
+    dasm_put(Dst, 5041);
     break;
   case BC_CALLT:
-    dasm_put(Dst, 4975, -LJ_TFUNC, Dt7(->ffid), FRAME_TYPE, Dt7(->field_pc), Dt7(->field_pc), PC2PROTO(k), FRAME_VARG, FRAME_TYPEP);
-    dasm_put(Dst, 5036, FRAME_TYPE);
+    dasm_put(Dst, 5046, -LJ_TFUNC, Dt7(->ffid), FRAME_TYPE, Dt7(->field_pc), Dt7(->field_pc), PC2PROTO(k), FRAME_VARG, FRAME_TYPEP);
+    dasm_put(Dst, 5107, FRAME_TYPE);
     break;
 
   case BC_ITERC:
-    dasm_put(Dst, 5047, -LJ_TFUNC, Dt7(->field_pc));
+    dasm_put(Dst, 5118, -LJ_TFUNC, Dt7(->field_pc));
     break;
 
   case BC_ITERN:
 #if LJ_HASJIT
 #endif
-    dasm_put(Dst, 5071, Dt6(->asize), Dt6(->array), -LJ_TNIL, ~LJ_TISNUM, Dt6(->hmask), Dt6(->node), DtB(->val), -LJ_TNIL, DtB(->key));
+    dasm_put(Dst, 5142, Dt6(->asize), Dt6(->array), -LJ_TNIL, ~LJ_TISNUM, Dt6(->hmask), Dt6(->node), DtB(->val), -LJ_TNIL, DtB(->key));
     break;
 
   case BC_ISNEXT:
-    dasm_put(Dst, 5136, -LJ_TFUNC, Dt8(->ffid), -LJ_TTAB, -LJ_TNIL, FF_next_N, BC_JMP, BC_ITERC);
+    dasm_put(Dst, 5207, -LJ_TFUNC, Dt8(->ffid), -LJ_TTAB, -LJ_TNIL, FF_next_N, BC_JMP, BC_ITERC);
     break;
 
   case BC_VARG:
-    dasm_put(Dst, 5175, FRAME_VARG, ~LJ_TNIL, Dt1(->maxstack), Dt1(->top), Dt1(->base), Dt1(->base));
+    dasm_put(Dst, 5246, FRAME_VARG, ~LJ_TNIL, Dt1(->maxstack), Dt1(->top), Dt1(->base), Dt1(->base));
     break;
 
   /* -- Returns ----------------------------------------------------------- */
 
   case BC_RETM:
-    dasm_put(Dst, 5247);
+    dasm_put(Dst, 5318);
     break;
 
   case BC_RET:
-    dasm_put(Dst, 5254, FRAME_TYPE, FRAME_VARG, Dt7(->field_pc), PC2PROTO(k), ~LJ_TNIL, FRAME_TYPEP);
+    dasm_put(Dst, 5325, FRAME_TYPE, FRAME_VARG, Dt7(->field_pc), PC2PROTO(k), ~LJ_TNIL, FRAME_TYPEP);
     break;
 
   case BC_RET0: case BC_RET1:
-    dasm_put(Dst, 5319, FRAME_TYPE, FRAME_VARG);
+    dasm_put(Dst, 5390, FRAME_TYPE, FRAME_VARG);
     if (op == BC_RET1) {
-      dasm_put(Dst, 5330);
+      dasm_put(Dst, 5401);
     }
-    dasm_put(Dst, 5332);
+    dasm_put(Dst, 5403);
     if (op == BC_RET1) {
-      dasm_put(Dst, 5335);
+      dasm_put(Dst, 5406);
     }
-    dasm_put(Dst, 5337, Dt7(->field_pc), PC2PROTO(k), ~LJ_TNIL);
+    dasm_put(Dst, 5408, Dt7(->field_pc), PC2PROTO(k), ~LJ_TNIL);
     break;
 
   /* -- Loops and branches ------------------------------------------------ */
@@ -7138,7 +7239,7 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
 
   case BC_FORL:
 #if LJ_HASJIT
-    dasm_put(Dst, 5363, -GG_DISP2HOT);
+    dasm_put(Dst, 5434, -GG_DISP2HOT, HOTCOUNT_LOOP);
 #endif
     break;
 
@@ -7150,68 +7251,68 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
   case BC_FORI:
   case BC_IFORL:
     vk = (op == BC_IFORL || op == BC_JFORL);
-    dasm_put(Dst, 5373);
+    dasm_put(Dst, 5445);
     if (op != BC_JFORL) {
-      dasm_put(Dst, 5375);
+      dasm_put(Dst, 5447);
     }
     if (!vk) {
-      dasm_put(Dst, 5377, -LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM);
+      dasm_put(Dst, 5449, -LJ_TISNUM, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-      dasm_put(Dst, 5395, -LJ_TISNUM);
+      dasm_put(Dst, 5467, -LJ_TISNUM);
       if (op == BC_IFORL) {
-	dasm_put(Dst, 5403);
+	dasm_put(Dst, 5475);
       } else {
-	dasm_put(Dst, 5405);
+	dasm_put(Dst, 5477);
       }
-      dasm_put(Dst, 5408);
+      dasm_put(Dst, 5480);
     }
-    dasm_put(Dst, 5413);
+    dasm_put(Dst, 5485);
     if (op == BC_FORI) {
-      dasm_put(Dst, 5415);
+      dasm_put(Dst, 5487);
     } else if (op == BC_JFORI) {
-      dasm_put(Dst, 5417);
+      dasm_put(Dst, 5489);
     } else if (op == BC_IFORL) {
-      dasm_put(Dst, 5420);
+      dasm_put(Dst, 5492);
     }
     if (vk) {
-      dasm_put(Dst, 5422);
+      dasm_put(Dst, 5494);
     }
-    dasm_put(Dst, 5424);
+    dasm_put(Dst, 5496);
     if (op == BC_JFORI || op == BC_JFORL) {
-      dasm_put(Dst, 5429, BC_JLOOP);
+      dasm_put(Dst, 5501, BC_JLOOP);
     }
-    dasm_put(Dst, 5432);
+    dasm_put(Dst, 5504);
     if (!vk) {
-      dasm_put(Dst, 5439);
+      dasm_put(Dst, 5511);
     } else {
-      dasm_put(Dst, 5441);
+      dasm_put(Dst, 5513);
     }
-    dasm_put(Dst, 5443);
+    dasm_put(Dst, 5515);
     if (!vk) {
-      dasm_put(Dst, 5447, -LJ_TISNUM, -LJ_TISNUM);
+      dasm_put(Dst, 5519, -LJ_TISNUM, -LJ_TISNUM);
     } else {
-      dasm_put(Dst, 5459);
+      dasm_put(Dst, 5531);
     }
-    dasm_put(Dst, 5468);
+    dasm_put(Dst, 5540);
     if (op == BC_FORI) {
-      dasm_put(Dst, 5472);
+      dasm_put(Dst, 5544);
     } else if (op == BC_JFORI) {
-      dasm_put(Dst, 5474, BC_JLOOP);
+      dasm_put(Dst, 5546, BC_JLOOP);
     } else if (op == BC_IFORL) {
-      dasm_put(Dst, 5479);
+      dasm_put(Dst, 5551);
     } else {
-      dasm_put(Dst, 5481, BC_JLOOP);
+      dasm_put(Dst, 5553, BC_JLOOP);
     }
-    dasm_put(Dst, 5484);
+    dasm_put(Dst, 5556);
     if (vk) {
-      dasm_put(Dst, 5490);
+      dasm_put(Dst, 5562);
     }
-    dasm_put(Dst, 5495);
+    dasm_put(Dst, 5567);
     break;
 
   case BC_ITERL:
 #if LJ_HASJIT
-    dasm_put(Dst, 5501, -GG_DISP2HOT);
+    dasm_put(Dst, 5573, -GG_DISP2HOT, HOTCOUNT_LOOP);
 #endif
     break;
 
@@ -7220,40 +7321,40 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     break;
 #endif
   case BC_IITERL:
-    dasm_put(Dst, 5511);
+    dasm_put(Dst, 5584);
     if (op == BC_JITERL) {
-      dasm_put(Dst, 5513, -LJ_TNIL, BC_JLOOP);
+      dasm_put(Dst, 5586, -LJ_TNIL, BC_JLOOP);
     } else {
-      dasm_put(Dst, 5519, -LJ_TNIL);
+      dasm_put(Dst, 5592, -LJ_TNIL);
     }
-    dasm_put(Dst, 5525);
+    dasm_put(Dst, 5598);
     break;
 
   case BC_LOOP:
 #if LJ_HASJIT
-    dasm_put(Dst, 5532, -GG_DISP2HOT);
+    dasm_put(Dst, 5605, -GG_DISP2HOT, HOTCOUNT_LOOP);
 #endif
     break;
 
   case BC_ILOOP:
-    dasm_put(Dst, 5542);
+    dasm_put(Dst, 5616);
     break;
 
   case BC_JLOOP:
 #if LJ_HASJIT
-    dasm_put(Dst, 5549, DISPATCH_J(trace), DISPATCH_GL(vmstate), DtD(->mcode), DISPATCH_GL(jit_base), DISPATCH_GL(jit_L));
+    dasm_put(Dst, 5623, DISPATCH_J(trace), DISPATCH_GL(vmstate), DtD(->mcode), DISPATCH_GL(jit_base), DISPATCH_GL(jit_L));
 #endif
     break;
 
   case BC_JMP:
-    dasm_put(Dst, 5563);
+    dasm_put(Dst, 5637);
     break;
 
   /* -- Function headers -------------------------------------------------- */
 
   case BC_FUNCF:
 #if LJ_HASJIT
-    dasm_put(Dst, 5572, -GG_DISP2HOT);
+    dasm_put(Dst, 5646, -GG_DISP2HOT, HOTCOUNT_CALL);
 #endif
   case BC_FUNCV:  /* NYI: compiled vararg functions. */
     break;
@@ -7263,42 +7364,42 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     break;
 #endif
   case BC_IFUNCF:
-    dasm_put(Dst, 5582, Dt1(->maxstack), -4+PC2PROTO(numparams), -4+PC2PROTO(k));
+    dasm_put(Dst, 5657, Dt1(->maxstack), -4+PC2PROTO(numparams), -4+PC2PROTO(k));
     if (op != BC_JFUNCF) {
-      dasm_put(Dst, 5592);
+      dasm_put(Dst, 5667);
     }
-    dasm_put(Dst, 5595, ~LJ_TNIL);
+    dasm_put(Dst, 5670, ~LJ_TNIL);
     if (op == BC_JFUNCF) {
-      dasm_put(Dst, 5602, BC_JLOOP);
+      dasm_put(Dst, 5677, BC_JLOOP);
     } else {
-      dasm_put(Dst, 5606);
+      dasm_put(Dst, 5681);
     }
-    dasm_put(Dst, 5611);
+    dasm_put(Dst, 5686);
     break;
 
   case BC_JFUNCV:
 #if !LJ_HASJIT
     break;
 #endif
-    dasm_put(Dst, 5617);
+    dasm_put(Dst, 5692);
     break;  /* NYI: compiled vararg functions. */
 
   case BC_IFUNCV:
-    dasm_put(Dst, 5619, Dt1(->maxstack), 8+FRAME_VARG, -4+PC2PROTO(k), -4+PC2PROTO(numparams), ~LJ_TNIL);
+    dasm_put(Dst, 5694, Dt1(->maxstack), 8+FRAME_VARG, -4+PC2PROTO(k), -4+PC2PROTO(numparams), ~LJ_TNIL);
     break;
 
   case BC_FUNCC:
   case BC_FUNCCW:
     if (op == BC_FUNCC) {
-      dasm_put(Dst, 5660, Dt8(->f));
+      dasm_put(Dst, 5735, Dt8(->f));
     } else {
-      dasm_put(Dst, 5663, DISPATCH_GL(wrapf));
+      dasm_put(Dst, 5738, DISPATCH_GL(wrapf));
     }
-    dasm_put(Dst, 5666, Dt1(->maxstack), Dt1(->base), Dt1(->top));
+    dasm_put(Dst, 5741, Dt1(->maxstack), Dt1(->base), Dt1(->top));
     if (op == BC_FUNCCW) {
-      dasm_put(Dst, 5676, Dt8(->f));
+      dasm_put(Dst, 5751, Dt8(->f));
     }
-    dasm_put(Dst, 5679, LJ_VMST_C, DISPATCH_GL(vmstate), Dt1(->base), LJ_VMST_INTERP, Dt1(->top), DISPATCH_GL(vmstate));
+    dasm_put(Dst, 5754, LJ_VMST_C, DISPATCH_GL(vmstate), Dt1(->base), LJ_VMST_INTERP, Dt1(->top), DISPATCH_GL(vmstate));
     break;
 
   /* ---------------------------------------------------------------------- */
@@ -7318,7 +7419,7 @@ static int build_backend(BuildCtx *ctx)
 
   build_subroutines(ctx);
 
-  dasm_put(Dst, 5701);
+  dasm_put(Dst, 5776);
   for (op = 0; op < BC__MAX; op++)
     build_ins(ctx, (BCOp)op, op);
 
@@ -7328,6 +7429,7 @@ static int build_backend(BuildCtx *ctx)
 /* Emit pseudo frame-info for all assembler functions. */
 static void emit_asm_debug(BuildCtx *ctx)
 {
+  int fcofs = (int)((uint8_t *)ctx->glob[GLOB_vm_ffi_call] - ctx->code);
   int i;
   switch (ctx->mode) {
   case BUILD_elfasm:
@@ -7353,13 +7455,30 @@ static void emit_asm_debug(BuildCtx *ctx)
 	"\t.long .Lbegin\n"
 	"\t.long %d\n"
 	"\t.byte 0xe\n\t.uleb128 %d\n"		/* def_cfa_offset */
-	"\t.byte 0x8e\n\t.uleb128 1\n",		/* Restore lr. */
-	(int)ctx->codesz, CFRAME_SIZE);
-    for (i = 11; i >= 4; i--)  /* Restore r4-r11. */
+	"\t.byte 0x8e\n\t.uleb128 1\n",		/* offset lr */
+	fcofs, CFRAME_SIZE);
+    for (i = 11; i >= 4; i--)  /* offset r4-r11 */
       fprintf(ctx->fp, "\t.byte %d\n\t.uleb128 %d\n", 0x80+i, 2+(11-i));
     fprintf(ctx->fp,
 	"\t.align 2\n"
 	".LEFDE0:\n\n");
+#if LJ_HASFFI
+    fprintf(ctx->fp,
+	".LSFDE1:\n"
+	"\t.long .LEFDE1-.LASFDE1\n"
+	".LASFDE1:\n"
+	"\t.long .Lframe0\n"
+	"\t.long lj_vm_ffi_call\n"
+	"\t.long %d\n"
+	"\t.byte 0xe\n\t.uleb128 16\n"		/* def_cfa_offset */
+	"\t.byte 0x8e\n\t.uleb128 1\n"		/* offset lr */
+	"\t.byte 0x8b\n\t.uleb128 2\n"		/* offset r11 */
+	"\t.byte 0x85\n\t.uleb128 3\n"		/* offset r5 */
+	"\t.byte 0x84\n\t.uleb128 4\n"		/* offset r4 */
+	"\t.byte 0xd\n\t.uleb128 0xb\n"		/* def_cfa_register r11 */
+	"\t.align 2\n"
+	".LEFDE1:\n\n", (int)ctx->codesz - fcofs);
+#endif
     break;
   default:
     break;
diff --git a/third_party/luajit/src/buildvm_asm.c b/third_party/luajit/src/buildvm_asm.c
index 49d6ffcaea7d338da71076db9b944e7c7c13fb4b..01330456ae5d0346d1b439855117822968d1360a 100644
--- a/third_party/luajit/src/buildvm_asm.c
+++ b/third_party/luajit/src/buildvm_asm.c
@@ -107,7 +107,7 @@ static void emit_asm_wordreloc(BuildCtx *ctx, uint8_t *p, int n,
 	    ins, sym);
     exit(1);
   }
-#elif LJ_TARGET_PPC
+#elif LJ_TARGET_PPC || LJ_TARGET_PPCSPE
   if ((ins >> 26) == 16) {
     fprintf(ctx->fp, "\t%s %d, %d, %s\n",
 	    (ins & 1) ? "bcl" : "bc", (ins >> 21) & 31, (ins >> 16) & 31, sym);
@@ -191,7 +191,7 @@ void emit_asm(BuildCtx *ctx)
   if (ctx->mode != BUILD_machasm)
     fprintf(ctx->fp, ".Lbegin:\n");
 
-#if LJ_TARGET_ARM && defined(__GNUC__) && !defined(__symbian__)
+#if LJ_TARGET_ARM && defined(__GNUC__) && !defined(LUAJIT_NO_UNWIND)
   /* This should really be moved into buildvm_arm.dasc. */
   fprintf(ctx->fp,
 	  ".fnstart\n"
@@ -202,6 +202,17 @@ void emit_asm(BuildCtx *ctx)
   for (i = rel = 0; i < ctx->nsym; i++) {
     int32_t ofs = ctx->sym[i].ofs;
     int32_t next = ctx->sym[i+1].ofs;
+#if LJ_TARGET_ARM && defined(__GNUC__) && !defined(LUAJIT_NO_UNWIND) && \
+    LJ_HASFFI
+    if (!strcmp(ctx->sym[i].name, "lj_vm_ffi_call"))
+      fprintf(ctx->fp,
+	      ".globl lj_err_unwind_arm\n"
+	      ".personality lj_err_unwind_arm\n"
+	      ".fnend\n"
+	      ".fnstart\n"
+	      ".save {r4, r5, r11, lr}\n"
+	      ".setfp r11, sp\n");
+#endif
     emit_asm_label(ctx, ctx->sym[i].name, next - ofs, 1);
     while (rel < ctx->nreloc && ctx->reloc[rel].ofs <= next) {
       BuildReloc *r = &ctx->reloc[rel];
@@ -227,10 +238,12 @@ void emit_asm(BuildCtx *ctx)
 #endif
   }
 
-#if LJ_TARGET_ARM && defined(__GNUC__) && !defined(__symbian__)
+#if LJ_TARGET_ARM && defined(__GNUC__) && !defined(LUAJIT_NO_UNWIND)
   fprintf(ctx->fp,
+#if !LJ_HASFFI
 	  ".globl lj_err_unwind_arm\n"
 	  ".personality lj_err_unwind_arm\n"
+#endif
 	  ".fnend\n");
 #endif
 
diff --git a/third_party/luajit/src/buildvm_peobj.c b/third_party/luajit/src/buildvm_peobj.c
index b97a5b03885b3bea3bb3ef3876c730cfe98df583..eb1d345fdf0e71fc6a6db4e5cc911d7742d4c824 100644
--- a/third_party/luajit/src/buildvm_peobj.c
+++ b/third_party/luajit/src/buildvm_peobj.c
@@ -191,15 +191,15 @@ void emit_peobj(BuildCtx *ctx)
 #if LJ_TARGET_X64
   memcpy(pesect[PEOBJ_SECT_PDATA].name, ".pdata", sizeof(".pdata")-1);
   pesect[PEOBJ_SECT_PDATA].ofs = sofs;
-  sofs += (pesect[PEOBJ_SECT_PDATA].size = 3*4);
+  sofs += (pesect[PEOBJ_SECT_PDATA].size = 6*4);
   pesect[PEOBJ_SECT_PDATA].relocofs = sofs;
-  sofs += (pesect[PEOBJ_SECT_PDATA].nreloc = 3) * PEOBJ_RELOC_SIZE;
+  sofs += (pesect[PEOBJ_SECT_PDATA].nreloc = 6) * PEOBJ_RELOC_SIZE;
   /* Flags: 40 = read, 30 = align4, 40 = initialized data. */
   pesect[PEOBJ_SECT_PDATA].flags = 0x40300040;
 
   memcpy(pesect[PEOBJ_SECT_XDATA].name, ".xdata", sizeof(".xdata")-1);
   pesect[PEOBJ_SECT_XDATA].ofs = sofs;
-  sofs += (pesect[PEOBJ_SECT_XDATA].size = 8*2+4);  /* See below. */
+  sofs += (pesect[PEOBJ_SECT_XDATA].size = 8*2+4+6*2);  /* See below. */
   pesect[PEOBJ_SECT_XDATA].relocofs = sofs;
   sofs += (pesect[PEOBJ_SECT_XDATA].nreloc = 1) * PEOBJ_RELOC_SIZE;
   /* Flags: 40 = read, 30 = align4, 40 = initialized data. */
@@ -247,9 +247,12 @@ void emit_peobj(BuildCtx *ctx)
 
 #if LJ_TARGET_X64
   { /* Write .pdata section. */
+    uint32_t fcofs = (uint32_t)ctx->sym[ctx->nsym-1].ofs;
     uint32_t pdata[3];  /* Start of .text, end of .text and .xdata. */
     PEreloc reloc;
-    pdata[0] = 0; pdata[1] = (uint32_t)ctx->codesz; pdata[2] = 0;
+    pdata[0] = 0; pdata[1] = fcofs; pdata[2] = 0;
+    owrite(ctx, &pdata, sizeof(pdata));
+    pdata[0] = fcofs; pdata[1] = (uint32_t)ctx->codesz; pdata[2] = 20;
     owrite(ctx, &pdata, sizeof(pdata));
     reloc.vaddr = 0; reloc.symidx = 1+2+nrsym+2+2+1;
     reloc.type = PEOBJ_RELOC_ADDR32NB;
@@ -260,12 +263,21 @@ void emit_peobj(BuildCtx *ctx)
     reloc.vaddr = 8; reloc.symidx = 1+2+nrsym+2;
     reloc.type = PEOBJ_RELOC_ADDR32NB;
     owrite(ctx, &reloc, PEOBJ_RELOC_SIZE);
+    reloc.vaddr = 12; reloc.symidx = 1+2+nrsym+2+2+1;
+    reloc.type = PEOBJ_RELOC_ADDR32NB;
+    owrite(ctx, &reloc, PEOBJ_RELOC_SIZE);
+    reloc.vaddr = 16; reloc.symidx = 1+2+nrsym+2+2+1;
+    reloc.type = PEOBJ_RELOC_ADDR32NB;
+    owrite(ctx, &reloc, PEOBJ_RELOC_SIZE);
+    reloc.vaddr = 20; reloc.symidx = 1+2+nrsym+2;
+    reloc.type = PEOBJ_RELOC_ADDR32NB;
+    owrite(ctx, &reloc, PEOBJ_RELOC_SIZE);
   }
   { /* Write .xdata section. */
-    uint16_t xdata[8+2];
+    uint16_t xdata[8+2+6];
     PEreloc reloc;
-    xdata[0] = 0x01|0x08|0x10;  /* Ver. 1, uhander/ehandler, prolog size 0. */
-    xdata[1] = 5;  /* Number of unwind codes, no frame pointer. */
+    xdata[0] = 0x01|0x08|0x10;  /* Ver. 1, uhandler/ehandler, prolog size 0. */
+    xdata[1] = 0x0005;  /* Number of unwind codes, no frame pointer. */
     xdata[2] = 0x4200;  /* Stack offset 4*8+8 = aword*5. */
     xdata[3] = 0x3000;  /* Push rbx. */
     xdata[4] = 0x6000;  /* Push rsi. */
@@ -273,8 +285,14 @@ void emit_peobj(BuildCtx *ctx)
     xdata[6] = 0x5000;  /* Push rbp. */
     xdata[7] = 0;  /* Alignment. */
     xdata[8] = xdata[9] = 0;  /* Relocated address of exception handler. */
+    xdata[10] = 0x01;  /* Ver. 1, no handler, prolog size 0. */
+    xdata[11] = 0x1504;  /* Number of unwind codes, fp = rbp, fpofs = 16. */
+    xdata[12] = 0x0300;  /* set_fpreg. */
+    xdata[13] = 0x0200;  /* stack offset 0*8+8 = aword*1. */
+    xdata[14] = 0x3000;  /* Push rbx. */
+    xdata[15] = 0x5000;  /* Push rbp. */
     owrite(ctx, &xdata, sizeof(xdata));
-    reloc.vaddr = sizeof(xdata)-4; reloc.symidx = 1+2+nrsym+2+2;
+    reloc.vaddr = 2*8; reloc.symidx = 1+2+nrsym+2+2;
     reloc.type = PEOBJ_RELOC_ADDR32NB;
     owrite(ctx, &reloc, PEOBJ_RELOC_SIZE);
   }
diff --git a/third_party/luajit/src/buildvm_ppc.dasc b/third_party/luajit/src/buildvm_ppc.dasc
index 4e3168830eeea8331626452a43bf5e8877bfbab6..c26f3924c7a979c704e2bd115c15783a0f297b0e 100644
--- a/third_party/luajit/src/buildvm_ppc.dasc
+++ b/third_party/luajit/src/buildvm_ppc.dasc
@@ -10,17 +10,13 @@
 |.globalnames globnames
 |.externnames extnames
 |
-|.if not SPE
-|.error "No support for plain PowerPC CPUs (yet)"
-|.endif
-|
 |// Note: The ragged indentation of the instructions is intentional.
 |//       The starting columns indicate data dependencies.
 |
 |//-----------------------------------------------------------------------
 |
 |// Fixed register assignments for the interpreter.
-|// Don't use: r1 = sp, r2 and r13 = reserved and/or small data area ptr
+|// Don't use: r1 = sp, r2 and r13 = reserved (TOC, TLS or SDATA)
 |
 |// The following must be C callee-save (but BASE is often refetched).
 |.define BASE,		r14	// Base of current Lua stack frame.
@@ -29,17 +25,14 @@
 |.define DISPATCH,	r17	// Opcode dispatch table.
 |.define LREG,		r18	// Register holding lua_State (also in SAVE_L).
 |.define MULTRES,	r19	// Size of multi-result: (nresults+1)*8.
+|.define JGL,		r31	// On-trace: global_State + 32768.
 |
-|// Constants for vectorized type-comparisons (hi+low GPR). C callee-save.
+|// Constants for type-comparisons, stores and conversions. C callee-save.
 |.define TISNUM,	r22
-|.if SPE
-|.define TISSTR,	r23
-|.define TISTAB,	r24
-|.define TISFUNC,	r25
-|.define TISNIL,	r26
-|.define TOBIT,		r27
-|.define ZERO,		TOBIT	// Zero in lo word.
-|.endif
+|.define TISNIL,	r23
+|.define ZERO,		r24
+|.define TOBIT,		f30	// 2^52 + 2^51.
+|.define TONUM,		f31	// 2^52 + 2^51 + 2^31.
 |
 |// The following temporaries are not saved across C calls, except for RA.
 |.define RA,		r20	// Callee-save.
@@ -63,60 +56,64 @@
 |.define CARG4,		r6	// Overlaps TMP3.
 |.define CARG5,		r7	// Overlaps INS.
 |
+|.define FARG1,		f1
+|.define FARG2,		f2
+|
 |.define CRET1,		r3
 |.define CRET2,		r4
 |
 |// Stack layout while in interpreter. Must match with lj_frame.h.
-|.if SPE
-|.define SAVE_LR,	180(sp)
-|.define CFRAME_SPACE,	176	// Delta for sp.
-|// Back chain for sp:	176(sp)	<-- sp entering interpreter
-|.define SAVE_r31,	168(sp)	// 64 bit register saves.
-|.define SAVE_r30,	160(sp)
-|.define SAVE_r29,	152(sp)
-|.define SAVE_r28,	144(sp)
-|.define SAVE_r27,	136(sp)
-|.define SAVE_r26,	128(sp)
-|.define SAVE_r25,	120(sp)
-|.define SAVE_r24,	112(sp)
-|.define SAVE_r23,	104(sp)
-|.define SAVE_r22,	96(sp)
-|.define SAVE_r21,	88(sp)
-|.define SAVE_r20,	80(sp)
-|.define SAVE_r19,	72(sp)
-|.define SAVE_r18,	64(sp)
-|.define SAVE_r17,	56(sp)
-|.define SAVE_r16,	48(sp)
-|.define SAVE_r15,	40(sp)
-|.define SAVE_r14,	32(sp)
-|.define SAVE_ERRF,	28(sp)	// 32 bit C frame info.
-|.define SAVE_NRES,	24(sp)
-|.define SAVE_CFRAME,	20(sp)
-|.define SAVE_L,	16(sp)
-|.define SAVE_PC,	12(sp)
-|.define SAVE_MULTRES,	8(sp)
+|.define SAVE_LR,	276(sp)
+|.define CFRAME_SPACE,	272	// Delta for sp.
+|// Back chain for sp:	272(sp)	<-- sp entering interpreter
+|.define SAVE_FPR_,	128	// .. 128+18*8: 64 bit FPR saves.
+|.define SAVE_GPR_,	56	// .. 56+18*4: 32 bit GPR saves.
+|.define SAVE_CR,	52(sp)	// 32 bit CR save.
+|.define SAVE_ERRF,	48(sp)	// 32 bit C frame info.
+|.define SAVE_NRES,	44(sp)
+|.define SAVE_CFRAME,	40(sp)
+|.define SAVE_L,	36(sp)
+|.define SAVE_PC,	32(sp)
+|.define SAVE_MULTRES,	28(sp)
+|.define UNUSED1,	24(sp)
+|.define TMPD_LO,	20(sp)
+|.define TMPD_HI,	16(sp)
+|.define TONUM_LO,	12(sp)
+|.define TONUM_HI,	8(sp)
 |// Next frame lr:	4(sp)
 |// Back chain for sp:	0(sp)	<-- sp while in interpreter
 |
-|.macro save_, reg; evstdd reg, SAVE_..reg; .endmacro
-|.macro rest_, reg; evldd reg, SAVE_..reg; .endmacro
-|.endif
+|.define TMPD_BLO,	23(sp)
+|.define TMPD,		TMPD_HI
+|.define TONUM_D,	TONUM_HI
+|
+|.macro save_, reg
+|  stw r..reg, SAVE_GPR_+(reg-14)*4(sp)
+|  stfd f..reg, SAVE_FPR_+(reg-14)*8(sp)
+|.endmacro
+|.macro rest_, reg
+|  lwz r..reg, SAVE_GPR_+(reg-14)*4(sp)
+|  lfd f..reg, SAVE_FPR_+(reg-14)*8(sp)
+|.endmacro
 |
 |.macro saveregs
 |  stwu sp, -CFRAME_SPACE(sp)
-|  save_ r14; save_ r15; save_ r16; save_ r17; save_ r18; save_ r19
+|  save_ 14; save_ 15; save_ 16
 |  mflr r0
-|  save_ r20; save_ r21; save_ r22; save_ r23; save_ r24; save_ r25
+|  save_ 17; save_ 18; save_ 19; save_ 20; save_ 21; save_ 22
 |  stw  r0, SAVE_LR
-|  save_ r26; save_ r27; save_ r28; save_ r29; save_ r30; save_ r31
+|  save_ 23; save_ 24; save_ 25
+|  mfcr r0
+|  save_ 26; save_ 27; save_ 28; save_ 29; save_ 30; save_ 31
+|  stw r0, SAVE_CR
 |.endmacro
 |
 |.macro restoreregs
-|  lwz r0, SAVE_LR
-|  rest_ r14; rest_ r15; rest_ r16; rest_ r17; rest_ r18; rest_ r19
-|  mtlr r0
-|  rest_ r20; rest_ r21; rest_ r22; rest_ r23; rest_ r24; rest_ r25
-|  rest_ r26; rest_ r27; rest_ r28; rest_ r29; rest_ r30; rest_ r31
+|  lwz r0, SAVE_LR; lwz r12, SAVE_CR
+|  rest_ 14; rest_ 15; rest_ 16; rest_ 17; rest_ 18; rest_ 19
+|  mtlr r0; mtcrf 0x38, r12
+|  rest_ 20; rest_ 21; rest_ 22; rest_ 23; rest_ 24; rest_ 25
+|  rest_ 26; rest_ 27; rest_ 28; rest_ 29; rest_ 30; rest_ 31
 |  addi sp, sp, CFRAME_SPACE
 |.endmacro
 |
@@ -147,6 +144,30 @@
 |// Trap for not-yet-implemented parts.
 |.macro NYI; tw 4, sp, sp; .endmacro
 |
+|// int/FP conversions.
+|.macro tonum_i, freg, reg
+|  xoris reg, reg, 0x8000
+|  stw reg, TONUM_LO
+|  lfd freg, TONUM_D
+|  fsub freg, freg, TONUM
+|.endmacro
+|
+|.macro tonum_u, freg, reg
+|  stw reg, TONUM_LO
+|  lfd freg, TONUM_D
+|  fsub freg, freg, TOBIT
+|.endmacro
+|
+|.macro toint, reg, freg, tmpfreg
+|  fctiwz tmpfreg, freg
+|  stfd tmpfreg, TMPD
+|  lwz reg, TMPD_LO
+|.endmacro
+|
+|.macro toint, reg, freg
+|  toint reg, freg, freg
+|.endmacro
+|
 |//-----------------------------------------------------------------------
 |
 |// Access to frame relative to BASE.
@@ -168,15 +189,15 @@
 |  lwz INS, 0(PC)
 |   addi PC, PC, 4
 |.endmacro
-|// Instruction decode+dispatch.
+|// Instruction decode+dispatch. Note: optimized for e300!
 |.macro ins_NEXT2
 |  decode_OP4 TMP1, INS
+|  lwzx TMP0, DISPATCH, TMP1
+|  mtctr TMP0
 |   decode_RB8 RB, INS
 |   decode_RD8 RD, INS
-|  lwzx TMP0, DISPATCH, TMP1
 |   decode_RA8 RA, INS
 |   decode_RC8 RC, INS
-|  mtctr TMP0
 |  bctr
 |.endmacro
 |.macro ins_NEXT
@@ -231,22 +252,17 @@
 |//-----------------------------------------------------------------------
 |
 |// Macros to test operand types.
-|.if SPE
-|.macro checknum, reg; evcmpltu reg, TISNUM; .endmacro
-|.macro checkstr, reg; evcmpeq reg, TISSTR; .endmacro
-|.macro checktab, reg; evcmpeq reg, TISTAB; .endmacro
-|.macro checkfunc, reg; evcmpeq reg, TISFUNC; .endmacro
-|.macro checknil, reg; evcmpeq reg, TISNIL; .endmacro
-|.macro checkok, label; blt label; .endmacro
-|.macro checkfail, label; bge label; .endmacro
-|.macro checkanyfail, label; bns label; .endmacro
-|.macro checkallok, label; bso label; .endmacro
-|.endif
+|.macro checknum, reg; cmplw reg, TISNUM; .endmacro
+|.macro checknum, cr, reg; cmplw cr, reg, TISNUM; .endmacro
+|.macro checkstr, reg; cmpwi reg, LJ_TSTR; .endmacro
+|.macro checktab, reg; cmpwi reg, LJ_TTAB; .endmacro
+|.macro checkfunc, reg; cmpwi reg, LJ_TFUNC; .endmacro
+|.macro checknil, reg; cmpwi reg, LJ_TNIL; .endmacro
 |
 |.macro branch_RD
 |  srwi TMP0, RD, 1
-|  add PC, PC, TMP0
 |  addis PC, PC, -(BCBIAS_J*4 >> 16)
+|  add PC, PC, TMP0
 |.endmacro
 |
 |// Assumes DISPATCH is relative to GL.
@@ -255,12 +271,21 @@
 |
 #define PC2PROTO(field)  ((int)offsetof(GCproto, field)-(int)sizeof(GCproto))
 |
+|.macro hotcheck, delta, target
+|  rlwinm TMP1, PC, 31, 25, 30
+|  addi TMP1, TMP1, GG_DISP2HOT
+|  lhzx TMP2, DISPATCH, TMP1
+|  addic. TMP2, TMP2, -delta
+|  sthx TMP2, DISPATCH, TMP1
+|  blt target
+|.endmacro
+|
 |.macro hotloop
-|  NYI
+|  hotcheck HOTCOUNT_LOOP, ->vm_hotloop
 |.endmacro
 |
 |.macro hotcall
-|  NYI
+|  hotcheck HOTCOUNT_CALL, ->vm_hotcall
 |.endmacro
 |
 |// Set current VM state. Uses TMP0.
@@ -292,7 +317,7 @@ static void build_subroutines(BuildCtx *ctx)
   |->vm_returnp:
   |  // See vm_return. Also: TMP2 = previous base.
   |  andi. TMP0, PC, FRAME_P
-  |   evsplati TMP1, LJ_TTRUE
+  |   li TMP1, LJ_TTRUE
   |  beq ->cont_dispatch
   |
   |  // Return from pcall or xpcall fast func.
@@ -314,7 +339,7 @@ static void build_subroutines(BuildCtx *ctx)
   |   rlwinm TMP2, PC, 0, 0, 28
   |    li_vmstate C
   |   sub TMP2, BASE, TMP2		// TMP2 = previous base.
-  |  bne ->vm_returnp
+  |  bney ->vm_returnp
   |
   |  addic. TMP1, RD, -8
   |   stw TMP2, L->base
@@ -325,11 +350,11 @@ static void build_subroutines(BuildCtx *ctx)
   |  beq >2
   |1:
   |  addic. TMP1, TMP1, -8
-  |   evldd TMP0, 0(RA)
+  |   lfd f0, 0(RA)
   |    addi RA, RA, 8
-  |   evstdd TMP0, 0(BASE)
+  |   stfd f0, 0(BASE)
   |    addi BASE, BASE, 8
-  |  bne <1
+  |  bney <1
   |
   |2:
   |  cmpw TMP2, RD			// More/less results wanted?
@@ -352,16 +377,17 @@ static void build_subroutines(BuildCtx *ctx)
   |  lwz TMP1, L->maxstack
   |  cmplw BASE, TMP1
   |  bge >8
-  |  evstdd TISNIL, 0(BASE)
+  |  stw TISNIL, 0(BASE)
   |  addi RD, RD, 8
   |  addi BASE, BASE, 8
   |  b <2
   |
   |7:  // Less results wanted.
+  |  subfic TMP3, TMP2, 0		// LUA_MULTRET+1 case?
   |   sub TMP0, RD, TMP2
-  |  cmpwi TMP2, 0			// LUA_MULTRET+1 case?
-  |   sub TMP0, BASE, TMP0		// Subtract the difference.
-  |  iseleq BASE, BASE, TMP0		// Either keep top or shrink it.
+  |  subfe TMP1, TMP1, TMP1		// TMP1 = TMP2 == 0 ? 0 : -1
+  |   and TMP0, TMP0, TMP1
+  |  sub BASE, BASE, TMP0		// Either keep top or shrink it.
   |  b <3
   |
   |8:  // Corner case: need to grow stack for filling up results.
@@ -396,24 +422,25 @@ static void build_subroutines(BuildCtx *ctx)
   |  rlwinm sp, CARG1, 0, 0, 29
   |->vm_unwind_ff_eh:			// Landing pad for external unwinder.
   |  lwz L, SAVE_L
-  |     evsplati TISNUM, LJ_TISNUM+1	// Setup type comparison constants.
-  |     evsplati TISFUNC, LJ_TFUNC
-  |     lus TOBIT, 0x4338
-  |     evsplati TISTAB, LJ_TTAB
-  |     li TMP0, 0
+  |     li TISNUM, LJ_TISNUM		// Setup type comparison constants.
   |  lwz BASE, L->base
-  |     evmergelo TOBIT, TOBIT, TMP0
+  |     lus TMP3, 0x59c0		// TOBIT = 2^52 + 2^51 (float).
   |   lwz DISPATCH, L->glref		// Setup pointer to dispatch table.
-  |     evsplati TISSTR, LJ_TSTR
+  |     li ZERO, 0
+  |     stw TMP3, TMPD
   |  li TMP1, LJ_TFALSE
-  |     evsplati TISNIL, LJ_TNIL
+  |     ori TMP3, TMP3, 0x0004		// TONUM = 2^52 + 2^51 + 2^31 (float).
+  |     li TISNIL, LJ_TNIL
   |    li_vmstate INTERP
+  |     lfs TOBIT, TMPD
   |  lwz PC, FRAME_PC(BASE)		// Fetch PC of previous frame.
   |  la RA, -8(BASE)			// Results start at BASE-8.
+  |     stw TMP3, TMPD
   |   addi DISPATCH, DISPATCH, GG_G2DISP
   |  stw TMP1, 0(RA)			// Prepend false to error message.
   |  li RD, 16				// 2 results: false + error message.
   |    st_vmstate
+  |     lfs TONUM, TMPD
   |  b ->vm_returnc
   |
   |//-----------------------------------------------------------------------
@@ -470,22 +497,25 @@ static void build_subroutines(BuildCtx *ctx)
   |  // Resume after yield (like a return).
   |  mr RA, BASE
   |   lwz BASE, L->base
-  |    evsplati TISNUM, LJ_TISNUM+1	// Setup type comparison constants.
+  |     li TISNUM, LJ_TISNUM		// Setup type comparison constants.
   |   lwz TMP1, L->top
-  |    evsplati TISFUNC, LJ_TFUNC
-  |    lus TOBIT, 0x4338
-  |    evsplati TISTAB, LJ_TTAB
   |  lwz PC, FRAME_PC(BASE)
-  |    li TMP2, 0
-  |    evsplati TISSTR, LJ_TSTR
+  |     lus TMP3, 0x59c0		// TOBIT = 2^52 + 2^51 (float).
   |   sub RD, TMP1, BASE
-  |    evmergelo TOBIT, TOBIT, TMP2
   |    stb CARG3, L->status
+  |     stw TMP3, TMPD
   |  andi. TMP0, PC, FRAME_TYPE
-  |    li_vmstate INTERP
+  |     ori TMP3, TMP3, 0x0004		// TONUM = 2^52 + 2^51 + 2^31 (float).
+  |     lfs TOBIT, TMPD
+  |     li ZERO, 0
+  |     stw TMP3, TMPD
   |   addi RD, RD, 8
-  |    evsplati TISNIL, LJ_TNIL
+  |     lus TMP0, 0x4338		// Hiword of 2^52 + 2^51 (double)
   |   mr MULTRES, RD
+  |     stw TMP0, TONUM_HI
+  |    li_vmstate INTERP
+  |     lfs TONUM, TMPD
+  |     li TISNIL, LJ_TNIL
   |    st_vmstate
   |  beq ->BC_RET_Z
   |  b ->vm_return
@@ -516,27 +546,29 @@ static void build_subroutines(BuildCtx *ctx)
   |
   |3:  // Entry point for vm_cpcall/vm_resume (BASE = base, PC = ftype).
   |  lwz TMP2, L->base			// TMP2 = old base (used in vmeta_call).
-  |    evsplati TISNUM, LJ_TISNUM+1	// Setup type comparison constants.
+  |     li TISNUM, LJ_TISNUM		// Setup type comparison constants.
   |   lwz TMP1, L->top
-  |    evsplati TISFUNC, LJ_TFUNC
+  |     lus TMP3, 0x59c0		// TOBIT = 2^52 + 2^51 (float).
   |  add PC, PC, BASE
-  |    evsplati TISTAB, LJ_TTAB
-  |    lus TOBIT, 0x4338
-  |    li TMP0, 0
+  |     stw TMP3, TMPD
+  |     li ZERO, 0
+  |     ori TMP3, TMP3, 0x0004		// TONUM = 2^52 + 2^51 + 2^31 (float).
+  |     lfs TOBIT, TMPD
   |  sub PC, PC, TMP2			// PC = frame delta + frame type
-  |    evsplati TISSTR, LJ_TSTR
+  |     stw TMP3, TMPD
+  |     lus TMP0, 0x4338		// Hiword of 2^52 + 2^51 (double)
   |   sub NARGS8:RC, TMP1, BASE
-  |    evmergelo TOBIT, TOBIT, TMP0
+  |     stw TMP0, TONUM_HI
   |    li_vmstate INTERP
-  |    evsplati TISNIL, LJ_TNIL
+  |     lfs TONUM, TMPD
+  |     li TISNIL, LJ_TNIL
   |    st_vmstate
   |
   |->vm_call_dispatch:
   |  // TMP2 = old base, BASE = new base, RC = nargs*8, PC = caller PC
-  |  li TMP0, -8
-  |  evlddx LFUNC:RB, BASE, TMP0
-  |  checkfunc LFUNC:RB
-  |  checkfail ->vmeta_call
+  |  lwz TMP0, FRAME_PC(BASE)
+  |   lwz LFUNC:RB, FRAME_FUNC(BASE)
+  |  checkfunc TMP0; bne ->vmeta_call
   |
   |->vm_call_dispatch_f:
   |  ins_call
@@ -581,62 +613,80 @@ static void build_subroutines(BuildCtx *ctx)
   |   mr RB, BASE
   |   mr BASE, TMP2			// Restore caller BASE.
   |    lwz LFUNC:TMP1, FRAME_FUNC(TMP2)
-  |  cmplwi TMP0, 0
+#if LJ_HASFFI
+  |  cmplwi TMP0, 1
+#endif
   |     lwz PC, -16(RB)			// Restore PC from [cont|PC].
-  |  beq >1
   |   subi TMP2, RD, 8
   |    lwz TMP1, LFUNC:TMP1->pc
-  |   evstddx TISNIL, RA, TMP2		// Ensure one valid arg.
+  |   stwx TISNIL, RA, TMP2		// Ensure one valid arg.
+#if LJ_HASFFI
+  |  ble >1
+#endif
   |    lwz KBASE, PC2PROTO(k)(TMP1)
   |  // BASE = base, RA = resultptr, RB = meta base
   |  mtctr TMP0
   |  bctr				// Jump to continuation.
   |
-  |1:  // Tail call from C function.
+#if LJ_HASFFI
+  |1:
+  |  beq ->cont_ffi_callback		// cont = 1: return from FFI callback.
+  |  // cont = 0: tailcall from C function.
   |  subi TMP1, RB, 16
   |  sub RC, TMP1, BASE
   |  b ->vm_call_tail
+#endif
   |
   |->cont_cat:				// RA = resultptr, RB = meta base
   |  lwz INS, -4(PC)
   |   subi CARG2, RB, 16
   |  decode_RB8 SAVE0, INS
-  |   evldd TMP0, 0(RA)
+  |   lfd f0, 0(RA)
   |  add TMP1, BASE, SAVE0
   |   stw BASE, L->base
   |  cmplw TMP1, CARG2
   |   sub CARG3, CARG2, TMP1
   |  decode_RA8 RA, INS
-  |   evstdd TMP0, 0(CARG2)
-  |  bne ->BC_CAT_Z
-  |   evstddx TMP0, BASE, RA
+  |   stfd f0, 0(CARG2)
+  |  bney ->BC_CAT_Z
+  |   stfdx f0, BASE, RA
   |  b ->cont_nop
   |
   |//-- Table indexing metamethods -----------------------------------------
   |
   |->vmeta_tgets1:
-  |  evmergelo STR:RC, TISSTR, STR:RC
   |  la CARG3, DISPATCH_GL(tmptv)(DISPATCH)
+  |  li TMP0, LJ_TSTR
   |   decode_RB8 RB, INS
-  |  evstdd STR:RC, 0(CARG3)
+  |  stw STR:RC, 4(CARG3)
   |   add CARG2, BASE, RB
+  |  stw TMP0, 0(CARG3)
   |  b >1
   |
   |->vmeta_tgets:
-  |  evmergelo TAB:RB, TISTAB, TAB:RB
   |  la CARG2, DISPATCH_GL(tmptv)(DISPATCH)
-  |   evmergelo STR:RC, TISSTR, STR:RC
-  |  evstdd TAB:RB, 0(CARG2)
+  |  li TMP0, LJ_TTAB
+  |  stw TAB:RB, 4(CARG2)
   |   la CARG3, DISPATCH_GL(tmptv2)(DISPATCH)
-  |   evstdd STR:RC, 0(CARG3)
+  |  stw TMP0, 0(CARG2)
+  |   li TMP1, LJ_TSTR
+  |   stw STR:RC, 4(CARG3)
+  |   stw TMP1, 0(CARG3)
   |  b >1
   |
   |->vmeta_tgetb:			// TMP0 = index
-  |  efdcfsi TMP0, TMP0
+  if (!LJ_DUALNUM) {
+    |  tonum_u f0, TMP0
+  }
   |   decode_RB8 RB, INS
   |  la CARG3, DISPATCH_GL(tmptv)(DISPATCH)
   |   add CARG2, BASE, RB
-  |  evstdd TMP0, 0(CARG3)
+  if (LJ_DUALNUM) {
+    |  stw TISNUM, 0(CARG3)
+    |  stw TMP0, 4(CARG3)
+  } else {
+    |  stfd f0, 0(CARG3)
+  }
   |  b >1
   |
   |->vmeta_tgetv:
@@ -652,9 +702,10 @@ static void build_subroutines(BuildCtx *ctx)
   |  // Returns TValue * (finished) or NULL (metamethod).
   |  cmplwi CRET1, 0
   |  beq >3
-  |  evldd TMP0, 0(CRET1)
-  |  evstddx TMP0, BASE, RA
-  |  ins_next
+  |   lfd f0, 0(CRET1)
+  |  ins_next1
+  |   stfdx f0, BASE, RA
+  |  ins_next2
   |
   |3:  // Call __index metamethod.
   |  // BASE = base, L->top = new base, stack = cont/func/t/k
@@ -669,28 +720,38 @@ static void build_subroutines(BuildCtx *ctx)
   |//-----------------------------------------------------------------------
   |
   |->vmeta_tsets1:
-  |  evmergelo STR:RC, TISSTR, STR:RC
   |  la CARG3, DISPATCH_GL(tmptv)(DISPATCH)
+  |  li TMP0, LJ_TSTR
   |   decode_RB8 RB, INS
-  |  evstdd STR:RC, 0(CARG3)
+  |  stw STR:RC, 4(CARG3)
   |   add CARG2, BASE, RB
+  |  stw TMP0, 0(CARG3)
   |  b >1
   |
   |->vmeta_tsets:
-  |  evmergelo TAB:RB, TISTAB, TAB:RB
   |  la CARG2, DISPATCH_GL(tmptv)(DISPATCH)
-  |   evmergelo STR:RC, TISSTR, STR:RC
-  |  evstdd TAB:RB, 0(CARG2)
+  |  li TMP0, LJ_TTAB
+  |  stw TAB:RB, 4(CARG2)
   |   la CARG3, DISPATCH_GL(tmptv2)(DISPATCH)
-  |   evstdd STR:RC, 0(CARG3)
+  |  stw TMP0, 0(CARG2)
+  |   li TMP1, LJ_TSTR
+  |   stw STR:RC, 4(CARG3)
+  |   stw TMP1, 0(CARG3)
   |  b >1
   |
   |->vmeta_tsetb:			// TMP0 = index
-  |  efdcfsi TMP0, TMP0
+  if (!LJ_DUALNUM) {
+    |  tonum_u f0, TMP0
+  }
   |   decode_RB8 RB, INS
   |  la CARG3, DISPATCH_GL(tmptv)(DISPATCH)
   |   add CARG2, BASE, RB
-  |  evstdd TMP0, 0(CARG3)
+  if (LJ_DUALNUM) {
+    |  stw TISNUM, 0(CARG3)
+    |  stw TMP0, 4(CARG3)
+  } else {
+    |  stfd f0, 0(CARG3)
+  }
   |  b >1
   |
   |->vmeta_tsetv:
@@ -705,11 +766,12 @@ static void build_subroutines(BuildCtx *ctx)
   |  bl extern lj_meta_tset		// (lua_State *L, TValue *o, TValue *k)
   |  // Returns TValue * (finished) or NULL (metamethod).
   |  cmplwi CRET1, 0
-  |   evlddx TMP0, BASE, RA
+  |   lfdx f0, BASE, RA
   |  beq >3
   |  // NOBARRIER: lj_meta_tset ensures the table is not black.
-  |   evstdd TMP0, 0(CRET1)
-  |  ins_next
+  |  ins_next1
+  |   stfd f0, 0(CRET1)
+  |  ins_next2
   |
   |3:  // Call __newindex metamethod.
   |  // BASE = base, L->top = new base, stack = cont/func/t/k/(v)
@@ -719,7 +781,7 @@ static void build_subroutines(BuildCtx *ctx)
   |   add PC, TMP1, BASE
   |  lwz LFUNC:RB, FRAME_FUNC(BASE)	// Guaranteed to be a function here.
   |   li NARGS8:RC, 24			// 3 args for func(t, k, v)
-  |  evstdd TMP0, 16(BASE)		// Copy value to third argument.
+  |  stfd f0, 16(BASE)			// Copy value to third argument.
   |  b ->vm_call_dispatch_f
   |
   |//-- Comparison metamethods ---------------------------------------------
@@ -727,9 +789,17 @@ static void build_subroutines(BuildCtx *ctx)
   |->vmeta_comp:
   |  mr CARG1, L
   |   subi PC, PC, 4
-  |  add CARG2, BASE, RA
+  if (LJ_DUALNUM) {
+    |  mr CARG2, RA
+  } else {
+    |  add CARG2, BASE, RA
+  }
   |   stw PC, SAVE_PC
-  |  add CARG3, BASE, RD
+  if (LJ_DUALNUM) {
+    |  mr CARG3, RD
+  } else {
+    |  add CARG3, BASE, RD
+  }
   |   stw BASE, L->base
   |  decode_OP1 CARG4, INS
   |  bl extern lj_meta_comp  // (lua_State *L, TValue *o1, *o2, int op)
@@ -737,33 +807,35 @@ static void build_subroutines(BuildCtx *ctx)
   |3:
   |  cmplwi CRET1, 1
   |  bgt ->vmeta_binop
+  |  subfic CRET1, CRET1, 0
   |4:
   |  lwz INS, 0(PC)
   |   addi PC, PC, 4
   |  decode_RD4 TMP2, INS
-  |  addis TMP3, PC, -(BCBIAS_J*4 >> 16)
-  |  add TMP2, TMP2, TMP3
-  |  isellt PC, PC, TMP2
+  |  addis TMP2, TMP2, -(BCBIAS_J*4 >> 16)
+  |  and TMP2, TMP2, CRET1
+  |  add PC, PC, TMP2
   |->cont_nop:
   |  ins_next
   |
   |->cont_ra:				// RA = resultptr
   |  lwz INS, -4(PC)
-  |   evldd TMP0, 0(RA)
+  |   lfd f0, 0(RA)
   |  decode_RA8 TMP1, INS
-  |   evstddx TMP0, BASE, TMP1
+  |   stfdx f0, BASE, TMP1
   |  b ->cont_nop
   |
   |->cont_condt:			// RA = resultptr
   |  lwz TMP0, 0(RA)
-  |   li TMP1, LJ_TTRUE
-  |  cmplw TMP1, TMP0			// Branch if result is true.
+  |  subfic TMP0, TMP0, LJ_TTRUE	// Branch if result is true.
+  |  subfe CRET1, CRET1, CRET1
+  |  not CRET1, CRET1
   |  b <4
   |
   |->cont_condf:			// RA = resultptr
   |  lwz TMP0, 0(RA)
-  |   li TMP1, LJ_TFALSE
-  |  cmplw TMP0, TMP1			// Branch if result is false.
+  |  subfic TMP0, TMP0, LJ_TTRUE	// Branch if result is false.
+  |  subfe CRET1, CRET1, CRET1
   |  b <4
   |
   |->vmeta_equal:
@@ -776,26 +848,53 @@ static void build_subroutines(BuildCtx *ctx)
   |  // Returns 0/1 or TValue * (metamethod).
   |  b <3
   |
-  |//-- Arithmetic metamethods ---------------------------------------------
+  |->vmeta_equal_cd:
+#if LJ_HASFFI
+  |  mr CARG2, INS
+  |  subi PC, PC, 4
+  |   stw BASE, L->base
+  |  mr CARG1, L
+  |   stw PC, SAVE_PC
+  |  bl extern lj_meta_equal_cd		// (lua_State *L, BCIns op)
+  |  // Returns 0/1 or TValue * (metamethod).
+  |  b <3
+#endif
   |
-  |->vmeta_arith_vn:
-  |  add CARG3, BASE, RB
-  |  add CARG4, KBASE, RC
-  |  b >1
+  |//-- Arithmetic metamethods ---------------------------------------------
   |
   |->vmeta_arith_nv:
   |  add CARG3, KBASE, RC
   |  add CARG4, BASE, RB
   |  b >1
+  |->vmeta_arith_nv2:
+  if (LJ_DUALNUM) {
+    |  mr CARG3, RC
+    |  mr CARG4, RB
+    |  b >1
+  }
   |
   |->vmeta_unm:
-  |  add CARG3, BASE, RD
-  |  mr CARG4, CARG3
+  |  mr CARG3, RD
+  |  mr CARG4, RD
+  |  b >1
+  |
+  |->vmeta_arith_vn:
+  |  add CARG3, BASE, RB
+  |  add CARG4, KBASE, RC
   |  b >1
   |
   |->vmeta_arith_vv:
   |  add CARG3, BASE, RB
   |  add CARG4, BASE, RC
+  if (LJ_DUALNUM) {
+    |  b >1
+  }
+  |->vmeta_arith_vn2:
+  |->vmeta_arith_vv2:
+  if (LJ_DUALNUM) {
+    |  mr CARG3, RB
+    |  mr CARG4, RC
+  }
   |1:
   |  add CARG2, BASE, RA
   |   stw BASE, L->base
@@ -812,6 +911,7 @@ static void build_subroutines(BuildCtx *ctx)
   |  // BASE = old base, CRET1 = new base, stack = cont/func/o1/o2
   |  sub TMP1, CRET1, BASE
   |   stw PC, -16(CRET1)		// [cont|PC]
+  |   mr TMP2, BASE
   |  addi PC, TMP1, FRAME_CONT
   |   mr BASE, CRET1
   |  li NARGS8:RC, 16			// 2 args for func(o1, o2).
@@ -821,7 +921,7 @@ static void build_subroutines(BuildCtx *ctx)
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
   |  mr SAVE0, CARG1
 #endif
-  |  add CARG2, BASE, RD
+  |  mr CARG2, RD
   |   stw BASE, L->base
   |  mr CARG1, L
   |   stw PC, SAVE_PC
@@ -883,7 +983,7 @@ static void build_subroutines(BuildCtx *ctx)
 #endif
   |  decode_RD8 RD, SAVE0
 #if LJ_HASJIT
-  |   beq =>BC_JFORI
+  |   beqy =>BC_JFORI
 #endif
   |  b =>BC_FORI
   |
@@ -898,29 +998,40 @@ static void build_subroutines(BuildCtx *ctx)
   |.macro .ffunc_1, name
   |->ff_ .. name:
   |  cmplwi NARGS8:RC, 8
-  |   evldd CARG1, 0(BASE)
+  |   lwz CARG3, 0(BASE)
+  |    lwz CARG1, 4(BASE)
   |  blt ->fff_fallback
   |.endmacro
   |
   |.macro .ffunc_2, name
   |->ff_ .. name:
   |  cmplwi NARGS8:RC, 16
-  |   evldd CARG1, 0(BASE)
-  |   evldd CARG2, 8(BASE)
+  |   lwz CARG3, 0(BASE)
+  |    lwz CARG4, 8(BASE)
+  |   lwz CARG1, 4(BASE)
+  |    lwz CARG2, 12(BASE)
   |  blt ->fff_fallback
   |.endmacro
   |
   |.macro .ffunc_n, name
-  |  .ffunc_1 name
-  |  checknum CARG1
-  |  checkfail ->fff_fallback
+  |->ff_ .. name:
+  |  cmplwi NARGS8:RC, 8
+  |   lwz CARG3, 0(BASE)
+  |    lfd FARG1, 0(BASE)
+  |  blt ->fff_fallback
+  |  checknum CARG3; bge ->fff_fallback
   |.endmacro
   |
   |.macro .ffunc_nn, name
-  |  .ffunc_2 name
-  |  evmergehi TMP0, CARG1, CARG2
-  |  checknum TMP0
-  |  checkanyfail ->fff_fallback
+  |->ff_ .. name:
+  |  cmplwi NARGS8:RC, 16
+  |   lwz CARG3, 0(BASE)
+  |    lfd FARG1, 0(BASE)
+  |   lwz CARG4, 8(BASE)
+  |    lfd FARG2, 8(BASE)
+  |  blt ->fff_fallback
+  |  checknum CARG3; bge ->fff_fallback
+  |  checknum CARG4; bge ->fff_fallback
   |.endmacro
   |
   |// Inlined GC threshold check. Caveat: uses TMP0 and TMP1.
@@ -933,97 +1044,94 @@ static void build_subroutines(BuildCtx *ctx)
   |
   |//-- Base library: checks -----------------------------------------------
   |
-  |.ffunc assert
-  |  cmplwi NARGS8:RC, 8
-  |   evldd TMP0, 0(BASE)
-  |  blt ->fff_fallback
-  |  evaddw TMP1, TISNIL, TISNIL	// Synthesize LJ_TFALSE.
-  |  la RA, -8(BASE)
-  |   evcmpltu cr1, TMP0, TMP1
+  |.ffunc_1 assert
+  |  li TMP1, LJ_TFALSE
+  |   la RA, -8(BASE)
+  |  cmplw cr1, CARG3, TMP1
   |    lwz PC, FRAME_PC(BASE)
   |  bge cr1, ->fff_fallback
-  |   evstdd TMP0, 0(RA)
+  |   stw CARG3, 0(RA)
   |  addi RD, NARGS8:RC, 8		// Compute (nresults+1)*8.
-  |   beq ->fff_res			// Done if exactly 1 argument.
+  |   stw CARG1, 4(RA)
+  |  beq ->fff_res			// Done if exactly 1 argument.
   |  li TMP1, 8
   |  subi RC, RC, 8
   |1:
   |  cmplw TMP1, RC
-  |   evlddx TMP0, BASE, TMP1
-  |   evstddx TMP0, RA, TMP1
+  |   lfdx f0, BASE, TMP1
+  |   stfdx f0, RA, TMP1
   |    addi TMP1, TMP1, 8
-  |  bne <1
+  |  bney <1
   |  b ->fff_res
   |
   |.ffunc type
   |  cmplwi NARGS8:RC, 8
   |   lwz CARG1, 0(BASE)
   |  blt ->fff_fallback
-  |    li TMP2, ~LJ_TNUMX
-  |  cmplw CARG1, TISNUM
-  |  not TMP1, CARG1
-  |  isellt TMP1, TMP2, TMP1
+  |  subfc TMP0, TISNUM, CARG1
+  |  subfe TMP2, CARG1, CARG1
+  |  orc TMP1, TMP2, TMP0
+  |  addi TMP1, TMP1, ~LJ_TISNUM+1
   |  slwi TMP1, TMP1, 3
   |   la TMP2, CFUNC:RB->upvalue
-  |  evlddx STR:CRET1, TMP2, TMP1
-  |  b ->fff_restv
+  |  lfdx FARG1, TMP2, TMP1
+  |  b ->fff_resn
   |
   |//-- Base library: getters and setters ---------------------------------
   |
   |.ffunc_1 getmetatable
-  |  checktab CARG1
-  |   evmergehi TMP1, CARG1, CARG1
-  |  checkfail >6
+  |  checktab CARG3; bne >6
   |1:  // Field metatable must be at same offset for GCtab and GCudata!
-  |  lwz TAB:RB, TAB:CARG1->metatable
+  |  lwz TAB:CARG1, TAB:CARG1->metatable
   |2:
-  |  evmr CRET1, TISNIL
-  |   cmplwi TAB:RB, 0
+  |  li CARG3, LJ_TNIL
+  |   cmplwi TAB:CARG1, 0
   |  lwz STR:RC, DISPATCH_GL(gcroot[GCROOT_MMNAME+MM_metatable])(DISPATCH)
   |   beq ->fff_restv
-  |  lwz TMP0, TAB:RB->hmask
-  |   evmergelo CRET1, TISTAB, TAB:RB	// Use metatable as default result.
+  |  lwz TMP0, TAB:CARG1->hmask
+  |   li CARG3, LJ_TTAB			// Use metatable as default result.
   |  lwz TMP1, STR:RC->hash
-  |  lwz NODE:TMP2, TAB:RB->node
-  |   evmergelo STR:RC, TISSTR, STR:RC
+  |  lwz NODE:TMP2, TAB:CARG1->node
   |  and TMP1, TMP1, TMP0		// idx = str->hash & tab->hmask
   |  slwi TMP0, TMP1, 5
   |  slwi TMP1, TMP1, 3
   |  sub TMP1, TMP0, TMP1
   |  add NODE:TMP2, NODE:TMP2, TMP1	// node = tab->node + (idx*32-idx*8)
   |3:  // Rearranged logic, because we expect _not_ to find the key.
-  |  evldd TMP0, NODE:TMP2->key
-  |   evldd TMP1, NODE:TMP2->val
-  |  evcmpeq TMP0, STR:RC
-  |   lwz NODE:TMP2, NODE:TMP2->next
-  |  checkallok >5
-  |   cmplwi NODE:TMP2, 0
-  |   beq ->fff_restv			// Not found, keep default result.
-  |   b <3
+  |  lwz CARG4, NODE:TMP2->key
+  |   lwz TMP0, 4+offsetof(Node, key)(NODE:TMP2)
+  |    lwz CARG2, NODE:TMP2->val
+  |     lwz TMP1, 4+offsetof(Node, val)(NODE:TMP2)
+  |  checkstr CARG4; bne >4
+  |   cmpw TMP0, STR:RC; beq >5
+  |4:
+  |  lwz NODE:TMP2, NODE:TMP2->next
+  |  cmplwi NODE:TMP2, 0
+  |  beq ->fff_restv			// Not found, keep default result.
+  |  b <3
   |5:
-  |  checknil TMP1
-  |  checkok ->fff_restv		// Ditto for nil value.
-  |  evmr CRET1, TMP1			// Return value of mt.__metatable.
+  |  checknil CARG2
+  |  beq ->fff_restv			// Ditto for nil value.
+  |  mr CARG3, CARG2			// Return value of mt.__metatable.
+  |  mr CARG1, TMP1
   |  b ->fff_restv
   |
   |6:
-  |  cmpwi TMP1, LJ_TUDATA
-  |   not TMP1, TMP1
-  |  beq <1
-  |  checknum CARG1
-  |   slwi TMP1, TMP1, 2
-  |   li TMP2, 4*~LJ_TNUMX
-  |  isellt TMP1, TMP2, TMP1
+  |  cmpwi CARG3, LJ_TUDATA; beq <1
+  |  subfc TMP0, TISNUM, CARG3
+  |  subfe TMP2, CARG3, CARG3
+  |  orc TMP1, TMP2, TMP0
+  |  addi TMP1, TMP1, ~LJ_TISNUM+1
+  |  slwi TMP1, TMP1, 2
   |   la TMP2, DISPATCH_GL(gcroot[GCROOT_BASEMT])(DISPATCH)
-  |  lwzx TAB:RB, TMP2, TMP1
+  |  lwzx TAB:CARG1, TMP2, TMP1
   |  b <2
   |
   |.ffunc_2 setmetatable
   |  // Fast path: no mt for table yet and not clearing the mt.
-  |  evmergehi TMP0, TAB:CARG1, TAB:CARG2
-  |  checktab TMP0
-  |  checkanyfail ->fff_fallback
+  |   checktab CARG3; bne ->fff_fallback
   |  lwz TAB:TMP1, TAB:CARG1->metatable
+  |   checktab CARG4; bne ->fff_fallback
   |  cmplwi TAB:TMP1, 0
   |   lbz TMP3, TAB:CARG1->marked
   |  bne ->fff_fallback
@@ -1034,64 +1142,65 @@ static void build_subroutines(BuildCtx *ctx)
   |  b ->fff_restv
   |
   |.ffunc rawget
-  |  cmplwi NARGS8:RC, 16
-  |   evldd CARG2, 0(BASE)
+  |  cmplwi NARGS8:RC, 8
+  |   lwz CARG4, 0(BASE)
+  |    lwz TAB:CARG2, 4(BASE)
   |  blt ->fff_fallback
-  |  checktab CARG2
+  |  checktab CARG4; bne ->fff_fallback
   |   la CARG3, 8(BASE)
-  |  checkfail ->fff_fallback
   |   mr CARG1, L
   |  bl extern lj_tab_get  // (lua_State *L, GCtab *t, cTValue *key)
   |  // Returns cTValue *.
-  |  evldd CRET1, 0(CRET1)
-  |  b ->fff_restv
+  |  lfd FARG1, 0(CRET1)
+  |  b ->fff_resn
   |
   |//-- Base library: conversions ------------------------------------------
   |
   |.ffunc tonumber
   |  // Only handles the number case inline (without a base argument).
   |  cmplwi NARGS8:RC, 8
-  |   evldd CARG1, 0(BASE)
+  |   lwz CARG1, 0(BASE)
+  |    lfd FARG1, 0(BASE)
   |  bne ->fff_fallback			// Exactly one argument.
-  |  checknum CARG1
-  |  checkok ->fff_restv
-  |  b ->fff_fallback
+  |   checknum CARG1; bgt ->fff_fallback
+  |  b ->fff_resn
   |
   |.ffunc_1 tostring
   |  // Only handles the string or number case inline.
-  |  checkstr CARG1
+  |  checkstr CARG3
   |  // A __tostring method in the string base metatable is ignored.
-  |  checkok ->fff_restv		// String key?
+  |  beq ->fff_restv			// String key?
   |  // Handle numbers inline, unless a number base metatable is present.
   |  lwz TMP0, DISPATCH_GL(gcroot[GCROOT_BASEMT_NUM])(DISPATCH)
-  |  checknum CARG1
+  |  checknum CARG3
   |  cmplwi cr1, TMP0, 0
   |   stw BASE, L->base			// Add frame since C call can throw.
-  |.if SPE
-  |  crand 4*cr0+eq, 4*cr0+lt, 4*cr1+eq
-  |.else
-  |.error "NYI"
-  |.endif
+  |  crorc 4*cr0+eq, 4*cr0+gt, 4*cr1+eq
   |   stw PC, SAVE_PC			// Redundant (but a defined value).
-  |  bne ->fff_fallback
+  |  beq ->fff_fallback
   |  ffgccheck
   |  mr CARG1, L
   |  mr CARG2, BASE
-  |  bl extern lj_str_fromnum		// (lua_State *L, lua_Number *np)
+  if (LJ_DUALNUM) {
+    |  bl extern lj_str_fromnumber	// (lua_State *L, cTValue *o)
+  } else {
+    |  bl extern lj_str_fromnum		// (lua_State *L, lua_Number *np)
+  }
   |  // Returns GCstr *.
-  |  evmergelo STR:CRET1, TISSTR, STR:CRET1
+  |  li CARG3, LJ_TSTR
   |  b ->fff_restv
   |
   |//-- Base library: iterators -------------------------------------------
   |
   |.ffunc next
   |  cmplwi NARGS8:RC, 8
-  |   evldd CARG2, 0(BASE)
+  |   lwz CARG1, 0(BASE)
+  |    lwz TAB:CARG2, 4(BASE)
   |  blt ->fff_fallback
-  |   evstddx TISNIL, BASE, NARGS8:RC	// Set missing 2nd arg to nil.
-  |  checktab TAB:CARG2
+  |   stwx TISNIL, BASE, NARGS8:RC	// Set missing 2nd arg to nil.
+  |  checktab CARG1
   |   lwz PC, FRAME_PC(BASE)
-  |  checkfail ->fff_fallback
+  |  bne ->fff_fallback
   |   stw BASE, L->base			// Add frame since C call can throw.
   |  mr CARG1, L
   |   stw BASE, L->top			// Dummy frame length is ok.
@@ -1100,60 +1209,86 @@ static void build_subroutines(BuildCtx *ctx)
   |  bl extern lj_tab_next	// (lua_State *L, GCtab *t, TValue *key)
   |  // Returns 0 at end of traversal.
   |  cmplwi CRET1, 0
-  |   evmr CRET1, TISNIL
+  |   li CARG3, LJ_TNIL
   |  beq ->fff_restv			// End of traversal: return nil.
-  |  evldd TMP0, 8(BASE)		// Copy key and value to results.
+  |  lfd f0, 8(BASE)			// Copy key and value to results.
   |   la RA, -8(BASE)
-  |  evldd TMP1, 16(BASE)
-  |  evstdd TMP0, 0(RA)
+  |  lfd f1, 16(BASE)
+  |  stfd f0, 0(RA)
   |   li RD, (2+1)*8
-  |  evstdd TMP1, 8(RA)
+  |  stfd f1, 8(RA)
   |  b ->fff_res
   |
   |.ffunc_1 pairs
-  |  checktab TAB:CARG1
+  |  checktab CARG3
   |   lwz PC, FRAME_PC(BASE)
-  |  checkfail ->fff_fallback
+  |  bne ->fff_fallback
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
   |   lwz TAB:TMP2, TAB:CARG1->metatable
-  |  evldd CFUNC:TMP0, CFUNC:RB->upvalue[0]
+  |  lfd f0, CFUNC:RB->upvalue[0]
   |   cmplwi TAB:TMP2, 0
   |  la RA, -8(BASE)
   |   bne ->fff_fallback
 #else
-  |  evldd CFUNC:TMP0, CFUNC:RB->upvalue[0]
+  |  lfd f0, CFUNC:RB->upvalue[0]
   |  la RA, -8(BASE)
 #endif
-  |   evstdd TISNIL, 8(BASE)
+  |   stw TISNIL, 8(BASE)
   |  li RD, (3+1)*8
-  |  evstdd CFUNC:TMP0, 0(RA)
+  |  stfd f0, 0(RA)
   |  b ->fff_res
   |
-  |.ffunc_2 ipairs_aux
-  |  checktab TAB:CARG1
+  |.ffunc ipairs_aux
+  |  cmplwi NARGS8:RC, 16
+  |   lwz CARG3, 0(BASE)
+  |    lwz TAB:CARG1, 4(BASE)
+  |   lwz CARG4, 8(BASE)
+  if (LJ_DUALNUM) {
+    |    lwz TMP2, 12(BASE)
+  } else {
+    |    lfd FARG2, 8(BASE)
+  }
+  |  blt ->fff_fallback
+  |  checktab CARG3
+  |  checknum cr1, CARG4
   |   lwz PC, FRAME_PC(BASE)
-  |  checkfail ->fff_fallback
-  |  checknum CARG2
-  |    lus TMP3, 0x3ff0
-  |  checkfail ->fff_fallback
-  |  efdctsi TMP2, CARG2
+  if (LJ_DUALNUM) {
+    |  bne ->fff_fallback
+    |  bne cr1, ->fff_fallback
+  } else {
+    |    lus TMP0, 0x3ff0
+    |    stw ZERO, TMPD_LO
+    |  bne ->fff_fallback
+    |    stw TMP0, TMPD_HI
+    |  bge cr1, ->fff_fallback
+    |    lfd FARG1, TMPD
+    |  toint TMP2, FARG2, f0
+  }
   |   lwz TMP0, TAB:CARG1->asize
-  |    evmergelo TMP3, TMP3, ZERO
   |   lwz TMP1, TAB:CARG1->array
-  |  efdadd CARG2, CARG2, TMP3
+  if (!LJ_DUALNUM) {
+    |  fadd FARG2, FARG2, FARG1
+  }
   |  addi TMP2, TMP2, 1
   |   la RA, -8(BASE)
   |  cmplw TMP0, TMP2
-  |   slwi TMP3, TMP2, 3
-  |  evstdd CARG2, 0(RA)
+  if (LJ_DUALNUM) {
+    |  stw TISNUM, 0(RA)
+    |   slwi TMP3, TMP2, 3
+    |  stw TMP2, 4(RA)
+  } else {
+    |   slwi TMP3, TMP2, 3
+    |  stfd FARG2, 0(RA)
+  }
   |  ble >2				// Not in array part?
-  |  evlddx TMP1, TMP1, TMP3
+  |  lwzx TMP2, TMP1, TMP3
+  |  lfdx f0, TMP1, TMP3
   |1:
-  |  checknil TMP1
+  |  checknil TMP2
   |   li RD, (0+1)*8
-  |  checkok ->fff_res			// End of iteration, return 0 results.
+  |  beq ->fff_res			// End of iteration, return 0 results.
   |   li RD, (2+1)*8
-  |  evstdd TMP1, 8(RA)
+  |  stfd f0, 8(RA)
   |  b ->fff_res
   |2:  // Check for empty hash part first. Otherwise call C function.
   |  lwz TMP0, TAB:CARG1->hmask
@@ -1166,27 +1301,32 @@ static void build_subroutines(BuildCtx *ctx)
   |  cmplwi CRET1, 0
   |   li RD, (0+1)*8
   |  beq ->fff_res
-  |  evldd TMP1, 0(CRET1)
+  |  lwz TMP2, 0(CRET1)
+  |  lfd f0, 0(CRET1)
   |  b <1
   |
   |.ffunc_1 ipairs
-  |  checktab TAB:CARG1
+  |  checktab CARG3
   |   lwz PC, FRAME_PC(BASE)
-  |  checkfail ->fff_fallback
+  |  bne ->fff_fallback
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
   |   lwz TAB:TMP2, TAB:CARG1->metatable
-  |  evldd CFUNC:TMP0, CFUNC:RB->upvalue[0]
+  |  lfd f0, CFUNC:RB->upvalue[0]
   |   cmplwi TAB:TMP2, 0
   |  la RA, -8(BASE)
   |   bne ->fff_fallback
 #else
-  |  evldd CFUNC:TMP0, CFUNC:RB->upvalue[0]
+  |  lfd f0, CFUNC:RB->upvalue[0]
   |  la RA, -8(BASE)
 #endif
-  |    evsplati TMP1, 0
+  if (LJ_DUALNUM) {
+    |  stw TISNUM, 8(BASE)
+  } else {
+    |  stw ZERO, 8(BASE)
+  }
+  |   stw ZERO, 12(BASE)
   |  li RD, (3+1)*8
-  |    evstdd TMP1, 8(BASE)
-  |  evstdd CFUNC:TMP0, 0(RA)
+  |  stfd f0, 0(RA)
   |  b ->fff_res
   |
   |//-- Base library: catch errors ----------------------------------------
@@ -1203,18 +1343,23 @@ static void build_subroutines(BuildCtx *ctx)
   |  addi PC, TMP3, 8+FRAME_PCALL
   |  b ->vm_call_dispatch
   |
-  |.ffunc_2 xpcall
-  |  lbz TMP3, DISPATCH_GL(hookmask)(DISPATCH)
+  |.ffunc xpcall
+  |  cmplwi NARGS8:RC, 16
+  |   lwz CARG4, 8(BASE)
+  |    lfd FARG2, 8(BASE)
+  |   lwz CARG3, 0(BASE)
+  |    lfd FARG1, 0(BASE)
+  |  blt ->fff_fallback
+  |  lbz TMP1, DISPATCH_GL(hookmask)(DISPATCH)
   |   mr TMP2, BASE
-  |  checkfunc CARG2			// Traceback must be a function.
-  |  checkfail ->fff_fallback
+  |  checkfunc CARG4; bne ->fff_fallback  // Traceback must be a function.
   |   la BASE, 16(BASE)
   |  // Remember active hook before pcall.
-  |  rlwinm TMP3, TMP3, 32-HOOK_ACTIVE_SHIFT, 31, 31
-  |   evstdd CARG2, 0(TMP2)		// Swap function and traceback.
+  |  rlwinm TMP1, TMP1, 32-HOOK_ACTIVE_SHIFT, 31, 31
+  |   stfd FARG2, 0(TMP2)		// Swap function and traceback.
   |  subi NARGS8:RC, NARGS8:RC, 16
-  |   evstdd CARG1, 8(TMP2)
-  |  addi PC, TMP3, 16+FRAME_PCALL
+  |   stfd FARG1, 8(TMP2)
+  |  addi PC, TMP1, 16+FRAME_PCALL
   |  b ->vm_call_dispatch
   |
   |//-- Coroutine library --------------------------------------------------
@@ -1222,15 +1367,11 @@ static void build_subroutines(BuildCtx *ctx)
   |.macro coroutine_resume_wrap, resume
   |.if resume
   |.ffunc_1 coroutine_resume
-  |  evmergehi TMP0, L:CARG1, L:CARG1
+  |  cmpwi CARG3, LJ_TTHREAD; bne ->fff_fallback
   |.else
   |.ffunc coroutine_wrap_aux
   |  lwz L:CARG1, CFUNC:RB->upvalue[0].gcr
   |.endif
-  |.if resume
-  |  cmpwi TMP0, LJ_TTHREAD
-  |  bne ->fff_fallback
-  |.endif
   |  lbz TMP0, L:CARG1->status
   |   lwz TMP1, L:CARG1->cframe
   |    lwz CARG2, L:CARG1->top
@@ -1260,9 +1401,9 @@ static void build_subroutines(BuildCtx *ctx)
   |  stw BASE, L->top
   |2:  // Move args to coroutine.
   |  cmpw TMP1, NARGS8:RC
-  |   evlddx TMP0, BASE, TMP1
+  |   lfdx f0, BASE, TMP1
   |  beq >3
-  |   evstddx TMP0, CARG2, TMP1
+  |   stfdx f0, CARG2, TMP1
   |  addi TMP1, TMP1, 8
   |  b <2
   |3:
@@ -1292,8 +1433,8 @@ static void build_subroutines(BuildCtx *ctx)
   |   stw TMP2, L:SAVE0->top		// Clear coroutine stack.
   |5:  // Move results from coroutine.
   |  cmplw TMP1, TMP3
-  |   evlddx TMP0, TMP2, TMP1
-  |   evstddx TMP0, BASE, TMP1
+  |   lfdx f0, TMP2, TMP1
+  |   stfdx f0, BASE, TMP1
   |    addi TMP1, TMP1, 8
   |  bne <5
   |6:
@@ -1318,12 +1459,12 @@ static void build_subroutines(BuildCtx *ctx)
   |  andi. TMP0, PC, FRAME_TYPE
   |  la TMP3, -8(TMP3)
   |   li TMP1, LJ_TFALSE
-  |  evldd TMP0, 0(TMP3)
+  |  lfd f0, 0(TMP3)
   |   stw TMP3, L:SAVE0->top		// Remove error from coroutine stack.
   |    li RD, (2+1)*8
   |   stw TMP1, -8(BASE)		// Prepend false to results.
   |    la RA, -8(BASE)
-  |  evstdd TMP0, 0(BASE)		// Copy error message.
+  |  stfd f0, 0(BASE)			// Copy error message.
   |  b <7
   |.else
   |  mr CARG1, L
@@ -1356,15 +1497,36 @@ static void build_subroutines(BuildCtx *ctx)
   |
   |//-- Math library -------------------------------------------------------
   |
-  |.ffunc_n math_abs
-  |  efdabs CRET1, CARG1
+  |.ffunc_1 math_abs
+  |  checknum CARG3
+  if (LJ_DUALNUM) {
+    |  bne >2
+    |  srawi TMP1, CARG1, 31
+    |  xor TMP2, TMP1, CARG1
+    |  sub. CARG1, TMP2, TMP1
+    |  blt >1
+    |->fff_resi:
+    |  lwz PC, FRAME_PC(BASE)
+    |  la RA, -8(BASE)
+    |  stw TISNUM, -8(BASE)
+    |  stw CRET1, -4(BASE)
+    |  b ->fff_res1
+    |1:
+    |  lus CARG3, 0x41e0	// 2^31.
+    |  li CARG1, 0
+    |  b ->fff_restv
+    |2:
+  }
+  |  bge ->fff_fallback
+  |  rlwinm CARG3, CARG3, 0, 1, 31
   |  // Fallthrough.
   |
   |->fff_restv:
-  |  // CRET1 = TValue result.
+  |  // CARG3/CARG1 = TValue result.
   |  lwz PC, FRAME_PC(BASE)
-  |   la RA, -8(BASE)
-  |  evstdd CRET1, 0(RA)
+  |   stw CARG3, -8(BASE)
+  |  la RA, -8(BASE)
+  |   stw CARG1, -4(BASE)
   |->fff_res1:
   |  // RA = results, PC = return.
   |  li RD, (1+1)*8
@@ -1372,7 +1534,7 @@ static void build_subroutines(BuildCtx *ctx)
   |  // RA = results, RD = (nresults+1)*8, PC = return.
   |  andi. TMP0, PC, FRAME_TYPE
   |   mr MULTRES, RD
-  |  bne ->vm_return
+  |  bney ->vm_return
   |  lwz INS, -4(PC)
   |  decode_RB8 RB, INS
   |5:
@@ -1387,54 +1549,101 @@ static void build_subroutines(BuildCtx *ctx)
   |6:  // Fill up results with nil.
   |  subi TMP1, RD, 8
   |   addi RD, RD, 8
-  |  evstddx TISNIL, RA, TMP1
+  |  stwx TISNIL, RA, TMP1
   |  b <5
   |
   |.macro math_extern, func
-  |  .ffunc math_ .. func
-  |  cmplwi NARGS8:RC, 8
-  |   evldd CARG2, 0(BASE)
-  |  blt ->fff_fallback
-  |  checknum CARG2
-  |   evmergehi CARG1, CARG2, CARG2
-  |  checkfail ->fff_fallback
+  |  .ffunc_n math_ .. func
   |  bl extern func
-  |  evmergelo CRET1, CRET1, CRET2
-  |  b ->fff_restv
+  |  b ->fff_resn
   |.endmacro
   |
   |.macro math_extern2, func
-  |  .ffunc math_ .. func
-  |  cmplwi NARGS8:RC, 16
-  |   evldd CARG2, 0(BASE)
-  |   evldd CARG4, 8(BASE)
-  |  blt ->fff_fallback
-  |  evmergehi CARG1, CARG4, CARG2
-  |  checknum CARG1
-  |   evmergehi CARG3, CARG4, CARG4
-  |  checkanyfail ->fff_fallback
+  |  .ffunc_nn math_ .. func
   |  bl extern func
-  |  evmergelo CRET1, CRET1, CRET2
-  |  b ->fff_restv
+  |  b ->fff_resn
   |.endmacro
   |
   |.macro math_round, func
-  |  .ffunc math_ .. func
-  |  cmplwi NARGS8:RC, 8
-  |   evldd CARG2, 0(BASE)
-  |  blt ->fff_fallback
-  |  checknum CARG2
-  |   evmergehi CARG1, CARG2, CARG2
-  |  checkfail ->fff_fallback
-  |   lwz PC, FRAME_PC(BASE)
-  |  bl ->vm_..func.._hilo;
-  |  la RA, -8(BASE)
-  |  evstdd CRET2, 0(RA)
-  |  b ->fff_res1
+  |  .ffunc_1 math_ .. func
+  |   checknum CARG3; beqy ->fff_restv
+  |  rlwinm TMP2, CARG3, 12, 21, 31
+  |   bge ->fff_fallback
+  |  addic. TMP2, TMP2, -1023		// exp = exponent(x) - 1023
+  |  cmplwi cr1, TMP2, 31		// 0 <= exp < 31?
+  |   subfic TMP0, TMP2, 31
+  |  blt >3
+  |  slwi TMP1, CARG3, 11
+  |   srwi TMP3, CARG1, 21
+  |  oris TMP1, TMP1, 0x8000
+  |   addi TMP2, TMP2, 1
+  |  or TMP1, TMP1, TMP3
+  |   slwi CARG2, CARG1, 11
+  |  bge cr1, >4
+  |   slw TMP3, TMP1, TMP2
+  |  srw CARG1, TMP1, TMP0
+  |   or TMP3, TMP3, CARG2
+  |  srawi TMP2, CARG3, 31
+  |.if "func" == "floor"
+  |  and TMP1, TMP3, TMP2
+  |  addic TMP0, TMP1, -1
+  |  subfe TMP1, TMP0, TMP1
+  |  add CARG1, CARG1, TMP1
+  |  xor CARG1, CARG1, TMP2
+  |  sub CARG1, CARG1, TMP2
+  |  b ->fff_resi
+  |.else
+  |  andc TMP1, TMP3, TMP2
+  |  addic TMP0, TMP1, -1
+  |  subfe TMP1, TMP0, TMP1
+  |  addo. CARG1, CARG1, TMP1
+  |  xor CARG1, CARG1, TMP2
+  |  sub CARG1, CARG1, TMP2
+  |  bns ->fff_resi
+  |  // Potential overflow.
+  |  mcrxr cr0; bley ->fff_resi		// Ignore unrelated overflow.
+  |  lus CARG3, 0x41e0			// 2^31.
+  |  li CARG1, 0
+  |  b ->fff_restv
+  |.endif
+  |3:  // |x| < 1
+  |  add TMP2, CARG3, CARG3
+  |   srawi TMP1, CARG3, 31
+  |  or TMP2, CARG1, TMP2		// ztest = (hi+hi) | lo
+  |.if "func" == "floor"
+  |  and TMP1, TMP2, TMP1		// (ztest & sign) == 0 ? 0 : -1
+  |  subfic TMP2, TMP1, 0
+  |  subfe CARG1, CARG1, CARG1
+  |.else
+  |  andc TMP1, TMP2, TMP1		// (ztest & ~sign) == 0 ? 0 : 1
+  |  addic TMP2, TMP1, -1
+  |  subfe CARG1, TMP2, TMP1
+  |.endif
+  |  b ->fff_resi
+  |4:  // exp >= 31. Check for -(2^31).
+  |  xoris TMP1, TMP1, 0x8000
+  |  srawi TMP2, CARG3, 31
+  |.if "func" == "floor"
+  |  or TMP1, TMP1, CARG2
+  |.endif
+  |  orc. TMP1, TMP1, TMP2
+  |  crand 4*cr0+eq, 4*cr0+eq, 4*cr1+eq
+  |  lus CARG1, 0x8000			// -(2^31).
+  |  beqy ->fff_resi
+  |5:
+  |  lfd FARG1, 0(BASE)
+  |  bl extern func
+  |  b ->fff_resn
   |.endmacro
   |
-  |  math_round floor
-  |  math_round ceil
+  if (LJ_DUALNUM) {
+    |  math_round floor
+    |  math_round ceil
+  } else {
+    |  // NYI: use internal implementation.
+    |  math_extern floor
+    |  math_extern ceil
+  }
   |
   |  math_extern sqrt
   |  math_extern log
@@ -1455,119 +1664,190 @@ static void build_subroutines(BuildCtx *ctx)
   |
   |->ff_math_deg:
   |.ffunc_n math_rad
-  |  evldd CARG2, CFUNC:RB->upvalue[0]
-  |  efdmul CRET1, CARG1, CARG2
-  |  b ->fff_restv
-  |
-  |.ffunc math_ldexp
-  |  cmplwi NARGS8:RC, 16
-  |   evldd CARG2, 0(BASE)
-  |   evldd CARG4, 8(BASE)
-  |  blt ->fff_fallback
-  |  evmergehi CARG1, CARG4, CARG2
-  |  checknum CARG1
-  |  checkanyfail ->fff_fallback
-  |  efdctsi CARG3, CARG4
+  |  lfd FARG2, CFUNC:RB->upvalue[0]
+  |  fmul FARG1, FARG1, FARG2
+  |  b ->fff_resn
+  |
+  if (LJ_DUALNUM) {
+    |.ffunc math_ldexp
+    |  cmplwi NARGS8:RC, 16
+    |   lwz CARG3, 0(BASE)
+    |    lfd FARG1, 0(BASE)
+    |   lwz CARG4, 8(BASE)
+    |    lwz CARG1, 12(BASE)
+    |  blt ->fff_fallback
+    |  checknum CARG3; bge ->fff_fallback
+    |  checknum CARG4; bne ->fff_fallback
+  } else {
+    |.ffunc_nn math_ldexp
+    |  toint CARG1, FARG2
+  }
   |  bl extern ldexp
-  |  evmergelo CRET1, CRET1, CRET2
-  |  b ->fff_restv
+  |  b ->fff_resn
   |
-  |.ffunc math_frexp
-  |  cmplwi NARGS8:RC, 8
-  |   evldd CARG2, 0(BASE)
-  |  blt ->fff_fallback
-  |  checknum CARG2
-  |   evmergehi CARG1, CARG2, CARG2
-  |  checkfail ->fff_fallback
-  |  la CARG3, DISPATCH_GL(tmptv)(DISPATCH)
+  |.ffunc_n math_frexp
+  |  la CARG1, DISPATCH_GL(tmptv)(DISPATCH)
   |   lwz PC, FRAME_PC(BASE)
   |  bl extern frexp
   |   lwz TMP1, DISPATCH_GL(tmptv)(DISPATCH)
-  |  evmergelo CRET1, CRET1, CRET2
-  |   efdcfsi CRET2, TMP1
   |   la RA, -8(BASE)
-  |  evstdd CRET1, 0(RA)
+  if (!LJ_DUALNUM) {
+    |   tonum_i FARG2, TMP1
+  }
+  |  stfd FARG1, 0(RA)
   |  li RD, (2+1)*8
-  |   evstdd CRET2, 8(RA)
+  if (LJ_DUALNUM) {
+    |   stw TISNUM, 8(RA)
+    |   stw TMP1, 12(RA)
+  } else {
+    |   stfd FARG2, 8(RA)
+  }
   |  b ->fff_res
   |
-  |.ffunc math_modf
-  |  cmplwi NARGS8:RC, 8
-  |   evldd CARG2, 0(BASE)
-  |  blt ->fff_fallback
-  |  checknum CARG2
-  |   evmergehi CARG1, CARG2, CARG2
-  |  checkfail ->fff_fallback
-  |  la CARG3, -8(BASE)
+  |.ffunc_n math_modf
+  |  la CARG1, -8(BASE)
   |   lwz PC, FRAME_PC(BASE)
   |  bl extern modf
-  |  evmergelo CRET1, CRET1, CRET2
   |   la RA, -8(BASE)
-  |  evstdd CRET1, 0(BASE)
+  |  stfd FARG1, 0(BASE)
   |  li RD, (2+1)*8
   |  b ->fff_res
   |
-  |.macro math_minmax, name, cmpop
+  |.macro math_minmax, name, ismax
+  ||if (LJ_DUALNUM) {
   |  .ffunc_1 name
-  |  checknum CARG1
-  |   li TMP1, 8
-  |  checkfail ->fff_fallback
+  |  checknum CARG3
+  |   addi TMP1, BASE, 8
+  |   add TMP2, BASE, NARGS8:RC
+  |  bne >4
+  |1:  // Handle integers.
+  |  lwz CARG4, 0(TMP1)
+  |   cmplw cr1, TMP1, TMP2
+  |  lwz CARG2, 4(TMP1)
+  |   bge cr1, ->fff_resi
+  |  checknum CARG4
+  |   xoris TMP0, CARG1, 0x8000
+  |   xoris TMP3, CARG2, 0x8000
+  |  bne >3
+  |  subfc TMP3, TMP3, TMP0
+  |  subfe TMP0, TMP0, TMP0
+  |.if ismax
+  |  andc TMP3, TMP3, TMP0
+  |.else
+  |  and TMP3, TMP3, TMP0
+  |.endif
+  |  add CARG1, TMP3, CARG2
+  |   addi TMP1, TMP1, 8
+  |  b <1
+  |3:
+  |  bge ->fff_fallback
+  |  // Convert intermediate result to number and continue below.
+  |  tonum_i FARG1, CARG1
+  |  lfd FARG2, 0(TMP1)
+  |  b >6
+  |4:
+  |   lfd FARG1, 0(BASE)
+  |  bge ->fff_fallback
+  |5:  // Handle numbers.
+  |  lwz CARG4, 0(TMP1)
+  |   cmplw cr1, TMP1, TMP2
+  |  lfd FARG2, 0(TMP1)
+  |   bge cr1, ->fff_resn
+  |  checknum CARG4; bge >7
+  |6:
+  |  fsub f0, FARG1, FARG2
+  |   addi TMP1, TMP1, 8
+  |.if ismax
+  |  fsel FARG1, f0, FARG1, FARG2
+  |.else
+  |  fsel FARG1, f0, FARG2, FARG1
+  |.endif
+  |  b <5
+  |7:  // Convert integer to number and continue above.
+  |   lwz CARG2, 4(TMP1)
+  |  bne ->fff_fallback
+  |  tonum_i FARG2, CARG2
+  |  b <6
+  ||} else {
+  |  .ffunc_n name
+  |  li TMP1, 8
   |1:
-  |  evlddx CARG2, BASE, TMP1
+  |   lwzx CARG2, BASE, TMP1
+  |   lfdx FARG2, BASE, TMP1
   |  cmplw cr1, TMP1, NARGS8:RC
   |   checknum CARG2
-  |  bge cr1, ->fff_restv		// Ok, since CRET1 = CARG1.
-  |   checkfail ->fff_fallback
-  |  cmpop CARG2, CARG1
+  |  bge cr1, ->fff_resn
+  |   bge ->fff_fallback
+  |  fsub f0, FARG1, FARG2
   |   addi TMP1, TMP1, 8
-  |  crmove 4*cr0+lt, 4*cr0+gt
-  |  evsel CARG1, CARG2, CARG1
+  |.if ismax
+  |  fsel FARG1, f0, FARG1, FARG2
+  |.else
+  |  fsel FARG1, f0, FARG2, FARG1
+  |.endif
   |  b <1
+  ||}
   |.endmacro
   |
-  |  math_minmax math_min, efdtstlt
-  |  math_minmax math_max, efdtstgt
+  |  math_minmax math_min, 0
+  |  math_minmax math_max, 1
   |
   |//-- String library -----------------------------------------------------
   |
   |.ffunc_1 string_len
-  |  checkstr STR:CARG1
-  |  checkfail ->fff_fallback
-  |  lwz TMP0, STR:CARG1->len
-  |  efdcfsi CRET1, TMP0
-  |  b ->fff_restv
+  |  checkstr CARG3; bne ->fff_fallback
+  |  lwz CRET1, STR:CARG1->len
+  |  b ->fff_resi
   |
   |.ffunc string_byte			// Only handle the 1-arg case here.
   |  cmplwi NARGS8:RC, 8
-  |   evldd STR:CARG1, 0(BASE)
+  |   lwz CARG3, 0(BASE)
+  |    lwz STR:CARG1, 4(BASE)
   |  bne ->fff_fallback			// Need exactly 1 argument.
-  |  checkstr STR:CARG1
-  |   la RA, -8(BASE)
-  |  checkfail ->fff_fallback
+  |   checkstr CARG3
+  |   bne ->fff_fallback
   |  lwz TMP0, STR:CARG1->len
-  |   li RD, (0+1)*8
-  |    lbz TMP1, STR:CARG1[1]		// Access is always ok (NUL at end).
-  |   li TMP2, (1+1)*8
-  |  cmplwi TMP0, 0
-  |   lwz PC, FRAME_PC(BASE)
-  |    efdcfsi CRET1, TMP1
-  |  iseleq RD, RD, TMP2
-  |    evstdd CRET1, 0(RA)
-  |  b ->fff_res
+  if (LJ_DUALNUM) {
+    |   lbz CARG1, STR:CARG1[1]		// Access is always ok (NUL at end).
+    |   li RD, (0+1)*8
+    |   lwz PC, FRAME_PC(BASE)
+    |  cmplwi TMP0, 0
+    |   la RA, -8(BASE)
+    |  beqy ->fff_res
+    |  b ->fff_resi
+  } else {
+    |   lbz TMP1, STR:CARG1[1]		// Access is always ok (NUL at end).
+    |  addic TMP3, TMP0, -1		// RD = ((str->len != 0)+1)*8
+    |  subfe RD, TMP3, TMP0
+    |   stw TMP1, TONUM_LO		// Inlined tonum_u f0, TMP1.
+    |  addi RD, RD, 1
+    |   lfd f0, TONUM_D
+    |  la RA, -8(BASE)
+    |  lwz PC, FRAME_PC(BASE)
+    |   fsub f0, f0, TOBIT
+    |  slwi RD, RD, 3
+    |   stfd f0, 0(RA)
+    |  b ->fff_res
+  }
   |
   |.ffunc string_char			// Only handle the 1-arg case here.
   |  ffgccheck
   |  cmplwi NARGS8:RC, 8
-  |   evldd CARG1, 0(BASE)
-  |  bne ->fff_fallback			// Exactly 1 argument.
-  |  checknum CARG1
-  |   la CARG2, DISPATCH_GL(tmptv)(DISPATCH)
-  |  checkfail ->fff_fallback
-  |  efdctsiz TMP0, CARG1
+  |   lwz CARG3, 0(BASE)
+  if (LJ_DUALNUM) {
+    |    lwz TMP0, 4(BASE)
+    |  bne ->fff_fallback		// Exactly 1 argument.
+    |  checknum CARG3; bne ->fff_fallback
+    |   la CARG2, 7(BASE)
+  } else {
+    |    lfd FARG1, 0(BASE)
+    |  bne ->fff_fallback		// Exactly 1 argument.
+    |  checknum CARG3; bge ->fff_fallback
+    |  toint TMP0, FARG1
+    |   la CARG2, TMPD_BLO
+  }
   |   li CARG3, 1
-  |  cmplwi TMP0, 255
-  |   stb TMP0, 0(CARG2)
-  |  bgt ->fff_fallback
+  |  cmplwi TMP0, 255; bgt ->fff_fallback
   |->fff_newstr:
   |  mr CARG1, L
   |  stw BASE, L->base
@@ -1575,67 +1855,95 @@ static void build_subroutines(BuildCtx *ctx)
   |  bl extern lj_str_new		// (lua_State *L, char *str, size_t l)
   |  // Returns GCstr *.
   |  lwz BASE, L->base
-  |   evmergelo STR:CRET1, TISSTR, STR:CRET1
+  |  li CARG3, LJ_TSTR
   |  b ->fff_restv
   |
   |.ffunc string_sub
   |  ffgccheck
   |  cmplwi NARGS8:RC, 16
-  |   evldd CARG3, 16(BASE)
-  |   evldd STR:CARG1, 0(BASE)
+  |   lwz CARG3, 16(BASE)
+  if (!LJ_DUALNUM) {
+    |    lfd f0, 16(BASE)
+  }
+  |   lwz TMP0, 0(BASE)
+  |    lwz STR:CARG1, 4(BASE)
   |  blt ->fff_fallback
-  |   evldd CARG2, 8(BASE)
+  |   lwz CARG2, 8(BASE)
+  if (LJ_DUALNUM) {
+    |    lwz TMP1, 12(BASE)
+  } else {
+    |    lfd f1, 8(BASE)
+  }
   |   li TMP2, -1
   |  beq >1
-  |  checknum CARG3
-  |  checkfail ->fff_fallback
-  |  efdctsiz TMP2, CARG3
-  |1:
-  |  checknum CARG2
-  |  checkfail ->fff_fallback
-  |  checkstr STR:CARG1
-  |   efdctsiz TMP1, CARG2
-  |  checkfail ->fff_fallback
+  if (LJ_DUALNUM) {
+    |  checknum CARG3
+    |   lwz TMP2, 20(BASE)
+    |  bne ->fff_fallback
+    |1:
+    |  checknum CARG2; bne ->fff_fallback
+  } else {
+    |  checknum CARG3; bge ->fff_fallback
+    |  toint TMP2, f0
+    |1:
+    |  checknum CARG2; bge ->fff_fallback
+  }
+  |  checkstr TMP0; bne ->fff_fallback
+  if (!LJ_DUALNUM) {
+    |   toint TMP1, f1
+  }
   |   lwz TMP0, STR:CARG1->len
   |  cmplw TMP0, TMP2			// len < end? (unsigned compare)
-  |   add TMP3, TMP2, TMP0
+  |   addi TMP3, TMP2, 1
   |  blt >5
   |2:
   |  cmpwi TMP1, 0			// start <= 0?
   |   add TMP3, TMP1, TMP0
   |  ble >7
   |3:
-  |  sub. CARG3, TMP2, TMP1
+  |  sub CARG3, TMP2, TMP1
   |    addi CARG2, STR:CARG1, #STR-1
+  |  srawi TMP0, CARG3, 31
   |   addi CARG3, CARG3, 1
   |    add CARG2, CARG2, TMP1
-  |  isellt CARG3, r0, CARG3
+  |  andc CARG3, CARG3, TMP0
   |  b ->fff_newstr
   |
   |5:  // Negative end or overflow.
-  |  cmpw TMP0, TMP2
-  |   addi TMP3, TMP3, 1
-  |  iselgt TMP2, TMP3, TMP0		// end = end > len ? len : end+len+1
+  |  sub CARG2, TMP0, TMP2
+  |  srawi CARG2, CARG2, 31
+  |  andc TMP3, TMP3, CARG2		// end = end > len ? len : end+len+1
+  |  add TMP2, TMP0, TMP3
   |  b <2
   |
   |7:  // Negative start or underflow.
-  |   cmpwi cr1, TMP3, 0
-  |  iseleq TMP1, r0, TMP3
-  |   isel TMP1, r0, TMP1, 4*cr1+lt
+  |  addic CARG3, TMP1, -1
+  |  subfe CARG3, CARG3, CARG3
+  |   srawi CARG2, TMP3, 31		// Note: modifies carry.
+  |  andc TMP3, TMP3, CARG3
+  |   andc TMP1, TMP3, CARG2
   |  addi TMP1, TMP1, 1			// start = 1 + (start ? start+len : 0)
   |  b <3
   |
   |.ffunc string_rep			// Only handle the 1-char case inline.
   |  ffgccheck
   |  cmplwi NARGS8:RC, 16
-  |   evldd CARG1, 0(BASE)
-  |   evldd CARG2, 8(BASE)
+  |   lwz TMP0, 0(BASE)
+  |    lwz STR:CARG1, 4(BASE)
+  |   lwz CARG4, 8(BASE)
+  if (LJ_DUALNUM) {
+    |    lwz CARG3, 12(BASE)
+  } else {
+    |    lfd FARG2, 8(BASE)
+  }
   |  blt ->fff_fallback
-  |  checknum CARG2
-  |  checkfail ->fff_fallback
-  |  checkstr STR:CARG1
-  |   efdctsiz CARG3, CARG2
-  |  checkfail ->fff_fallback
+  |  checkstr TMP0; bne ->fff_fallback
+  if (LJ_DUALNUM) {
+    |  checknum CARG4; bne ->fff_fallback
+  } else {
+    |  checknum CARG4; bge ->fff_fallback
+    |    toint CARG3, FARG2
+  }
   |   lwz TMP0, STR:CARG1->len
   |  cmpwi CARG3, 0
   |   lwz TMP1, DISPATCH_GL(tmpbuf.sz)(DISPATCH)
@@ -1655,18 +1963,19 @@ static void build_subroutines(BuildCtx *ctx)
   |  bne <1
   |  b ->fff_newstr
   |2:  // Return empty string.
-  |  la STR:CRET1, DISPATCH_GL(strempty)(DISPATCH)
-  |  evmergelo CRET1, TISSTR, STR:CRET1
+  |  la STR:CARG1, DISPATCH_GL(strempty)(DISPATCH)
+  |  li CARG3, LJ_TSTR
   |  b ->fff_restv
   |
   |.ffunc string_reverse
   |  ffgccheck
   |  cmplwi NARGS8:RC, 8
-  |   evldd CARG1, 0(BASE)
+  |   lwz CARG3, 0(BASE)
+  |    lwz STR:CARG1, 4(BASE)
   |  blt ->fff_fallback
-  |  checkstr STR:CARG1
+  |  checkstr CARG3
   |   lwz TMP1, DISPATCH_GL(tmpbuf.sz)(DISPATCH)
-  |  checkfail ->fff_fallback
+  |  bne ->fff_fallback
   |  lwz CARG3, STR:CARG1->len
   |   la CARG1, #STR(STR:CARG1)
   |   lwz CARG2, DISPATCH_GL(tmpbuf.buf)(DISPATCH)
@@ -1677,7 +1986,7 @@ static void build_subroutines(BuildCtx *ctx)
   |1:  // Reverse string copy.
   |  cmpwi TMP3, 0
   |   lbzx TMP1, CARG1, TMP2
-  |  blt ->fff_newstr
+  |  blty ->fff_newstr
   |   stbx TMP1, CARG2, TMP3
   |  subi TMP3, TMP3, 1
   |  addi TMP2, TMP2, 1
@@ -1687,11 +1996,12 @@ static void build_subroutines(BuildCtx *ctx)
   |  .ffunc name
   |  ffgccheck
   |  cmplwi NARGS8:RC, 8
-  |   evldd CARG1, 0(BASE)
+  |   lwz CARG3, 0(BASE)
+  |    lwz STR:CARG1, 4(BASE)
   |  blt ->fff_fallback
-  |  checkstr STR:CARG1
+  |  checkstr CARG3
   |   lwz TMP1, DISPATCH_GL(tmpbuf.sz)(DISPATCH)
-  |  checkfail ->fff_fallback
+  |  bne ->fff_fallback
   |  lwz CARG3, STR:CARG1->len
   |   la CARG1, #STR(STR:CARG1)
   |   lwz CARG2, DISPATCH_GL(tmpbuf.buf)(DISPATCH)
@@ -1701,11 +2011,13 @@ static void build_subroutines(BuildCtx *ctx)
   |1:  // ASCII case conversion.
   |  cmplw TMP2, CARG3
   |   lbzx TMP1, CARG1, TMP2
-  |  bge ->fff_newstr
+  |  bgey ->fff_newstr
   |   subi TMP0, TMP1, lo
   |    xori TMP3, TMP1, 0x20
-  |   cmplwi TMP0, 26
-  |   isellt TMP1, TMP3, TMP1
+  |   addic TMP0, TMP0, -26
+  |   subfe TMP3, TMP3, TMP3
+  |   andi. TMP3, TMP3, 0x20
+  |   xor TMP1, TMP1, TMP3
   |   stbx TMP1, CARG2, TMP2
   |  addi TMP2, TMP2, 1
   |  b <1
@@ -1717,35 +2029,47 @@ static void build_subroutines(BuildCtx *ctx)
   |//-- Table library ------------------------------------------------------
   |
   |.ffunc_1 table_getn
-  |  checktab CARG1
-  |  checkfail ->fff_fallback
+  |  checktab CARG3; bne ->fff_fallback
   |  bl extern lj_tab_len		// (GCtab *t)
   |  // Returns uint32_t (but less than 2^31).
-  |  efdcfsi CRET1, CRET1
-  |  b ->fff_restv
+  |  b ->fff_resi
   |
   |//-- Bit library --------------------------------------------------------
   |
   |.macro .ffunc_bit, name
+  ||if (LJ_DUALNUM) {
+  |  .ffunc_1 bit_..name
+  |  checknum CARG3; bnel ->fff_tobit_fb
+  ||} else {
   |  .ffunc_n bit_..name
-  |  efdadd CARG1, CARG1, TOBIT
+  |  fadd FARG1, FARG1, TOBIT
+  |  stfd FARG1, TMPD
+  |  lwz CARG1, TMPD_LO
+  ||}
   |.endmacro
   |
-  |.ffunc_bit tobit
-  |->fff_resbit:
-  |  efdcfsi CRET1, CARG1
-  |  b ->fff_restv
-  |
   |.macro .ffunc_bit_op, name, ins
   |  .ffunc_bit name
-  |   li TMP1, 8
+  |  addi TMP1, BASE, 8
+  |  add TMP2, BASE, NARGS8:RC
   |1:
-  |  evlddx CARG2, BASE, TMP1
-  |  cmplw cr1, TMP1, NARGS8:RC
-  |   checknum CARG2
-  |  bge cr1, ->fff_resbit
-  |   checkfail ->fff_fallback
-  |  efdadd CARG2, CARG2, TOBIT
+  |  lwz CARG4, 0(TMP1)
+  |   cmplw cr1, TMP1, TMP2
+  ||if (LJ_DUALNUM) {
+  |  lwz CARG2, 4(TMP1)
+  ||} else {
+  |  lfd FARG1, 0(TMP1)
+  ||}
+  |   bgey cr1, ->fff_resi
+  |  checknum CARG4
+  ||if (LJ_DUALNUM) {
+  |  bnel ->fff_bitop_fb
+  ||} else {
+  |  fadd FARG1, FARG1, TOBIT
+  |  bge ->fff_fallback
+  |  stfd FARG1, TMPD
+  |  lwz CARG2, TMPD_LO
+  ||}
   |  ins CARG1, CARG1, CARG2
   |   addi TMP1, TMP1, 8
   |  b <1
@@ -1759,26 +2083,35 @@ static void build_subroutines(BuildCtx *ctx)
   |  rotlwi TMP0, CARG1, 8
   |  rlwimi TMP0, CARG1, 24, 0, 7
   |  rlwimi TMP0, CARG1, 24, 16, 23
-  |  efdcfsi CRET1, TMP0
-  |  b ->fff_restv
+  |  mr CRET1, TMP0
+  |  b ->fff_resi
   |
   |.ffunc_bit bnot
-  |  not TMP0, CARG1
-  |  efdcfsi CRET1, TMP0
-  |  b ->fff_restv
+  |  not CRET1, CARG1
+  |  b ->fff_resi
   |
   |.macro .ffunc_bit_sh, name, ins, shmod
+  ||if (LJ_DUALNUM) {
+  |  .ffunc_2 bit_..name
+  |  checknum CARG3; bnel ->fff_tobit_fb
+  |  // Note: no inline conversion from number for 2nd argument!
+  |  checknum CARG4; bne ->fff_fallback
+  ||} else {
   |  .ffunc_nn bit_..name
-  |  efdadd CARG2, CARG2, TOBIT
-  |   efdadd CARG1, CARG1, TOBIT
+  |  fadd FARG1, FARG1, TOBIT
+  |  fadd FARG2, FARG2, TOBIT
+  |  stfd FARG1, TMPD
+  |  lwz CARG1, TMPD_LO
+  |  stfd FARG2, TMPD
+  |  lwz CARG2, TMPD_LO
+  ||}
   |.if shmod == 1
   |  rlwinm CARG2, CARG2, 0, 27, 31
   |.elif shmod == 2
   |  neg CARG2, CARG2
   |.endif
-  |  ins TMP0, CARG1, CARG2
-  |  efdcfsi CRET1, TMP0
-  |  b ->fff_restv
+  |  ins CRET1, CARG1, CARG2
+  |  b ->fff_resi
   |.endmacro
   |
   |.ffunc_bit_sh lshift, slw, 1
@@ -1787,6 +2120,39 @@ static void build_subroutines(BuildCtx *ctx)
   |.ffunc_bit_sh rol, rotlw, 0
   |.ffunc_bit_sh ror, rotlw, 2
   |
+  |.ffunc_bit tobit
+  if (LJ_DUALNUM) {
+    |  b ->fff_resi
+  } else {
+    |->fff_resi:
+    |  tonum_i FARG1, CRET1
+  }
+  |->fff_resn:
+  |  lwz PC, FRAME_PC(BASE)
+  |  la RA, -8(BASE)
+  |  stfd FARG1, -8(BASE)
+  |  b ->fff_res1
+  |
+  |// Fallback FP number to bit conversion.
+  |->fff_tobit_fb:
+  if (LJ_DUALNUM) {
+    |  lfd FARG1, 0(BASE)
+    |  bgt ->fff_fallback
+    |  fadd FARG1, FARG1, TOBIT
+    |  stfd FARG1, TMPD
+    |  lwz CARG1, TMPD_LO
+    |  blr
+  }
+  |->fff_bitop_fb:
+  if (LJ_DUALNUM) {
+    |  lfd FARG1, 0(TMP1)
+    |  bgt ->fff_fallback
+    |  fadd FARG1, FARG1, TOBIT
+    |  stfd FARG1, TMPD
+    |  lwz CARG2, TMPD_LO
+    |  blr
+  }
+  |
   |//-----------------------------------------------------------------------
   |
   |->fff_fallback:			// Call fast function fallback handler.
@@ -1857,7 +2223,18 @@ static void build_subroutines(BuildCtx *ctx)
   |
   |->vm_record:				// Dispatch target for recording phase.
 #if LJ_HASJIT
-  |  NYI
+  |  lbz TMP3, DISPATCH_GL(hookmask)(DISPATCH)
+  |  andi. TMP0, TMP3, HOOK_VMEVENT	// No recording while in vmevent.
+  |  bne >5
+  |  // Decrement the hookcount for consistency, but always do the call.
+  |   lwz TMP2, DISPATCH_GL(hookcount)(DISPATCH)
+  |  andi. TMP0, TMP3, HOOK_ACTIVE
+  |  bne >1
+  |   subi TMP2, TMP2, 1
+  |  andi. TMP0, TMP3, LUA_MASKLINE|LUA_MASKCOUNT
+  |  beqy >1
+  |   stw TMP2, DISPATCH_GL(hookcount)(DISPATCH)
+  |  b >1
 #endif
   |
   |->vm_rethook:			// Dispatch target for return hooks.
@@ -1911,7 +2288,19 @@ static void build_subroutines(BuildCtx *ctx)
   |
   |->vm_hotloop:			// Hot loop counter underflow.
 #if LJ_HASJIT
-  |  NYI
+  |  lwz LFUNC:TMP1, FRAME_FUNC(BASE)
+  |   addi CARG1, DISPATCH, GG_DISP2J
+  |   stw PC, SAVE_PC
+  |  lwz TMP1, LFUNC:TMP1->pc
+  |   mr CARG2, PC
+  |   stw L, DISPATCH_J(L)(DISPATCH)
+  |  lbz TMP1, PC2PROTO(framesize)(TMP1)
+  |   stw BASE, L->base
+  |  slwi TMP1, TMP1, 3
+  |  add TMP1, BASE, TMP1
+  |  stw TMP1, L->top
+  |  bl extern lj_trace_hot		// (jit_State *J, const BCIns *pc)
+  |  b <3
 #endif
   |
   |->vm_callhook:			// Dispatch target for call hooks.
@@ -1939,6 +2328,7 @@ static void build_subroutines(BuildCtx *ctx)
   |  sub NARGS8:RC, TMP0, BASE
   |  add RA, BASE, RA
   |  lwz LFUNC:RB, FRAME_FUNC(BASE)
+  |  lwz INS, -4(PC)
   |  mtctr CRET1
   |  bctr
   |
@@ -1946,149 +2336,199 @@ static void build_subroutines(BuildCtx *ctx)
   |//-- Trace exit handler -------------------------------------------------
   |//-----------------------------------------------------------------------
   |
+  |.macro savex_, a, b, c, d
+  |  stfd f..a, 16+a*8(sp)
+  |  stfd f..b, 16+b*8(sp)
+  |  stfd f..c, 16+c*8(sp)
+  |  stfd f..d, 16+d*8(sp)
+  |.endmacro
+  |
   |->vm_exit_handler:
 #if LJ_HASJIT
-  |  NYI
+  |  addi sp, sp, -(16+32*8+32*4)
+  |  stmw r2, 16+32*8+2*4(sp)
+  |    addi DISPATCH, JGL, -GG_DISP2G-32768
+  |    li CARG2, ~LJ_VMST_EXIT
+  |   lwz CARG1, 16+32*8+32*4(sp)	// Get stack chain.
+  |    stw CARG2, DISPATCH_GL(vmstate)(DISPATCH)
+  |  savex_ 0,1,2,3
+  |   stw CARG1, 0(sp)			// Store extended stack chain.
+  |   mcrxr cr0				// Clear SO flag.
+  |  savex_ 4,5,6,7
+  |   addi CARG2, sp, 16+32*8+32*4	// Recompute original value of sp.
+  |  savex_ 8,9,10,11
+  |   stw CARG2, 16+32*8+1*4(sp)	// Store sp in RID_SP.
+  |  savex_ 12,13,14,15
+  |   mflr CARG3
+  |   li TMP1, 0
+  |  savex_ 16,17,18,19
+  |   stw TMP1, 16+32*8+0*4(sp)		// Clear RID_TMP.
+  |  savex_ 20,21,22,23
+  |   lhz CARG4, 2(CARG3)		// Load trace number.
+  |  savex_ 24,25,26,27
+  |  lwz L, DISPATCH_GL(jit_L)(DISPATCH)
+  |  savex_ 28,29,30,31
+  |   sub CARG3, TMP0, CARG3		// Compute exit number.
+  |  lwz BASE, DISPATCH_GL(jit_base)(DISPATCH)
+  |   srwi CARG3, CARG3, 2
+  |  stw L, DISPATCH_J(L)(DISPATCH)
+  |   subi CARG3, CARG3, 2
+  |  stw TMP1, DISPATCH_GL(jit_L)(DISPATCH)
+  |   stw CARG4, DISPATCH_J(parent)(DISPATCH)
+  |  stw BASE, L->base
+  |  addi CARG1, DISPATCH, GG_DISP2J
+  |   stw CARG3, DISPATCH_J(exitno)(DISPATCH)
+  |  addi CARG2, sp, 16
+  |  bl extern lj_trace_exit		// (jit_State *J, ExitState *ex)
+  |  // Returns MULTRES (unscaled) or negated error code.
+  |  lwz TMP1, L->cframe
+  |  lwz TMP2, 0(sp)
+  |   lwz BASE, L->base
+  |  rlwinm sp, TMP1, 0, 0, 29
+  |   lwz PC, SAVE_PC			// Get SAVE_PC.
+  |  stw TMP2, 0(sp)
+  |  stw L, SAVE_L			// Set SAVE_L (on-trace resume/yield).
+  |  b >1
 #endif
   |->vm_exit_interp:
 #if LJ_HASJIT
-  |  NYI
-#endif
-  |
-  |//-----------------------------------------------------------------------
-  |//-- Math helper functions ----------------------------------------------
-  |//-----------------------------------------------------------------------
-  |
-  |// FP value rounding. Called by math.floor/math.ceil fast functions
-  |// and from JIT code.
-  |//
-  |// This can be inlined if the CPU has the frin/friz/frip/frim instructions.
-  |// The alternative hard-float approaches have a deep dependency chain.
-  |// The resulting latency is at least 3x-7x the double-precision FP latency
-  |// (e500v2: 6cy, e600: 5cy, Cell: 10cy) or around 20-70 cycles.
-  |//
-  |// The soft-float approach is tedious, but much faster (e500v2: ~11cy/~6cy).
-  |// However it relies on a fast way to transfer the FP value to GPRs
-  |// (e500v2: 0cy for lo-word, 1cy for hi-word).
-  |//
-  |.macro vm_round, name, mode
-  |  // Used temporaries: TMP0, TMP1, TMP2, TMP3.
-  |->name.._efd:			// Input: CARG2, output: CRET2
-  |  evmergehi CARG1, CARG2, CARG2
-  |->name.._hilo:
-  |  // Input: CARG1 (hi), CARG2 (hi, lo), output: CRET2
-  |  rlwinm TMP2, CARG1, 12, 21, 31
-  |  addic. TMP2, TMP2, -1023		// exp = exponent(x) - 1023
-  |   li TMP1, -1
-  |  cmplwi cr1, TMP2, 51		// 0 <= exp <= 51?
-  |   subfic TMP0, TMP2, 52
-  |  bgt cr1, >1
-  |   lus TMP3, 0xfff0
-  |  slw TMP0, TMP1, TMP0		// lomask = -1 << (52-exp)
-  |   sraw TMP1, TMP3, TMP2		// himask = (int32_t)0xfff00000 >> exp
-  |.if mode == 2		// trunc(x):
-  |  evmergelo TMP0, TMP1, TMP0
-  |  evand CRET2, CARG2, TMP0		// hi &= himask, lo &= lomask
-  |.else
-  |  andc TMP2, CARG2, TMP0
-  |   andc TMP3, CARG1, TMP1
-  |  or TMP2, TMP2, TMP3		// ztest = (hi&~himask) | (lo&~lomask)
-  |   srawi TMP3, CARG1, 31		// signmask = (int32_t)hi >> 31
-  |.if mode == 0		// floor(x):
-  |  and. TMP2, TMP2, TMP3		// iszero = ((ztest & signmask) == 0)
-  |.else			// ceil(x):
-  |  andc. TMP2, TMP2, TMP3		// iszero = ((ztest & ~signmask) == 0)
-  |.endif
-  |  and CARG2, CARG2, TMP0		// lo &= lomask
-  |  and CARG1, CARG1, TMP1		// hi &= himask
-  |   subc TMP0, CARG2, TMP0
-  |  iseleq TMP0, CARG2, TMP0		// lo = iszero ? lo : lo-lomask
-  |   sube TMP1, CARG1, TMP1
-  |  iseleq TMP1, CARG1, TMP1		// hi = iszero ? hi : hi-himask+carry
-  |  evmergelo CRET2, TMP1, TMP0
-  |.endif
-  |  blr
+  |  // CARG1 = MULTRES or negated error code, BASE, PC and JGL set.
+  |  lwz L, SAVE_L
+  |  addi DISPATCH, JGL, -GG_DISP2G-32768
   |1:
-  |  bgtlr				// Already done if >=2^52, +-inf or nan.
-  |.if mode == 2		// trunc(x):
-  |  rlwinm TMP1, CARG1, 0, 0, 0	// hi = sign(x)
-  |  li TMP0, 0
-  |  evmergelo CRET2, TMP1, TMP0
-  |.else
-  |  rlwinm TMP2, CARG1, 0, 1, 31
-  |  srawi TMP0, CARG1, 31		// signmask = (int32_t)hi >> 31
-  |  or TMP2, TMP2, CARG2		// ztest = abs(hi) | lo
-  |   lus TMP1, 0x3ff0
-  |.if mode == 0		// floor(x):
-  |  and. TMP2, TMP2, TMP0		// iszero = ((ztest & signmask) == 0)
-  |.else			// ceil(x):
-  |  andc. TMP2, TMP2, TMP0		// iszero = ((ztest & ~signmask) == 0)
-  |.endif
-  |   li TMP0, 0
-  |  iseleq TMP1, r0, TMP1
-  |  rlwimi CARG1, TMP1, 0, 1, 31	// hi = sign(x) | (iszero ? 0.0 : 1.0)
-  |  evmergelo CRET2, CARG1, TMP0
-  |.endif
-  |  blr
-  |.endmacro
-  |
-  |->vm_floor:
-  |  mflr CARG3
-  |  bl ->vm_floor_hilo
-  |  mtlr CARG3
-  |  evmergehi CRET1, CRET2, CRET2
-  |  blr
+  |  cmpwi CARG1, 0
+  |  blt >3				// Check for error from exit.
+  |  lwz LFUNC:TMP1, FRAME_FUNC(BASE)
+  |   slwi MULTRES, CARG1, 3
+  |    li TMP2, 0
+  |   stw MULTRES, SAVE_MULTRES
+  |  lwz TMP1, LFUNC:TMP1->pc
+  |    stw TMP2, DISPATCH_GL(jit_L)(DISPATCH)
+  |  lwz KBASE, PC2PROTO(k)(TMP1)
+  |  // Setup type comparison constants.
+  |  li TISNUM, LJ_TISNUM
+  |  lus TMP3, 0x59c0			// TOBIT = 2^52 + 2^51 (float).
+  |  stw TMP3, TMPD
+  |  li ZERO, 0
+  |  ori TMP3, TMP3, 0x0004		// TONUM = 2^52 + 2^51 + 2^31 (float).
+  |  lfs TOBIT, TMPD
+  |  stw TMP3, TMPD
+  |  lus TMP0, 0x4338			// Hiword of 2^52 + 2^51 (double)
+  |    li TISNIL, LJ_TNIL
+  |  stw TMP0, TONUM_HI
+  |  lfs TONUM, TMPD
+  |  // Modified copy of ins_next which handles function header dispatch, too.
+  |  lwz INS, 0(PC)
+  |   addi PC, PC, 4
+  |    // Assumes TISNIL == ~LJ_VMST_INTERP == -1.
+  |    stw TISNIL, DISPATCH_GL(vmstate)(DISPATCH)
+  |  decode_OP4 TMP1, INS
+  |   decode_RA8 RA, INS
+  |  lwzx TMP0, DISPATCH, TMP1
+  |  mtctr TMP0
+  |  cmplwi TMP1, BC_FUNCF*4		// Function header?
+  |  bge >2
+  |   decode_RB8 RB, INS
+  |   decode_RD8 RD, INS
+  |   decode_RC8 RC, INS
+  |  bctr
+  |2:
+  |   subi RC, MULTRES, 8
+  |   add RA, RA, BASE
+  |  bctr
   |
-  |  vm_round vm_floor, 0
-  |  vm_round vm_ceil,  1
-#if LJ_HASJIT
-  |  vm_round vm_trunc, 2
-#else
-  |->vm_trunc_efd:
-  |->vm_trunc_hilo:
+  |3:  // Rethrow error from the right C frame.
+  |  neg CARG2, CARG1
+  |  mr CARG1, L
+  |  bl extern lj_err_throw		// (lua_State *L, int errcode)
 #endif
   |
-  |->vm_powi:
-#if LJ_HASJIT
-  |  NYI
-#endif
+  |//-----------------------------------------------------------------------
+  |//-- Math helper functions ----------------------------------------------
+  |//-----------------------------------------------------------------------
   |
-  |->vm_foldfpm:
+  |  // NYI: Use internal implementation.
+  |->vm_floor:
+  |  b extern floor
+  |->vm_ceil:
+  |  b extern ceil
+  |->vm_trunc:
 #if LJ_HASJIT
-  |  NYI
+  |  b extern trunc
 #endif
+  |
+  |->vm_modi:
+  |  divwo. TMP0, CARG1, CARG2
+  |  bso >1
+  |   xor. CARG3, CARG1, CARG2
+  |  mullw TMP0, TMP0, CARG2
+  |  sub CARG1, CARG1, TMP0
+  |   bgelr
+  |  cmpwi CARG1, 0; beqlr
+  |  add CARG1, CARG1, CARG2
+  |  blr
+  |1:
+  |  cmpwi CARG2, 0
+  |   li CARG1, 0
+  |  beqlr
+  |  mcrxr cr0			// Clear SO for -2147483648 % -1 and return 0.
+  |  blr
   |
   |// Callable from C: double lj_vm_foldarith(double x, double y, int op)
   |// Compute x op y for basic arithmetic operators (+ - * / % ^ and unary -)
   |// and basic math functions. ORDER ARITH
   |->vm_foldarith:
-  |  evmergelo CARG2, CARG1, CARG2
-  |   cmplwi CARG5, 1
-  |  evmergelo CARG4, CARG3, CARG4
-  |   beq >1; bgt >2
-  |  efdadd CRET2, CARG2, CARG4; evmergehi CRET1, CRET2, CRET2; blr
+  |  cmplwi CARG1, 1
+  |  beq >1; bgt >2
+  |  fadd FARG1, FARG1, FARG2; blr
   |1:
-  |  efdsub CRET2, CARG2, CARG4; evmergehi CRET1, CRET2, CRET2; blr
+  |  fsub FARG1, FARG1, FARG2; blr
   |2:
-  |   cmplwi CARG5, 3; beq >1; bgt >2
-  |  efdmul CRET2, CARG2, CARG4; evmergehi CRET1, CRET2, CRET2; blr
+  |   cmplwi CARG1, 3; beq >1; bgt >2
+  |  fmul FARG1, FARG1, FARG2; blr
   |1:
-  |  efddiv CRET2, CARG2, CARG4; evmergehi CRET1, CRET2, CRET2; blr
+  |  fdiv FARG1, FARG1, FARG2; blr
   |2:
-  |   cmplwi CARG5, 5; beq >1; bgt >2
-  |  evmr CARG3, CARG2; efddiv CRET2, CARG2, CARG4; evmr RB, CARG4
-  |  mflr RC; bl ->vm_floor_efd; mtlr RC
-  |  efdmul CRET2, CRET2, RB; efdsub CRET2, CARG3, CRET2
-  |  evmergehi CRET1, CRET2, CRET2; blr
+  |   cmplwi CARG1, 5; beq >1; bgt >2
+  |  // NYI: Use internal implementation of floor and avoid spills.
+  |  stwu sp, -32(sp); stfd f14, 16(sp); stfd f15, 24(sp)
+  |   mflr r0
+  |  fmr f14, FARG1
+  |  fdiv FARG1, FARG1, FARG2
+  |   stw r0, 36(sp)
+  |  fmr f15, FARG2
+  |  bl extern floor
+  |   lwz r0, 36(sp)
+  |  fmul FARG1, FARG1, f15
+  |   mtlr r0
+  |  fsub FARG1, f14, FARG1
+  |  lfd f14, 16(sp); lfd f15, 24(sp); addi sp, sp, 32; blr
   |1:
   |  b extern pow
   |2:
-  |   cmplwi CARG5, 7; beq >1; bgt >2
-  |  xoris CARG1, CARG1, 0x8000; blr
+  |   cmplwi CARG1, 7; beq >1; bgt >2
+  |  fneg FARG1, FARG1; blr
   |1:
-  |  rlwinm CARG1, CARG1, 0, 1, 31; blr
+  |  fabs FARG1, FARG1; blr
+  |2:
+#if LJ_HASJIT
+  |   cmplwi CARG1, 9; beq >9; bgt >2
+  |  b extern atan2
+  |  // No support needed for IR_LDEXP.
   |2:
+  |   cmplwi CARG1, 11; bgt >9
+  |  fsub f0, FARG1, FARG2
+  |  beq >1
+  |  fsel FARG1, f0, FARG2, FARG1	// IR_MAX
+  |  blr
+  |1:
+  |  fsel FARG1, f0, FARG1, FARG2	// IR_MIN
+  |  blr
+  |9:
+  |  NYI  // Bad op.
+#else
   |  NYI  // Other operations only needed by JIT compiler.
+#endif
   |
   |//-----------------------------------------------------------------------
   |//-- Miscellaneous functions --------------------------------------------
@@ -2098,10 +2538,135 @@ static void build_subroutines(BuildCtx *ctx)
   |//-- FFI helper functions -----------------------------------------------
   |//-----------------------------------------------------------------------
   |
-  |->vm_ffi_call:
+  |// Handler for callback functions. Callback slot number in r11, g in r12.
+  |->vm_ffi_callback:
+#if LJ_HASFFI
+  |.type CTSTATE, CTState, PC
+  |  saveregs
+  |  lwz CTSTATE, GL:r12->ctype_state
+  |   addi DISPATCH, r12, GG_G2DISP
+  |  stw r11, CTSTATE->cb.slot
+  |  stw r3, CTSTATE->cb.gpr[0]
+  |   stfd f1, CTSTATE->cb.fpr[0]
+  |  stw r4, CTSTATE->cb.gpr[1]
+  |   stfd f2, CTSTATE->cb.fpr[1]
+  |  stw r5, CTSTATE->cb.gpr[2]
+  |   stfd f3, CTSTATE->cb.fpr[2]
+  |  stw r6, CTSTATE->cb.gpr[3]
+  |   stfd f4, CTSTATE->cb.fpr[3]
+  |  stw r7, CTSTATE->cb.gpr[4]
+  |   stfd f5, CTSTATE->cb.fpr[4]
+  |  stw r8, CTSTATE->cb.gpr[5]
+  |   stfd f6, CTSTATE->cb.fpr[5]
+  |  stw r9, CTSTATE->cb.gpr[6]
+  |   stfd f7, CTSTATE->cb.fpr[6]
+  |  stw r10, CTSTATE->cb.gpr[7]
+  |   stfd f8, CTSTATE->cb.fpr[7]
+  |  addi TMP0, sp, CFRAME_SPACE+8
+  |  stw TMP0, CTSTATE->cb.stack
+  |   mr CARG1, CTSTATE
+  |  stw CTSTATE, SAVE_PC		// Any value outside of bytecode is ok.
+  |   mr CARG2, sp
+  |  bl extern lj_ccallback_enter	// (CTState *cts, void *cf)
+  |  // Returns lua_State *.
+  |  lwz BASE, L:CRET1->base
+  |     li TISNUM, LJ_TISNUM            // Setup type comparison constants.
+  |  lwz RC, L:CRET1->top
+  |     lus TMP3, 0x59c0                // TOBIT = 2^52 + 2^51 (float).
+  |     li ZERO, 0
+  |   mr L, CRET1
+  |     stw TMP3, TMPD
+  |  lwz LFUNC:RB, FRAME_FUNC(BASE)
+  |     ori TMP3, TMP3, 0x0004          // TONUM = 2^52 + 2^51 + 2^31 (float).
+  |     li TISNIL, LJ_TNIL
+  |    li_vmstate INTERP
+  |     lfs TOBIT, TMPD
+  |     stw TMP3, TMPD
+  |  sub RC, RC, BASE
+  |    st_vmstate
+  |     lfs TONUM, TMPD
+  |  ins_callt
+#endif
+  |
+  |->cont_ffi_callback:                 // Return from FFI callback.
+#if LJ_HASFFI
+  |  lwz CTSTATE, DISPATCH_GL(ctype_state)(DISPATCH)
+  |   stw BASE, L->base
+  |   stw RB, L->top
+  |  stw L, CTSTATE->L
+  |  mr CARG1, CTSTATE
+  |  mr CARG2, RA
+  |  bl extern lj_ccallback_leave	// (CTState *cts, TValue *o)
+  |  lwz CRET1, CTSTATE->cb.gpr[0]
+  |  lfd FARG1, CTSTATE->cb.fpr[0]
+  |  lwz CRET2, CTSTATE->cb.gpr[1]
+  |  b ->vm_leave_unw
+#endif
+  |
+  |->vm_ffi_call:			// Call C function via FFI.
+  |  // Caveat: needs special frame unwinding, see below.
 #if LJ_HASFFI
-  |  NYI
+  |  .type CCSTATE, CCallState, CARG1
+  |  lwz TMP1, CCSTATE->spadj
+  |    mflr TMP0
+  |   lbz CARG2, CCSTATE->nsp
+  |   lbz CARG3, CCSTATE->nfpr
+  |  neg TMP1, TMP1
+  |    stw TMP0, 4(sp)
+  |   cmpwi cr1, CARG3, 0
+  |  mr TMP2, sp
+  |   addic. CARG2, CARG2, -1
+  |  stwux sp, sp, TMP1
+  |   crnot 4*cr1+eq, 4*cr1+eq		// For vararg calls.
+  |  stw r14, -4(TMP2)
+  |   li TMP3, 0
+  |  stw CCSTATE, -8(TMP2)
+  |  mr r14, TMP2
+  |  la TMP1, CCSTATE->stack
+  |   slwi CARG2, CARG2, 2
+  |   blty >2
+  |  la TMP2, 8(sp)
+  |1:
+  |  lwzx TMP0, TMP1, CARG2
+  |  stwx TMP0, TMP2, CARG2
+  |   addic. CARG2, CARG2, -4
+  |  bge <1
+  |2:
+  |  bney cr1, >3
+  |  lfd f1, CCSTATE->fpr[0]
+  |  lfd f2, CCSTATE->fpr[1]
+  |  lfd f3, CCSTATE->fpr[2]
+  |  lfd f4, CCSTATE->fpr[3]
+  |  lfd f5, CCSTATE->fpr[4]
+  |  lfd f6, CCSTATE->fpr[5]
+  |  lfd f7, CCSTATE->fpr[6]
+  |  lfd f8, CCSTATE->fpr[7]
+  |3:
+  |   lwz TMP0, CCSTATE->func
+  |  lwz CARG2, CCSTATE->gpr[1]
+  |  lwz CARG3, CCSTATE->gpr[2]
+  |  lwz CARG4, CCSTATE->gpr[3]
+  |  lwz CARG5, CCSTATE->gpr[4]
+  |   mtctr TMP0
+  |  lwz r8, CCSTATE->gpr[5]
+  |  lwz r9, CCSTATE->gpr[6]
+  |  lwz r10, CCSTATE->gpr[7]
+  |  lwz CARG1, CCSTATE->gpr[0]		// Do this last, since CCSTATE is CARG1.
+  |   bctrl
+  |  lwz CCSTATE:TMP1, -8(r14)
+  |  lwz TMP2, -4(r14)
+  |   lwz TMP0, 4(r14)
+  |  stw CARG1, CCSTATE:TMP1->gpr[0]
+  |  stfd FARG1, CCSTATE:TMP1->fpr[0]
+  |  stw CARG2, CCSTATE:TMP1->gpr[1]
+  |   mtlr TMP0
+  |  stw CARG3, CCSTATE:TMP1->gpr[2]
+  |   mr sp, r14
+  |  stw CARG4, CCSTATE:TMP1->gpr[3]
+  |   mr r14, TMP2
+  |  blr
 #endif
+  |// Note: vm_ffi_call must be the last function in this object file!
   |
   |//-----------------------------------------------------------------------
 }
@@ -2120,71 +2685,182 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
 
   case BC_ISLT: case BC_ISGE: case BC_ISLE: case BC_ISGT:
     |  // RA = src1*8, RD = src2*8, JMP with RD = target
-    |  evlddx TMP0, BASE, RA
-    |   addi PC, PC, 4
-    |  evlddx TMP1, BASE, RD
-    |   addis TMP3, PC, -(BCBIAS_J*4 >> 16)
-    |   lwz TMP2, -4(PC)
-    |  evmergehi RB, TMP0, TMP1
-    |   decode_RD4 TMP2, TMP2
-    |  checknum RB
-    |   add TMP2, TMP2, TMP3
-    |  checkanyfail ->vmeta_comp
-    |  efdcmplt TMP0, TMP1
-    if (op == BC_ISLE || op == BC_ISGT) {
-      |  efdcmpeq cr1, TMP0, TMP1
-      |  cror 4*cr0+gt, 4*cr0+gt, 4*cr1+gt
-    }
-    if (op == BC_ISLT || op == BC_ISLE) {
-      |  iselgt PC, TMP2, PC
+    if (LJ_DUALNUM) {
+      |  lwzux TMP0, RA, BASE
+      |    addi PC, PC, 4
+      |   lwz CARG2, 4(RA)
+      |  lwzux TMP1, RD, BASE
+      |    lwz TMP2, -4(PC)
+      |  checknum cr0, TMP0
+      |   lwz CARG3, 4(RD)
+      |    decode_RD4 TMP2, TMP2
+      |  checknum cr1, TMP1
+      |    addis TMP2, TMP2, -(BCBIAS_J*4 >> 16)
+      |  bne cr0, >7
+      |  bne cr1, >8
+      |   cmpw CARG2, CARG3
+      if (op == BC_ISLT) {
+	|  bge >2
+      } else if (op == BC_ISGE) {
+	|  blt >2
+      } else if (op == BC_ISLE) {
+	|  bgt >2
+      } else {
+	|  ble >2
+      }
+      |1:
+      |  add PC, PC, TMP2
+      |2:
+      |  ins_next
+      |
+      |7:  // RA is not an integer.
+      |  bgt cr0, ->vmeta_comp
+      |  // RA is a number.
+      |   lfd f0, 0(RA)
+      |  bgt cr1, ->vmeta_comp
+      |  blt cr1, >4
+      |  // RA is a number, RD is an integer.
+      |  tonum_i f1, CARG3
+      |  b >5
+      |
+      |8: // RA is an integer, RD is not an integer.
+      |  bgt cr1, ->vmeta_comp
+      |  // RA is an integer, RD is a number.
+      |  tonum_i f0, CARG2
+      |4:
+      |  lfd f1, 0(RD)
+      |5:
+      |  fcmpu cr0, f0, f1
+      if (op == BC_ISLT) {
+	|  bge <2
+      } else if (op == BC_ISGE) {
+	|  blt <2
+      } else if (op == BC_ISLE) {
+	|  cror 4*cr0+lt, 4*cr0+lt, 4*cr0+eq
+	|  bge <2
+      } else {
+	|  cror 4*cr0+lt, 4*cr0+lt, 4*cr0+eq
+	|  blt <2
+      }
+      |  b <1
     } else {
-      |  iselgt PC, PC, TMP2
+      |  lwzx TMP0, BASE, RA
+      |    addi PC, PC, 4
+      |   lfdx f0, BASE, RA
+      |  lwzx TMP1, BASE, RD
+      |  checknum cr0, TMP0
+      |    lwz TMP2, -4(PC)
+      |   lfdx f1, BASE, RD
+      |  checknum cr1, TMP1
+      |    decode_RD4 TMP2, TMP2
+      |  bge cr0, ->vmeta_comp
+      |    addis TMP2, TMP2, -(BCBIAS_J*4 >> 16)
+      |  bge cr1, ->vmeta_comp
+      |  fcmpu cr0, f0, f1
+      if (op == BC_ISLT) {
+	|  bge >1
+      } else if (op == BC_ISGE) {
+	|  blt >1
+      } else if (op == BC_ISLE) {
+	|  cror 4*cr0+lt, 4*cr0+lt, 4*cr0+eq
+	|  bge >1
+      } else {
+	|  cror 4*cr0+lt, 4*cr0+lt, 4*cr0+eq
+	|  blt >1
+      }
+      |  add PC, PC, TMP2
+      |1:
+      |  ins_next
     }
-    |  ins_next
     break;
 
   case BC_ISEQV: case BC_ISNEV:
     vk = op == BC_ISEQV;
     |  // RA = src1*8, RD = src2*8, JMP with RD = target
-    |  evlddx CARG2, BASE, RA
-    |   addi PC, PC, 4
-    |  evlddx CARG3, BASE, RD
-    |   addis TMP3, PC, -(BCBIAS_J*4 >> 16)
-    |   lwz TMP2, -4(PC)
-    |  evmergehi RB, CARG2, CARG3
-    |   decode_RD4 TMP2, TMP2
-    |  checknum RB
-    |   add TMP2, TMP2, TMP3
-    |  checkanyfail >5
-    |  efdcmpeq CARG2, CARG3
-    if (vk) {
-      |  iselgt PC, TMP2, PC
+    if (LJ_DUALNUM) {
+      |  lwzux TMP0, RA, BASE
+      |    addi PC, PC, 4
+      |   lwz CARG2, 4(RA)
+      |  lwzux TMP1, RD, BASE
+      |  checknum cr0, TMP0
+      |    lwz TMP2, -4(PC)
+      |  checknum cr1, TMP1
+      |    decode_RD4 TMP2, TMP2
+      |   lwz CARG3, 4(RD)
+      |  cror 4*cr7+gt, 4*cr0+gt, 4*cr1+gt
+      |    addis TMP2, TMP2, -(BCBIAS_J*4 >> 16)
+      if (vk) {
+	|  ble cr7, ->BC_ISEQN_Z
+      } else {
+	|  ble cr7, ->BC_ISNEN_Z
+      }
     } else {
-      |  iselgt PC, PC, TMP2
+      |  lwzux TMP0, RA, BASE
+      |   lwz TMP2, 0(PC)
+      |    lfd f0, 0(RA)
+      |   addi PC, PC, 4
+      |  lwzux TMP1, RD, BASE
+      |  checknum cr0, TMP0
+      |   decode_RD4 TMP2, TMP2
+      |    lfd f1, 0(RD)
+      |  checknum cr1, TMP1
+      |   addis TMP2, TMP2, -(BCBIAS_J*4 >> 16)
+      |  bge cr0, >5
+      |  bge cr1, >5
+      |  fcmpu cr0, f0, f1
+      if (vk) {
+	|  bne >1
+	|  add PC, PC, TMP2
+      } else {
+	|  beq >1
+	|  add PC, PC, TMP2
+      }
+      |1:
+      |  ins_next
     }
-    |1:
-    |  ins_next
-    |
     |5:  // Either or both types are not numbers.
-    |  evcmpeq CARG2, CARG3
-    |   not TMP3, RB
+    if (!LJ_DUALNUM) {
+      |    lwz CARG2, 4(RA)
+      |    lwz CARG3, 4(RD)
+    }
+    if (LJ_HASFFI) {
+      |  cmpwi cr7, TMP0, LJ_TCDATA
+      |  cmpwi cr5, TMP1, LJ_TCDATA
+    }
+    |   not TMP3, TMP0
+    |  cmplw TMP0, TMP1
     |   cmplwi cr1, TMP3, ~LJ_TISPRI		// Primitive?
-    |  crorc 4*cr7+lt, 4*cr0+so, 4*cr0+lt	// 1: Same tv or different type.
+    if (LJ_HASFFI) {
+      |  cror 4*cr7+eq, 4*cr7+eq, 4*cr5+eq
+    }
     |   cmplwi cr6, TMP3, ~LJ_TISTABUD		// Table or userdata?
-    |  crandc 4*cr7+gt, 4*cr0+lt, 4*cr1+gt	// 2: Same type and primitive.
+    if (LJ_HASFFI) {
+      |  beq cr7, ->vmeta_equal_cd
+    }
+    |    cmplw cr5, CARG2, CARG3
+    |  crandc 4*cr0+gt, 4*cr0+eq, 4*cr1+gt	// 2: Same type and primitive.
+    |  crorc 4*cr0+lt, 4*cr5+eq, 4*cr0+eq	// 1: Same tv or different type.
+    |  crand 4*cr0+eq, 4*cr0+eq, 4*cr5+eq	// 0: Same type and same tv.
     |   mr SAVE0, PC
+    |  cror 4*cr0+eq, 4*cr0+eq, 4*cr0+gt	// 0 or 2.
+    |  cror 4*cr0+lt, 4*cr0+lt, 4*cr0+gt	// 1 or 2.
     if (vk) {
-      |  isel PC, TMP2, PC, 4*cr7+gt
+      |  bne cr0, >6
+      |  add PC, PC, TMP2
+      |6:
     } else {
-      |  isel TMP2, PC, TMP2, 4*cr7+gt
+      |  beq cr0, >6
+      |  add PC, PC, TMP2
+      |6:
     }
-    |  cror 4*cr7+lt, 4*cr7+lt, 4*cr7+gt	// 1 or 2.
-    if (vk) {
-      |  isel PC, TMP2, PC, 4*cr0+so
+    if (LJ_DUALNUM) {
+      |  bge cr0, >2			// Done if 1 or 2.
+      |1:
+      |  ins_next
+      |2:
     } else {
-      |  isel PC, PC, TMP2, 4*cr0+so
+      |  blt cr0, <1			// Done if 1 or 2.
     }
-    |  blt cr7, <1			// Done if 1 or 2.
     |  blt cr6, <1			// Done if not tab/ud.
     |
     |  // Different tables or userdatas. Need to check __eq metamethod.
@@ -2203,52 +2879,115 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
   case BC_ISEQS: case BC_ISNES:
     vk = op == BC_ISEQS;
     |  // RA = src*8, RD = str_const*8 (~), JMP with RD = target
-    |  evlddx TMP0, BASE, RA
+    |  lwzux TMP0, RA, BASE
     |   srwi RD, RD, 1
-    |    lwz INS, 0(PC)
+    |  lwz STR:TMP3, 4(RA)
+    |    lwz TMP2, 0(PC)
     |   subfic RD, RD, -4
     |    addi PC, PC, 4
+    if (LJ_HASFFI) {
+      |  cmpwi TMP0, LJ_TCDATA
+    }
     |   lwzx STR:TMP1, KBASE, RD	// KBASE-4-str_const*4
-    |    addis TMP3, PC, -(BCBIAS_J*4 >> 16)
-    |    decode_RD4 TMP2, INS
-    |   evmergelo STR:TMP1, TISSTR, STR:TMP1
-    |    add TMP2, TMP2, TMP3
-    |  evcmpeq TMP0, STR:TMP1
+    |  subfic TMP0, TMP0, LJ_TSTR
+    if (LJ_HASFFI) {
+      |  beq ->vmeta_equal_cd
+    }
+    |  sub TMP1, STR:TMP1, STR:TMP3
+    |  or TMP0, TMP0, TMP1
+    |    decode_RD4 TMP2, TMP2
+    |  subfic TMP0, TMP0, 0
+    |    addis TMP2, TMP2, -(BCBIAS_J*4 >> 16)
+    |  subfe TMP1, TMP1, TMP1
     if (vk) {
-      |  isel PC, TMP2, PC, 4*cr0+so
+      |  andc TMP2, TMP2, TMP1
     } else {
-      |  isel PC, PC, TMP2, 4*cr0+so
+      |  and TMP2, TMP2, TMP1
     }
+    |  add PC, PC, TMP2
     |  ins_next
     break;
 
   case BC_ISEQN: case BC_ISNEN:
     vk = op == BC_ISEQN;
     |  // RA = src*8, RD = num_const*8, JMP with RD = target
-    |  evlddx TMP0, BASE, RA
-    |   addi PC, PC, 4
-    |  evlddx TMP1, KBASE, RD
-    |   addis TMP3, PC, -(BCBIAS_J*4 >> 16)
-    |   lwz INS, -4(PC)
-    |  checknum TMP0
-    |  checkfail >5
-    |  efdcmpeq TMP0, TMP1
-    |1:
-    |   decode_RD4 TMP2, INS
-    |   add TMP2, TMP2, TMP3
+    if (LJ_DUALNUM) {
+      |  lwzux TMP0, RA, BASE
+      |    addi PC, PC, 4
+      |   lwz CARG2, 4(RA)
+      |  lwzux TMP1, RD, KBASE
+      |  checknum cr0, TMP0
+      |    lwz TMP2, -4(PC)
+      |  checknum cr1, TMP1
+      |    decode_RD4 TMP2, TMP2
+      |   lwz CARG3, 4(RD)
+      |    addis TMP2, TMP2, -(BCBIAS_J*4 >> 16)
+      if (vk) {
+	|->BC_ISEQN_Z:
+      } else {
+	|->BC_ISNEN_Z:
+      }
+      |  bne cr0, >7
+      |  bne cr1, >8
+      |   cmpw CARG2, CARG3
+      |4:
+    } else {
+      if (vk) {
+	|->BC_ISEQN_Z:  // Dummy label.
+      } else {
+	|->BC_ISNEN_Z:  // Dummy label.
+      }
+      |  lwzx TMP0, BASE, RA
+      |    addi PC, PC, 4
+      |   lfdx f0, BASE, RA
+      |    lwz TMP2, -4(PC)
+      |  lfdx f1, KBASE, RD
+      |    decode_RD4 TMP2, TMP2
+      |  checknum TMP0
+      |    addis TMP2, TMP2, -(BCBIAS_J*4 >> 16)
+      |  bge >3
+      |  fcmpu cr0, f0, f1
+    }
     if (vk) {
-      |  iselgt PC, TMP2, PC
-      |5:
+      |  bne >1
+      |  add PC, PC, TMP2
+      |1:
+      if (!LJ_HASFFI) {
+	|3:
+      }
     } else {
-      |  iselgt PC, PC, TMP2
+      |  beq >2
+      |1:
+      if (!LJ_HASFFI) {
+	|3:
+      }
+      |  add PC, PC, TMP2
+      |2:
     }
-    |3:
     |  ins_next
-    if (!vk) {
-      |5:
-      |  decode_RD4 TMP2, INS
-      |  add PC, TMP2, TMP3
-      |  b <3
+    if (LJ_HASFFI) {
+      |3:
+      |  cmpwi TMP0, LJ_TCDATA
+      |  beq ->vmeta_equal_cd
+      |  b <1
+    }
+    if (LJ_DUALNUM) {
+      |7:  // RA is not an integer.
+      |  bge cr0, <3
+      |  // RA is a number.
+      |   lfd f0, 0(RA)
+      |  blt cr1, >1
+      |  // RA is a number, RD is an integer.
+      |  tonum_i f1, CARG3
+      |  b >2
+      |
+      |8: // RA is an integer, RD is a number.
+      |  tonum_i f0, CARG2
+      |1:
+      |  lfd f1, 0(RD)
+      |2:
+      |  fcmpu cr0, f0, f1
+      |  b <4
     }
     break;
 
@@ -2257,18 +2996,26 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |  // RA = src*8, RD = primitive_type*8 (~), JMP with RD = target
     |  lwzx TMP0, BASE, RA
     |   srwi TMP1, RD, 3
-    |    lwz INS, 0(PC)
-    |    addi PC, PC, 4
+    |    lwz TMP2, 0(PC)
     |   not TMP1, TMP1
-    |    addis TMP3, PC, -(BCBIAS_J*4 >> 16)
-    |  cmplw TMP0, TMP1
-    |    decode_RD4 TMP2, INS
-    |    add TMP2, TMP2, TMP3
+    |    addi PC, PC, 4
+    if (LJ_HASFFI) {
+      |  cmpwi TMP0, LJ_TCDATA
+    }
+    |  sub TMP0, TMP0, TMP1
+    if (LJ_HASFFI) {
+      |  beq ->vmeta_equal_cd
+    }
+    |    decode_RD4 TMP2, TMP2
+    |  addic TMP0, TMP0, -1
+    |    addis TMP2, TMP2, -(BCBIAS_J*4 >> 16)
+    |  subfe TMP1, TMP1, TMP1
     if (vk) {
-      |  iseleq PC, TMP2, PC
+      |  and TMP2, TMP2, TMP1
     } else {
-      |  iseleq PC, PC, TMP2
+      |  andc TMP2, TMP2, TMP1
     }
+    |  add PC, PC, TMP2
     |  ins_next
     break;
 
@@ -2276,29 +3023,32 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
 
   case BC_ISTC: case BC_ISFC: case BC_IST: case BC_ISF:
     |  // RA = dst*8 or unused, RD = src*8, JMP with RD = target
-    |  evlddx TMP0, BASE, RD
-    |   evaddw TMP1, TISNIL, TISNIL	// Synthesize LJ_TFALSE.
+    |  lwzx TMP0, BASE, RD
     |   lwz INS, 0(PC)
-    |  evcmpltu TMP0, TMP1
     |   addi PC, PC, 4
     if (op == BC_IST || op == BC_ISF) {
-      |  addis TMP3, PC, -(BCBIAS_J*4 >> 16)
-      |  decode_RD4 TMP2, INS
-      |  add TMP2, TMP2, TMP3
+      |  subfic TMP0, TMP0, LJ_TTRUE
+      |   decode_RD4 TMP2, INS
+      |  subfe TMP1, TMP1, TMP1
+      |   addis TMP2, TMP2, -(BCBIAS_J*4 >> 16)
       if (op == BC_IST) {
-	|  isellt PC, TMP2, PC
+	|  andc TMP2, TMP2, TMP1
       } else {
-	|  isellt PC, PC, TMP2
+	|  and TMP2, TMP2, TMP1
       }
+      |  add PC, PC, TMP2
     } else {
+      |  li TMP1, LJ_TFALSE
+      |   lfdx f0, BASE, RD
+      |  cmplw TMP0, TMP1
       if (op == BC_ISTC) {
-	|  checkfail >1
+	|  bge >1
       } else {
-	|  checkok >1
+	|  blt >1
       }
       |  addis PC, PC, -(BCBIAS_J*4 >> 16)
       |  decode_RD4 TMP2, INS
-      |   evstddx TMP0, BASE, RA
+      |   stfdx f0, BASE, RA
       |  add PC, PC, TMP2
       |1:
     }
@@ -2310,8 +3060,8 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
   case BC_MOV:
     |  // RA = dst*8, RD = src*8
     |  ins_next1
-    |  evlddx TMP0, BASE, RD
-    |  evstddx TMP0, BASE, RA
+    |  lfdx f0, BASE, RD
+    |  stfdx f0, BASE, RA
     |  ins_next2
     break;
   case BC_NOT:
@@ -2325,28 +3075,57 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     break;
   case BC_UNM:
     |  // RA = dst*8, RD = src*8
-    |  evlddx TMP0, BASE, RD
-    |  checknum TMP0
-    |  checkfail ->vmeta_unm
-    |  efdneg TMP0, TMP0
+    |  lwzux TMP1, RD, BASE
+    |   lwz TMP0, 4(RD)
+    |  checknum TMP1
+    if (LJ_DUALNUM) {
+      |  bne >5
+      |  nego. TMP0, TMP0
+      |  bso >4
+      |1:
+      |  ins_next1
+      |  stwux TISNUM, RA, BASE
+      |   stw TMP0, 4(RA)
+      |3:
+      |  ins_next2
+      |4:  // Potential overflow.
+      |  mcrxr cr0; bley <1		// Ignore unrelated overflow.
+      |  lus TMP1, 0x41e0		// 2^31.
+      |  li TMP0, 0
+      |  b >7
+    }
+    |5:
+    |  bge ->vmeta_unm
+    |  xoris TMP1, TMP1, 0x8000
+    |7:
     |  ins_next1
-    |  evstddx TMP0, BASE, RA
-    |  ins_next2
+    |  stwux TMP1, RA, BASE
+    |   stw TMP0, 4(RA)
+    if (LJ_DUALNUM) {
+      |  b <3
+    } else {
+      |  ins_next2
+    }
     break;
   case BC_LEN:
     |  // RA = dst*8, RD = src*8
-    |  evlddx CARG1, BASE, RD
-    |  checkstr CARG1
-    |  checkfail >2
+    |  lwzux TMP0, RD, BASE
+    |   lwz CARG1, 4(RD)
+    |  checkstr TMP0; bne >2
     |  lwz CRET1, STR:CARG1->len
     |1:
-    |  ins_next1
-    |  efdcfsi TMP0, CRET1
-    |  evstddx TMP0, BASE, RA
+    if (LJ_DUALNUM) {
+      |  ins_next1
+      |  stwux TISNUM, RA, BASE
+      |   stw CRET1, 4(RA)
+    } else {
+      |  tonum_u f0, CRET1		// Result is a non-negative integer.
+      |  ins_next1
+      |  stfdx f0, BASE, RA
+    }
     |  ins_next2
     |2:
-    |  checktab CARG1
-    |  checkfail ->vmeta_len
+    |  checktab TMP0; bne ->vmeta_len
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
     |  lwz TAB:TMP2, TAB:CARG1->metatable
     |  cmplwi TAB:TMP2, 0
@@ -2368,78 +3147,195 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
 
   /* -- Binary ops -------------------------------------------------------- */
 
-    |.macro ins_arithpre, t0, t1
+    |.macro ins_arithpre
     |  // RA = dst*8, RB = src1*8, RC = src2*8 | num_const*8
     ||vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     ||switch (vk) {
     ||case 0:
-    |   evlddx t0, BASE, RB
-    |    checknum t0
-    |   evlddx t1, KBASE, RC
-    |    checkfail ->vmeta_arith_vn
+    |   lwzx TMP1, BASE, RB
+    ||if (LJ_DUALNUM) {
+    |   lwzx TMP2, KBASE, RC
+    ||}
+    |    lfdx f14, BASE, RB
+    |    lfdx f15, KBASE, RC
+    ||if (LJ_DUALNUM) {
+    |   checknum cr0, TMP1
+    |   checknum cr1, TMP2
+    |   crand 4*cr0+lt, 4*cr0+lt, 4*cr1+lt
+    |   bge ->vmeta_arith_vn
+    ||} else {
+    |   checknum TMP1; bge ->vmeta_arith_vn
+    ||}
     ||  break;
     ||case 1:
-    |   evlddx t1, BASE, RB
-    |    checknum t1
-    |   evlddx t0, KBASE, RC
-    |    checkfail ->vmeta_arith_nv
+    |   lwzx TMP1, BASE, RB
+    ||if (LJ_DUALNUM) {
+    |   lwzx TMP2, KBASE, RC
+    ||}
+    |    lfdx f15, BASE, RB
+    |    lfdx f14, KBASE, RC
+    ||if (LJ_DUALNUM) {
+    |   checknum cr0, TMP1
+    |   checknum cr1, TMP2
+    |   crand 4*cr0+lt, 4*cr0+lt, 4*cr1+lt
+    |   bge ->vmeta_arith_nv
+    ||} else {
+    |   checknum TMP1; bge ->vmeta_arith_nv
+    ||}
     ||  break;
     ||default:
-    |   evlddx t0, BASE, RB
-    |   evlddx t1, BASE, RC
-    |    evmergehi TMP2, t0, t1
-    |    checknum TMP2
-    |    checkanyfail ->vmeta_arith_vv
+    |   lwzx TMP1, BASE, RB
+    |   lwzx TMP2, BASE, RC
+    |    lfdx f14, BASE, RB
+    |    lfdx f15, BASE, RC
+    |   checknum cr0, TMP1
+    |   checknum cr1, TMP2
+    |   crand 4*cr0+lt, 4*cr0+lt, 4*cr1+lt
+    |   bge ->vmeta_arith_vv
     ||  break;
     ||}
     |.endmacro
     |
-    |.macro ins_arith, ins
-    |  ins_arithpre TMP0, TMP1
+    |.macro ins_arithfallback, ins
+    ||switch (vk) {
+    ||case 0:
+    |   ins ->vmeta_arith_vn2
+    ||  break;
+    ||case 1:
+    |   ins ->vmeta_arith_nv2
+    ||  break;
+    ||default:
+    |   ins ->vmeta_arith_vv2
+    ||  break;
+    ||}
+    |.endmacro
+    |
+    |.macro intmod, a, b, c
+    |  bl ->vm_modi
+    |.endmacro
+    |
+    |.macro fpmod, a, b, c
+    |->BC_MODVN_Z:
+    |  fdiv FARG1, b, c
+    |  // NYI: Use internal implementation of floor.
+    |  bl extern floor			// floor(b/c)
+    |  fmul a, FARG1, c
+    |  fsub a, b, a			// b - floor(b/c)*c
+    |.endmacro
+    |
+    |.macro ins_arithfp, fpins
+    |  ins_arithpre
+    |.if "fpins" == "fpmod_"
+    |  b ->BC_MODVN_Z			// Avoid 3 copies. It's slow anyway.
+    |.else
+    |  fpins f0, f14, f15
     |  ins_next1
-    |  ins TMP0, TMP0, TMP1
-    |  evstddx TMP0, BASE, RA
+    |  stfdx f0, BASE, RA
     |  ins_next2
+    |.endif
+    |.endmacro
+    |
+    |.macro ins_arithdn, intins, fpins
+    |  // RA = dst*8, RB = src1*8, RC = src2*8 | num_const*8
+    ||vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
+    ||switch (vk) {
+    ||case 0:
+    |   lwzux TMP1, RB, BASE
+    |   lwzux TMP2, RC, KBASE
+    |    lwz CARG1, 4(RB)
+    |   checknum cr0, TMP1
+    |    lwz CARG2, 4(RC)
+    ||  break;
+    ||case 1:
+    |   lwzux TMP1, RB, BASE
+    |   lwzux TMP2, RC, KBASE
+    |    lwz CARG2, 4(RB)
+    |   checknum cr0, TMP1
+    |    lwz CARG1, 4(RC)
+    ||  break;
+    ||default:
+    |   lwzux TMP1, RB, BASE
+    |   lwzux TMP2, RC, BASE
+    |    lwz CARG1, 4(RB)
+    |   checknum cr0, TMP1
+    |    lwz CARG2, 4(RC)
+    ||  break;
+    ||}
+    |  checknum cr1, TMP2
+    |  bne >5
+    |  bne cr1, >5
+    |  intins CARG1, CARG1, CARG2
+    |  bso >4
+    |1:
+    |  ins_next1
+    |  stwux TISNUM, RA, BASE
+    |  stw CARG1, 4(RA)
+    |2:
+    |  ins_next2
+    |4:  // Overflow.
+    |  mcrxr cr0; bley <1		// Ignore unrelated overflow.
+    |  ins_arithfallback b
+    |5:  // FP variant.
+    ||if (vk == 1) {
+    |  lfd f15, 0(RB)
+    |   crand 4*cr0+lt, 4*cr0+lt, 4*cr1+lt
+    |  lfd f14, 0(RC)
+    ||} else {
+    |  lfd f14, 0(RB)
+    |   crand 4*cr0+lt, 4*cr0+lt, 4*cr1+lt
+    |  lfd f15, 0(RC)
+    ||}
+    |   ins_arithfallback bge
+    |.if "fpins" == "fpmod_"
+    |  b ->BC_MODVN_Z			// Avoid 3 copies. It's slow anyway.
+    |.else
+    |  fpins f0, f14, f15
+    |  ins_next1
+    |  stfdx f0, BASE, RA
+    |  b <2
+    |.endif
+    |.endmacro
+    |
+    |.macro ins_arith, intins, fpins
+    ||if (LJ_DUALNUM) {
+    |  ins_arithdn intins, fpins
+    ||} else {
+    |  ins_arithfp fpins
+    ||}
     |.endmacro
 
   case BC_ADDVN: case BC_ADDNV: case BC_ADDVV:
-    |  ins_arith efdadd
+    |  ins_arith addo., fadd
     break;
   case BC_SUBVN: case BC_SUBNV: case BC_SUBVV:
-    |  ins_arith efdsub
+    |  ins_arith subo., fsub
     break;
   case BC_MULVN: case BC_MULNV: case BC_MULVV:
-    |  ins_arith efdmul
+    |  ins_arith mullwo., fmul
     break;
   case BC_DIVVN: case BC_DIVNV: case BC_DIVVV:
-    |  ins_arith efddiv
+    |  ins_arithfp fdiv
     break;
   case BC_MODVN:
-    |  ins_arithpre RD, SAVE0
-    |->BC_MODVN_Z:
-    |  efddiv CARG2, RD, SAVE0
-    |  bl ->vm_floor_efd		// floor(b/c)
-    |  efdmul TMP0, CRET2, SAVE0
-    |  ins_next1
-    |  efdsub TMP0, RD, TMP0		// b - floor(b/c)*c
-    |  evstddx TMP0, BASE, RA
-    |  ins_next2
+    |  ins_arith intmod, fpmod
     break;
   case BC_MODNV: case BC_MODVV:
-    |  ins_arithpre RD, SAVE0
-    |  b ->BC_MODVN_Z			// Avoid 3 copies. It's slow anyway.
+    |  ins_arith intmod, fpmod_
     break;
   case BC_POW:
-    |  evlddx CARG2, BASE, RB
-    |  evlddx CARG4, BASE, RC
-    |  evmergehi CARG1, CARG4, CARG2
-    |  checknum CARG1
-    |   evmergehi CARG3, CARG4, CARG4
-    |  checkanyfail ->vmeta_arith_vv
+    |  // NYI: (partial) integer arithmetic.
+    |  lwzx TMP1, BASE, RB
+    |   lfdx FARG1, BASE, RB
+    |  lwzx TMP2, BASE, RC
+    |   lfdx FARG2, BASE, RC
+    |  checknum cr0, TMP1
+    |  checknum cr1, TMP2
+    |  crand 4*cr0+lt, 4*cr0+lt, 4*cr1+lt
+    |  bge ->vmeta_arith_vv
     |  bl extern pow
-    |  evmergelo CRET2, CRET1, CRET2
-    |  evstddx CRET2, BASE, RA
-    |  ins_next
+    |  ins_next1
+    |  stfdx FARG1, BASE, RA
+    |  ins_next2
     break;
 
   case BC_CAT:
@@ -2457,50 +3353,73 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |  cmplwi CRET1, 0
     |   lwz BASE, L->base
     |  bne ->vmeta_binop
-    |  evlddx TMP0, BASE, SAVE0		// Copy result from RB to RA.
-    |  evstddx TMP0, BASE, RA
-    |  ins_next
+    |  ins_next1
+    |  lfdx f0, BASE, SAVE0		// Copy result from RB to RA.
+    |  stfdx f0, BASE, RA
+    |  ins_next2
     break;
 
   /* -- Constant ops ------------------------------------------------------ */
 
   case BC_KSTR:
     |  // RA = dst*8, RD = str_const*8 (~)
-    |  ins_next1
     |  srwi TMP1, RD, 1
     |  subfic TMP1, TMP1, -4
+    |  ins_next1
     |  lwzx TMP0, KBASE, TMP1		// KBASE-4-str_const*4
-    |  evmergelo TMP0, TISSTR, TMP0
-    |  evstddx TMP0, BASE, RA
+    |  li TMP2, LJ_TSTR
+    |  stwux TMP2, RA, BASE
+    |  stw TMP0, 4(RA)
     |  ins_next2
     break;
   case BC_KCDATA:
 #if LJ_HASFFI
     |  // RA = dst*8, RD = cdata_const*8 (~)
-    |  ins_next1
     |  srwi TMP1, RD, 1
     |  subfic TMP1, TMP1, -4
+    |  ins_next1
     |  lwzx TMP0, KBASE, TMP1		// KBASE-4-cdata_const*4
     |  li TMP2, LJ_TCDATA
-    |  evmergelo TMP0, TMP2, TMP0
-    |  evstddx TMP0, BASE, RA
+    |  stwux TMP2, RA, BASE
+    |  stw TMP0, 4(RA)
     |  ins_next2
 #endif
     break;
   case BC_KSHORT:
     |  // RA = dst*8, RD = int16_literal*8
-    |  srwi TMP1, RD, 3
-    |  extsh TMP1, TMP1
-    |  ins_next1
-    |  efdcfsi TMP0, TMP1
-    |  evstddx TMP0, BASE, RA
-    |  ins_next2
+    if (LJ_DUALNUM) {
+      |  slwi RD, RD, 13
+      |  srawi RD, RD, 16
+      |  ins_next1
+      |   stwux TISNUM, RA, BASE
+      |   stw RD, 4(RA)
+      |  ins_next2
+    } else {
+      |  // The soft-float approach is faster.
+      |  slwi RD, RD, 13
+      |  srawi TMP1, RD, 31
+      |  xor TMP2, TMP1, RD
+      |  sub TMP2, TMP2, TMP1		// TMP2 = abs(x)
+      |  cntlzw TMP3, TMP2
+      |  subfic TMP1, TMP3, 0x40d	// TMP1 = exponent-1
+      |   slw TMP2, TMP2, TMP3		// TMP2 = left aligned mantissa
+      |    subfic TMP3, RD, 0
+      |  slwi TMP1, TMP1, 20
+      |   rlwimi RD, TMP2, 21, 1, 31	// hi = sign(x) | (mantissa>>11)
+      |    subfe TMP0, TMP0, TMP0
+      |   add RD, RD, TMP1		// hi = hi + exponent-1
+      |    and RD, RD, TMP0		// hi = x == 0 ? 0 : hi
+      |  ins_next1
+      |    stwux RD, RA, BASE
+      |    stw ZERO, 4(RA)
+      |  ins_next2
+    }
     break;
   case BC_KNUM:
     |  // RA = dst*8, RD = num_const*8
-    |  evlddx TMP0, KBASE, RD
     |  ins_next1
-    |  evstddx TMP0, BASE, RA
+    |  lfdx f0, KBASE, RD
+    |  stfdx f0, BASE, RA
     |  ins_next2
     break;
   case BC_KPRI:
@@ -2513,10 +3432,10 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     break;
   case BC_KNIL:
     |  // RA = base*8, RD = end*8
-    |  evstddx TISNIL, BASE, RA
+    |  stwx TISNIL, BASE, RA
     |   addi RA, RA, 8
     |1:
-    |  evstddx TISNIL, BASE, RA
+    |  stwx TISNIL, BASE, RA
     |  cmpw RA, RD
     |   addi RA, RA, 8
     |  blt <1
@@ -2527,14 +3446,14 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
 
   case BC_UGET:
     |  // RA = dst*8, RD = uvnum*8
-    |  ins_next1
     |  lwz LFUNC:RB, FRAME_FUNC(BASE)
     |   srwi RD, RD, 1
     |   addi RD, RD, offsetof(GCfuncL, uvptr)
     |  lwzx UPVAL:RB, LFUNC:RB, RD
+    |  ins_next1
     |  lwz TMP1, UPVAL:RB->v
-    |  evldd TMP0, 0(TMP1)
-    |  evstddx TMP0, BASE, RA
+    |  lfd f0, 0(TMP1)
+    |  stfdx f0, BASE, RA
     |  ins_next2
     break;
   case BC_USETV:
@@ -2542,15 +3461,16 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |  lwz LFUNC:RB, FRAME_FUNC(BASE)
     |    srwi RA, RA, 1
     |    addi RA, RA, offsetof(GCfuncL, uvptr)
-    |   evlddx TMP1, BASE, RD
+    |   lfdux f0, RD, BASE
     |  lwzx UPVAL:RB, LFUNC:RB, RA
     |  lbz TMP3, UPVAL:RB->marked
     |   lwz CARG2, UPVAL:RB->v
     |  andi. TMP3, TMP3, LJ_GC_BLACK	// isblack(uv)
     |    lbz TMP0, UPVAL:RB->closed
-    |   evmergehi TMP2, TMP1, TMP1
-    |   evstdd TMP1, 0(CARG2)
+    |   lwz TMP2, 0(RD)
+    |   stfd f0, 0(CARG2)
     |    cmplwi cr1, TMP0, 0
+    |   lwz TMP1, 4(RD)
     |  cror 4*cr0+eq, 4*cr0+eq, 4*cr1+eq
     |   subi TMP2, TMP2, (LJ_TISNUM+1)
     |  bne >2				// Upvalue is closed and black?
@@ -2570,7 +3490,6 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     break;
   case BC_USETS:
     |  // RA = uvnum*8, RD = str_const*8 (~)
-    |  ins_next1
     |  lwz LFUNC:RB, FRAME_FUNC(BASE)
     |   srwi TMP1, RD, 1
     |    srwi RA, RA, 1
@@ -2578,16 +3497,17 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |    addi RA, RA, offsetof(GCfuncL, uvptr)
     |   lwzx STR:TMP1, KBASE, TMP1	// KBASE-4-str_const*4
     |  lwzx UPVAL:RB, LFUNC:RB, RA
-    |   evmergelo STR:TMP1, TISSTR, STR:TMP1
     |  lbz TMP3, UPVAL:RB->marked
     |   lwz CARG2, UPVAL:RB->v
     |  andi. TMP3, TMP3, LJ_GC_BLACK	// isblack(uv)
     |   lbz TMP3, STR:TMP1->marked
     |   lbz TMP2, UPVAL:RB->closed
-    |   evstdd STR:TMP1, 0(CARG2)
+    |   li TMP0, LJ_TSTR
+    |   stw STR:TMP1, 4(CARG2)
+    |   stw TMP0, 0(CARG2)
     |  bne >2
     |1:
-    |  ins_next2
+    |  ins_next
     |
     |2:  // Check if string is white and ensure upvalue is closed.
     |  andi. TMP3, TMP3, LJ_GC_WHITES	// iswhite(str)
@@ -2601,25 +3521,25 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     break;
   case BC_USETN:
     |  // RA = uvnum*8, RD = num_const*8
-    |  ins_next1
     |  lwz LFUNC:RB, FRAME_FUNC(BASE)
     |   srwi RA, RA, 1
     |   addi RA, RA, offsetof(GCfuncL, uvptr)
-    |    evlddx TMP0, KBASE, RD
+    |    lfdx f0, KBASE, RD
     |  lwzx UPVAL:RB, LFUNC:RB, RA
+    |  ins_next1
     |  lwz TMP1, UPVAL:RB->v
-    |  evstdd TMP0, 0(TMP1)
+    |  stfd f0, 0(TMP1)
     |  ins_next2
     break;
   case BC_USETP:
     |  // RA = uvnum*8, RD = primitive_type*8 (~)
-    |  ins_next1
     |  lwz LFUNC:RB, FRAME_FUNC(BASE)
     |   srwi RA, RA, 1
-    |   addi RA, RA, offsetof(GCfuncL, uvptr)
     |    srwi TMP0, RD, 3
-    |  lwzx UPVAL:RB, LFUNC:RB, RA
+    |   addi RA, RA, offsetof(GCfuncL, uvptr)
     |    not TMP0, TMP0
+    |  lwzx UPVAL:RB, LFUNC:RB, RA
+    |  ins_next1
     |  lwz TMP1, UPVAL:RB->v
     |  stw TMP0, 0(TMP1)
     |  ins_next2
@@ -2653,8 +3573,9 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |  bl extern lj_func_newL_gc
     |  // Returns GCfuncL *.
     |  lwz BASE, L->base
-    |  evmergelo LFUNC:CRET1, TISFUNC, LFUNC:CRET1
-    |  evstddx LFUNC:CRET1, BASE, RA
+    |   li TMP0, LJ_TFUNC
+    |  stwux TMP0, RA, BASE
+    |  stw LFUNC:CRET1, 4(RA)
     |  ins_next
     break;
 
@@ -2674,9 +3595,8 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     if (op == BC_TNEW) {
       |  rlwinm CARG2, RD, 29, 21, 31
       |  rlwinm CARG3, RD, 18, 27, 31
-      |  cmpwi CARG2, 0x7ff
-      |   li TMP1, 0x801
-      |  iseleq CARG2, TMP1, CARG2
+      |  cmpwi CARG2, 0x7ff; beq >3
+      |2:
       |  bl extern lj_tab_new  // (lua_State *L, int32_t asize, uint32_t hbits)
       |  // Returns Table *.
     } else {
@@ -2687,9 +3607,15 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
       |  // Returns Table *.
     }
     |  lwz BASE, L->base
-    |  evmergelo TAB:CRET1, TISTAB, TAB:CRET1
-    |  evstddx TAB:CRET1, BASE, RA
+    |   li TMP0, LJ_TTAB
+    |  stwux TMP0, RA, BASE
+    |  stw TAB:CRET1, 4(RA)
     |  ins_next
+    if (op == BC_TNEW) {
+      |3:
+      |  li CARG2, 0x801
+      |  b <2
+    }
     |5:
     |  mr SAVE0, RD
     |  bl extern lj_gc_step_fixtop  // (lua_State *L)
@@ -2716,28 +3642,46 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
 
   case BC_TGETV:
     |  // RA = dst*8, RB = table*8, RC = key*8
-    |  evlddx TAB:RB, BASE, RB
-    |   evlddx RC, BASE, RC
-    |  checktab TAB:RB
-    |  checkfail ->vmeta_tgetv
-    |  checknum RC
-    |  checkfail >5
-    |  // Convert number key to integer
-    |  efdctsi TMP2, RC
-    |   lwz TMP0, TAB:RB->asize
-    |  efdcfsi TMP1, TMP2
-    |   cmplw cr0, TMP0, TMP2
-    |  efdcmpeq cr1, RC, TMP1
-    |   lwz TMP1, TAB:RB->array
-    |  crand 4*cr0+gt, 4*cr0+gt, 4*cr1+gt
-    |   slwi TMP2, TMP2, 3
+    |  lwzux CARG1, RB, BASE
+    |  lwzux CARG2, RC, BASE
+    |   lwz TAB:RB, 4(RB)
+    if (LJ_DUALNUM) {
+      |   lwz RC, 4(RC)
+    } else {
+      |   lfd f0, 0(RC)
+    }
+    |  checktab CARG1
+    |   checknum cr1, CARG2
+    |  bne ->vmeta_tgetv
+    if (LJ_DUALNUM) {
+      |  lwz TMP0, TAB:RB->asize
+      |   bne cr1, >5
+      |   lwz TMP1, TAB:RB->array
+      |  cmplw TMP0, RC
+      |   slwi TMP2, RC, 3
+    } else {
+      |   bge cr1, >5
+      |  // Convert number key to integer, check for integerness and range.
+      |  fctiwz f1, f0
+      |    fadd f2, f0, TOBIT
+      |  stfd f1, TMPD
+      |   lwz TMP0, TAB:RB->asize
+      |    fsub f2, f2, TOBIT
+      |  lwz TMP2, TMPD_LO
+      |   lwz TMP1, TAB:RB->array
+      |    fcmpu cr1, f0, f2
+      |  cmplw cr0, TMP0, TMP2
+      |  crand 4*cr0+gt, 4*cr0+gt, 4*cr1+eq
+      |   slwi TMP2, TMP2, 3
+    }
     |  ble ->vmeta_tgetv		// Integer key and in array part?
-    |  evlddx TMP1, TMP1, TMP2
-    |  checknil TMP1
-    |  checkok >2
+    |  lwzx TMP0, TMP1, TMP2
+    |   lfdx f14, TMP1, TMP2
+    |  checknil TMP0; beq >2
     |1:
-    |  evstddx TMP1, BASE, RA
-    |  ins_next
+    |  ins_next1
+    |   stfdx f14, BASE, RA
+    |  ins_next2
     |
     |2:  // Check for __index if table value is nil.
     |  lwz TAB:TMP2, TAB:RB->metatable
@@ -2749,38 +3693,42 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |  b ->vmeta_tgetv
     |
     |5:
-    |  checkstr STR:RC			// String key?
-    |  checkok ->BC_TGETS_Z
-    |  b ->vmeta_tgetv
+    |  checkstr CARG2; bne ->vmeta_tgetv
+    if (!LJ_DUALNUM) {
+      |  lwz STR:RC, 4(RC)
+    }
+    |  b ->BC_TGETS_Z			// String key?
     break;
   case BC_TGETS:
     |  // RA = dst*8, RB = table*8, RC = str_const*8 (~)
-    |  evlddx TAB:RB, BASE, RB
+    |  lwzux CARG1, RB, BASE
     |   srwi TMP1, RC, 1
-    |  checktab TAB:RB
+    |    lwz TAB:RB, 4(RB)
     |   subfic TMP1, TMP1, -4
+    |  checktab CARG1
     |   lwzx STR:RC, KBASE, TMP1	// KBASE-4-str_const*4
-    |  checkfail ->vmeta_tgets1
+    |  bne ->vmeta_tgets1
     |->BC_TGETS_Z:
     |  // TAB:RB = GCtab *, STR:RC = GCstr *, RA = dst*8
     |  lwz TMP0, TAB:RB->hmask
     |  lwz TMP1, STR:RC->hash
     |  lwz NODE:TMP2, TAB:RB->node
-    |   evmergelo STR:RC, TISSTR, STR:RC
     |  and TMP1, TMP1, TMP0		// idx = str->hash & tab->hmask
     |  slwi TMP0, TMP1, 5
     |  slwi TMP1, TMP1, 3
     |  sub TMP1, TMP0, TMP1
     |  add NODE:TMP2, NODE:TMP2, TMP1	// node = tab->node + (idx*32-idx*8)
     |1:
-    |  evldd TMP0, NODE:TMP2->key
-    |   evldd TMP1, NODE:TMP2->val
-    |  evcmpeq TMP0, STR:RC
-    |  checkanyfail >4
-    |   checknil TMP1
-    |   checkok >5			// Key found, but nil value?
+    |  lwz CARG1, NODE:TMP2->key
+    |   lwz TMP0, 4+offsetof(Node, key)(NODE:TMP2)
+    |    lwz CARG2, NODE:TMP2->val
+    |     lwz TMP1, 4+offsetof(Node, val)(NODE:TMP2)
+    |  checkstr CARG1; bne >4
+    |   cmpw TMP0, STR:RC; bne >4
+    |    checknil CARG2; beq >5		// Key found, but nil value?
     |3:
-    |   evstddx TMP1, BASE, RA
+    |    stwux CARG2, RA, BASE
+    |     stw TMP1, 4(RA)
     |  ins_next
     |
     |4:  // Follow hash chain.
@@ -2788,7 +3736,7 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |  cmplwi NODE:TMP2, 0
     |  bne <1
     |  // End of hash chain: key not found, nil result.
-    |   evmr TMP1, TISNIL
+    |   li CARG2, LJ_TNIL
     |
     |5:  // Check for __index if table value is nil.
     |  lwz TAB:TMP2, TAB:RB->metatable
@@ -2801,20 +3749,19 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     break;
   case BC_TGETB:
     |  // RA = dst*8, RB = table*8, RC = index*8
-    |  evlddx TAB:RB, BASE, RB
+    |  lwzux CARG1, RB, BASE
     |   srwi TMP0, RC, 3
-    |  checktab TAB:RB
-    |  checkfail ->vmeta_tgetb
+    |   lwz TAB:RB, 4(RB)
+    |  checktab CARG1; bne ->vmeta_tgetb
     |  lwz TMP1, TAB:RB->asize
     |   lwz TMP2, TAB:RB->array
-    |  cmplw TMP0, TMP1
-    |  bge ->vmeta_tgetb
-    |  evlddx TMP1, TMP2, RC
-    |  checknil TMP1
-    |  checkok >5
+    |  cmplw TMP0, TMP1; bge ->vmeta_tgetb
+    |  lwzx TMP1, TMP2, RC
+    |   lfdx f0, TMP2, RC
+    |  checknil TMP1; beq >5
     |1:
     |  ins_next1
-    |  evstddx TMP1, BASE, RA
+    |   stfdx f0, BASE, RA
     |  ins_next2
     |
     |5:  // Check for __index if table value is nil.
@@ -2829,30 +3776,46 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
 
   case BC_TSETV:
     |  // RA = src*8, RB = table*8, RC = key*8
-    |  evlddx TAB:RB, BASE, RB
-    |   evlddx RC, BASE, RC
-    |  checktab TAB:RB
-    |  checkfail ->vmeta_tsetv
-    |  checknum RC
-    |  checkfail >5
-    |  // Convert number key to integer
-    |  efdctsi TMP2, RC
-    |    evlddx SAVE0, BASE, RA
-    |   lwz TMP0, TAB:RB->asize
-    |  efdcfsi TMP1, TMP2
-    |   cmplw cr0, TMP0, TMP2
-    |  efdcmpeq cr1, RC, TMP1
-    |   lwz TMP1, TAB:RB->array
-    |  crand 4*cr0+gt, 4*cr0+gt, 4*cr1+gt
-    |   slwi TMP0, TMP2, 3
+    |  lwzux CARG1, RB, BASE
+    |  lwzux CARG2, RC, BASE
+    |   lwz TAB:RB, 4(RB)
+    if (LJ_DUALNUM) {
+      |   lwz RC, 4(RC)
+    } else {
+      |   lfd f0, 0(RC)
+    }
+    |  checktab CARG1
+    |   checknum cr1, CARG2
+    |  bne ->vmeta_tsetv
+    if (LJ_DUALNUM) {
+      |  lwz TMP0, TAB:RB->asize
+      |   bne cr1, >5
+      |   lwz TMP1, TAB:RB->array
+      |  cmplw TMP0, RC
+      |   slwi TMP0, RC, 3
+    } else {
+      |   bge cr1, >5
+      |  // Convert number key to integer, check for integerness and range.
+      |  fctiwz f1, f0
+      |    fadd f2, f0, TOBIT
+      |  stfd f1, TMPD
+      |   lwz TMP0, TAB:RB->asize
+      |    fsub f2, f2, TOBIT
+      |  lwz TMP2, TMPD_LO
+      |   lwz TMP1, TAB:RB->array
+      |    fcmpu cr1, f0, f2
+      |  cmplw cr0, TMP0, TMP2
+      |  crand 4*cr0+gt, 4*cr0+gt, 4*cr1+eq
+      |   slwi TMP0, TMP2, 3
+    }
     |  ble ->vmeta_tsetv		// Integer key and in array part?
-    |   lbz TMP3, TAB:RB->marked
-    |  evlddx TMP2, TMP1, TMP0
-    |  checknil TMP2
-    |  checkok >3
+    |   lwzx TMP2, TMP1, TMP0
+    |  lbz TMP3, TAB:RB->marked
+    |    lfdx f14, BASE, RA
+    |   checknil TMP2; beq >3
     |1:
     |  andi. TMP2, TMP3, LJ_GC_BLACK	// isblack(table)
-    |   evstddx SAVE0, TMP1, TMP0
+    |    stfdx f14, TMP1, TMP0
     |  bne >7
     |2:
     |  ins_next
@@ -2867,46 +3830,57 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |  b ->vmeta_tsetv
     |
     |5:
-    |  checkstr STR:RC			// String key?
-    |  checkok ->BC_TSETS_Z
-    |  b ->vmeta_tsetv
+    |  checkstr CARG2; bne ->vmeta_tsetv
+    if (!LJ_DUALNUM) {
+      |  lwz STR:RC, 4(RC)
+    }
+    |  b ->BC_TSETS_Z			// String key?
     |
     |7:  // Possible table write barrier for the value. Skip valiswhite check.
     |  barrierback TAB:RB, TMP3, TMP0
     |  b <2
     break;
+    |1:
+    |  checkstr CARG1; bne >4
+    |   cmpw TMP0, STR:RC; bne >4
+    |    checknil CARG2; beq >5		// Key found, but nil value?
+    |3:
+    |    stwux CARG2, RA, BASE
+    |     stw TMP1, 4(RA)
+    |  ins_next
   case BC_TSETS:
     |  // RA = src*8, RB = table*8, RC = str_const*8 (~)
-    |  evlddx TAB:RB, BASE, RB
+    |  lwzux CARG1, RB, BASE
     |   srwi TMP1, RC, 1
-    |  checktab TAB:RB
+    |    lwz TAB:RB, 4(RB)
     |   subfic TMP1, TMP1, -4
+    |  checktab CARG1
     |   lwzx STR:RC, KBASE, TMP1	// KBASE-4-str_const*4
-    |  checkfail ->vmeta_tsets1
+    |  bne ->vmeta_tsets1
     |->BC_TSETS_Z:
     |  // TAB:RB = GCtab *, STR:RC = GCstr *, RA = src*8
     |  lwz TMP0, TAB:RB->hmask
     |  lwz TMP1, STR:RC->hash
     |  lwz NODE:TMP2, TAB:RB->node
-    |   evmergelo STR:RC, TISSTR, STR:RC
     |    stb ZERO, TAB:RB->nomm		// Clear metamethod cache.
     |  and TMP1, TMP1, TMP0		// idx = str->hash & tab->hmask
-    |    evlddx SAVE0, BASE, RA
+    |    lfdx f14, BASE, RA
     |  slwi TMP0, TMP1, 5
     |  slwi TMP1, TMP1, 3
     |  sub TMP1, TMP0, TMP1
     |    lbz TMP3, TAB:RB->marked
     |  add NODE:TMP2, NODE:TMP2, TMP1	// node = tab->node + (idx*32-idx*8)
     |1:
-    |  evldd TMP0, NODE:TMP2->key
-    |   evldd TMP1, NODE:TMP2->val
-    |  evcmpeq TMP0, STR:RC
-    |  checkanyfail >5
-    |   checknil TMP1
-    |   checkok >4			// Key found, but nil value?
+    |  lwz CARG1, NODE:TMP2->key
+    |   lwz TMP0, 4+offsetof(Node, key)(NODE:TMP2)
+    |    lwz CARG2, NODE:TMP2->val
+    |     lwz TMP1, 4+offsetof(Node, val)(NODE:TMP2)
+    |  checkstr CARG1; bne >5
+    |   cmpw TMP0, STR:RC; bne >5
+    |    checknil CARG2; beq >4		// Key found, but nil value?
     |2:
     |  andi. TMP0, TMP3, LJ_GC_BLACK	// isblack(table)
-    |    evstdd SAVE0, NODE:TMP2->val
+    |    stfd f14, NODE:TMP2->val
     |  bne >7
     |3:
     |  ins_next
@@ -2938,12 +3912,14 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |  andi. TMP0, TMP0, 1<<MM_newindex
     |  beq ->vmeta_tsets		// 'no __newindex' flag NOT set: check.
     |6:
-    |  mr CARG2, TAB:RB
-    |  evstdd STR:RC, 0(CARG3)
+    |  li TMP0, LJ_TSTR
+    |   stw STR:RC, 4(CARG3)
+    |   mr CARG2, TAB:RB
+    |  stw TMP0, 0(CARG3)
     |  bl extern lj_tab_newkey		// (lua_State *L, GCtab *t, TValue *k)
     |  // Returns TValue *.
     |  lwz BASE, L->base
-    |  evstdd SAVE0, 0(CRET1)
+    |  stfd f14, 0(CRET1)
     |  b <3				// No 2nd write barrier needed.
     |
     |7:  // Possible table write barrier for the value. Skip valiswhite check.
@@ -2952,22 +3928,21 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     break;
   case BC_TSETB:
     |  // RA = src*8, RB = table*8, RC = index*8
-    |  evlddx TAB:RB, BASE, RB
+    |  lwzux CARG1, RB, BASE
     |   srwi TMP0, RC, 3
-    |  checktab TAB:RB
-    |  checkfail ->vmeta_tsetb
+    |   lwz TAB:RB, 4(RB)
+    |  checktab CARG1; bne ->vmeta_tsetb
     |  lwz TMP1, TAB:RB->asize
     |   lwz TMP2, TAB:RB->array
     |    lbz TMP3, TAB:RB->marked
     |  cmplw TMP0, TMP1
-    |   evlddx SAVE0, BASE, RA
+    |   lfdx f14, BASE, RA
     |  bge ->vmeta_tsetb
-    |  evlddx TMP1, TMP2, RC
-    |  checknil TMP1
-    |  checkok >5
+    |  lwzx TMP1, TMP2, RC
+    |  checknil TMP1; beq >5
     |1:
     |  andi. TMP0, TMP3, LJ_GC_BLACK	// isblack(table)
-    |   evstddx SAVE0, TMP2, RC
+    |   stfdx f14, TMP2, RC
     |  bne >7
     |2:
     |  ins_next
@@ -3007,10 +3982,10 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |   add TMP1, TMP1, TMP0
     |    andi. TMP0, TMP3, LJ_GC_BLACK	// isblack(table)
     |3:  // Copy result slots to table.
-    |   evldd TMP0, 0(RA)
+    |   lfd f0, 0(RA)
     |  addi RA, RA, 8
     |  cmpw cr1, RA, TMP2
-    |   evstdd TMP0, 0(TMP1)
+    |   stfd f0, 0(TMP1)
     |    addi TMP1, TMP1, 8
     |  blt cr1, <3
     |  bne >7
@@ -3028,7 +4003,7 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |  b <1
     |
     |7:  // Possible table write barrier for any value. Skip valiswhite check.
-    |  barrierback TAB:RB, TMP3, TMP0
+    |  barrierback TAB:CARG2, TMP3, TMP0
     |  b <4
     break;
 
@@ -3041,13 +4016,12 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     break;
   case BC_CALL:
     |  // RA = base*8, (RB = (nresults+1)*8,) RC = (nargs+1)*8
-    |  evlddx LFUNC:RB, BASE, RA
-    |   mr TMP2, BASE
-    |   add BASE, BASE, RA
+    |  mr TMP2, BASE
+    |  lwzux TMP0, BASE, RA
+    |   lwz LFUNC:RB, 4(BASE)
     |    subi NARGS8:RC, NARGS8:RC, 8
-    |  checkfunc LFUNC:RB
     |   addi BASE, BASE, 8
-    |  checkfail ->vmeta_call
+    |  checkfunc TMP0; bne ->vmeta_call
     |  ins_call
     break;
 
@@ -3058,13 +4032,13 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     break;
   case BC_CALLT:
     |  // RA = base*8, (RB = 0,) RC = (nargs+1)*8
-    |  evlddx LFUNC:RB, BASE, RA
-    |   add RA, BASE, RA
-    |    lwz TMP1, FRAME_PC(BASE)
+    |  lwzux TMP0, RA, BASE
+    |   lwz LFUNC:RB, 4(RA)
     |    subi NARGS8:RC, NARGS8:RC, 8
-    |  checkfunc LFUNC:RB
+    |    lwz TMP1, FRAME_PC(BASE)
+    |  checkfunc TMP0
     |   addi RA, RA, 8
-    |  checkfail ->vmeta_callt
+    |  bne ->vmeta_callt
     |->BC_CALLT_Z:
     |  andi. TMP0, TMP1, FRAME_TYPE	// Caveat: preserve cr0 until the crand.
     |   lbz TMP3, LFUNC:RB->ffid
@@ -3078,9 +4052,9 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |    beq cr1, >3
     |2:
     |  addi TMP3, TMP2, 8
-    |   evlddx TMP0, RA, TMP2
+    |   lfdx f0, RA, TMP2
     |  cmplw cr1, TMP3, NARGS8:RC
-    |   evstddx TMP0, BASE, TMP2
+    |   stfdx f0, BASE, TMP2
     |  mr TMP2, TMP3
     |  bne cr1, <2
     |3:
@@ -3109,19 +4083,19 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
 
   case BC_ITERC:
     |  // RA = base*8, (RB = (nresults+1)*8, RC = (nargs+1)*8 ((2+1)*8))
-    |  subi RA, RA, 24			// evldd doesn't support neg. offsets.
-    |   mr TMP2, BASE
-    |  evlddx LFUNC:RB, BASE, RA
-    |   add BASE, BASE, RA
-    |   evldd TMP0, 8(BASE)
-    |    evldd TMP1, 16(BASE)
-    |  evstdd LFUNC:RB, 24(BASE)	// Copy callable.
-    |  checkfunc LFUNC:RB
-    |   evstdd TMP0, 32(BASE)		// Copy state.
+    |  mr TMP2, BASE
+    |  add BASE, BASE, RA
+    |  lwz TMP1, -24(BASE)
+    |   lwz LFUNC:RB, -20(BASE)
+    |    lfd f1, -8(BASE)
+    |    lfd f0, -16(BASE)
+    |  stw TMP1, 0(BASE)		// Copy callable.
+    |   stw LFUNC:RB, 4(BASE)
+    |  checkfunc TMP1
+    |    stfd f1, 16(BASE)		// Copy control var.
     |     li NARGS8:RC, 16		// Iterators get 2 arguments.
-    |    evstdd TMP1, 40(BASE)		// Copy control var.
-    |     addi BASE, BASE, 32
-    |  checkfail ->vmeta_call
+    |    stfdu f0, 8(BASE)		// Copy state.
+    |  bne ->vmeta_call
     |  ins_call
     break;
 
@@ -3140,18 +4114,26 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |  cmplw RC, TMP0
     |   slwi TMP3, RC, 3
     |  bge >5				// Index points after array part?
-    |  evlddx TMP2, TMP1, TMP3
+    |  lwzx TMP2, TMP1, TMP3
+    |   lfdx f0, TMP1, TMP3
     |  checknil TMP2
     |     lwz INS, -4(PC)
-    |  checkok >4
-    |   efdcfsi TMP0, RC
+    |  beq >4
+    if (LJ_DUALNUM) {
+      |   stw RC, 4(RA)
+      |   stw TISNUM, 0(RA)
+    } else {
+      |   tonum_u f1, RC
+    }
     |    addi RC, RC, 1
     |     addis TMP3, PC, -(BCBIAS_J*4 >> 16)
-    |  evstdd TMP2, 8(RA)
+    |  stfd f0, 8(RA)
     |     decode_RD4 TMP1, INS
     |    stw RC, -4(RA)			// Update control var.
     |     add PC, TMP1, TMP3
-    |   evstdd TMP0, 0(RA)
+    if (!LJ_DUALNUM) {
+      |   stfd f1, 0(RA)
+    }
     |3:
     |  ins_next
     |
@@ -3166,20 +4148,21 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |6:
     |  cmplw RC, TMP1			// End of iteration? Branch to ITERL+1.
     |   slwi TMP3, RC, 5
-    |  bgt <3
+    |  bgty <3
     |   slwi RB, RC, 3
     |   sub TMP3, TMP3, RB
-    |  evlddx RB, TMP2, TMP3
+    |  lwzx RB, TMP2, TMP3
+    |  lfdx f0, TMP2, TMP3
     |   add NODE:TMP3, TMP2, TMP3
     |  checknil RB
     |     lwz INS, -4(PC)
-    |  checkok >7
-    |   evldd TMP3, NODE:TMP3->key
+    |  beq >7
+    |   lfd f1, NODE:TMP3->key
     |     addis TMP2, PC, -(BCBIAS_J*4 >> 16)
-    |  evstdd RB, 8(RA)
+    |  stfd f0, 8(RA)
     |    add RC, RC, TMP0
     |     decode_RD4 TMP1, INS
-    |   evstdd TMP3, 0(RA)
+    |   stfd f1, 0(RA)
     |    addi RC, RC, 1
     |     add PC, TMP1, TMP2
     |    stw RC, -4(RA)			// Update control var.
@@ -3193,11 +4176,10 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
   case BC_ISNEXT:
     |  // RA = base*8, RD = target (points to ITERN)
     |  add RA, BASE, RA
-    |   li TMP2, -24
-    |  evlddx CFUNC:TMP1, RA, TMP2
+    |  lwz TMP0, -24(RA)
+    |  lwz CFUNC:TMP1, -20(RA)
     |   lwz TMP2, -16(RA)
     |    lwz TMP3, -8(RA)
-    |  evmergehi TMP0, CFUNC:TMP1, CFUNC:TMP1
     |   cmpwi cr0, TMP2, LJ_TTAB
     |  cmpwi cr1, TMP0, LJ_TFUNC
     |    cmpwi cr6, TMP3, LJ_TNIL
@@ -3238,16 +4220,16 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |   subi TMP2, TMP2, 16
     |   ble >2				// No vararg slots?
     |1:  // Copy vararg slots to destination slots.
-    |  evldd TMP0, 0(RC)
+    |  lfd f0, 0(RC)
     |   addi RC, RC, 8
-    |  evstdd TMP0, 0(RA)
+    |  stfd f0, 0(RA)
     |  cmplw RA, TMP2
     |   cmplw cr1, RC, TMP3
     |  bge >3				// All destination slots filled?
     |    addi RA, RA, 8
     |   blt cr1, <1			// More vararg slots?
     |2:  // Fill up remainder with nil.
-    |  evstdd TISNIL, 0(RA)
+    |  stw TISNIL, 0(RA)
     |  cmplw RA, TMP2
     |   addi RA, RA, 8
     |  blt <2
@@ -3257,15 +4239,15 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |5:  // Copy all varargs.
     |  lwz TMP0, L->maxstack
     |   li MULTRES, 8			// MULTRES = (0+1)*8
-    |  ble <3				// No vararg slots?
+    |  bley <3				// No vararg slots?
     |  add TMP2, RA, TMP1
     |  cmplw TMP2, TMP0
     |   addi MULTRES, TMP1, 8
     |  bgt >7
     |6:
-    |  evldd TMP0, 0(RC)
+    |  lfd f0, 0(RC)
     |   addi RC, RC, 8
-    |  evstdd TMP0, 0(RA)
+    |  stfd f0, 0(RA)
     |  cmplw RC, TMP3
     |   addi RA, RA, 8
     |  blt <6				// More vararg slots?
@@ -3316,14 +4298,14 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |   li TMP1, 0
     |2:
     |  addi TMP3, TMP1, 8
-    |   evlddx TMP0, RA, TMP1
+    |   lfdx f0, RA, TMP1
     |  cmpw TMP3, RC
-    |   evstddx TMP0, TMP2, TMP1
+    |   stfdx f0, TMP2, TMP1
     |  beq >3
     |  addi TMP1, TMP3, 8
-    |   evlddx TMP0, RA, TMP3
+    |   lfdx f1, RA, TMP3
     |  cmpw TMP1, RC
-    |   evstddx TMP0, TMP2, TMP3
+    |   stfdx f1, TMP2, TMP3
     |  bne <2
     |3:
     |5:
@@ -3340,7 +4322,7 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |6:  // Fill up results with nil.
     |  subi TMP1, RD, 8
     |   addi RD, RD, 8
-    |  evstddx TISNIL, TMP2, TMP1
+    |  stwx TISNIL, TMP2, TMP1
     |  b <5
     |
     |->BC_RETV_Z:  // Non-standard return case.
@@ -3359,14 +4341,14 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |    mr MULTRES, RD
     |  andi. TMP0, PC, FRAME_TYPE
     |   xori TMP1, PC, FRAME_VARG
-    |  bne ->BC_RETV_Z
+    |  bney ->BC_RETV_Z
     |
     |  lwz INS, -4(PC)
     |   subi TMP2, BASE, 8
     |  decode_RB8 RB, INS
     if (op == BC_RET1) {
-      |  evldd TMP0, 0(RA)
-      |  evstdd TMP0, 0(TMP2)
+      |  lfd f0, 0(RA)
+      |  stfd f0, 0(TMP2)
     }
     |5:
     |  cmplw RB, RD
@@ -3382,7 +4364,7 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |6:  // Fill up results with nil.
     |  subi TMP1, RD, 8
     |   addi RD, RD, 8
-    |  evstddx TISNIL, TMP2, TMP1
+    |  stwx TISNIL, TMP2, TMP1
     |  b <5
     break;
 
@@ -3404,47 +4386,148 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
   case BC_IFORL:
     |  // RA = base*8, RD = target (after end of loop or start of loop)
     vk = (op == BC_IFORL || op == BC_JFORL);
-    |  add RA, BASE, RA
-    |  evldd TMP1, FORL_IDX*8(RA)
-    |  evldd TMP3, FORL_STEP*8(RA)
-    |  evldd TMP2, FORL_STOP*8(RA)
-    if (!vk) {
-      |  evcmpgtu cr0, TMP1, TISNUM
-      |  evcmpgtu cr7, TMP3, TISNUM
-      |  evcmpgtu cr1, TMP2, TISNUM
-      |  cror 4*cr0+lt, 4*cr0+lt, 4*cr7+lt
-      |  cror 4*cr0+lt, 4*cr0+lt, 4*cr1+lt
-      |  blt ->vmeta_for
+    if (LJ_DUALNUM) {
+      |  // Integer loop.
+      |  lwzux TMP1, RA, BASE
+      |   lwz CARG1, FORL_IDX*8+4(RA)
+      |  cmplw cr0, TMP1, TISNUM
+      if (vk) {
+	|   lwz CARG3, FORL_STEP*8+4(RA)
+	|  bne >9
+	|  addo. CARG1, CARG1, CARG3
+	|    cmpwi cr6, CARG3, 0
+	|   lwz CARG2, FORL_STOP*8+4(RA)
+	|  bso >6
+	|4:
+	|  stw CARG1, FORL_IDX*8+4(RA)
+      } else {
+	|  lwz TMP3, FORL_STEP*8(RA)
+	|   lwz CARG3, FORL_STEP*8+4(RA)
+	|  lwz TMP2, FORL_STOP*8(RA)
+	|   lwz CARG2, FORL_STOP*8+4(RA)
+	|  cmplw cr7, TMP3, TISNUM
+	|  cmplw cr1, TMP2, TISNUM
+	|  crand 4*cr0+eq, 4*cr0+eq, 4*cr7+eq
+	|  crand 4*cr0+eq, 4*cr0+eq, 4*cr1+eq
+	|    cmpwi cr6, CARG3, 0
+	|  bne >9
+      }
+      |    blt cr6, >5
+      |  cmpw CARG1, CARG2
+      |1:
+      |   stw TISNUM, FORL_EXT*8(RA)
+      if (op != BC_JFORL) {
+	|  srwi RD, RD, 1
+      }
+      |   stw CARG1, FORL_EXT*8+4(RA)
+      if (op != BC_JFORL) {
+	|  add RD, PC, RD
+      }
+      if (op == BC_FORI) {
+	|  bgt >3  // See FP loop below.
+      } else if (op == BC_JFORI) {
+	|  addis PC, RD, -(BCBIAS_J*4 >> 16)
+	|  bley >7
+      } else if (op == BC_IFORL) {
+	|  bgt >2
+	|  addis PC, RD, -(BCBIAS_J*4 >> 16)
+      } else {
+	|  bley =>BC_JLOOP
+      }
+      |2:
+      |  ins_next
+      |5:  // Invert check for negative step.
+      |  cmpw CARG2, CARG1
+      |  b <1
+      if (vk) {
+	|6:  // Potential overflow.
+	|  mcrxr cr0; bley <4		// Ignore unrelated overflow.
+	|  b <2
+      }
     }
     if (vk) {
-      |  efdadd TMP1, TMP1, TMP3
-      |  evstdd TMP1, FORL_IDX*8(RA)
+      if (LJ_DUALNUM) {
+	|9:  // FP loop.
+	|  lfd f1, FORL_IDX*8(RA)
+      } else {
+	|  lfdux f1, RA, BASE
+      }
+      |  lfd f3, FORL_STEP*8(RA)
+      |  lfd f2, FORL_STOP*8(RA)
+      |   lwz TMP3, FORL_STEP*8(RA)
+      |  fadd f1, f1, f3
+      |  stfd f1, FORL_IDX*8(RA)
+    } else {
+      if (LJ_DUALNUM) {
+	|9:  // FP loop.
+      } else {
+	|  lwzux TMP1, RA, BASE
+	|  lwz TMP3, FORL_STEP*8(RA)
+	|  lwz TMP2, FORL_STOP*8(RA)
+	|  cmplw cr0, TMP1, TISNUM
+	|  cmplw cr7, TMP3, TISNUM
+	|  cmplw cr1, TMP2, TISNUM
+      }
+      |   lfd f1, FORL_IDX*8(RA)
+      |  crand 4*cr0+lt, 4*cr0+lt, 4*cr7+lt
+      |   lfd f3, FORL_STEP*8(RA)
+      |  crand 4*cr0+lt, 4*cr0+lt, 4*cr1+lt
+      |   lfd f2, FORL_STOP*8(RA)
+      |  bge ->vmeta_for
     }
-    |   evcmpgts TMP3, TISNIL
-    |  evstdd TMP1, FORL_EXT*8(RA)
-    |   bge >2
-    |  efdcmpgt TMP1, TMP2
-    |1:
+    |  cmpwi cr6, TMP3, 0
     if (op != BC_JFORL) {
       |  srwi RD, RD, 1
+    }
+    |   stfd f1, FORL_EXT*8(RA)
+    if (op != BC_JFORL) {
       |  add RD, PC, RD
-      if (op == BC_JFORI) {
-	|  addis PC, RD, -(BCBIAS_J*4 >> 16)
+    }
+    |  fcmpu cr0, f1, f2
+    if (op == BC_JFORI) {
+      |  addis PC, RD, -(BCBIAS_J*4 >> 16)
+    }
+    |  blt cr6, >5
+    if (op == BC_FORI) {
+      |  bgt >3
+    } else if (op == BC_IFORL) {
+      if (LJ_DUALNUM) {
+	|  bgty <2
       } else {
-	|  addis RD, RD, -(BCBIAS_J*4 >> 16)
+	|  bgt >2
       }
+      |1:
+      |  addis PC, RD, -(BCBIAS_J*4 >> 16)
+    } else if (op == BC_JFORI) {
+      |  bley >7
+    } else {
+      |  bley =>BC_JLOOP
     }
+    if (LJ_DUALNUM) {
+      |  b <2
+    } else {
+      |2:
+      |  ins_next
+    }
+    |5:  // Negative step.
     if (op == BC_FORI) {
-      |  iselgt PC, RD, PC
+      |  bge <2
+      |3:  // Used by integer loop, too.
+      |  addis PC, RD, -(BCBIAS_J*4 >> 16)
     } else if (op == BC_IFORL) {
-      |  iselgt PC, PC, RD
+      |  bgey <1
+    } else if (op == BC_JFORI) {
+      |  bgey >7
     } else {
-      |  ble =>BC_JLOOP
+      |  bgey =>BC_JLOOP
+    }
+    |  b <2
+    if (op == BC_JFORI) {
+      |7:
+      |  lwz INS, -4(PC)
+      |  decode_RD8 RD, INS
+      |  b =>BC_JLOOP
     }
-    |  ins_next
-    |2:
-    |  efdcmpgt TMP2, TMP1
-    |  b <1
     break;
 
   case BC_ITERL:
@@ -3460,15 +4543,17 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
 #endif
   case BC_IITERL:
     |  // RA = base*8, RD = target
-    |  evlddx TMP1, BASE, RA
-    |   subi RA, RA, 8
-    |  checknil TMP1
-    |  checkok >1			// Stop if iterator returned nil.
+    |  lwzux TMP1, RA, BASE
+    |   lwz TMP2, 4(RA)
+    |  checknil TMP1; beq >1		// Stop if iterator returned nil.
     if (op == BC_JITERL) {
-      |  NYI
+      |  stw TMP1, -8(RA)
+      |   stw TMP2, -4(RA)
+      |  b =>BC_JLOOP
     } else {
       |  branch_RD			// Otherwise save control var + branch.
-      |  evstddx TMP1, BASE, RA
+      |  stw TMP1, -8(RA)
+      |   stw TMP2, -4(RA)
     }
     |1:
     |  ins_next
@@ -3491,7 +4576,19 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
 
   case BC_JLOOP:
 #if LJ_HASJIT
-    |  NYI
+    |  // RA = base*8 (ignored), RD = traceno*8
+    |  lwz TMP1, DISPATCH_J(trace)(DISPATCH)
+    |  srwi RD, RD, 1
+    |  // Traces on PPC don't store the trace number, so use 0.
+    |   stw ZERO, DISPATCH_GL(vmstate)(DISPATCH)
+    |  lwzx TRACE:TMP2, TMP1, RD
+    |  mcrxr cr0			// Clear SO flag.
+    |  lwz TMP2, TRACE:TMP2->mcode
+    |   stw BASE, DISPATCH_GL(jit_base)(DISPATCH)
+    |  mtctr TMP2
+    |   stw L, DISPATCH_GL(jit_L)(DISPATCH)
+    |   addi JGL, DISPATCH, GG_DISP2G+32768
+    |  bctr
 #endif
     break;
 
@@ -3523,18 +4620,21 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |  cmplw RA, TMP2
     |   slwi TMP1, TMP1, 3
     |  bgt ->vm_growstack_l
-    |  ins_next1
+    if (op != BC_JFUNCF) {
+      |  ins_next1
+    }
     |2:
     |  cmplw NARGS8:RC, TMP1		// Check for missing parameters.
     |  ble >3
     if (op == BC_JFUNCF) {
-      |  NYI
+      |  decode_RD8 RD, INS
+      |  b =>BC_JLOOP
     } else {
       |  ins_next2
     }
     |
     |3:  // Clear missing parameters.
-    |  evstddx TISNIL, BASE, NARGS8:RC
+    |  stwx TISNIL, BASE, NARGS8:RC
     |  addi NARGS8:RC, NARGS8:RC, 8
     |  b <2
     break;
@@ -3566,20 +4666,22 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |  beq >3
     |1:
     |  cmplw RA, RC			// Less args than parameters?
-    |   evldd TMP0, 0(RA)
+    |   lwz TMP0, 0(RA)
+    |   lwz TMP3, 4(RA)
     |  bge >4
-    |    evstdd TISNIL, 0(RA)		// Clear old fixarg slot (help the GC).
+    |    stw TISNIL, 0(RA)		// Clear old fixarg slot (help the GC).
     |    addi RA, RA, 8
     |2:
     |  addic. TMP2, TMP2, -1
-    |   evstdd TMP0, 8(TMP1)
+    |   stw TMP0, 8(TMP1)
+    |   stw TMP3, 12(TMP1)
     |    addi TMP1, TMP1, 8
     |  bne <1
     |3:
     |  ins_next2
     |
     |4:  // Clear missing parameters.
-    |  evmr TMP0, TISNIL
+    |  li TMP0, LJ_TNIL
     |  b <2
     break;
 
@@ -3607,9 +4709,9 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     |     st_vmstate
     |  bctrl				// (lua_State *L [, lua_CFunction f])
     |  // Returns nresults.
-    |  lwz TMP1, L->top
-    |   slwi RD, CRET1, 3
     |  lwz BASE, L->base
+    |   slwi RD, CRET1, 3
+    |  lwz TMP1, L->top
     |    li_vmstate INTERP
     |  lwz PC, FRAME_PC(BASE)		// Fetch PC of caller.
     |   sub RA, TMP1, RD		// RA = L->top - nresults*8
@@ -3644,6 +4746,7 @@ static int build_backend(BuildCtx *ctx)
 /* Emit pseudo frame-info for all assembler functions. */
 static void emit_asm_debug(BuildCtx *ctx)
 {
+  int fcofs = (int)((uint8_t *)ctx->glob[GLOB_vm_ffi_call] - ctx->code);
   int i;
   switch (ctx->mode) {
   case BUILD_elfasm:
@@ -3669,20 +4772,31 @@ static void emit_asm_debug(BuildCtx *ctx)
 	"\t.long .Lbegin\n"
 	"\t.long %d\n"
 	"\t.byte 0xe\n\t.uleb128 %d\n"
-	"\t.byte 0x11\n\t.uleb128 65\n\t.sleb128 -1\n",
-	(int)ctx->codesz, CFRAME_SIZE);
+	"\t.byte 0x11\n\t.uleb128 65\n\t.sleb128 -1\n"
+	"\t.byte 0x5\n\t.uleb128 70\n\t.uleb128 55\n",
+	fcofs, CFRAME_SIZE);
     for (i = 14; i <= 31; i++)
-#if LJ_TARGET_PPCSPE
       fprintf(ctx->fp,
 	"\t.byte %d\n\t.uleb128 %d\n"
-	"\t.byte 5\n\t.uleb128 %d\n\t.uleb128 %d\n",
-	0x80+i, 1+2*(31-i), 1200+i, 2+2*(31-i));
-#else
-#error "missing frame info for saved registers"
-#endif
+	"\t.byte %d\n\t.uleb128 %d\n",
+	0x80+i, 37+(31-i), 0x80+32+i, 2+2*(31-i));
     fprintf(ctx->fp,
 	"\t.align 2\n"
 	".LEFDE0:\n\n");
+#if LJ_HASFFI
+    fprintf(ctx->fp,
+	".LSFDE1:\n"
+	"\t.long .LEFDE1-.LASFDE1\n"
+	".LASFDE1:\n"
+	"\t.long .Lframe0\n"
+	"\t.long lj_vm_ffi_call\n"
+	"\t.long %d\n"
+	"\t.byte 0x11\n\t.uleb128 65\n\t.sleb128 -1\n"
+	"\t.byte 0x8e\n\t.uleb128 2\n"
+	"\t.byte 0xd\n\t.uleb128 0xe\n"
+	"\t.align 2\n"
+	".LEFDE1:\n\n", (int)ctx->codesz - fcofs);
+#endif
     fprintf(ctx->fp, "\t.section .eh_frame,\"a\",@progbits\n");
     fprintf(ctx->fp,
 	".Lframe1:\n"
@@ -3702,28 +4816,55 @@ static void emit_asm_debug(BuildCtx *ctx)
 	"\t.align 2\n"
 	".LECIE1:\n\n");
     fprintf(ctx->fp,
-	".LSFDE1:\n"
-	"\t.long .LEFDE1-.LASFDE1\n"
-	".LASFDE1:\n"
-	"\t.long .LASFDE1-.Lframe1\n"
+	".LSFDE2:\n"
+	"\t.long .LEFDE2-.LASFDE2\n"
+	".LASFDE2:\n"
+	"\t.long .LASFDE2-.Lframe1\n"
 	"\t.long .Lbegin-.\n"
 	"\t.long %d\n"
 	"\t.uleb128 0\n"			/* augmentation length */
 	"\t.byte 0xe\n\t.uleb128 %d\n"
-	"\t.byte 0x11\n\t.uleb128 65\n\t.sleb128 -1\n",
-	(int)ctx->codesz, CFRAME_SIZE);
+	"\t.byte 0x11\n\t.uleb128 65\n\t.sleb128 -1\n"
+	"\t.byte 0x5\n\t.uleb128 70\n\t.uleb128 55\n",
+	fcofs, CFRAME_SIZE);
     for (i = 14; i <= 31; i++)
-#if LJ_TARGET_PPCSPE
       fprintf(ctx->fp,
 	"\t.byte %d\n\t.uleb128 %d\n"
-	"\t.byte 5\n\t.uleb128 %d\n\t.uleb128 %d\n",
-	0x80+i, 1+2*(31-i), 1200+i, 2+2*(31-i));
-#else
-#error "missing frame info for saved registers"
-#endif
+	"\t.byte %d\n\t.uleb128 %d\n",
+	0x80+i, 37+(31-i), 0x80+32+i, 2+2*(31-i));
     fprintf(ctx->fp,
 	"\t.align 2\n"
-	".LEFDE1:\n\n");
+	".LEFDE2:\n\n");
+#if LJ_HASFFI
+    fprintf(ctx->fp,
+	".Lframe2:\n"
+	"\t.long .LECIE2-.LSCIE2\n"
+	".LSCIE2:\n"
+	"\t.long 0\n"
+	"\t.byte 0x1\n"
+	"\t.string \"zR\"\n"
+	"\t.uleb128 0x1\n"
+	"\t.sleb128 -4\n"
+	"\t.byte 65\n"
+	"\t.uleb128 1\n"			/* augmentation length */
+	"\t.byte 0x1b\n"			/* pcrel|sdata4 */
+	"\t.byte 0xc\n\t.uleb128 1\n\t.uleb128 0\n"
+	"\t.align 2\n"
+	".LECIE2:\n\n");
+    fprintf(ctx->fp,
+	".LSFDE3:\n"
+	"\t.long .LEFDE3-.LASFDE3\n"
+	".LASFDE3:\n"
+	"\t.long .LASFDE3-.Lframe2\n"
+	"\t.long lj_vm_ffi_call-.\n"
+	"\t.long %d\n"
+	"\t.uleb128 0\n"			/* augmentation length */
+	"\t.byte 0x11\n\t.uleb128 65\n\t.sleb128 -1\n"
+	"\t.byte 0x8e\n\t.uleb128 2\n"
+	"\t.byte 0xd\n\t.uleb128 0xe\n"
+	"\t.align 2\n"
+	".LEFDE3:\n\n", (int)ctx->codesz - fcofs);
+#endif
     break;
   default:
     break;
diff --git a/third_party/luajit/src/buildvm_ppc.h b/third_party/luajit/src/buildvm_ppc.h
new file mode 100644
index 0000000000000000000000000000000000000000..b42b5faacae206c3c9500dc490ee0d5b2607f282
--- /dev/null
+++ b/third_party/luajit/src/buildvm_ppc.h
@@ -0,0 +1,9804 @@
+/*
+** This file has been pre-processed with DynASM.
+** http://luajit.org/dynasm.html
+** DynASM version 1.3.0, DynASM ppc version 1.3.0
+** DO NOT EDIT! The original file is in "buildvm_ppc.dasc".
+*/
+
+#if DASM_VERSION != 10300
+#error "Version mismatch between DynASM and included encoding engine"
+#endif
+
+#define DASM_SECTION_CODE_OP	0
+#define DASM_SECTION_CODE_SUB	1
+#define DASM_MAXSECTION		2
+static const unsigned int build_actionlist[7771] = {
+0x00010001,
+0x00060014,
+0x72000000,
+0x00090200,
+0x39000000,
+0x00098200,
+0x41820000,
+0x00050815,
+0x8209fff8,
+0x7d2e4b78,
+0x9514fff8,
+0x00060016,
+0x72000000,
+0x00090200,
+0x398c0008,
+0x7d936378,
+0x41820000,
+0x00050817,
+0x00060018,
+0x2c000000,
+0x00098200,
+0x56090038,
+0x38000000,
+0x00098200,
+0x7d297050,
+0x40a20000,
+0x00050814,
+0x350cfff8,
+0x91320000,
+0x00098200,
+0x8121002c,
+0x39cefff8,
+0x90110000,
+0x00098200,
+0x55291800,
+0x000900a1,
+0x41820000,
+0x00050802,
+0x0006000b,
+0x3508fff8,
+0xc8140000,
+0x3a940008,
+0xd80e0000,
+0x39ce0008,
+0x40a20000,
+0x0005080b,
+0x0006000c,
+0x7c096000,
+0x40820000,
+0x00050806,
+0x0006000d,
+0x91d20000,
+0x00098200,
+0x00060019,
+0x00000000,
+0x80010028,
+0x38600000,
+0x90120000,
+0x00098200,
+0x0006001a,
+0x80010114,
+0x81810034,
+0x81c10000,
+0x00098200,
+0xc9c10000,
+0x00098200,
+0x81e10000,
+0x00098200,
+0xc9e10000,
+0x00098200,
+0x82010000,
+0x00098200,
+0xca010000,
+0x00098200,
+0x82210000,
+0x00098200,
+0xca210000,
+0x00098200,
+0x82410000,
+0x00098200,
+0xca410000,
+0x00098200,
+0x82610000,
+0x00098200,
+0xca610000,
+0x00098200,
+0x7c0803a6,
+0x7d838120,
+0x82810000,
+0x00098200,
+0xca810000,
+0x00098200,
+0x82a10000,
+0x00098200,
+0xcaa10000,
+0x00098200,
+0x82c10000,
+0x00098200,
+0xcac10000,
+0x00098200,
+0x82e10000,
+0x00098200,
+0xcae10000,
+0x00098200,
+0x00000000,
+0x83010000,
+0x00098200,
+0xcb010000,
+0x00098200,
+0x83210000,
+0x00098200,
+0xcb210000,
+0x00098200,
+0x83410000,
+0x00098200,
+0xcb410000,
+0x00098200,
+0x83610000,
+0x00098200,
+0xcb610000,
+0x00098200,
+0x83810000,
+0x00098200,
+0xcb810000,
+0x00098200,
+0x83a10000,
+0x00098200,
+0xcba10000,
+0x00098200,
+0x83c10000,
+0x00098200,
+0xcbc10000,
+0x00098200,
+0x83e10000,
+0x00098200,
+0xcbe10000,
+0x00098200,
+0x38210110,
+0x4e800020,
+0x00060010,
+0x40810000,
+0x00050807,
+0x81120000,
+0x00098200,
+0x7c0e4040,
+0x40800000,
+0x00050808,
+0x92ee0000,
+0x398c0008,
+0x39ce0008,
+0x48000000,
+0x0005000c,
+0x00060011,
+0x00000000,
+0x20c90000,
+0x7c096050,
+0x7d084110,
+0x7c004038,
+0x7dc07050,
+0x48000000,
+0x0005000d,
+0x00060012,
+0x91d20000,
+0x00098200,
+0x7d956378,
+0x7d244b78,
+0x7e439378,
+0x48000001,
+0x00030000,
+0x8121002c,
+0x7eacab78,
+0x55291800,
+0x000900a1,
+0x81d20000,
+0x00098200,
+0x48000000,
+0x0005000c,
+0x0006001b,
+0x7c611b78,
+0x7c832378,
+0x0006001c,
+0x82410024,
+0x38000000,
+0x00098200,
+0x81120000,
+0x00098200,
+0x90080000,
+0x00098200,
+0x48000000,
+0x0005001a,
+0x0006001d,
+0x5461003a,
+0x0006001e,
+0x82410024,
+0x3ac00000,
+0x00098200,
+0x81d20000,
+0x00098200,
+0x3cc059c0,
+0x82320000,
+0x00098200,
+0x3b000000,
+0x90c10010,
+0x39000000,
+0x00098200,
+0x60c60004,
+0x3ae00000,
+0x00098200,
+0x38000000,
+0x00098200,
+0xc3c10010,
+0x820efff8,
+0x3a8efff8,
+0x90c10010,
+0x3a310000,
+0x00098200,
+0x00000000,
+0x91140000,
+0x39800010,
+0x90110000,
+0x00098200,
+0xc3e10010,
+0x48000000,
+0x00050016,
+0x0006001f,
+0x38800000,
+0x00098200,
+0x48000000,
+0x00050002,
+0x00060020,
+0x7d6e5a14,
+0x7e8ea050,
+0x91d20000,
+0x00098200,
+0x3a100004,
+0x91720000,
+0x00098200,
+0x568400fe,
+0x000900ab,
+0x0006000c,
+0x92010020,
+0x7e439378,
+0x48000001,
+0x00030000,
+0x81d20000,
+0x00098200,
+0x81720000,
+0x00098200,
+0x814efffc,
+0x7d6e5850,
+0x820a0000,
+0x00098200,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x54f4dd78,
+0x7c11402e,
+0x7e947214,
+0x7c0903a6,
+0x4e800420,
+0x00060021,
+0x9421fef0,
+0x91c10000,
+0x00098200,
+0xd9c10000,
+0x00098200,
+0x91e10000,
+0x00098200,
+0xd9e10000,
+0x00098200,
+0x92010000,
+0x00098200,
+0xda010000,
+0x00098200,
+0x7c0802a6,
+0x92210000,
+0x00098200,
+0x00000000,
+0xda210000,
+0x00098200,
+0x92410000,
+0x00098200,
+0xda410000,
+0x00098200,
+0x92610000,
+0x00098200,
+0xda610000,
+0x00098200,
+0x92810000,
+0x00098200,
+0xda810000,
+0x00098200,
+0x92a10000,
+0x00098200,
+0xdaa10000,
+0x00098200,
+0x92c10000,
+0x00098200,
+0xdac10000,
+0x00098200,
+0x90010114,
+0x92e10000,
+0x00098200,
+0xdae10000,
+0x00098200,
+0x93010000,
+0x00098200,
+0xdb010000,
+0x00098200,
+0x93210000,
+0x00098200,
+0xdb210000,
+0x00098200,
+0x7c000026,
+0x93410000,
+0x00098200,
+0xdb410000,
+0x00098200,
+0x93610000,
+0x00098200,
+0xdb610000,
+0x00098200,
+0x93810000,
+0x00098200,
+0x00000000,
+0xdb810000,
+0x00098200,
+0x93a10000,
+0x00098200,
+0xdba10000,
+0x00098200,
+0x93c10000,
+0x00098200,
+0xdbc10000,
+0x00098200,
+0x93e10000,
+0x00098200,
+0xdbe10000,
+0x00098200,
+0x90010034,
+0x7c721b78,
+0x82320000,
+0x00098200,
+0x7c8e2378,
+0x89120000,
+0x00098200,
+0x92410024,
+0x3a000000,
+0x00098200,
+0x38010000,
+0x00098200,
+0x3a310000,
+0x00098200,
+0x90a1002c,
+0x28080000,
+0x90a10030,
+0x90120000,
+0x00098200,
+0x90a10028,
+0x90610020,
+0x41820000,
+0x00050803,
+0x7dd47378,
+0x81d20000,
+0x00098200,
+0x3ac00000,
+0x00098200,
+0x81120000,
+0x00098200,
+0x820efff8,
+0x3cc059c0,
+0x7d8e4050,
+0x98b20000,
+0x00098200,
+0x90c10010,
+0x72000000,
+0x00090200,
+0x60c60004,
+0xc3c10010,
+0x3b000000,
+0x90c10010,
+0x398c0008,
+0x3c004338,
+0x7d936378,
+0x90010008,
+0x38000000,
+0x00098200,
+0xc3e10010,
+0x3ae00000,
+0x00098200,
+0x90110000,
+0x00098200,
+0x00000000,
+0x41820000,
+0x00050817,
+0x48000000,
+0x00050018,
+0x00060022,
+0x9421fef0,
+0x91c10000,
+0x00098200,
+0xd9c10000,
+0x00098200,
+0x91e10000,
+0x00098200,
+0xd9e10000,
+0x00098200,
+0x92010000,
+0x00098200,
+0xda010000,
+0x00098200,
+0x7c0802a6,
+0x92210000,
+0x00098200,
+0xda210000,
+0x00098200,
+0x92410000,
+0x00098200,
+0xda410000,
+0x00098200,
+0x92610000,
+0x00098200,
+0xda610000,
+0x00098200,
+0x92810000,
+0x00098200,
+0xda810000,
+0x00098200,
+0x92a10000,
+0x00098200,
+0xdaa10000,
+0x00098200,
+0x92c10000,
+0x00098200,
+0xdac10000,
+0x00098200,
+0x90010114,
+0x92e10000,
+0x00098200,
+0x00000000,
+0xdae10000,
+0x00098200,
+0x93010000,
+0x00098200,
+0xdb010000,
+0x00098200,
+0x93210000,
+0x00098200,
+0xdb210000,
+0x00098200,
+0x7c000026,
+0x93410000,
+0x00098200,
+0xdb410000,
+0x00098200,
+0x93610000,
+0x00098200,
+0xdb610000,
+0x00098200,
+0x93810000,
+0x00098200,
+0xdb810000,
+0x00098200,
+0x93a10000,
+0x00098200,
+0xdba10000,
+0x00098200,
+0x93c10000,
+0x00098200,
+0xdbc10000,
+0x00098200,
+0x93e10000,
+0x00098200,
+0xdbe10000,
+0x00098200,
+0x90010034,
+0x3a000000,
+0x00098200,
+0x90c10030,
+0x48000000,
+0x00050001,
+0x00060023,
+0x9421fef0,
+0x91c10000,
+0x00098200,
+0xd9c10000,
+0x00098200,
+0x00000000,
+0x91e10000,
+0x00098200,
+0xd9e10000,
+0x00098200,
+0x92010000,
+0x00098200,
+0xda010000,
+0x00098200,
+0x7c0802a6,
+0x92210000,
+0x00098200,
+0xda210000,
+0x00098200,
+0x92410000,
+0x00098200,
+0xda410000,
+0x00098200,
+0x92610000,
+0x00098200,
+0xda610000,
+0x00098200,
+0x92810000,
+0x00098200,
+0xda810000,
+0x00098200,
+0x92a10000,
+0x00098200,
+0xdaa10000,
+0x00098200,
+0x92c10000,
+0x00098200,
+0xdac10000,
+0x00098200,
+0x90010114,
+0x92e10000,
+0x00098200,
+0xdae10000,
+0x00098200,
+0x93010000,
+0x00098200,
+0xdb010000,
+0x00098200,
+0x93210000,
+0x00098200,
+0xdb210000,
+0x00098200,
+0x00000000,
+0x7c000026,
+0x93410000,
+0x00098200,
+0xdb410000,
+0x00098200,
+0x93610000,
+0x00098200,
+0xdb610000,
+0x00098200,
+0x93810000,
+0x00098200,
+0xdb810000,
+0x00098200,
+0x93a10000,
+0x00098200,
+0xdba10000,
+0x00098200,
+0x93c10000,
+0x00098200,
+0xdbc10000,
+0x00098200,
+0x93e10000,
+0x00098200,
+0xdbe10000,
+0x00098200,
+0x90010034,
+0x3a000000,
+0x00098200,
+0x0006000b,
+0x81030000,
+0x00098200,
+0x90a1002c,
+0x7c721b78,
+0x90610024,
+0x7c8e2378,
+0x90320000,
+0x00098200,
+0x82320000,
+0x00098200,
+0x90610020,
+0x91010028,
+0x3a310000,
+0x00098200,
+0x0006000d,
+0x81320000,
+0x00098200,
+0x3ac00000,
+0x00098200,
+0x81120000,
+0x00098200,
+0x00000000,
+0x3cc059c0,
+0x7e107214,
+0x90c10010,
+0x3b000000,
+0x60c60004,
+0xc3c10010,
+0x7e098050,
+0x90c10010,
+0x3c004338,
+0x7d6e4050,
+0x90010008,
+0x38000000,
+0x00098200,
+0xc3e10010,
+0x3ae00000,
+0x00098200,
+0x90110000,
+0x00098200,
+0x00060024,
+0x800efff8,
+0x814efffc,
+0x2c000000,
+0x00098200,
+0x40820000,
+0x00050825,
+0x00060026,
+0x920efff8,
+0x820a0000,
+0x00098200,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x54f4dd78,
+0x7c11402e,
+0x7e947214,
+0x7c0903a6,
+0x4e800420,
+0x00060027,
+0x9421fef0,
+0x91c10000,
+0x00098200,
+0xd9c10000,
+0x00098200,
+0x91e10000,
+0x00098200,
+0xd9e10000,
+0x00098200,
+0x92010000,
+0x00098200,
+0xda010000,
+0x00098200,
+0x7c0802a6,
+0x92210000,
+0x00098200,
+0xda210000,
+0x00098200,
+0x92410000,
+0x00098200,
+0xda410000,
+0x00098200,
+0x92610000,
+0x00098200,
+0xda610000,
+0x00098200,
+0x92810000,
+0x00098200,
+0x00000000,
+0xda810000,
+0x00098200,
+0x92a10000,
+0x00098200,
+0xdaa10000,
+0x00098200,
+0x92c10000,
+0x00098200,
+0xdac10000,
+0x00098200,
+0x90010114,
+0x92e10000,
+0x00098200,
+0xdae10000,
+0x00098200,
+0x93010000,
+0x00098200,
+0xdb010000,
+0x00098200,
+0x93210000,
+0x00098200,
+0xdb210000,
+0x00098200,
+0x7c000026,
+0x93410000,
+0x00098200,
+0xdb410000,
+0x00098200,
+0x93610000,
+0x00098200,
+0xdb610000,
+0x00098200,
+0x93810000,
+0x00098200,
+0xdb810000,
+0x00098200,
+0x93a10000,
+0x00098200,
+0xdba10000,
+0x00098200,
+0x93c10000,
+0x00098200,
+0xdbc10000,
+0x00098200,
+0x93e10000,
+0x00098200,
+0x00000000,
+0xdbe10000,
+0x00098200,
+0x90010034,
+0x7c721b78,
+0x80030000,
+0x00098200,
+0x90610024,
+0x81120000,
+0x00098200,
+0x90610020,
+0x7c080050,
+0x81120000,
+0x00098200,
+0x90320000,
+0x00098200,
+0x39200000,
+0x9001002c,
+0x91210030,
+0x91010028,
+0x7cc903a6,
+0x4e800421,
+0x7c6e1b79,
+0x82320000,
+0x00098200,
+0x3a000000,
+0x00098200,
+0x3a310000,
+0x00098200,
+0x40820000,
+0x0005080d,
+0x48000000,
+0x00050019,
+0x00060015,
+0x800efff4,
+0x7dca7378,
+0x7d2e4b78,
+0x8109fffc,
+0x00000000,
+0x28000001,
+0x00000000,
+0x820afff0,
+0x392cfff8,
+0x81080000,
+0x00098200,
+0x7ef4492e,
+0x00000000,
+0x40810000,
+0x00050801,
+0x00000000,
+0x81e80000,
+0x00098200,
+0x7c0903a6,
+0x4e800420,
+0x00000000,
+0x0006000b,
+0x41820000,
+0x00050828,
+0x390afff0,
+0x7d6e4050,
+0x48000000,
+0x00050029,
+0x00000000,
+0x0006002a,
+0x80f0fffc,
+0x388afff0,
+0x54f55d78,
+0xc8140000,
+0x7d0eaa14,
+0x91d20000,
+0x00098200,
+0x7c082040,
+0x7ca82050,
+0x54f4dd78,
+0xd8040000,
+0x40a20000,
+0x0005082b,
+0x7c0ea5ae,
+0x48000000,
+0x0005002c,
+0x0006002d,
+0x38b10000,
+0x00098200,
+0x38000000,
+0x00098200,
+0x54ea5d78,
+0x91650004,
+0x7c8e5214,
+0x90050000,
+0x48000000,
+0x00050001,
+0x0006002e,
+0x38910000,
+0x00098200,
+0x38000000,
+0x00098200,
+0x91440004,
+0x38b10000,
+0x00098200,
+0x90040000,
+0x39000000,
+0x00098200,
+0x91650004,
+0x91050000,
+0x48000000,
+0x00050001,
+0x0006002f,
+0x00000000,
+0x9001000c,
+0xc8010008,
+0xfc00f028,
+0x00000000,
+0x54ea5d78,
+0x38b10000,
+0x00098200,
+0x7c8e5214,
+0x00000000,
+0x92c50000,
+0x90050004,
+0x00000000,
+0xd8050000,
+0x00000000,
+0x48000000,
+0x00050001,
+0x00060030,
+0x54ea5d78,
+0x54eb9d78,
+0x7c8e5214,
+0x7cae5a14,
+0x0006000b,
+0x91d20000,
+0x00098200,
+0x7e439378,
+0x92010020,
+0x48000001,
+0x00030001,
+0x28030000,
+0x41820000,
+0x00050803,
+0xc8030000,
+0x80f00000,
+0x3a100004,
+0x7c0ea5ae,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000d,
+0x210e0000,
+0x00098200,
+0x81d20000,
+0x00098200,
+0x920efff0,
+0x7e087214,
+0x814efffc,
+0x39600010,
+0x48000000,
+0x00050026,
+0x00060031,
+0x38b10000,
+0x00098200,
+0x38000000,
+0x00098200,
+0x54ea5d78,
+0x91650004,
+0x7c8e5214,
+0x90050000,
+0x48000000,
+0x00050001,
+0x00060032,
+0x38910000,
+0x00098200,
+0x38000000,
+0x00098200,
+0x91440004,
+0x38b10000,
+0x00098200,
+0x90040000,
+0x39000000,
+0x00098200,
+0x91650004,
+0x91050000,
+0x48000000,
+0x00050001,
+0x00060033,
+0x00000000,
+0x9001000c,
+0xc8010008,
+0xfc00f028,
+0x00000000,
+0x54ea5d78,
+0x38b10000,
+0x00098200,
+0x7c8e5214,
+0x00000000,
+0x92c50000,
+0x90050004,
+0x00000000,
+0xd8050000,
+0x00000000,
+0x48000000,
+0x00050001,
+0x00060034,
+0x54ea5d78,
+0x54eb9d78,
+0x7c8e5214,
+0x7cae5a14,
+0x0006000b,
+0x91d20000,
+0x00098200,
+0x7e439378,
+0x92010020,
+0x48000001,
+0x00030002,
+0x28030000,
+0x7c0ea4ae,
+0x41820000,
+0x00050803,
+0x80f00000,
+0x3a100004,
+0xd8030000,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000d,
+0x210e0000,
+0x00098200,
+0x81d20000,
+0x00098200,
+0x920efff0,
+0x7e087214,
+0x814efffc,
+0x39600018,
+0xd80e0010,
+0x48000000,
+0x00050026,
+0x00060035,
+0x7e439378,
+0x3a10fffc,
+0x00000000,
+0x7e84a378,
+0x00000000,
+0x7c8ea214,
+0x00000000,
+0x92010020,
+0x00000000,
+0x7d856378,
+0x00000000,
+0x7cae6214,
+0x00000000,
+0x91d20000,
+0x00098200,
+0x54e6063e,
+0x48000001,
+0x00030003,
+0x0006000d,
+0x28030001,
+0x41810000,
+0x00050836,
+0x20630000,
+0x0006000e,
+0x80f00000,
+0x3a100004,
+0x54e993ba,
+0x3d290000,
+0x00098200,
+0x7d291838,
+0x7e104a14,
+0x0006002c,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00060037,
+0x80f0fffc,
+0xc8140000,
+0x54e8dd78,
+0x7c0e45ae,
+0x48000000,
+0x0005002c,
+0x00060038,
+0x80140000,
+0x20000000,
+0x00098200,
+0x7c631910,
+0x7c6318f8,
+0x48000000,
+0x0005000e,
+0x00060039,
+0x80140000,
+0x20000000,
+0x00098200,
+0x7c631910,
+0x48000000,
+0x0005000e,
+0x0006003a,
+0x3a10fffc,
+0x91d20000,
+0x00098200,
+0x7e439378,
+0x92010020,
+0x48000001,
+0x00030004,
+0x48000000,
+0x0005000d,
+0x0006003b,
+0x00000000,
+0x7ce43b78,
+0x3a10fffc,
+0x91d20000,
+0x00098200,
+0x7e439378,
+0x92010020,
+0x48000001,
+0x00030005,
+0x48000000,
+0x0005000d,
+0x00000000,
+0x0006003c,
+0x7caf5a14,
+0x7cce5214,
+0x48000000,
+0x00050001,
+0x0006003d,
+0x00000000,
+0x7d655b78,
+0x7d465378,
+0x48000000,
+0x00050001,
+0x00000000,
+0x0006003e,
+0x7d856378,
+0x7d866378,
+0x48000000,
+0x00050001,
+0x0006003f,
+0x7cae5214,
+0x7ccf5a14,
+0x48000000,
+0x00050001,
+0x00060040,
+0x7cae5214,
+0x7cce5a14,
+0x00000000,
+0x48000000,
+0x00050001,
+0x00000000,
+0x00060041,
+0x00060042,
+0x00000000,
+0x7d455378,
+0x7d665b78,
+0x00000000,
+0x0006000b,
+0x7c8ea214,
+0x91d20000,
+0x00098200,
+0x7e439378,
+0x92010020,
+0x54e7063e,
+0x48000001,
+0x00030006,
+0x28030000,
+0x41820000,
+0x0005082c,
+0x00060036,
+0x7d0e1850,
+0x9203fff0,
+0x7dc97378,
+0x3a080000,
+0x00098200,
+0x7c6e1b78,
+0x39600010,
+0x48000000,
+0x00050024,
+0x00060043,
+0x00000000,
+0x7c751b78,
+0x00000000,
+0x7d846378,
+0x91d20000,
+0x00098200,
+0x7e439378,
+0x92010020,
+0x48000001,
+0x00030007,
+0x00000000,
+0x28030000,
+0x40820000,
+0x00050836,
+0x7ea3ab78,
+0x48000000,
+0x00050044,
+0x00000000,
+0x48000000,
+0x00050036,
+0x00000000,
+0x00060025,
+0x7e439378,
+0x91320000,
+0x00098200,
+0x388efff8,
+0x92010020,
+0x7cae5a14,
+0x7d755b78,
+0x48000001,
+0x00030008,
+0x814efffc,
+0x39750008,
+0x920efff8,
+0x820a0000,
+0x00098200,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x54f4dd78,
+0x7c11402e,
+0x7e947214,
+0x7c0903a6,
+0x4e800420,
+0x00060045,
+0x7e439378,
+0x91d20000,
+0x00098200,
+0x3894fff8,
+0x92010020,
+0x7cb45a14,
+0x7d755b78,
+0x48000001,
+0x00030008,
+0x810efff8,
+0x39750008,
+0x8154fffc,
+0x48000000,
+0x00050046,
+0x00060047,
+0x7e439378,
+0x91d20000,
+0x00098200,
+0x7e84a378,
+0x92010020,
+0x7cf53b78,
+0x48000001,
+0x00030009,
+0x00000000,
+0x56a0063e,
+0x00000000,
+0x56b4dd78,
+0x00000000,
+0x2c000000,
+0x00098200,
+0x00000000,
+0x56ac9b78,
+0x00000000,
+0x41a20000,
+0x00070800,
+0x00000000,
+0x48000000,
+0x00070000,
+0x00060048,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x39000000,
+0x00098200,
+0x3a8efff8,
+0x7c854040,
+0x820efff8,
+0x40840000,
+0x00050849,
+0x90b40000,
+0x398b0008,
+0x90740004,
+0x41820000,
+0x0005084a,
+0x39000008,
+0x396bfff8,
+0x0006000b,
+0x7c085840,
+0x7c0e44ae,
+0x7c1445ae,
+0x39080008,
+0x40a20000,
+0x0005080b,
+0x48000000,
+0x0005004a,
+0x0006004b,
+0x280b0008,
+0x806e0000,
+0x41800000,
+0x00050849,
+0x7c161810,
+0x7d231910,
+0x7d280338,
+0x39080000,
+0x00098200,
+0x55081800,
+0x000900a1,
+0x392a0000,
+0x00098200,
+0x7c2944ae,
+0x48000000,
+0x0005004c,
+0x0006004d,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x2c050000,
+0x00098200,
+0x40820000,
+0x00050806,
+0x0006000b,
+0x80630000,
+0x00098200,
+0x0006000c,
+0x00000000,
+0x38a00000,
+0x00098200,
+0x28030000,
+0x81710000,
+0x00098200,
+0x41820000,
+0x0005084e,
+0x80030000,
+0x00098200,
+0x38a00000,
+0x00098200,
+0x810b0000,
+0x00098200,
+0x81230000,
+0x00098200,
+0x7d080038,
+0x55002800,
+0x000900a1,
+0x55081800,
+0x000900a1,
+0x7d080050,
+0x7d294214,
+0x0006000d,
+0x80c90000,
+0x00098200,
+0x80090000,
+0x00098200,
+0x80890000,
+0x00098200,
+0x81090000,
+0x00098200,
+0x2c060000,
+0x00098200,
+0x40820000,
+0x00050804,
+0x7c005800,
+0x41820000,
+0x00050805,
+0x0006000e,
+0x81290000,
+0x00098200,
+0x28090000,
+0x41820000,
+0x0005084e,
+0x48000000,
+0x0005000d,
+0x0006000f,
+0x00000000,
+0x2c040000,
+0x00098200,
+0x41820000,
+0x0005084e,
+0x7c852378,
+0x7d034378,
+0x48000000,
+0x0005004e,
+0x00060010,
+0x2c050000,
+0x00098200,
+0x41820000,
+0x0005080b,
+0x7c162810,
+0x7d252910,
+0x7d280338,
+0x39080000,
+0x00098200,
+0x55081000,
+0x000900a1,
+0x39310000,
+0x00098200,
+0x7c69402e,
+0x48000000,
+0x0005000c,
+0x0006004f,
+0x280b0010,
+0x80ae0000,
+0x80ce0008,
+0x806e0004,
+0x808e000c,
+0x41800000,
+0x00050849,
+0x2c050000,
+0x00098200,
+0x40820000,
+0x00050849,
+0x81030000,
+0x00098200,
+0x2c060000,
+0x00098200,
+0x40820000,
+0x00050849,
+0x28080000,
+0x88c30000,
+0x00098200,
+0x40820000,
+0x00050849,
+0x70c00000,
+0x00090200,
+0x90830000,
+0x00098200,
+0x41820000,
+0x0005084e,
+0x00000000,
+0x80110000,
+0x00098200,
+0x54c607b8,
+0x90710000,
+0x00098200,
+0x98c30000,
+0x00098200,
+0x90030000,
+0x00098200,
+0x48000000,
+0x0005004e,
+0x00060050,
+0x280b0008,
+0x80ce0000,
+0x808e0004,
+0x41800000,
+0x00050849,
+0x2c060000,
+0x00098200,
+0x40820000,
+0x00050849,
+0x38ae0008,
+0x7e439378,
+0x48000001,
+0x0003000a,
+0xc8230000,
+0x48000000,
+0x0005004c,
+0x00060051,
+0x280b0008,
+0x806e0000,
+0xc82e0000,
+0x40820000,
+0x00050849,
+0x7c03b040,
+0x41810000,
+0x00050849,
+0x48000000,
+0x0005004c,
+0x00060052,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x2c050000,
+0x00098200,
+0x41820000,
+0x0005084e,
+0x80110000,
+0x00098200,
+0x7c05b040,
+0x28800000,
+0x91d20000,
+0x00098200,
+0x4c413342,
+0x92010020,
+0x41820000,
+0x00050849,
+0x00000000,
+0x80110000,
+0x00098200,
+0x81110000,
+0x00098200,
+0x7c004040,
+0x40800001,
+0x00050853,
+0x7e439378,
+0x7dc47378,
+0x00000000,
+0x48000001,
+0x0003000b,
+0x00000000,
+0x48000001,
+0x0003000c,
+0x00000000,
+0x38a00000,
+0x00098200,
+0x48000000,
+0x0005004e,
+0x00060054,
+0x280b0008,
+0x806e0000,
+0x808e0004,
+0x41800000,
+0x00050849,
+0x7eee592e,
+0x2c030000,
+0x00098200,
+0x820efff8,
+0x40820000,
+0x00050849,
+0x91d20000,
+0x00098200,
+0x7e439378,
+0x91d20000,
+0x00098200,
+0x38ae0008,
+0x92010020,
+0x48000001,
+0x0003000d,
+0x28030000,
+0x38a00000,
+0x00098200,
+0x41820000,
+0x0005084e,
+0xc80e0008,
+0x3a8efff8,
+0xc82e0010,
+0xd8140000,
+0x39800000,
+0x00098200,
+0xd8340008,
+0x48000000,
+0x0005004a,
+0x00060055,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x2c050000,
+0x00098200,
+0x820efff8,
+0x40820000,
+0x00050849,
+0x00000000,
+0x81230000,
+0x00098200,
+0xc80a0000,
+0x00098200,
+0x28090000,
+0x3a8efff8,
+0x40820000,
+0x00050849,
+0x00000000,
+0xc80a0000,
+0x00098200,
+0x3a8efff8,
+0x00000000,
+0x92ee0008,
+0x39800000,
+0x00098200,
+0xd8140000,
+0x48000000,
+0x0005004a,
+0x00060056,
+0x280b0010,
+0x80ae0000,
+0x806e0004,
+0x80ce0008,
+0x00000000,
+0x812e000c,
+0x00000000,
+0xc84e0008,
+0x00000000,
+0x41800000,
+0x00050849,
+0x2c050000,
+0x00098200,
+0x7c86b040,
+0x820efff8,
+0x00000000,
+0x40820000,
+0x00050849,
+0x40860000,
+0x00050849,
+0x00000000,
+0x3c003ff0,
+0x93010014,
+0x40820000,
+0x00050849,
+0x90010010,
+0x40840000,
+0x00050849,
+0xc8210010,
+0xfc00101e,
+0xd8010010,
+0x81210014,
+0x00000000,
+0x80030000,
+0x00098200,
+0x81030000,
+0x00098200,
+0x00000000,
+0xfc42082a,
+0x00000000,
+0x39290001,
+0x3a8efff8,
+0x7c004840,
+0x00000000,
+0x92d40000,
+0x55261800,
+0x000900a1,
+0x91340004,
+0x00000000,
+0x55261800,
+0x000900a1,
+0xd8540000,
+0x00000000,
+0x40810000,
+0x00050802,
+0x7d28302e,
+0x7c0834ae,
+0x0006000b,
+0x2c090000,
+0x00098200,
+0x39800000,
+0x00098200,
+0x41820000,
+0x0005084a,
+0x39800000,
+0x00098200,
+0xd8140008,
+0x48000000,
+0x0005004a,
+0x0006000c,
+0x80030000,
+0x00098200,
+0x28000000,
+0x39800000,
+0x00098200,
+0x41820000,
+0x0005084a,
+0x7d244b78,
+0x48000001,
+0x0003000e,
+0x28030000,
+0x39800000,
+0x00098200,
+0x41820000,
+0x0005084a,
+0x81230000,
+0xc8030000,
+0x48000000,
+0x0005000b,
+0x00060057,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x2c050000,
+0x00098200,
+0x820efff8,
+0x40820000,
+0x00050849,
+0x00000000,
+0x81230000,
+0x00098200,
+0xc80a0000,
+0x00098200,
+0x28090000,
+0x3a8efff8,
+0x40820000,
+0x00050849,
+0x00000000,
+0xc80a0000,
+0x00098200,
+0x3a8efff8,
+0x00000000,
+0x92ce0008,
+0x00000000,
+0x930e0008,
+0x00000000,
+0x930e000c,
+0x39800000,
+0x00098200,
+0xd8140000,
+0x48000000,
+0x0005004a,
+0x00060058,
+0x280b0008,
+0x88d10000,
+0x00098200,
+0x41800000,
+0x00050849,
+0x7dc97378,
+0x39ce0008,
+0x54c607fe,
+0x000900ab,
+0x396bfff8,
+0x3a060000,
+0x00098200,
+0x48000000,
+0x00050024,
+0x00060059,
+0x280b0010,
+0x80ce0008,
+0xc84e0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x89110000,
+0x00098200,
+0x7dc97378,
+0x2c060000,
+0x00098200,
+0x40820000,
+0x00050849,
+0x39ce0010,
+0x550807fe,
+0x000900ab,
+0xd8490000,
+0x396bfff0,
+0xd8290008,
+0x3a080000,
+0x00098200,
+0x48000000,
+0x00050024,
+0x0006005a,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x2c050000,
+0x00098200,
+0x40820000,
+0x00050849,
+0x88030000,
+0x00098200,
+0x81030000,
+0x00098200,
+0x00000000,
+0x80830000,
+0x00098200,
+0x28000000,
+0x00090200,
+0x81230000,
+0x00098200,
+0x28880000,
+0x80030000,
+0x00098200,
+0x7f844840,
+0x820efff8,
+0x4f013342,
+0x7d245a14,
+0x4f3e1102,
+0x7c890040,
+0x4f18cb82,
+0x92010020,
+0x4f182b82,
+0x91d20000,
+0x00098200,
+0x41980000,
+0x00050849,
+0x0006000b,
+0x39ce0008,
+0x396bfff8,
+0x3929fff8,
+0x91230000,
+0x00098200,
+0x39000000,
+0x91d20000,
+0x00098200,
+0x0006000c,
+0x7c085800,
+0x7c0e44ae,
+0x41820000,
+0x00050803,
+0x7c0445ae,
+0x39080008,
+0x48000000,
+0x0005000c,
+0x0006000d,
+0x38a00000,
+0x7c751b78,
+0x38c00000,
+0x48000001,
+0x00050021,
+0x0006000e,
+0x81350000,
+0x00098200,
+0x28030000,
+0x00090200,
+0x80d50000,
+0x00098200,
+0x38000000,
+0x00098200,
+0x81d20000,
+0x00098200,
+0x90110000,
+0x00098200,
+0x41810000,
+0x00050808,
+0x00000000,
+0x7d893050,
+0x80120000,
+0x00098200,
+0x280c0000,
+0x7d0e6214,
+0x41820000,
+0x00050806,
+0x7c080040,
+0x39000000,
+0x41810000,
+0x00050809,
+0x38ccfff8,
+0x91350000,
+0x00098200,
+0x0006000f,
+0x7c083040,
+0x7c0944ae,
+0x7c0e45ae,
+0x39080008,
+0x40820000,
+0x0005080f,
+0x00060010,
+0x72000000,
+0x00090200,
+0x39000000,
+0x00098200,
+0x3a8efff8,
+0x910efff8,
+0x398c0010,
+0x00060011,
+0x92010020,
+0x7d936378,
+0x41820000,
+0x00050817,
+0x48000000,
+0x00050018,
+0x00060012,
+0x72000000,
+0x00090200,
+0x38c6fff8,
+0x39000000,
+0x00098200,
+0xc8060000,
+0x90d50000,
+0x00098200,
+0x39800000,
+0x00098200,
+0x910efff8,
+0x3a8efff8,
+0xd80e0000,
+0x48000000,
+0x00050011,
+0x00060013,
+0x7e439378,
+0x558400fe,
+0x000900ab,
+0x48000001,
+0x00030000,
+0x38600000,
+0x48000000,
+0x0005000e,
+0x0006005b,
+0x00000000,
+0x806a0000,
+0x00098200,
+0x88030000,
+0x00098200,
+0x81030000,
+0x00098200,
+0x80830000,
+0x00098200,
+0x28000000,
+0x00090200,
+0x81230000,
+0x00098200,
+0x28880000,
+0x80030000,
+0x00098200,
+0x7f844840,
+0x820efff8,
+0x4f013342,
+0x7d245a14,
+0x4f3e1102,
+0x7c890040,
+0x4f18cb82,
+0x92010020,
+0x4f182b82,
+0x91d20000,
+0x00098200,
+0x41980000,
+0x00050849,
+0x0006000b,
+0x91230000,
+0x00098200,
+0x39000000,
+0x91d20000,
+0x00098200,
+0x0006000c,
+0x7c085800,
+0x7c0e44ae,
+0x41820000,
+0x00050803,
+0x7c0445ae,
+0x39080008,
+0x48000000,
+0x0005000c,
+0x0006000d,
+0x38a00000,
+0x7c751b78,
+0x38c00000,
+0x48000001,
+0x00050021,
+0x0006000e,
+0x81350000,
+0x00098200,
+0x28030000,
+0x00090200,
+0x80d50000,
+0x00098200,
+0x38000000,
+0x00098200,
+0x00000000,
+0x81d20000,
+0x00098200,
+0x90110000,
+0x00098200,
+0x41810000,
+0x00050808,
+0x7d893050,
+0x80120000,
+0x00098200,
+0x280c0000,
+0x7d0e6214,
+0x41820000,
+0x00050806,
+0x7c080040,
+0x39000000,
+0x41810000,
+0x00050809,
+0x38ccfff8,
+0x91350000,
+0x00098200,
+0x0006000f,
+0x7c083040,
+0x7c0944ae,
+0x7c0e45ae,
+0x39080008,
+0x40820000,
+0x0005080f,
+0x00060010,
+0x72000000,
+0x00090200,
+0x7dd47378,
+0x398c0008,
+0x00060011,
+0x92010020,
+0x7d936378,
+0x41820000,
+0x00050817,
+0x48000000,
+0x00050018,
+0x00060012,
+0x7e439378,
+0x7ea4ab78,
+0x48000001,
+0x0003000f,
+0x00060013,
+0x7e439378,
+0x558400fe,
+0x000900ab,
+0x48000001,
+0x00030000,
+0x38600000,
+0x48000000,
+0x0005000e,
+0x0006005c,
+0x80120000,
+0x00098200,
+0x00000000,
+0x7d0e5a14,
+0x91d20000,
+0x00098200,
+0x70000000,
+0x00090200,
+0x91120000,
+0x00098200,
+0x38600000,
+0x00098200,
+0x41820000,
+0x00050849,
+0x93120000,
+0x00098200,
+0x98720000,
+0x00098200,
+0x48000000,
+0x0005001a,
+0x0006005d,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x00000000,
+0x40820000,
+0x00050802,
+0x7c68fe70,
+0x7d091a78,
+0x7c684851,
+0x41800000,
+0x00050801,
+0x0006005e,
+0x820efff8,
+0x3a8efff8,
+0x92cefff8,
+0x906efffc,
+0x48000000,
+0x0005005f,
+0x0006000b,
+0x3ca041e0,
+0x38600000,
+0x48000000,
+0x0005004e,
+0x0006000c,
+0x00000000,
+0x40800000,
+0x00050849,
+0x54a5007e,
+0x0006004e,
+0x820efff8,
+0x90aefff8,
+0x3a8efff8,
+0x906efffc,
+0x0006005f,
+0x39800000,
+0x00098200,
+0x0006004a,
+0x72000000,
+0x00090200,
+0x7d936378,
+0x40a20000,
+0x00050818,
+0x80f0fffc,
+0x54ea5d78,
+0x0006000f,
+0x7c0a6040,
+0x54e0dd78,
+0x41810000,
+0x00050806,
+0x80f00000,
+0x3a100004,
+0x7dc0a050,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00060010,
+0x390cfff8,
+0x398c0008,
+0x7ef4412e,
+0x48000000,
+0x0005000f,
+0x00000000,
+0x00060060,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x41a20000,
+0x0005084e,
+0x54a9657e,
+0x40800000,
+0x00050849,
+0x3529fc01,
+0x2889001f,
+0x2009001f,
+0x41800000,
+0x00050803,
+0x54a85800,
+0x000900a1,
+0x5466057e,
+0x000900ab,
+0x65088000,
+0x39290001,
+0x7d083378,
+0x54645800,
+0x000900a1,
+0x40840000,
+0x00050804,
+0x7d064830,
+0x7d030430,
+0x7cc62378,
+0x7ca9fe70,
+0x7cc84838,
+0x3008ffff,
+0x7d004110,
+0x7c634214,
+0x7c634a78,
+0x7c691850,
+0x48000000,
+0x0005005e,
+0x0006000d,
+0x7d252a14,
+0x7ca8fe70,
+0x7c694b78,
+0x7d284038,
+0x21280000,
+0x7c631910,
+0x48000000,
+0x0005005e,
+0x0006000e,
+0x6d088000,
+0x7ca9fe70,
+0x7d082378,
+0x7d084b39,
+0x4c423202,
+0x3c608000,
+0x41a20000,
+0x0005085e,
+0x0006000f,
+0xc82e0000,
+0x48000001,
+0x00030010,
+0x48000000,
+0x0005004c,
+0x00060061,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x41a20000,
+0x0005084e,
+0x54a9657e,
+0x40800000,
+0x00050849,
+0x3529fc01,
+0x2889001f,
+0x2009001f,
+0x41800000,
+0x00050803,
+0x00000000,
+0x54a85800,
+0x000900a1,
+0x5466057e,
+0x000900ab,
+0x65088000,
+0x39290001,
+0x7d083378,
+0x54645800,
+0x000900a1,
+0x40840000,
+0x00050804,
+0x7d064830,
+0x7d030430,
+0x7cc62378,
+0x7ca9fe70,
+0x7cc84878,
+0x3008ffff,
+0x7d004110,
+0x7c634615,
+0x7c634a78,
+0x7c691850,
+0x40830000,
+0x0005085e,
+0x7c000400,
+0x40a10000,
+0x0005085e,
+0x3ca041e0,
+0x38600000,
+0x48000000,
+0x0005004e,
+0x0006000d,
+0x7d252a14,
+0x7ca8fe70,
+0x7c694b78,
+0x7d284078,
+0x3128ffff,
+0x7c694110,
+0x48000000,
+0x0005005e,
+0x0006000e,
+0x6d088000,
+0x7ca9fe70,
+0x7d084b39,
+0x4c423202,
+0x3c608000,
+0x41a20000,
+0x0005085e,
+0x0006000f,
+0xc82e0000,
+0x48000001,
+0x00030011,
+0x48000000,
+0x0005004c,
+0x00000000,
+0x00060060,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x48000001,
+0x00030010,
+0x48000000,
+0x0005004c,
+0x00060061,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x48000001,
+0x00030011,
+0x48000000,
+0x0005004c,
+0x00000000,
+0x00060062,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x48000001,
+0x00030012,
+0x48000000,
+0x0005004c,
+0x00060063,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x48000001,
+0x00030013,
+0x48000000,
+0x0005004c,
+0x00060064,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x48000001,
+0x00030014,
+0x48000000,
+0x0005004c,
+0x00060065,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x48000001,
+0x00030015,
+0x48000000,
+0x0005004c,
+0x00060066,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x00000000,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x48000001,
+0x00030016,
+0x48000000,
+0x0005004c,
+0x00060067,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x48000001,
+0x00030017,
+0x48000000,
+0x0005004c,
+0x00060068,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x48000001,
+0x00030018,
+0x48000000,
+0x0005004c,
+0x00060069,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x48000001,
+0x00030019,
+0x48000000,
+0x0005004c,
+0x0006006a,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x48000001,
+0x0003001a,
+0x00000000,
+0x48000000,
+0x0005004c,
+0x0006006b,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x48000001,
+0x0003001b,
+0x48000000,
+0x0005004c,
+0x0006006c,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x48000001,
+0x0003001c,
+0x48000000,
+0x0005004c,
+0x0006006d,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x48000001,
+0x0003001d,
+0x48000000,
+0x0005004c,
+0x0006006e,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x48000001,
+0x0003001e,
+0x48000000,
+0x0005004c,
+0x0006006f,
+0x00000000,
+0x280b0010,
+0x80ae0000,
+0xc82e0000,
+0x80ce0008,
+0xc84e0008,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x7c06b040,
+0x40800000,
+0x00050849,
+0x48000001,
+0x0003001f,
+0x48000000,
+0x0005004c,
+0x00060070,
+0x280b0010,
+0x80ae0000,
+0xc82e0000,
+0x80ce0008,
+0xc84e0008,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x7c06b040,
+0x40800000,
+0x00050849,
+0x48000001,
+0x00030020,
+0x48000000,
+0x0005004c,
+0x00060071,
+0x280b0010,
+0x80ae0000,
+0xc82e0000,
+0x80ce0008,
+0xc84e0008,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x7c06b040,
+0x40800000,
+0x00050849,
+0x48000001,
+0x00030021,
+0x48000000,
+0x0005004c,
+0x00060072,
+0x00060073,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0xc84a0000,
+0x00098200,
+0x00000000,
+0xfc2100b2,
+0x48000000,
+0x0005004c,
+0x00000000,
+0x00060074,
+0x280b0010,
+0x80ae0000,
+0xc82e0000,
+0x80ce0008,
+0x806e000c,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x7c06b040,
+0x40820000,
+0x00050849,
+0x00000000,
+0x00060074,
+0x280b0010,
+0x80ae0000,
+0xc82e0000,
+0x80ce0008,
+0xc84e0008,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x7c06b040,
+0x40800000,
+0x00050849,
+0xfc40101e,
+0xd8410010,
+0x80610014,
+0x00000000,
+0x48000001,
+0x00030022,
+0x48000000,
+0x0005004c,
+0x00060075,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x38710000,
+0x00098200,
+0x820efff8,
+0x48000001,
+0x00030023,
+0x81110000,
+0x00098200,
+0x3a8efff8,
+0x00000000,
+0x6d088000,
+0x9101000c,
+0xc8410008,
+0xfc42f828,
+0x00000000,
+0xd8340000,
+0x39800000,
+0x00098200,
+0x00000000,
+0x92d40008,
+0x9114000c,
+0x00000000,
+0xd8540008,
+0x00000000,
+0x48000000,
+0x0005004a,
+0x00060076,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x386efff8,
+0x820efff8,
+0x48000001,
+0x00030024,
+0x3a8efff8,
+0xd82e0000,
+0x39800000,
+0x00098200,
+0x48000000,
+0x0005004a,
+0x00000000,
+0x00060077,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x390e0008,
+0x7d2e5a14,
+0x40820000,
+0x00050804,
+0x0006000b,
+0x80c80000,
+0x7c884840,
+0x80880004,
+0x40840000,
+0x0005085e,
+0x7c06b040,
+0x6c608000,
+0x6c868000,
+0x40820000,
+0x00050803,
+0x7cc60010,
+0x7c000110,
+0x7cc60038,
+0x7c662214,
+0x39080008,
+0x48000000,
+0x0005000b,
+0x0006000d,
+0x40800000,
+0x00050849,
+0x6c638000,
+0x9061000c,
+0xc8210008,
+0xfc21f828,
+0xc8480000,
+0x48000000,
+0x00050006,
+0x0006000e,
+0xc82e0000,
+0x40800000,
+0x00050849,
+0x0006000f,
+0x80c80000,
+0x7c884840,
+0xc8480000,
+0x40840000,
+0x0005084c,
+0x7c06b040,
+0x40800000,
+0x00050807,
+0x00060010,
+0xfc011028,
+0x39080008,
+0xfc2008ae,
+0x48000000,
+0x0005000f,
+0x00060011,
+0x80880004,
+0x40820000,
+0x00050849,
+0x6c848000,
+0x9081000c,
+0xc8410008,
+0xfc42f828,
+0x48000000,
+0x00050010,
+0x00000000,
+0x00060077,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x39000008,
+0x0006000b,
+0x7c8e402e,
+0x7c4e44ae,
+0x7c885840,
+0x7c04b040,
+0x40840000,
+0x0005084c,
+0x40800000,
+0x00050849,
+0xfc011028,
+0x39080008,
+0xfc2008ae,
+0x48000000,
+0x0005000b,
+0x00000000,
+0x00060078,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x390e0008,
+0x7d2e5a14,
+0x40820000,
+0x00050804,
+0x0006000b,
+0x80c80000,
+0x7c884840,
+0x80880004,
+0x40840000,
+0x0005085e,
+0x7c06b040,
+0x6c608000,
+0x6c868000,
+0x40820000,
+0x00050803,
+0x7cc60010,
+0x7c000110,
+0x7cc60078,
+0x7c662214,
+0x39080008,
+0x48000000,
+0x0005000b,
+0x0006000d,
+0x40800000,
+0x00050849,
+0x6c638000,
+0x9061000c,
+0xc8210008,
+0xfc21f828,
+0xc8480000,
+0x48000000,
+0x00050006,
+0x0006000e,
+0xc82e0000,
+0x40800000,
+0x00050849,
+0x0006000f,
+0x80c80000,
+0x7c884840,
+0xc8480000,
+0x40840000,
+0x0005084c,
+0x7c06b040,
+0x40800000,
+0x00050807,
+0x00060010,
+0xfc011028,
+0x39080008,
+0xfc20106e,
+0x48000000,
+0x0005000f,
+0x00060011,
+0x80880004,
+0x40820000,
+0x00050849,
+0x6c848000,
+0x9081000c,
+0xc8410008,
+0xfc42f828,
+0x48000000,
+0x00050010,
+0x00000000,
+0x00060078,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x39000008,
+0x0006000b,
+0x7c8e402e,
+0x7c4e44ae,
+0x7c885840,
+0x7c04b040,
+0x40840000,
+0x0005084c,
+0x40800000,
+0x00050849,
+0xfc011028,
+0x39080008,
+0xfc20106e,
+0x48000000,
+0x0005000b,
+0x00000000,
+0x00060079,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x2c050000,
+0x00098200,
+0x40820000,
+0x00050849,
+0x80630000,
+0x00098200,
+0x48000000,
+0x0005005e,
+0x0006007a,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x40820000,
+0x00050849,
+0x2c050000,
+0x00098200,
+0x40820000,
+0x00050849,
+0x80030000,
+0x00098200,
+0x00000000,
+0x88630000,
+0x00098200,
+0x39800000,
+0x00098200,
+0x820efff8,
+0x28000000,
+0x3a8efff8,
+0x41a20000,
+0x0005084a,
+0x48000000,
+0x0005005e,
+0x00000000,
+0x89030000,
+0x00098200,
+0x30c0ffff,
+0x7d860110,
+0x9101000c,
+0x398c0001,
+0xc8010008,
+0x3a8efff8,
+0x820efff8,
+0xfc00f028,
+0x558c1800,
+0x000900a1,
+0xd8140000,
+0x48000000,
+0x0005004a,
+0x00000000,
+0x0006007b,
+0x80110000,
+0x00098200,
+0x81110000,
+0x00098200,
+0x7c004040,
+0x40800001,
+0x00050853,
+0x280b0008,
+0x80ae0000,
+0x00000000,
+0x800e0004,
+0x40820000,
+0x00050849,
+0x7c05b040,
+0x40820000,
+0x00050849,
+0x388e0007,
+0x00000000,
+0xc82e0000,
+0x40820000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0xfc20081e,
+0xd8210010,
+0x80010014,
+0x38810017,
+0x00000000,
+0x38a00001,
+0x280000ff,
+0x41810000,
+0x00050849,
+0x0006007c,
+0x7e439378,
+0x91d20000,
+0x00098200,
+0x92010020,
+0x48000001,
+0x00030025,
+0x81d20000,
+0x00098200,
+0x38a00000,
+0x00098200,
+0x48000000,
+0x0005004e,
+0x0006007d,
+0x80110000,
+0x00098200,
+0x81110000,
+0x00098200,
+0x7c004040,
+0x40800001,
+0x00050853,
+0x280b0010,
+0x80ae0010,
+0x00000000,
+0xc80e0010,
+0x00000000,
+0x800e0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x808e0008,
+0x00000000,
+0x810e000c,
+0x00000000,
+0xc82e0008,
+0x00000000,
+0x3920ffff,
+0x41820000,
+0x00050801,
+0x00000000,
+0x7c05b040,
+0x812e0014,
+0x40820000,
+0x00050849,
+0x0006000b,
+0x7c04b040,
+0x40820000,
+0x00050849,
+0x00000000,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0xfc00001e,
+0xd8010010,
+0x81210014,
+0x0006000b,
+0x7c04b040,
+0x40800000,
+0x00050849,
+0x00000000,
+0x2c000000,
+0x00098200,
+0x40820000,
+0x00050849,
+0x00000000,
+0xfc20081e,
+0xd8210010,
+0x81010014,
+0x00000000,
+0x80030000,
+0x00098200,
+0x7c004840,
+0x38c90001,
+0x41800000,
+0x00050805,
+0x0006000c,
+0x2c080000,
+0x7cc80214,
+0x40810000,
+0x00050807,
+0x0006000d,
+0x7ca84850,
+0x38830000,
+0x00098200,
+0x7ca0fe70,
+0x38a50001,
+0x7c844214,
+0x7ca50078,
+0x48000000,
+0x0005007c,
+0x0006000f,
+0x7c890050,
+0x7c84fe70,
+0x7cc62078,
+0x7d203214,
+0x48000000,
+0x0005000c,
+0x00060011,
+0x30a8ffff,
+0x7ca52910,
+0x7cc4fe70,
+0x7cc62878,
+0x7cc82078,
+0x39080001,
+0x48000000,
+0x0005000d,
+0x0006007e,
+0x80110000,
+0x00098200,
+0x81110000,
+0x00098200,
+0x7c004040,
+0x40800001,
+0x00050853,
+0x280b0010,
+0x800e0000,
+0x806e0004,
+0x80ce0008,
+0x00000000,
+0x80ae000c,
+0x00000000,
+0xc84e0008,
+0x00000000,
+0x41800000,
+0x00050849,
+0x2c000000,
+0x00098200,
+0x40820000,
+0x00050849,
+0x00000000,
+0x7c06b040,
+0x40820000,
+0x00050849,
+0x00000000,
+0x7c06b040,
+0x40800000,
+0x00050849,
+0xfc40101e,
+0xd8410010,
+0x80a10014,
+0x00000000,
+0x80030000,
+0x00098200,
+0x2c050000,
+0x81110000,
+0x00098200,
+0x40810000,
+0x00050802,
+0x28000001,
+0x3925ffff,
+0x41800000,
+0x00050802,
+0x7c882840,
+0x40820000,
+0x00050849,
+0x88030000,
+0x00098200,
+0x80910000,
+0x00098200,
+0x41840000,
+0x00050849,
+0x0006000b,
+0x28090000,
+0x7c0449ae,
+0x3929ffff,
+0x40820000,
+0x0005080b,
+0x48000000,
+0x0005007c,
+0x0006000c,
+0x38710000,
+0x00098200,
+0x38a00000,
+0x00098200,
+0x48000000,
+0x0005004e,
+0x0006007f,
+0x80110000,
+0x00098200,
+0x81110000,
+0x00098200,
+0x7c004040,
+0x40800001,
+0x00050853,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x2c050000,
+0x00098200,
+0x81110000,
+0x00098200,
+0x00000000,
+0x40820000,
+0x00050849,
+0x80a30000,
+0x00098200,
+0x38630000,
+0x00098200,
+0x80910000,
+0x00098200,
+0x39200000,
+0x7c082840,
+0x38c5ffff,
+0x41800000,
+0x00050849,
+0x0006000b,
+0x2c060000,
+0x7d0348ae,
+0x41a00000,
+0x0005087c,
+0x7d0431ae,
+0x38c6ffff,
+0x39290001,
+0x48000000,
+0x0005000b,
+0x00060080,
+0x80110000,
+0x00098200,
+0x81110000,
+0x00098200,
+0x7c004040,
+0x40800001,
+0x00050853,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x2c050000,
+0x00098200,
+0x81110000,
+0x00098200,
+0x40820000,
+0x00050849,
+0x80a30000,
+0x00098200,
+0x38630000,
+0x00098200,
+0x80910000,
+0x00098200,
+0x7c082840,
+0x39200000,
+0x41800000,
+0x00050849,
+0x0006000b,
+0x7c092840,
+0x7d0348ae,
+0x40a00000,
+0x0005087c,
+0x00000000,
+0x3808ffbf,
+0x69060020,
+0x3000ffe6,
+0x7cc63110,
+0x70c60020,
+0x7d083278,
+0x7d0449ae,
+0x39290001,
+0x48000000,
+0x0005000b,
+0x00060081,
+0x80110000,
+0x00098200,
+0x81110000,
+0x00098200,
+0x7c004040,
+0x40800001,
+0x00050853,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x2c050000,
+0x00098200,
+0x81110000,
+0x00098200,
+0x40820000,
+0x00050849,
+0x80a30000,
+0x00098200,
+0x38630000,
+0x00098200,
+0x80910000,
+0x00098200,
+0x7c082840,
+0x39200000,
+0x41800000,
+0x00050849,
+0x0006000b,
+0x7c092840,
+0x7d0348ae,
+0x40a00000,
+0x0005087c,
+0x3808ff9f,
+0x69060020,
+0x3000ffe6,
+0x7cc63110,
+0x70c60020,
+0x7d083278,
+0x7d0449ae,
+0x39290001,
+0x48000000,
+0x0005000b,
+0x00060082,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x2c050000,
+0x00098200,
+0x40820000,
+0x00050849,
+0x48000001,
+0x00030026,
+0x48000000,
+0x0005005e,
+0x00000000,
+0x00060083,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40820001,
+0x00050884,
+0x00000000,
+0x00060083,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0xfc21f02a,
+0xd8210010,
+0x80610014,
+0x00000000,
+0x390e0008,
+0x7d2e5a14,
+0x0006000b,
+0x80c80000,
+0x7c884840,
+0x00000000,
+0x80880004,
+0x00000000,
+0xc8280000,
+0x00000000,
+0x40a40000,
+0x0005085e,
+0x7c06b040,
+0x00000000,
+0x40820001,
+0x00050885,
+0x00000000,
+0xfc21f02a,
+0x40800000,
+0x00050849,
+0xd8210010,
+0x80810014,
+0x00000000,
+0x7c632038,
+0x39080008,
+0x48000000,
+0x0005000b,
+0x00000000,
+0x00060086,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40820001,
+0x00050884,
+0x00000000,
+0x00060086,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0xfc21f02a,
+0xd8210010,
+0x80610014,
+0x00000000,
+0x390e0008,
+0x7d2e5a14,
+0x0006000b,
+0x80c80000,
+0x7c884840,
+0x00000000,
+0x80880004,
+0x00000000,
+0xc8280000,
+0x00000000,
+0x40a40000,
+0x0005085e,
+0x7c06b040,
+0x00000000,
+0x40820001,
+0x00050885,
+0x00000000,
+0xfc21f02a,
+0x40800000,
+0x00050849,
+0xd8210010,
+0x80810014,
+0x00000000,
+0x7c632378,
+0x39080008,
+0x48000000,
+0x0005000b,
+0x00000000,
+0x00060087,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40820001,
+0x00050884,
+0x00000000,
+0x00060087,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0xfc21f02a,
+0xd8210010,
+0x80610014,
+0x00000000,
+0x390e0008,
+0x7d2e5a14,
+0x0006000b,
+0x80c80000,
+0x7c884840,
+0x00000000,
+0x80880004,
+0x00000000,
+0xc8280000,
+0x00000000,
+0x40a40000,
+0x0005085e,
+0x7c06b040,
+0x00000000,
+0x40820001,
+0x00050885,
+0x00000000,
+0xfc21f02a,
+0x40800000,
+0x00050849,
+0xd8210010,
+0x80810014,
+0x00000000,
+0x7c632278,
+0x39080008,
+0x48000000,
+0x0005000b,
+0x00000000,
+0x00060088,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40820001,
+0x00050884,
+0x00000000,
+0x00060088,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0xfc21f02a,
+0xd8210010,
+0x80610014,
+0x00000000,
+0x5460403e,
+0x5060c00e,
+0x5060c42e,
+0x7c030378,
+0x48000000,
+0x0005005e,
+0x00000000,
+0x00060089,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40820001,
+0x00050884,
+0x00000000,
+0x00060089,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0xfc21f02a,
+0xd8210010,
+0x80610014,
+0x00000000,
+0x7c6318f8,
+0x48000000,
+0x0005005e,
+0x00000000,
+0x0006008a,
+0x280b0010,
+0x80ae0000,
+0x80ce0008,
+0x806e0004,
+0x808e000c,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40820001,
+0x00050884,
+0x7c06b040,
+0x40820000,
+0x00050849,
+0x00000000,
+0x0006008a,
+0x280b0010,
+0x80ae0000,
+0xc82e0000,
+0x80ce0008,
+0xc84e0008,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x7c06b040,
+0x40800000,
+0x00050849,
+0xfc21f02a,
+0xfc42f02a,
+0xd8210010,
+0x80610014,
+0xd8410010,
+0x80810014,
+0x00000000,
+0x548406fe,
+0x7c632030,
+0x48000000,
+0x0005005e,
+0x00000000,
+0x0006008b,
+0x280b0010,
+0x80ae0000,
+0x80ce0008,
+0x806e0004,
+0x808e000c,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40820001,
+0x00050884,
+0x7c06b040,
+0x40820000,
+0x00050849,
+0x00000000,
+0x0006008b,
+0x280b0010,
+0x80ae0000,
+0xc82e0000,
+0x80ce0008,
+0xc84e0008,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x7c06b040,
+0x40800000,
+0x00050849,
+0xfc21f02a,
+0xfc42f02a,
+0xd8210010,
+0x80610014,
+0xd8410010,
+0x80810014,
+0x00000000,
+0x548406fe,
+0x7c632430,
+0x48000000,
+0x0005005e,
+0x00000000,
+0x0006008c,
+0x280b0010,
+0x80ae0000,
+0x80ce0008,
+0x806e0004,
+0x808e000c,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40820001,
+0x00050884,
+0x7c06b040,
+0x40820000,
+0x00050849,
+0x00000000,
+0x0006008c,
+0x280b0010,
+0x80ae0000,
+0xc82e0000,
+0x80ce0008,
+0xc84e0008,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x7c06b040,
+0x40800000,
+0x00050849,
+0xfc21f02a,
+0xfc42f02a,
+0xd8210010,
+0x80610014,
+0xd8410010,
+0x80810014,
+0x00000000,
+0x548406fe,
+0x7c632630,
+0x48000000,
+0x0005005e,
+0x00000000,
+0x0006008d,
+0x280b0010,
+0x80ae0000,
+0x80ce0008,
+0x806e0004,
+0x808e000c,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40820001,
+0x00050884,
+0x7c06b040,
+0x40820000,
+0x00050849,
+0x00000000,
+0x0006008d,
+0x280b0010,
+0x80ae0000,
+0xc82e0000,
+0x80ce0008,
+0xc84e0008,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x7c06b040,
+0x40800000,
+0x00050849,
+0xfc21f02a,
+0xfc42f02a,
+0xd8210010,
+0x80610014,
+0xd8410010,
+0x80810014,
+0x00000000,
+0x5c63203e,
+0x48000000,
+0x0005005e,
+0x00000000,
+0x0006008e,
+0x280b0010,
+0x80ae0000,
+0x80ce0008,
+0x806e0004,
+0x808e000c,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40820001,
+0x00050884,
+0x7c06b040,
+0x40820000,
+0x00050849,
+0x00000000,
+0x0006008e,
+0x280b0010,
+0x80ae0000,
+0xc82e0000,
+0x80ce0008,
+0xc84e0008,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0x7c06b040,
+0x40800000,
+0x00050849,
+0xfc21f02a,
+0xfc42f02a,
+0xd8210010,
+0x80610014,
+0xd8410010,
+0x80810014,
+0x00000000,
+0x7c8400d0,
+0x5c63203e,
+0x48000000,
+0x0005005e,
+0x00000000,
+0x0006008f,
+0x280b0008,
+0x80ae0000,
+0x806e0004,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40820001,
+0x00050884,
+0x00000000,
+0x0006008f,
+0x280b0008,
+0x80ae0000,
+0xc82e0000,
+0x41800000,
+0x00050849,
+0x7c05b040,
+0x40800000,
+0x00050849,
+0xfc21f02a,
+0xd8210010,
+0x80610014,
+0x00000000,
+0x48000000,
+0x0005005e,
+0x00000000,
+0x0006005e,
+0x6c638000,
+0x9061000c,
+0xc8210008,
+0xfc21f828,
+0x00000000,
+0x0006004c,
+0x820efff8,
+0x3a8efff8,
+0xd82efff8,
+0x48000000,
+0x0005005f,
+0x00060084,
+0x00000000,
+0xc82e0000,
+0x41810000,
+0x00050849,
+0xfc21f02a,
+0xd8210010,
+0x80610014,
+0x4e800020,
+0x00000000,
+0x00060085,
+0x00000000,
+0xc8280000,
+0x41810000,
+0x00050849,
+0xfc21f02a,
+0xd8210010,
+0x80810014,
+0x4e800020,
+0x00000000,
+0x00060049,
+0x80ca0000,
+0x00098200,
+0x7d0e5a14,
+0x820efff8,
+0x38080000,
+0x00098200,
+0x81320000,
+0x00098200,
+0x92010020,
+0x7c004840,
+0x91d20000,
+0x00098200,
+0x91120000,
+0x00098200,
+0x7e439378,
+0x41810000,
+0x00050805,
+0x7cc903a6,
+0x4e800421,
+0x81d20000,
+0x00098200,
+0x2c030000,
+0x546c1800,
+0x000900a1,
+0x3a8efff8,
+0x41810000,
+0x0005084a,
+0x0006000b,
+0x80120000,
+0x00098200,
+0x814efffc,
+0x7d6e0050,
+0x40820000,
+0x00050829,
+0x820a0000,
+0x00098200,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x54f4dd78,
+0x7c11402e,
+0x7e947214,
+0x7c0903a6,
+0x4e800420,
+0x00060029,
+0x72000000,
+0x00090200,
+0x56080038,
+0x40820000,
+0x00050803,
+0x80f0fffc,
+0x54e8dd78,
+0x0006000d,
+0x7d287050,
+0x48000000,
+0x00050024,
+0x0006000f,
+0x38800000,
+0x00098200,
+0x48000001,
+0x00030000,
+0x00000000,
+0x81d20000,
+0x00098200,
+0x7c000000,
+0x48000000,
+0x0005000b,
+0x00060053,
+0x7ea802a6,
+0x91d20000,
+0x00098200,
+0x7c0e5a14,
+0x92010020,
+0x90120000,
+0x00098200,
+0x7e439378,
+0x48000001,
+0x00030027,
+0x81d20000,
+0x00098200,
+0x7ea803a6,
+0x80120000,
+0x00098200,
+0x7d6e0050,
+0x814efffc,
+0x4e800020,
+0x00060090,
+0x00000000,
+0x88d10000,
+0x00098200,
+0x70c00000,
+0x00090200,
+0x40820000,
+0x00050805,
+0x81310000,
+0x00098200,
+0x70c00000,
+0x00090200,
+0x40820000,
+0x00050801,
+0x3929ffff,
+0x70c00000,
+0x00090200,
+0x41a20000,
+0x00050801,
+0x91310000,
+0x00098200,
+0x48000000,
+0x00050001,
+0x00000000,
+0x00060091,
+0x88d10000,
+0x00098200,
+0x70c00000,
+0x00090200,
+0x41820000,
+0x00050801,
+0x0006000f,
+0x39080000,
+0x00098200,
+0x7c11402e,
+0x7c0903a6,
+0x4e800420,
+0x00060092,
+0x88d10000,
+0x00098200,
+0x81310000,
+0x00098200,
+0x70c00000,
+0x00090200,
+0x54c007c0,
+0x000900ab,
+0x40820000,
+0x0005080f,
+0x2c800000,
+0x3529ffff,
+0x41860000,
+0x0005080f,
+0x91310000,
+0x00098200,
+0x41820000,
+0x00050801,
+0x40840000,
+0x0005080f,
+0x0006000b,
+0x7e439378,
+0x9261001c,
+0x7e048378,
+0x91d20000,
+0x00098200,
+0x48000001,
+0x00030028,
+0x0006000d,
+0x81d20000,
+0x00098200,
+0x0006000e,
+0x00000000,
+0x80f0fffc,
+0x54e815ba,
+0x54ea5d78,
+0x39080000,
+0x00098200,
+0x54ec9b78,
+0x7c11402e,
+0x54f4dd78,
+0x54eb9d78,
+0x7c0903a6,
+0x4e800420,
+0x00060093,
+0x3a100004,
+0x826affec,
+0x48000000,
+0x0005000e,
+0x00060094,
+0x00000000,
+0x810efffc,
+0x38710000,
+0x00098200,
+0x92010020,
+0x81080000,
+0x00098200,
+0x7e048378,
+0x92510000,
+0x00098200,
+0x89080000,
+0x00098200,
+0x91d20000,
+0x00098200,
+0x55081800,
+0x000900a1,
+0x7d0e4214,
+0x91120000,
+0x00098200,
+0x48000001,
+0x00030029,
+0x48000000,
+0x0005000d,
+0x00000000,
+0x00060095,
+0x7e048378,
+0x00000000,
+0x48000000,
+0x00050001,
+0x00000000,
+0x00060096,
+0x00000000,
+0x62040001,
+0x0006000b,
+0x00000000,
+0x7c0e5a14,
+0x92010020,
+0x7e439378,
+0x91d20000,
+0x00098200,
+0x7e8ea050,
+0x90120000,
+0x00098200,
+0x48000001,
+0x0003002a,
+0x81d20000,
+0x00098200,
+0x80120000,
+0x00098200,
+0x93010020,
+0x7d6e0050,
+0x7e8ea214,
+0x814efffc,
+0x80f0fffc,
+0x7c6903a6,
+0x4e800420,
+0x00060097,
+0x00000000,
+0x38210000,
+0x00098200,
+0xbc410000,
+0x00098200,
+0x3a3f0000,
+0x00098200,
+0x38800000,
+0x00098200,
+0x80610000,
+0x00098200,
+0x90910000,
+0x00098200,
+0xd8010000,
+0x00098200,
+0xd8210000,
+0x00098200,
+0xd8410000,
+0x00098200,
+0xd8610000,
+0x00098200,
+0x90610000,
+0x7c000400,
+0xd8810000,
+0x00098200,
+0xd8a10000,
+0x00098200,
+0xd8c10000,
+0x00098200,
+0xd8e10000,
+0x00098200,
+0x38810000,
+0x00098200,
+0xd9010000,
+0x00098200,
+0xd9210000,
+0x00098200,
+0xd9410000,
+0x00098200,
+0xd9610000,
+0x00098200,
+0x90810000,
+0x00098200,
+0xd9810000,
+0x00098200,
+0xd9a10000,
+0x00098200,
+0x00000000,
+0xd9c10000,
+0x00098200,
+0xd9e10000,
+0x00098200,
+0x7ca802a6,
+0x39000000,
+0xda010000,
+0x00098200,
+0xda210000,
+0x00098200,
+0xda410000,
+0x00098200,
+0xda610000,
+0x00098200,
+0x91010000,
+0x00098200,
+0xda810000,
+0x00098200,
+0xdaa10000,
+0x00098200,
+0xdac10000,
+0x00098200,
+0xdae10000,
+0x00098200,
+0xa0c50002,
+0xdb010000,
+0x00098200,
+0xdb210000,
+0x00098200,
+0xdb410000,
+0x00098200,
+0xdb610000,
+0x00098200,
+0x82510000,
+0x00098200,
+0xdb810000,
+0x00098200,
+0xdba10000,
+0x00098200,
+0xdbc10000,
+0x00098200,
+0xdbe10000,
+0x00098200,
+0x7ca50050,
+0x81d10000,
+0x00098200,
+0x54a500be,
+0x000900ab,
+0x00000000,
+0x92510000,
+0x00098200,
+0x38a5fffe,
+0x91110000,
+0x00098200,
+0x90d10000,
+0x00098200,
+0x91d20000,
+0x00098200,
+0x38710000,
+0x00098200,
+0x90b10000,
+0x00098200,
+0x38810010,
+0x48000001,
+0x0003002b,
+0x81120000,
+0x00098200,
+0x81210000,
+0x81d20000,
+0x00098200,
+0x5501003a,
+0x82010020,
+0x91210000,
+0x92410024,
+0x48000000,
+0x00050001,
+0x00000000,
+0x00060098,
+0x00000000,
+0x82410024,
+0x3a3f0000,
+0x00098200,
+0x0006000b,
+0x2c030000,
+0x41800000,
+0x00050803,
+0x810efffc,
+0x54731800,
+0x000900a1,
+0x39200000,
+0x9261001c,
+0x81080000,
+0x00098200,
+0x91310000,
+0x00098200,
+0x81e80000,
+0x00098200,
+0x3ac00000,
+0x00098200,
+0x3cc059c0,
+0x90c10010,
+0x3b000000,
+0x60c60004,
+0xc3c10010,
+0x90c10010,
+0x3c004338,
+0x3ae00000,
+0x00098200,
+0x90010008,
+0xc3e10010,
+0x80f00000,
+0x3a100004,
+0x92f10000,
+0x00098200,
+0x54e815ba,
+0x54f4dd78,
+0x7c11402e,
+0x7c0903a6,
+0x28080000,
+0x00090200,
+0x40800000,
+0x00050802,
+0x54ea5d78,
+0x54ec9b78,
+0x54eb9d78,
+0x4e800420,
+0x0006000c,
+0x3973fff8,
+0x7e947214,
+0x4e800420,
+0x0006000d,
+0x7c8300d0,
+0x7e439378,
+0x48000001,
+0x0003002c,
+0x00000000,
+0x00060099,
+0x48000000,
+0x00030010,
+0x0006009a,
+0x48000000,
+0x00030011,
+0x0006009b,
+0x00000000,
+0x48000000,
+0x0003002d,
+0x00000000,
+0x0006009c,
+0x7c0327d7,
+0x41830000,
+0x00050801,
+0x7c652279,
+0x7c0021d6,
+0x7c601850,
+0x4c800020,
+0x2c030000,
+0x4d820020,
+0x7c632214,
+0x4e800020,
+0x0006000b,
+0x2c040000,
+0x38600000,
+0x4d820020,
+0x7c000400,
+0x4e800020,
+0x0006009d,
+0x28030001,
+0x41820000,
+0x00050801,
+0x41810000,
+0x00050802,
+0xfc21102a,
+0x4e800020,
+0x0006000b,
+0xfc211028,
+0x4e800020,
+0x0006000c,
+0x28030003,
+0x41820000,
+0x00050801,
+0x41810000,
+0x00050802,
+0xfc2100b2,
+0x4e800020,
+0x0006000b,
+0xfc211024,
+0x4e800020,
+0x0006000c,
+0x28030005,
+0x41820000,
+0x00050801,
+0x41810000,
+0x00050802,
+0x9421ffe0,
+0xd9c10010,
+0xd9e10018,
+0x7c0802a6,
+0xfdc00890,
+0xfc211024,
+0x90010024,
+0xfde01090,
+0x48000001,
+0x00030010,
+0x80010024,
+0xfc2103f2,
+0x7c0803a6,
+0xfc2e0828,
+0xc9c10010,
+0xc9e10018,
+0x38210020,
+0x4e800020,
+0x0006000b,
+0x48000000,
+0x0003001f,
+0x0006000c,
+0x28030007,
+0x41820000,
+0x00050801,
+0x41810000,
+0x00050802,
+0xfc200850,
+0x4e800020,
+0x0006000b,
+0xfc200a10,
+0x4e800020,
+0x0006000c,
+0x00000000,
+0x28030009,
+0x41820000,
+0x00050809,
+0x41810000,
+0x00050802,
+0x48000000,
+0x00030020,
+0x0006000c,
+0x2803000b,
+0x41810000,
+0x00050809,
+0xfc011028,
+0x41820000,
+0x00050801,
+0xfc2008ae,
+0x4e800020,
+0x0006000b,
+0xfc20106e,
+0x4e800020,
+0x00060013,
+0x7c810808,
+0x00000000,
+0x7c810808,
+0x00000000,
+0x0006009e,
+0x00000000,
+0x9421fef0,
+0x91c10000,
+0x00098200,
+0xd9c10000,
+0x00098200,
+0x91e10000,
+0x00098200,
+0xd9e10000,
+0x00098200,
+0x92010000,
+0x00098200,
+0xda010000,
+0x00098200,
+0x7c0802a6,
+0x92210000,
+0x00098200,
+0xda210000,
+0x00098200,
+0x92410000,
+0x00098200,
+0xda410000,
+0x00098200,
+0x92610000,
+0x00098200,
+0xda610000,
+0x00098200,
+0x92810000,
+0x00098200,
+0xda810000,
+0x00098200,
+0x92a10000,
+0x00098200,
+0xdaa10000,
+0x00098200,
+0x92c10000,
+0x00098200,
+0xdac10000,
+0x00098200,
+0x90010114,
+0x92e10000,
+0x00098200,
+0xdae10000,
+0x00098200,
+0x93010000,
+0x00098200,
+0xdb010000,
+0x00098200,
+0x00000000,
+0x93210000,
+0x00098200,
+0xdb210000,
+0x00098200,
+0x7c000026,
+0x93410000,
+0x00098200,
+0xdb410000,
+0x00098200,
+0x93610000,
+0x00098200,
+0xdb610000,
+0x00098200,
+0x93810000,
+0x00098200,
+0xdb810000,
+0x00098200,
+0x93a10000,
+0x00098200,
+0xdba10000,
+0x00098200,
+0x93c10000,
+0x00098200,
+0xdbc10000,
+0x00098200,
+0x93e10000,
+0x00098200,
+0xdbe10000,
+0x00098200,
+0x90010034,
+0x820c0000,
+0x00098200,
+0x3a2c0000,
+0x00098200,
+0x91700000,
+0x00098200,
+0x90700000,
+0x00098200,
+0xd8300000,
+0x00098200,
+0x90900000,
+0x00098200,
+0xd8500000,
+0x00098200,
+0x90b00000,
+0x00098200,
+0x00000000,
+0xd8700000,
+0x00098200,
+0x90d00000,
+0x00098200,
+0xd8900000,
+0x00098200,
+0x90f00000,
+0x00098200,
+0xd8b00000,
+0x00098200,
+0x91100000,
+0x00098200,
+0xd8d00000,
+0x00098200,
+0x91300000,
+0x00098200,
+0xd8f00000,
+0x00098200,
+0x91500000,
+0x00098200,
+0xd9100000,
+0x00098200,
+0x38010000,
+0x00098200,
+0x90100000,
+0x00098200,
+0x7e038378,
+0x92010020,
+0x7c240b78,
+0x48000001,
+0x0003002e,
+0x81c30000,
+0x00098200,
+0x3ac00000,
+0x00098200,
+0x81630000,
+0x00098200,
+0x3cc059c0,
+0x3b000000,
+0x7c721b78,
+0x90c10010,
+0x814efffc,
+0x60c60004,
+0x3ae00000,
+0x00098200,
+0x38000000,
+0x00098200,
+0xc3c10010,
+0x90c10010,
+0x7d6e5850,
+0x90110000,
+0x00098200,
+0xc3e10010,
+0x820a0000,
+0x00098200,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x54f4dd78,
+0x7c11402e,
+0x7e947214,
+0x7c0903a6,
+0x4e800420,
+0x00000000,
+0x00060028,
+0x00000000,
+0x82110000,
+0x00098200,
+0x91d20000,
+0x00098200,
+0x91520000,
+0x00098200,
+0x92500000,
+0x00098200,
+0x7e038378,
+0x7e84a378,
+0x48000001,
+0x0003002f,
+0x80700000,
+0x00098200,
+0xc8300000,
+0x00098200,
+0x80900000,
+0x00098200,
+0x48000000,
+0x0005001a,
+0x00000000,
+0x0006009f,
+0x00000000,
+0x81030000,
+0x00098200,
+0x7c0802a6,
+0x88830000,
+0x00098200,
+0x88a30000,
+0x00098200,
+0x7d0800d0,
+0x90010004,
+0x2c850000,
+0x7c290b78,
+0x3484ffff,
+0x7c21416e,
+0x4cc63042,
+0x91c9fffc,
+0x38c00000,
+0x9069fff8,
+0x7d2e4b78,
+0x39030000,
+0x00098200,
+0x54841000,
+0x000900a1,
+0x41a00000,
+0x00050802,
+0x39210008,
+0x0006000b,
+0x7c08202e,
+0x7c09212e,
+0x3484fffc,
+0x40800000,
+0x0005080b,
+0x0006000c,
+0x40a60000,
+0x00050803,
+0xc8230000,
+0x00098200,
+0xc8430000,
+0x00098200,
+0xc8630000,
+0x00098200,
+0xc8830000,
+0x00098200,
+0xc8a30000,
+0x00098200,
+0xc8c30000,
+0x00098200,
+0xc8e30000,
+0x00098200,
+0xc9030000,
+0x00098200,
+0x0006000d,
+0x80030000,
+0x00098200,
+0x80830000,
+0x00098200,
+0x80a30000,
+0x00098200,
+0x00000000,
+0x80c30000,
+0x00098200,
+0x80e30000,
+0x00098200,
+0x7c0903a6,
+0x81030000,
+0x00098200,
+0x81230000,
+0x00098200,
+0x81430000,
+0x00098200,
+0x80630000,
+0x00098200,
+0x4e800421,
+0x810efff8,
+0x812efffc,
+0x800e0004,
+0x90680000,
+0x00098200,
+0xd8280000,
+0x00098200,
+0x90880000,
+0x00098200,
+0x7c0803a6,
+0x90a80000,
+0x00098200,
+0x7dc17378,
+0x90c80000,
+0x00098200,
+0x7d2e4b78,
+0x4e800020,
+0x00000000,
+0x00080000,
+0x00000000,
+0x7c14706e,
+0x3a100004,
+0x80940004,
+0x7d0c706e,
+0x8130fffc,
+0x7c00b040,
+0x80ac0004,
+0x552993ba,
+0x7c88b040,
+0x3d290000,
+0x00098200,
+0x40820000,
+0x00050807,
+0x40860000,
+0x00050808,
+0x7c042800,
+0x00000000,
+0x40800000,
+0x00050802,
+0x00000000,
+0x41800000,
+0x00050802,
+0x00000000,
+0x41810000,
+0x00050802,
+0x00000000,
+0x40810000,
+0x00050802,
+0x00000000,
+0x0006000b,
+0x7e104a14,
+0x0006000c,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00060011,
+0x41810000,
+0x00050835,
+0xc8140000,
+0x41850000,
+0x00050835,
+0x41840000,
+0x00050804,
+0x6ca58000,
+0x90a1000c,
+0xc8210008,
+0xfc21f828,
+0x48000000,
+0x00050005,
+0x00060012,
+0x41850000,
+0x00050835,
+0x6c848000,
+0x9081000c,
+0xc8010008,
+0xfc00f828,
+0x0006000e,
+0xc82c0000,
+0x0006000f,
+0xfc000800,
+0x00000000,
+0x40800000,
+0x0005080c,
+0x00000000,
+0x41800000,
+0x0005080c,
+0x00000000,
+0x4c001382,
+0x40800000,
+0x0005080c,
+0x00000000,
+0x4c001382,
+0x41800000,
+0x0005080c,
+0x00000000,
+0x48000000,
+0x0005000b,
+0x00000000,
+0x7c0ea02e,
+0x3a100004,
+0x7c0ea4ae,
+0x7d0e602e,
+0x7c00b040,
+0x8130fffc,
+0x7c2e64ae,
+0x7c88b040,
+0x552993ba,
+0x40800000,
+0x00050835,
+0x3d290000,
+0x00098200,
+0x40840000,
+0x00050835,
+0xfc000800,
+0x00000000,
+0x40800000,
+0x00050801,
+0x00000000,
+0x41800000,
+0x00050801,
+0x00000000,
+0x4c001382,
+0x40800000,
+0x00050801,
+0x00000000,
+0x4c001382,
+0x41800000,
+0x00050801,
+0x00000000,
+0x7e104a14,
+0x0006000b,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x7c14706e,
+0x3a100004,
+0x80940004,
+0x7d0c706e,
+0x7c00b040,
+0x8130fffc,
+0x7c88b040,
+0x552993ba,
+0x80ac0004,
+0x4fa12b82,
+0x3d290000,
+0x00098200,
+0x00000000,
+0x409d0000,
+0x000508a0,
+0x00000000,
+0x409d0000,
+0x000508a1,
+0x00000000,
+0x7c14706e,
+0x81300000,
+0xc8140000,
+0x3a100004,
+0x7d0c706e,
+0x7c00b040,
+0x552993ba,
+0xc82c0000,
+0x7c88b040,
+0x3d290000,
+0x00098200,
+0x40800000,
+0x00050805,
+0x40840000,
+0x00050805,
+0xfc000800,
+0x00000000,
+0x40820000,
+0x00050801,
+0x7e104a14,
+0x00000000,
+0x41820000,
+0x00050801,
+0x7e104a14,
+0x00000000,
+0x0006000b,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x0006000f,
+0x00000000,
+0x80940004,
+0x80ac0004,
+0x00000000,
+0x2f800000,
+0x00098200,
+0x2e880000,
+0x00098200,
+0x00000000,
+0x7c0600f8,
+0x7c004040,
+0x28860000,
+0x00090200,
+0x00000000,
+0x4fdeb382,
+0x00000000,
+0x2b060000,
+0x00090200,
+0x00000000,
+0x419e0000,
+0x0005083b,
+0x00000000,
+0x7e842840,
+0x4c222902,
+0x4c161342,
+0x4c42b202,
+0x7e158378,
+0x4c420b82,
+0x4c000b82,
+0x00000000,
+0x40820000,
+0x00050806,
+0x7e104a14,
+0x00060010,
+0x00000000,
+0x41820000,
+0x00050806,
+0x7e104a14,
+0x00060010,
+0x00000000,
+0x40800000,
+0x00050802,
+0x0006000b,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000c,
+0x00000000,
+0x41800000,
+0x0005080b,
+0x00000000,
+0x41980000,
+0x0005080b,
+0x81240000,
+0x00098200,
+0x38c00000,
+0x00098200,
+0x28090000,
+0x41820000,
+0x0005080b,
+0x89290000,
+0x00098200,
+0x71290000,
+0x00090200,
+0x40820000,
+0x0005080b,
+0x7eb0ab78,
+0x48000000,
+0x0005003a,
+0x00000000,
+0x7c14706e,
+0x558c007e,
+0x000900ab,
+0x80d40004,
+0x81300000,
+0x218cfffc,
+0x3a100004,
+0x00000000,
+0x2c000000,
+0x00098200,
+0x00000000,
+0x7d0f602e,
+0x20000000,
+0x00098200,
+0x00000000,
+0x41820000,
+0x0005083b,
+0x00000000,
+0x7d064050,
+0x7c004378,
+0x552993ba,
+0x20000000,
+0x3d290000,
+0x00098200,
+0x7d084110,
+0x00000000,
+0x7d294078,
+0x00000000,
+0x7d294038,
+0x00000000,
+0x7e104a14,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x7c14706e,
+0x3a100004,
+0x80940004,
+0x7d0c786e,
+0x7c00b040,
+0x8130fffc,
+0x7c88b040,
+0x552993ba,
+0x80ac0004,
+0x3d290000,
+0x00098200,
+0x00000000,
+0x000600a0,
+0x00000000,
+0x000600a1,
+0x00000000,
+0x40820000,
+0x00050807,
+0x40860000,
+0x00050808,
+0x7c042800,
+0x0006000e,
+0x00000000,
+0x000600a0,
+0x00000000,
+0x000600a1,
+0x00000000,
+0x7c0ea02e,
+0x3a100004,
+0x7c0ea4ae,
+0x8130fffc,
+0x7c2f64ae,
+0x552993ba,
+0x7c00b040,
+0x3d290000,
+0x00098200,
+0x40800000,
+0x00050803,
+0xfc000800,
+0x00000000,
+0x40820000,
+0x00050801,
+0x7e104a14,
+0x0006000b,
+0x00000000,
+0x0006000d,
+0x00000000,
+0x41820000,
+0x00050802,
+0x0006000b,
+0x00000000,
+0x0006000d,
+0x00000000,
+0x7e104a14,
+0x0006000c,
+0x00000000,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x0006000d,
+0x2c000000,
+0x00098200,
+0x41820000,
+0x0005083b,
+0x48000000,
+0x0005000b,
+0x00000000,
+0x00060011,
+0x40800000,
+0x0005080d,
+0xc8140000,
+0x41840000,
+0x00050801,
+0x6ca58000,
+0x90a1000c,
+0xc8210008,
+0xfc21f828,
+0x48000000,
+0x00050002,
+0x00060012,
+0x6c848000,
+0x9081000c,
+0xc8010008,
+0xfc00f828,
+0x0006000b,
+0xc82c0000,
+0x0006000c,
+0xfc000800,
+0x48000000,
+0x0005000e,
+0x00000000,
+0x7c0ea02e,
+0x558800fe,
+0x000900ab,
+0x81300000,
+0x7d0840f8,
+0x3a100004,
+0x00000000,
+0x2c000000,
+0x00098200,
+0x00000000,
+0x7c080050,
+0x00000000,
+0x41820000,
+0x0005083b,
+0x00000000,
+0x552993ba,
+0x3000ffff,
+0x3d290000,
+0x00098200,
+0x7d084110,
+0x00000000,
+0x7d294038,
+0x00000000,
+0x7d294078,
+0x00000000,
+0x7e104a14,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x7c0e602e,
+0x80f00000,
+0x3a100004,
+0x00000000,
+0x20000000,
+0x00098200,
+0x54e993ba,
+0x7d084110,
+0x3d290000,
+0x00098200,
+0x00000000,
+0x7d294078,
+0x00000000,
+0x7d294038,
+0x00000000,
+0x7e104a14,
+0x00000000,
+0x39000000,
+0x00098200,
+0x7c0e64ae,
+0x7c004040,
+0x00000000,
+0x40800000,
+0x00050801,
+0x00000000,
+0x41800000,
+0x00050801,
+0x00000000,
+0x3e100000,
+0x00098200,
+0x54e993ba,
+0x7c0ea5ae,
+0x7e104a14,
+0x0006000b,
+0x00000000,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x80f00000,
+0x3a100004,
+0x7c0e64ae,
+0x7c0ea5ae,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x80f00000,
+0x3a100004,
+0x7c0e602e,
+0x21000000,
+0x00098200,
+0x7c004114,
+0x7c0ea12e,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x7d0c706e,
+0x800c0004,
+0x7c08b040,
+0x00000000,
+0x40820000,
+0x00050805,
+0x7c0004d1,
+0x41830000,
+0x00050804,
+0x0006000b,
+0x80f00000,
+0x3a100004,
+0x7ed4716e,
+0x90140004,
+0x0006000d,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000e,
+0x7c000400,
+0x40a10000,
+0x0005080b,
+0x3d0041e0,
+0x38000000,
+0x48000000,
+0x00050007,
+0x00000000,
+0x0006000f,
+0x40800000,
+0x0005083e,
+0x6d088000,
+0x00060011,
+0x80f00000,
+0x3a100004,
+0x7d14716e,
+0x90140004,
+0x00000000,
+0x48000000,
+0x0005000d,
+0x00000000,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x7c0c706e,
+0x806c0004,
+0x2c000000,
+0x00098200,
+0x40820000,
+0x00050802,
+0x80630000,
+0x00098200,
+0x0006000b,
+0x00000000,
+0x80f00000,
+0x3a100004,
+0x7ed4716e,
+0x90740004,
+0x00000000,
+0x9061000c,
+0xc8010008,
+0xfc00f028,
+0x80f00000,
+0x3a100004,
+0x7c0ea5ae,
+0x00000000,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000c,
+0x2c000000,
+0x00098200,
+0x40820000,
+0x00050843,
+0x00000000,
+0x81230000,
+0x00098200,
+0x28090000,
+0x40820000,
+0x00050809,
+0x0006000d,
+0x00000000,
+0x00060044,
+0x48000001,
+0x00030026,
+0x48000000,
+0x0005000b,
+0x00000000,
+0x00060013,
+0x88090000,
+0x00098200,
+0x70000000,
+0x00090200,
+0x40820000,
+0x0005080d,
+0x48000000,
+0x00050043,
+0x00000000,
+0x7d0a706e,
+0x7d2b786e,
+0x806a0004,
+0x7c08b040,
+0x808b0004,
+0x00000000,
+0x7d0a706e,
+0x7d2b786e,
+0x808a0004,
+0x7c08b040,
+0x806b0004,
+0x00000000,
+0x7d0a706e,
+0x7d2b706e,
+0x806a0004,
+0x7c08b040,
+0x808b0004,
+0x00000000,
+0x7c89b040,
+0x40820000,
+0x00050805,
+0x40860000,
+0x00050805,
+0x7c632615,
+0x41830000,
+0x00050804,
+0x0006000b,
+0x80f00000,
+0x3a100004,
+0x7ed4716e,
+0x90740004,
+0x0006000c,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000e,
+0x7c000400,
+0x40a10000,
+0x0005080b,
+0x00000000,
+0x48000000,
+0x00050041,
+0x00000000,
+0x48000000,
+0x0005003d,
+0x00000000,
+0x48000000,
+0x00050042,
+0x00000000,
+0x0006000f,
+0x00000000,
+0xc9ea0000,
+0x4c002202,
+0xc9cb0000,
+0x00000000,
+0xc9ca0000,
+0x4c002202,
+0xc9eb0000,
+0x00000000,
+0x40800000,
+0x00050841,
+0x00000000,
+0x40800000,
+0x0005083d,
+0x00000000,
+0x40800000,
+0x00050842,
+0x00000000,
+0xfc0e782a,
+0x80f00000,
+0x3a100004,
+0x7c0ea5ae,
+0x48000000,
+0x0005000c,
+0x00000000,
+0x7d0e502e,
+0x00000000,
+0x7d2f582e,
+0x00000000,
+0x7dce54ae,
+0x7def5cae,
+0x00000000,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x0005083f,
+0x00000000,
+0x7c08b040,
+0x40800000,
+0x0005083f,
+0x00000000,
+0x7d0e502e,
+0x00000000,
+0x7d2f582e,
+0x00000000,
+0x7dee54ae,
+0x7dcf5cae,
+0x00000000,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x0005083c,
+0x00000000,
+0x7c08b040,
+0x40800000,
+0x0005083c,
+0x00000000,
+0x7d0e502e,
+0x7d2e582e,
+0x7dce54ae,
+0x7dee5cae,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x00050840,
+0x00000000,
+0xfc0e782a,
+0x80f00000,
+0x3a100004,
+0x7c0ea5ae,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x7d0a706e,
+0x7d2b786e,
+0x806a0004,
+0x7c08b040,
+0x808b0004,
+0x00000000,
+0x7d0a706e,
+0x7d2b786e,
+0x808a0004,
+0x7c08b040,
+0x806b0004,
+0x00000000,
+0x7d0a706e,
+0x7d2b706e,
+0x806a0004,
+0x7c08b040,
+0x808b0004,
+0x00000000,
+0x7c89b040,
+0x40820000,
+0x00050805,
+0x40860000,
+0x00050805,
+0x7c641c51,
+0x41830000,
+0x00050804,
+0x0006000b,
+0x80f00000,
+0x3a100004,
+0x7ed4716e,
+0x90740004,
+0x0006000c,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000e,
+0x7c000400,
+0x40a10000,
+0x0005080b,
+0x00000000,
+0x48000000,
+0x00050041,
+0x00000000,
+0x48000000,
+0x0005003d,
+0x00000000,
+0x48000000,
+0x00050042,
+0x00000000,
+0x0006000f,
+0x00000000,
+0xc9ea0000,
+0x4c002202,
+0xc9cb0000,
+0x00000000,
+0xc9ca0000,
+0x4c002202,
+0xc9eb0000,
+0x00000000,
+0x40800000,
+0x00050841,
+0x00000000,
+0x40800000,
+0x0005083d,
+0x00000000,
+0x40800000,
+0x00050842,
+0x00000000,
+0xfc0e7828,
+0x80f00000,
+0x3a100004,
+0x7c0ea5ae,
+0x48000000,
+0x0005000c,
+0x00000000,
+0x7d0e502e,
+0x00000000,
+0x7d2f582e,
+0x00000000,
+0x7dce54ae,
+0x7def5cae,
+0x00000000,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x0005083f,
+0x00000000,
+0x7c08b040,
+0x40800000,
+0x0005083f,
+0x00000000,
+0x7d0e502e,
+0x00000000,
+0x7d2f582e,
+0x00000000,
+0x7dee54ae,
+0x7dcf5cae,
+0x00000000,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x0005083c,
+0x00000000,
+0x7c08b040,
+0x40800000,
+0x0005083c,
+0x00000000,
+0x7d0e502e,
+0x7d2e582e,
+0x7dce54ae,
+0x7dee5cae,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x00050840,
+0x00000000,
+0xfc0e7828,
+0x80f00000,
+0x3a100004,
+0x7c0ea5ae,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x7d0a706e,
+0x7d2b786e,
+0x806a0004,
+0x7c08b040,
+0x808b0004,
+0x00000000,
+0x7d0a706e,
+0x7d2b786e,
+0x808a0004,
+0x7c08b040,
+0x806b0004,
+0x00000000,
+0x7d0a706e,
+0x7d2b706e,
+0x806a0004,
+0x7c08b040,
+0x808b0004,
+0x00000000,
+0x7c89b040,
+0x40820000,
+0x00050805,
+0x40860000,
+0x00050805,
+0x7c6325d7,
+0x41830000,
+0x00050804,
+0x0006000b,
+0x80f00000,
+0x3a100004,
+0x7ed4716e,
+0x90740004,
+0x0006000c,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000e,
+0x7c000400,
+0x40a10000,
+0x0005080b,
+0x00000000,
+0x48000000,
+0x00050041,
+0x00000000,
+0x48000000,
+0x0005003d,
+0x00000000,
+0x48000000,
+0x00050042,
+0x00000000,
+0x0006000f,
+0x00000000,
+0xc9ea0000,
+0x4c002202,
+0xc9cb0000,
+0x00000000,
+0xc9ca0000,
+0x4c002202,
+0xc9eb0000,
+0x00000000,
+0x40800000,
+0x00050841,
+0x00000000,
+0x40800000,
+0x0005083d,
+0x00000000,
+0x40800000,
+0x00050842,
+0x00000000,
+0xfc0e03f2,
+0x80f00000,
+0x3a100004,
+0x7c0ea5ae,
+0x48000000,
+0x0005000c,
+0x00000000,
+0x7d0e502e,
+0x00000000,
+0x7d2f582e,
+0x00000000,
+0x7dce54ae,
+0x7def5cae,
+0x00000000,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x0005083f,
+0x00000000,
+0x7c08b040,
+0x40800000,
+0x0005083f,
+0x00000000,
+0x7d0e502e,
+0x00000000,
+0x7d2f582e,
+0x00000000,
+0x7dee54ae,
+0x7dcf5cae,
+0x00000000,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x0005083c,
+0x00000000,
+0x7c08b040,
+0x40800000,
+0x0005083c,
+0x00000000,
+0x7d0e502e,
+0x7d2e582e,
+0x7dce54ae,
+0x7dee5cae,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x00050840,
+0x00000000,
+0xfc0e03f2,
+0x80f00000,
+0x3a100004,
+0x7c0ea5ae,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x7d0e502e,
+0x00000000,
+0x7d2f582e,
+0x00000000,
+0x7dce54ae,
+0x7def5cae,
+0x00000000,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x0005083f,
+0x00000000,
+0x7c08b040,
+0x40800000,
+0x0005083f,
+0x00000000,
+0x7d0e502e,
+0x00000000,
+0x7d2f582e,
+0x00000000,
+0x7dee54ae,
+0x7dcf5cae,
+0x00000000,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x0005083c,
+0x00000000,
+0x7c08b040,
+0x40800000,
+0x0005083c,
+0x00000000,
+0x7d0e502e,
+0x7d2e582e,
+0x7dce54ae,
+0x7dee5cae,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x00050840,
+0x00000000,
+0xfc0e7824,
+0x80f00000,
+0x3a100004,
+0x7c0ea5ae,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x7d0a706e,
+0x7d2b786e,
+0x806a0004,
+0x7c08b040,
+0x808b0004,
+0x00000000,
+0x7d0a706e,
+0x7d2b786e,
+0x808a0004,
+0x7c08b040,
+0x806b0004,
+0x00000000,
+0x7d0a706e,
+0x7d2b706e,
+0x806a0004,
+0x7c08b040,
+0x808b0004,
+0x00000000,
+0x7c89b040,
+0x40820000,
+0x00050805,
+0x40860000,
+0x00050805,
+0x48000001,
+0x0005009c,
+0x41830000,
+0x00050804,
+0x0006000b,
+0x80f00000,
+0x3a100004,
+0x7ed4716e,
+0x90740004,
+0x0006000c,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000e,
+0x7c000400,
+0x40a10000,
+0x0005080b,
+0x00000000,
+0x48000000,
+0x00050041,
+0x00000000,
+0x48000000,
+0x0005003d,
+0x00000000,
+0x48000000,
+0x00050042,
+0x00000000,
+0x0006000f,
+0x00000000,
+0xc9ea0000,
+0x4c002202,
+0xc9cb0000,
+0x00000000,
+0xc9ca0000,
+0x4c002202,
+0xc9eb0000,
+0x00000000,
+0x40800000,
+0x00050841,
+0x00000000,
+0x40800000,
+0x0005083d,
+0x00000000,
+0x40800000,
+0x00050842,
+0x00000000,
+0x000600a2,
+0xfc2e7824,
+0x48000001,
+0x00030010,
+0xfc0103f2,
+0xfc0e0028,
+0x80f00000,
+0x3a100004,
+0x7c0ea5ae,
+0x48000000,
+0x0005000c,
+0x00000000,
+0x7d0e502e,
+0x00000000,
+0x7d2f582e,
+0x00000000,
+0x7dce54ae,
+0x7def5cae,
+0x00000000,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x0005083f,
+0x00000000,
+0x7c08b040,
+0x40800000,
+0x0005083f,
+0x00000000,
+0x7d0e502e,
+0x00000000,
+0x7d2f582e,
+0x00000000,
+0x7dee54ae,
+0x7dcf5cae,
+0x00000000,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x0005083c,
+0x00000000,
+0x7c08b040,
+0x40800000,
+0x0005083c,
+0x00000000,
+0x7d0e502e,
+0x7d2e582e,
+0x7dce54ae,
+0x7dee5cae,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x00050840,
+0x00000000,
+0x000600a2,
+0xfc2e7824,
+0x48000001,
+0x00030010,
+0xfc0103f2,
+0xfc0e0028,
+0x80f00000,
+0x3a100004,
+0x7c0ea5ae,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x7d0a706e,
+0x7d2b786e,
+0x806a0004,
+0x7c08b040,
+0x808b0004,
+0x00000000,
+0x7d0a706e,
+0x7d2b786e,
+0x808a0004,
+0x7c08b040,
+0x806b0004,
+0x00000000,
+0x7d0a706e,
+0x7d2b706e,
+0x806a0004,
+0x7c08b040,
+0x808b0004,
+0x00000000,
+0x7c89b040,
+0x40820000,
+0x00050805,
+0x40860000,
+0x00050805,
+0x48000001,
+0x0005009c,
+0x41830000,
+0x00050804,
+0x0006000b,
+0x80f00000,
+0x3a100004,
+0x7ed4716e,
+0x90740004,
+0x0006000c,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000e,
+0x7c000400,
+0x40a10000,
+0x0005080b,
+0x00000000,
+0x48000000,
+0x00050041,
+0x00000000,
+0x48000000,
+0x0005003d,
+0x00000000,
+0x48000000,
+0x00050042,
+0x00000000,
+0x0006000f,
+0x00000000,
+0xc9ea0000,
+0x4c002202,
+0xc9cb0000,
+0x00000000,
+0xc9ca0000,
+0x4c002202,
+0xc9eb0000,
+0x00000000,
+0x40800000,
+0x00050841,
+0x00000000,
+0x40800000,
+0x0005083d,
+0x00000000,
+0x40800000,
+0x00050842,
+0x00000000,
+0x48000000,
+0x000500a2,
+0x00000000,
+0x7d0e502e,
+0x00000000,
+0x7d2f582e,
+0x00000000,
+0x7dce54ae,
+0x7def5cae,
+0x00000000,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x0005083f,
+0x00000000,
+0x7c08b040,
+0x40800000,
+0x0005083f,
+0x00000000,
+0x7d0e502e,
+0x00000000,
+0x7d2f582e,
+0x00000000,
+0x7dee54ae,
+0x7dcf5cae,
+0x00000000,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x0005083c,
+0x00000000,
+0x7c08b040,
+0x40800000,
+0x0005083c,
+0x00000000,
+0x7d0e502e,
+0x7d2e582e,
+0x7dce54ae,
+0x7dee5cae,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x00050840,
+0x00000000,
+0x48000000,
+0x000500a2,
+0x00000000,
+0x7d0e502e,
+0x7c2e54ae,
+0x7d2e582e,
+0x7c4e5cae,
+0x7c08b040,
+0x7c89b040,
+0x4c002202,
+0x40800000,
+0x00050840,
+0x48000001,
+0x0003001f,
+0x80f00000,
+0x3a100004,
+0x7c2ea5ae,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x7caa5850,
+0x91d20000,
+0x00098200,
+0x7c8e5a14,
+0x7d555378,
+0x0006002b,
+0x92010020,
+0x7e439378,
+0x54a500fe,
+0x000900ab,
+0x48000001,
+0x00030030,
+0x28030000,
+0x81d20000,
+0x00098200,
+0x40820000,
+0x00050836,
+0x80f00000,
+0x3a100004,
+0x7c0eacae,
+0x7c0ea5ae,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x5588007e,
+0x000900ab,
+0x2108fffc,
+0x80f00000,
+0x3a100004,
+0x7c0f402e,
+0x39200000,
+0x00098200,
+0x7d34716e,
+0x90140004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x5588007e,
+0x000900ab,
+0x2108fffc,
+0x80f00000,
+0x3a100004,
+0x7c0f402e,
+0x39200000,
+0x00098200,
+0x7d34716e,
+0x90140004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x558c6800,
+0x000900a1,
+0x7d8c8670,
+0x80f00000,
+0x3a100004,
+0x7ed4716e,
+0x91940004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x558c6800,
+0x000900a1,
+0x7d88fe70,
+0x7d096278,
+0x7d284850,
+0x7d260034,
+0x2106040d,
+0x7d293030,
+0x20cc0000,
+0x5508a000,
+0x000900a1,
+0x512ca87e,
+0x7c000110,
+0x7d8c4214,
+0x7d8c0038,
+0x80f00000,
+0x3a100004,
+0x7d94716e,
+0x93140004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x80f00000,
+0x3a100004,
+0x7c0f64ae,
+0x7c0ea5ae,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x558800fe,
+0x000900ab,
+0x7d0040f8,
+0x80f00000,
+0x3a100004,
+0x7c0ea12e,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x7eeea12e,
+0x3a940008,
+0x0006000b,
+0x7eeea12e,
+0x7c146000,
+0x3a940008,
+0x41800000,
+0x0005080b,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x814efffc,
+0x558c007e,
+0x000900ab,
+0x398c0000,
+0x00098200,
+0x7d4a602e,
+0x80f00000,
+0x3a100004,
+0x810a0000,
+0x00098200,
+0xc8080000,
+0x7c0ea5ae,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x814efffc,
+0x5694007e,
+0x000900ab,
+0x3a940000,
+0x00098200,
+0x7c0c74ee,
+0x7d4aa02e,
+0x88ca0000,
+0x00098200,
+0x808a0000,
+0x00098200,
+0x70c60000,
+0x00090200,
+0x880a0000,
+0x00098200,
+0x812c0000,
+0xd8040000,
+0x28800000,
+0x810c0004,
+0x4c423382,
+0x39290000,
+0x00098200,
+0x40820000,
+0x00050802,
+0x0006000b,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000c,
+0x28090000,
+0x00090200,
+0x40800000,
+0x0005080b,
+0x88c80000,
+0x00098200,
+0x70c60000,
+0x00090200,
+0x38710000,
+0x00098200,
+0x41820000,
+0x0005080b,
+0x48000001,
+0x00030031,
+0x48000000,
+0x0005000b,
+0x00000000,
+0x814efffc,
+0x5588007e,
+0x000900ab,
+0x5694007e,
+0x000900ab,
+0x2108fffc,
+0x3a940000,
+0x00098200,
+0x7d0f402e,
+0x7d4aa02e,
+0x88ca0000,
+0x00098200,
+0x808a0000,
+0x00098200,
+0x70c60000,
+0x00090200,
+0x88c80000,
+0x00098200,
+0x892a0000,
+0x00098200,
+0x38000000,
+0x00098200,
+0x91040004,
+0x90040000,
+0x40820000,
+0x00050802,
+0x0006000b,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000c,
+0x70c60000,
+0x00090200,
+0x28890000,
+0x4c423382,
+0x38710000,
+0x00098200,
+0x41820000,
+0x0005080b,
+0x48000001,
+0x00030031,
+0x48000000,
+0x0005000b,
+0x00000000,
+0x814efffc,
+0x5694007e,
+0x000900ab,
+0x3a940000,
+0x00098200,
+0x7c0f64ae,
+0x7d4aa02e,
+0x80f00000,
+0x3a100004,
+0x810a0000,
+0x00098200,
+0xd8080000,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x814efffc,
+0x5694007e,
+0x000900ab,
+0x558000fe,
+0x000900ab,
+0x3a940000,
+0x00098200,
+0x7c0000f8,
+0x7d4aa02e,
+0x80f00000,
+0x3a100004,
+0x810a0000,
+0x00098200,
+0x90080000,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x81120000,
+0x00098200,
+0x5580007e,
+0x000900ab,
+0x3e100000,
+0x00098200,
+0x7e100214,
+0x91d20000,
+0x00098200,
+0x28080000,
+0x7e439378,
+0x41820000,
+0x00050801,
+0x7c8ea214,
+0x48000001,
+0x00030032,
+0x81d20000,
+0x00098200,
+0x0006000b,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x5588007e,
+0x000900ab,
+0x91d20000,
+0x00098200,
+0x2108fffc,
+0x92010020,
+0x7c8f402e,
+0x7e439378,
+0x80aefffc,
+0x48000001,
+0x00030033,
+0x81d20000,
+0x00098200,
+0x38000000,
+0x00098200,
+0x7c14716e,
+0x90740004,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x80110000,
+0x00098200,
+0x7e439378,
+0x81110000,
+0x00098200,
+0x91d20000,
+0x00098200,
+0x7c004040,
+0x92010020,
+0x40800000,
+0x00050805,
+0x0006000b,
+0x00000000,
+0x5584ed7e,
+0x558596fe,
+0x2c0407ff,
+0x41820000,
+0x00050803,
+0x0006000c,
+0x48000001,
+0x00030034,
+0x00000000,
+0x5588007e,
+0x000900ab,
+0x2108fffc,
+0x7c8f402e,
+0x48000001,
+0x00030035,
+0x00000000,
+0x81d20000,
+0x00098200,
+0x38000000,
+0x00098200,
+0x7c14716e,
+0x90740004,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x0006000d,
+0x38800801,
+0x48000000,
+0x0005000c,
+0x00000000,
+0x0006000f,
+0x7d956378,
+0x48000001,
+0x00030036,
+0x7eacab78,
+0x7e439378,
+0x48000000,
+0x0005000b,
+0x00000000,
+0x812efffc,
+0x5588007e,
+0x000900ab,
+0x81490000,
+0x00098200,
+0x2108fffc,
+0x7d6f402e,
+0x00000000,
+0x48000000,
+0x000500a3,
+0x00000000,
+0x48000000,
+0x000500a4,
+0x00000000,
+0x7c6a706e,
+0x7c8b706e,
+0x814a0004,
+0x00000000,
+0x816b0004,
+0x00000000,
+0xc80b0000,
+0x00000000,
+0x2c030000,
+0x00098200,
+0x7c84b040,
+0x40820000,
+0x00050830,
+0x00000000,
+0x800a0000,
+0x00098200,
+0x40860000,
+0x00050805,
+0x810a0000,
+0x00098200,
+0x7c005840,
+0x55691800,
+0x000900a1,
+0x00000000,
+0x40840000,
+0x00050805,
+0xfc20001e,
+0xfc40f02a,
+0xd8210010,
+0x800a0000,
+0x00098200,
+0xfc42f028,
+0x81210014,
+0x810a0000,
+0x00098200,
+0xfc801000,
+0x7c004840,
+0x4c213202,
+0x55291800,
+0x000900a1,
+0x00000000,
+0x40810000,
+0x00050830,
+0x7c08482e,
+0x7dc84cae,
+0x2c000000,
+0x00098200,
+0x41820000,
+0x00050802,
+0x0006000b,
+0x80f00000,
+0x3a100004,
+0x7dcea5ae,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000c,
+0x812a0000,
+0x00098200,
+0x28090000,
+0x41820000,
+0x0005080b,
+0x88090000,
+0x00098200,
+0x70000000,
+0x00090200,
+0x40820000,
+0x0005080b,
+0x48000000,
+0x00050030,
+0x0006000f,
+0x2c040000,
+0x00098200,
+0x40820000,
+0x00050830,
+0x00000000,
+0x816b0004,
+0x00000000,
+0x48000000,
+0x000500a3,
+0x00000000,
+0x7c6a706e,
+0x5568007e,
+0x000900ab,
+0x814a0004,
+0x2108fffc,
+0x2c030000,
+0x00098200,
+0x7d6f402e,
+0x40820000,
+0x0005082d,
+0x000600a3,
+0x800a0000,
+0x00098200,
+0x810b0000,
+0x00098200,
+0x812a0000,
+0x00098200,
+0x7d080038,
+0x55002800,
+0x000900a1,
+0x55081800,
+0x000900a1,
+0x7d080050,
+0x7d294214,
+0x0006000b,
+0x80690000,
+0x00098200,
+0x80090000,
+0x00098200,
+0x80890000,
+0x00098200,
+0x81090000,
+0x00098200,
+0x2c030000,
+0x00098200,
+0x40820000,
+0x00050804,
+0x7c005800,
+0x40820000,
+0x00050804,
+0x2c040000,
+0x00098200,
+0x41820000,
+0x00050805,
+0x0006000d,
+0x7c94716e,
+0x91140004,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000e,
+0x81290000,
+0x00098200,
+0x00000000,
+0x28090000,
+0x40820000,
+0x0005080b,
+0x38800000,
+0x00098200,
+0x0006000f,
+0x812a0000,
+0x00098200,
+0x28090000,
+0x41820000,
+0x0005080d,
+0x88090000,
+0x00098200,
+0x70000000,
+0x00090200,
+0x40820000,
+0x0005080d,
+0x48000000,
+0x0005002e,
+0x00000000,
+0x7c6a706e,
+0x556000fe,
+0x000900ab,
+0x814a0004,
+0x2c030000,
+0x00098200,
+0x40820000,
+0x0005082f,
+0x810a0000,
+0x00098200,
+0x812a0000,
+0x00098200,
+0x7c004040,
+0x40800000,
+0x0005082f,
+0x7d09582e,
+0x7c095cae,
+0x2c080000,
+0x00098200,
+0x41820000,
+0x00050805,
+0x0006000b,
+0x80f00000,
+0x3a100004,
+0x7c0ea5ae,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000f,
+0x812a0000,
+0x00098200,
+0x28090000,
+0x41820000,
+0x0005080b,
+0x89290000,
+0x00098200,
+0x71290000,
+0x00090200,
+0x40820000,
+0x0005080b,
+0x48000000,
+0x0005002f,
+0x00000000,
+0x7c6a706e,
+0x7c8b706e,
+0x814a0004,
+0x00000000,
+0x816b0004,
+0x00000000,
+0xc80b0000,
+0x00000000,
+0x2c030000,
+0x00098200,
+0x7c84b040,
+0x40820000,
+0x00050834,
+0x00000000,
+0x800a0000,
+0x00098200,
+0x40860000,
+0x00050805,
+0x810a0000,
+0x00098200,
+0x7c005840,
+0x55601800,
+0x000900a1,
+0x00000000,
+0x40840000,
+0x00050805,
+0xfc20001e,
+0xfc40f02a,
+0xd8210010,
+0x800a0000,
+0x00098200,
+0xfc42f028,
+0x81210014,
+0x810a0000,
+0x00098200,
+0xfc801000,
+0x7c004840,
+0x4c213202,
+0x55201800,
+0x000900a1,
+0x00000000,
+0x40810000,
+0x00050834,
+0x7d28002e,
+0x88ca0000,
+0x00098200,
+0x7dcea4ae,
+0x2c090000,
+0x00098200,
+0x41820000,
+0x00050803,
+0x0006000b,
+0x70c90000,
+0x00090200,
+0x7dc805ae,
+0x40820000,
+0x00050807,
+0x0006000c,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000d,
+0x812a0000,
+0x00098200,
+0x28090000,
+0x41820000,
+0x0005080b,
+0x89290000,
+0x00098200,
+0x71290000,
+0x00090200,
+0x40820000,
+0x0005080b,
+0x48000000,
+0x00050034,
+0x0006000f,
+0x2c040000,
+0x00098200,
+0x40820000,
+0x00050834,
+0x00000000,
+0x816b0004,
+0x00000000,
+0x48000000,
+0x000500a4,
+0x00060011,
+0x80110000,
+0x00098200,
+0x54c607b8,
+0x91510000,
+0x00098200,
+0x98ca0000,
+0x00098200,
+0x900a0000,
+0x00098200,
+0x48000000,
+0x0005000c,
+0x00000000,
+0x0006000b,
+0x2c030000,
+0x00098200,
+0x40820000,
+0x00050804,
+0x7c005800,
+0x40820000,
+0x00050804,
+0x2c040000,
+0x00098200,
+0x41820000,
+0x00050805,
+0x0006000d,
+0x7c94716e,
+0x91140004,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x7c6a706e,
+0x5568007e,
+0x000900ab,
+0x814a0004,
+0x2108fffc,
+0x2c030000,
+0x00098200,
+0x7d6f402e,
+0x40820000,
+0x00050831,
+0x000600a4,
+0x800a0000,
+0x00098200,
+0x810b0000,
+0x00098200,
+0x812a0000,
+0x00098200,
+0x9b0a0000,
+0x00098200,
+0x7d080038,
+0x7dcea4ae,
+0x55002800,
+0x000900a1,
+0x55081800,
+0x000900a1,
+0x7d080050,
+0x88ca0000,
+0x00098200,
+0x7d294214,
+0x0006000b,
+0x80690000,
+0x00098200,
+0x80090000,
+0x00098200,
+0x80890000,
+0x00098200,
+0x81090000,
+0x00098200,
+0x2c030000,
+0x00098200,
+0x40820000,
+0x00050805,
+0x7c005800,
+0x40820000,
+0x00050805,
+0x2c040000,
+0x00098200,
+0x41820000,
+0x00050804,
+0x0006000c,
+0x00000000,
+0x70c00000,
+0x00090200,
+0xd9c90000,
+0x00098200,
+0x40820000,
+0x00050807,
+0x0006000d,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000e,
+0x810a0000,
+0x00098200,
+0x28080000,
+0x41820000,
+0x0005080c,
+0x88080000,
+0x00098200,
+0x70000000,
+0x00090200,
+0x40820000,
+0x0005080c,
+0x48000000,
+0x00050032,
+0x0006000f,
+0x81290000,
+0x00098200,
+0x28090000,
+0x40820000,
+0x0005080b,
+0x810a0000,
+0x00098200,
+0x38b10000,
+0x00098200,
+0x92010020,
+0x7e439378,
+0x28080000,
+0x91d20000,
+0x00098200,
+0x41820000,
+0x00050806,
+0x88080000,
+0x00098200,
+0x70000000,
+0x00090200,
+0x41820000,
+0x00050832,
+0x00060010,
+0x00000000,
+0x38000000,
+0x00098200,
+0x91650004,
+0x7d445378,
+0x90050000,
+0x48000001,
+0x00030037,
+0x81d20000,
+0x00098200,
+0xd9c30000,
+0x48000000,
+0x0005000d,
+0x00060011,
+0x80110000,
+0x00098200,
+0x54c607b8,
+0x91510000,
+0x00098200,
+0x98ca0000,
+0x00098200,
+0x900a0000,
+0x00098200,
+0x48000000,
+0x0005000d,
+0x00000000,
+0x7c6a706e,
+0x556000fe,
+0x000900ab,
+0x814a0004,
+0x2c030000,
+0x00098200,
+0x40820000,
+0x00050833,
+0x810a0000,
+0x00098200,
+0x812a0000,
+0x00098200,
+0x88ca0000,
+0x00098200,
+0x7c004040,
+0x7dcea4ae,
+0x40800000,
+0x00050833,
+0x7d09582e,
+0x2c080000,
+0x00098200,
+0x41820000,
+0x00050805,
+0x0006000b,
+0x70c00000,
+0x00090200,
+0x7dc95dae,
+0x40820000,
+0x00050807,
+0x0006000c,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000f,
+0x810a0000,
+0x00098200,
+0x28080000,
+0x41820000,
+0x0005080b,
+0x89080000,
+0x00098200,
+0x71080000,
+0x00090200,
+0x40820000,
+0x0005080b,
+0x48000000,
+0x00050033,
+0x00060011,
+0x80110000,
+0x00098200,
+0x00000000,
+0x54c607b8,
+0x91510000,
+0x00098200,
+0x98ca0000,
+0x00098200,
+0x900a0000,
+0x00098200,
+0x48000000,
+0x0005000c,
+0x00000000,
+0x7e8ea214,
+0x0006000b,
+0x7ccf6214,
+0x8094fffc,
+0x3413fff8,
+0x80c60004,
+0x540500fe,
+0x000900ab,
+0x41820000,
+0x00050804,
+0x7ca53214,
+0x81240000,
+0x00098200,
+0x54c81800,
+0x000900a1,
+0x88c40000,
+0x00098200,
+0x7c054840,
+0x7d340214,
+0x80040000,
+0x00098200,
+0x41810000,
+0x00050805,
+0x7d080214,
+0x70c00000,
+0x00090200,
+0x0006000d,
+0xc8140000,
+0x3a940008,
+0x7c944800,
+0xd8080000,
+0x39080008,
+0x41840000,
+0x0005080d,
+0x40820000,
+0x00050807,
+0x0006000e,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000f,
+0x91d20000,
+0x00098200,
+0x7e439378,
+0x92010020,
+0x7d956378,
+0x48000001,
+0x00030038,
+0x7eacab78,
+0x48000000,
+0x0005000b,
+0x00060011,
+0x80110000,
+0x00098200,
+0x54c607b8,
+0x90910000,
+0x00098200,
+0x98c40000,
+0x00098200,
+0x90040000,
+0x00098200,
+0x00000000,
+0x48000000,
+0x0005000e,
+0x00000000,
+0x7d6b9a14,
+0x00000000,
+0x7dc97378,
+0x7c0ea06e,
+0x814e0004,
+0x396bfff8,
+0x39ce0008,
+0x2c000000,
+0x00098200,
+0x40820000,
+0x00050825,
+0x920efff8,
+0x820a0000,
+0x00098200,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x54f4dd78,
+0x7c11402e,
+0x7e947214,
+0x7c0903a6,
+0x4e800420,
+0x00000000,
+0x7d6b9a14,
+0x00000000,
+0x7c14706e,
+0x81540004,
+0x396bfff8,
+0x810efff8,
+0x2c000000,
+0x00098200,
+0x3a940008,
+0x40820000,
+0x00050845,
+0x00060046,
+0x71000000,
+0x00090200,
+0x88ca0000,
+0x00098200,
+0x69090000,
+0x00090200,
+0x288b0000,
+0x40820000,
+0x00050807,
+0x0006000b,
+0x914efffc,
+0x39200000,
+0x2b860001,
+0x41860000,
+0x00050803,
+0x0006000c,
+0x38c90008,
+0x7c144cae,
+0x7c865840,
+0x7c0e4dae,
+0x7cc93378,
+0x40860000,
+0x0005080c,
+0x0006000d,
+0x4c42ea02,
+0x41820000,
+0x00050805,
+0x0006000e,
+0x820a0000,
+0x00098200,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x54f4dd78,
+0x7c11402e,
+0x7e947214,
+0x7c0903a6,
+0x4e800420,
+0x0006000f,
+0x80e8fffc,
+0x54f4dd78,
+0x7d147050,
+0x81080000,
+0x00098200,
+0x81080000,
+0x00098200,
+0x81e80000,
+0x00098200,
+0x48000000,
+0x0005000e,
+0x00060011,
+0x71200000,
+0x00090200,
+0x00000000,
+0x40820000,
+0x0005080b,
+0x7dc97050,
+0x810efff8,
+0x71000000,
+0x00090200,
+0x48000000,
+0x0005000b,
+0x00000000,
+0x7dc97378,
+0x7dcea214,
+0x810effe8,
+0x814effec,
+0xc82efff8,
+0xc80efff0,
+0x910e0000,
+0x914e0004,
+0x2c080000,
+0x00098200,
+0xd82e0010,
+0x39600010,
+0xdc0e0008,
+0x40820000,
+0x00050825,
+0x920efff8,
+0x820a0000,
+0x00098200,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x54f4dd78,
+0x7c11402e,
+0x7e947214,
+0x7c0903a6,
+0x4e800420,
+0x00000000,
+0x7e8ea214,
+0x8154fff4,
+0x8174fffc,
+0x800a0000,
+0x00098200,
+0x810a0000,
+0x00098200,
+0x3a100004,
+0x0006000b,
+0x7c0b0040,
+0x55661800,
+0x000900a1,
+0x40800000,
+0x00050805,
+0x7d28302e,
+0x7c0834ae,
+0x2c090000,
+0x00098200,
+0x80f0fffc,
+0x41820000,
+0x00050804,
+0x00000000,
+0x91740004,
+0x92d40000,
+0x00000000,
+0x9161000c,
+0xc8210008,
+0xfc21f028,
+0x00000000,
+0x396b0001,
+0x3cd00000,
+0x00098200,
+0xd8140008,
+0x54e893ba,
+0x9174fffc,
+0x7e083214,
+0x00000000,
+0xd8340000,
+0x00000000,
+0x0006000d,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000e,
+0x396b0001,
+0x48000000,
+0x0005000b,
+0x0006000f,
+0x810a0000,
+0x00098200,
+0x7d605850,
+0x812a0000,
+0x00098200,
+0x00060010,
+0x7c0b4040,
+0x55662800,
+0x000900a1,
+0x41a10000,
+0x0005080d,
+0x556a1800,
+0x000900a1,
+0x7cca3050,
+0x7d49302e,
+0x7c0934ae,
+0x7cc93214,
+0x2c0a0000,
+0x00098200,
+0x80f0fffc,
+0x41820000,
+0x00050807,
+0xc8260000,
+0x00098200,
+0x3d300000,
+0x00098200,
+0xd8140008,
+0x7d6b0214,
+0x54e893ba,
+0xd8340000,
+0x396b0001,
+0x7e084a14,
+0x9174fffc,
+0x48000000,
+0x0005000d,
+0x00060011,
+0x396b0001,
+0x48000000,
+0x00050010,
+0x00000000,
+0x7e8ea214,
+0x8014ffe8,
+0x8114ffec,
+0x8134fff0,
+0x80d4fff8,
+0x2c090000,
+0x00098200,
+0x2c800000,
+0x00098200,
+0x2f060000,
+0x00098200,
+0x40860000,
+0x00050805,
+0x89080000,
+0x00098200,
+0x4c42d202,
+0x2f880000,
+0x00098200,
+0x5580007e,
+0x000900ab,
+0x4c42f202,
+0x7cd00214,
+0x40820000,
+0x00050805,
+0x9314fffc,
+0x3e060000,
+0x00098200,
+0x0006000b,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000f,
+0x38000000,
+0x00098200,
+0x39000000,
+0x00098200,
+0x9810ffff,
+0x3e060000,
+0x00098200,
+0x99100003,
+0x48000000,
+0x0005000b,
+0x00000000,
+0x800efff8,
+0x7d6e5a14,
+0x7e8ea214,
+0x396b0000,
+0x00098200,
+0x7d345214,
+0x38cefff8,
+0x7d605850,
+0x288a0000,
+0x7d0b3051,
+0x41860000,
+0x00050805,
+0x3929fff0,
+0x40810000,
+0x00050802,
+0x0006000b,
+0xc80b0000,
+0x396b0008,
+0xd8140000,
+0x7c144840,
+0x7c8b3040,
+0x40800000,
+0x00050803,
+0x3a940008,
+0x41840000,
+0x0005080b,
+0x0006000c,
+0x92f40000,
+0x7c144840,
+0x3a940008,
+0x41800000,
+0x0005080c,
+0x0006000d,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000f,
+0x80120000,
+0x00098200,
+0x3a600008,
+0x40a10000,
+0x0005080d,
+0x7d344214,
+0x7c090040,
+0x3a680008,
+0x41810000,
+0x00050807,
+0x00060010,
+0xc80b0000,
+0x396b0008,
+0xd8140000,
+0x7c0b3040,
+0x3a940008,
+0x41800000,
+0x00050810,
+0x48000000,
+0x0005000d,
+0x00060011,
+0x7e439378,
+0x92920000,
+0x00098200,
+0x7eae5850,
+0x91d20000,
+0x00098200,
+0x7e8ea050,
+0x92010020,
+0x550400fe,
+0x000900ab,
+0x48000001,
+0x00030000,
+0x81d20000,
+0x00098200,
+0x00000000,
+0x7e8ea214,
+0x7d6eaa14,
+0x38cefff8,
+0x48000000,
+0x00050010,
+0x00000000,
+0x7d8c9a14,
+0x00000000,
+0x820efff8,
+0x7e8ea214,
+0x7d936378,
+0x0006000b,
+0x72000000,
+0x00090200,
+0x6a080000,
+0x00090200,
+0x40820000,
+0x000508a5,
+0x00060017,
+0x80f0fffc,
+0x2c0c0008,
+0x392efff8,
+0x396cfff8,
+0x54ea5d78,
+0x41820000,
+0x00050803,
+0x39000000,
+0x0006000c,
+0x38c80008,
+0x7c1444ae,
+0x7c065800,
+0x7c0945ae,
+0x41820000,
+0x00050803,
+0x39060008,
+0x7c3434ae,
+0x7c085800,
+0x7c2935ae,
+0x40820000,
+0x0005080c,
+0x0006000d,
+0x0006000f,
+0x7c0a6040,
+0x54f4dd78,
+0x41810000,
+0x00050806,
+0x7dd44850,
+0x810efffc,
+0x80f00000,
+0x3a100004,
+0x81080000,
+0x00098200,
+0x81e80000,
+0x00098200,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00060010,
+0x390cfff8,
+0x398c0008,
+0x7ee9412e,
+0x48000000,
+0x0005000f,
+0x000600a5,
+0x71090000,
+0x00090200,
+0x40820000,
+0x00050818,
+0x7dc87050,
+0x820efff8,
+0x48000000,
+0x0005000b,
+0x00000000,
+0x820efff8,
+0x7e8ea214,
+0x7d936378,
+0x72000000,
+0x00090200,
+0x6a080000,
+0x00090200,
+0x40a20000,
+0x000508a5,
+0x80f0fffc,
+0x392efff8,
+0x54ea5d78,
+0x00000000,
+0xc8140000,
+0xd8090000,
+0x00000000,
+0x0006000f,
+0x7c0a6040,
+0x54f4dd78,
+0x41810000,
+0x00050806,
+0x7dd44850,
+0x810efffc,
+0x80f00000,
+0x3a100004,
+0x81080000,
+0x00098200,
+0x81e80000,
+0x00098200,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00060010,
+0x390cfff8,
+0x398c0008,
+0x7ee9412e,
+0x48000000,
+0x0005000f,
+0x00000000,
+0x5608fe7c,
+0x39080000,
+0x00098200,
+0x7d31422e,
+0x35290000,
+0x00098200,
+0x7d31432e,
+0x41800000,
+0x00050894,
+0x00000000,
+0x7d14706e,
+0x80740000,
+0x00098200,
+0x7c08b040,
+0x00000000,
+0x80b40000,
+0x00098200,
+0x40820000,
+0x00050809,
+0x7c632e15,
+0x2f050000,
+0x80940000,
+0x00098200,
+0x41830000,
+0x00050806,
+0x0006000e,
+0x90740000,
+0x00098200,
+0x00000000,
+0x80d40000,
+0x00098200,
+0x80b40000,
+0x00098200,
+0x81340000,
+0x00098200,
+0x80940000,
+0x00098200,
+0x7f86b040,
+0x7c89b040,
+0x4c42f202,
+0x4c423202,
+0x2f050000,
+0x40820000,
+0x00050809,
+0x00000000,
+0x41980000,
+0x00050805,
+0x7c032000,
+0x0006000b,
+0x92d40000,
+0x00098200,
+0x00000000,
+0x558c007e,
+0x000900ab,
+0x00000000,
+0x90740000,
+0x00098200,
+0x00000000,
+0x7d906214,
+0x00000000,
+0x41810000,
+0x00050803,
+0x00000000,
+0x3e0c0000,
+0x00098200,
+0x40a10000,
+0x00050807,
+0x00000000,
+0x41810000,
+0x00050802,
+0x3e0c0000,
+0x00098200,
+0x00000000,
+0x40a10000,
+0x00070800,
+0x00000000,
+0x0006000c,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000f,
+0x7c041800,
+0x48000000,
+0x0005000b,
+0x00000000,
+0x00060010,
+0x7c000400,
+0x40a10000,
+0x0005080e,
+0x48000000,
+0x0005000c,
+0x00000000,
+0x00060013,
+0xc8340000,
+0x00098200,
+0x00000000,
+0x7c3474ee,
+0x00000000,
+0xc8740000,
+0x00098200,
+0xc8540000,
+0x00098200,
+0x80d40000,
+0x00098200,
+0xfc21182a,
+0xd8340000,
+0x00098200,
+0x00000000,
+0x00060013,
+0x00000000,
+0x7d14706e,
+0x80d40000,
+0x00098200,
+0x81340000,
+0x00098200,
+0x7c08b040,
+0x7f86b040,
+0x7c89b040,
+0x00000000,
+0xc8340000,
+0x00098200,
+0x4c00e202,
+0xc8740000,
+0x00098200,
+0x4c002202,
+0xc8540000,
+0x00098200,
+0x40800000,
+0x00050847,
+0x00000000,
+0x2f060000,
+0x00000000,
+0x558c007e,
+0x000900ab,
+0x00000000,
+0xd8340000,
+0x00098200,
+0x00000000,
+0x7d906214,
+0x00000000,
+0xfc011000,
+0x00000000,
+0x3e0c0000,
+0x00098200,
+0x00000000,
+0x41980000,
+0x00050805,
+0x00000000,
+0x41810000,
+0x00050803,
+0x00000000,
+0x41a10000,
+0x0005080c,
+0x00000000,
+0x41810000,
+0x00050802,
+0x00000000,
+0x0006000b,
+0x3e0c0000,
+0x00098200,
+0x00000000,
+0x40a10000,
+0x00050807,
+0x00000000,
+0x40a10000,
+0x00070800,
+0x00000000,
+0x48000000,
+0x0005000c,
+0x00000000,
+0x0006000c,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x0006000f,
+0x00000000,
+0x40800000,
+0x0005080c,
+0x0006000d,
+0x3e0c0000,
+0x00098200,
+0x00000000,
+0x40a00000,
+0x0005080b,
+0x00000000,
+0x40a00000,
+0x00050807,
+0x00000000,
+0x40a00000,
+0x00070800,
+0x00000000,
+0x48000000,
+0x0005000c,
+0x00000000,
+0x00060011,
+0x80f0fffc,
+0x54ec9b78,
+0x48000000,
+0x00070000,
+0x00000000,
+0x5608fe7c,
+0x39080000,
+0x00098200,
+0x7d31422e,
+0x35290000,
+0x00098200,
+0x7d31432e,
+0x41800000,
+0x00050894,
+0x00000000,
+0x7d14706e,
+0x81340004,
+0x2c080000,
+0x00098200,
+0x41820000,
+0x00050801,
+0x00000000,
+0x9114fff8,
+0x9134fffc,
+0x48000000,
+0x00070000,
+0x00000000,
+0x5580007e,
+0x000900ab,
+0x3e100000,
+0x00098200,
+0x7e100214,
+0x9114fff8,
+0x9134fffc,
+0x00000000,
+0x0006000b,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x5608fe7c,
+0x39080000,
+0x00098200,
+0x7d31422e,
+0x35290000,
+0x00098200,
+0x7d31432e,
+0x41800000,
+0x00050894,
+0x00000000,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x81110000,
+0x00098200,
+0x558c007e,
+0x000900ab,
+0x93110000,
+0x00098200,
+0x7d28602e,
+0x7c000400,
+0x81290000,
+0x00098200,
+0x91d10000,
+0x00098200,
+0x7d2903a6,
+0x92510000,
+0x00098200,
+0x3bf10000,
+0x00098200,
+0x4e800420,
+0x00000000,
+0x5580007e,
+0x000900ab,
+0x3e100000,
+0x00098200,
+0x7e100214,
+0x80f00000,
+0x3a100004,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x5608fe7c,
+0x39080000,
+0x00098200,
+0x7d31422e,
+0x35290000,
+0x00098200,
+0x7d31432e,
+0x41800000,
+0x00050896,
+0x00000000,
+0x81320000,
+0x00098200,
+0x89100000,
+0x00098200,
+0x81f00000,
+0x00098200,
+0x7c144840,
+0x55081800,
+0x000900a1,
+0x41810000,
+0x00050820,
+0x00000000,
+0x80f00000,
+0x3a100004,
+0x00000000,
+0x0006000c,
+0x7c0b4040,
+0x40810000,
+0x00050803,
+0x00000000,
+0x54ec9b78,
+0x48000000,
+0x00070000,
+0x00000000,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x00000000,
+0x0006000d,
+0x7eee592e,
+0x396b0008,
+0x48000000,
+0x0005000c,
+0x00000000,
+0x7c810808,
+0x00000000,
+0x81320000,
+0x00098200,
+0x7d0e5a14,
+0x7c145a14,
+0x91480004,
+0x38cb0000,
+0x00098200,
+0x81f00000,
+0x00098200,
+0x7c004840,
+0x90c80000,
+0x40800000,
+0x00050820,
+0x89300000,
+0x00098200,
+0x7dd47378,
+0x7d0b4378,
+0x80f00000,
+0x3a100004,
+0x2c090000,
+0x39c80008,
+0x41820000,
+0x00050803,
+0x0006000b,
+0x7c145840,
+0x80140000,
+0x80d40004,
+0x40800000,
+0x00050804,
+0x92f40000,
+0x3a940008,
+0x0006000c,
+0x3529ffff,
+0x90080008,
+0x90c8000c,
+0x39080008,
+0x40820000,
+0x0005080b,
+0x0006000d,
+0x54e815ba,
+0x7c11402e,
+0x7c0903a6,
+0x54ea5d78,
+0x54ec9b78,
+0x54f4dd78,
+0x54eb9d78,
+0x4e800420,
+0x0006000e,
+0x38000000,
+0x00098200,
+0x48000000,
+0x0005000c,
+0x00000000,
+0x80ca0000,
+0x00098200,
+0x00000000,
+0x80d10000,
+0x00098200,
+0x00000000,
+0x7d145a14,
+0x81320000,
+0x00098200,
+0x7d6e5a14,
+0x91d20000,
+0x00098200,
+0x7c084840,
+0x91720000,
+0x00098200,
+0x38000000,
+0x00098200,
+0x7cc903a6,
+0x00000000,
+0x808a0000,
+0x00098200,
+0x00000000,
+0x7e439378,
+0x41810000,
+0x0005081f,
+0x90110000,
+0x00098200,
+0x4e800421,
+0x81d20000,
+0x00098200,
+0x546c1800,
+0x000900a1,
+0x81120000,
+0x00098200,
+0x38000000,
+0x00098200,
+0x820efff8,
+0x7e8c4050,
+0x90110000,
+0x00098200,
+0x48000000,
+0x00050016,
+0x00000000,
+0x00010000
+};
+
+enum {
+  GLOB_vm_returnp,
+  GLOB_cont_dispatch,
+  GLOB_vm_returnc,
+  GLOB_BC_RET_Z,
+  GLOB_vm_return,
+  GLOB_vm_leave_cp,
+  GLOB_vm_leave_unw,
+  GLOB_vm_unwind_c,
+  GLOB_vm_unwind_c_eh,
+  GLOB_vm_unwind_ff,
+  GLOB_vm_unwind_ff_eh,
+  GLOB_vm_growstack_c,
+  GLOB_vm_growstack_l,
+  GLOB_vm_resume,
+  GLOB_vm_pcall,
+  GLOB_vm_call,
+  GLOB_vm_call_dispatch,
+  GLOB_vmeta_call,
+  GLOB_vm_call_dispatch_f,
+  GLOB_vm_cpcall,
+  GLOB_cont_ffi_callback,
+  GLOB_vm_call_tail,
+  GLOB_cont_cat,
+  GLOB_BC_CAT_Z,
+  GLOB_cont_nop,
+  GLOB_vmeta_tgets1,
+  GLOB_vmeta_tgets,
+  GLOB_vmeta_tgetb,
+  GLOB_vmeta_tgetv,
+  GLOB_vmeta_tsets1,
+  GLOB_vmeta_tsets,
+  GLOB_vmeta_tsetb,
+  GLOB_vmeta_tsetv,
+  GLOB_vmeta_comp,
+  GLOB_vmeta_binop,
+  GLOB_cont_ra,
+  GLOB_cont_condt,
+  GLOB_cont_condf,
+  GLOB_vmeta_equal,
+  GLOB_vmeta_equal_cd,
+  GLOB_vmeta_arith_nv,
+  GLOB_vmeta_arith_nv2,
+  GLOB_vmeta_unm,
+  GLOB_vmeta_arith_vn,
+  GLOB_vmeta_arith_vv,
+  GLOB_vmeta_arith_vn2,
+  GLOB_vmeta_arith_vv2,
+  GLOB_vmeta_len,
+  GLOB_BC_LEN_Z,
+  GLOB_vmeta_callt,
+  GLOB_BC_CALLT_Z,
+  GLOB_vmeta_for,
+  GLOB_ff_assert,
+  GLOB_fff_fallback,
+  GLOB_fff_res,
+  GLOB_ff_type,
+  GLOB_fff_resn,
+  GLOB_ff_getmetatable,
+  GLOB_fff_restv,
+  GLOB_ff_setmetatable,
+  GLOB_ff_rawget,
+  GLOB_ff_tonumber,
+  GLOB_ff_tostring,
+  GLOB_fff_gcstep,
+  GLOB_ff_next,
+  GLOB_ff_pairs,
+  GLOB_ff_ipairs_aux,
+  GLOB_ff_ipairs,
+  GLOB_ff_pcall,
+  GLOB_ff_xpcall,
+  GLOB_ff_coroutine_resume,
+  GLOB_ff_coroutine_wrap_aux,
+  GLOB_ff_coroutine_yield,
+  GLOB_ff_math_abs,
+  GLOB_fff_resi,
+  GLOB_fff_res1,
+  GLOB_ff_math_floor,
+  GLOB_ff_math_ceil,
+  GLOB_ff_math_sqrt,
+  GLOB_ff_math_log,
+  GLOB_ff_math_log10,
+  GLOB_ff_math_exp,
+  GLOB_ff_math_sin,
+  GLOB_ff_math_cos,
+  GLOB_ff_math_tan,
+  GLOB_ff_math_asin,
+  GLOB_ff_math_acos,
+  GLOB_ff_math_atan,
+  GLOB_ff_math_sinh,
+  GLOB_ff_math_cosh,
+  GLOB_ff_math_tanh,
+  GLOB_ff_math_pow,
+  GLOB_ff_math_atan2,
+  GLOB_ff_math_fmod,
+  GLOB_ff_math_deg,
+  GLOB_ff_math_rad,
+  GLOB_ff_math_ldexp,
+  GLOB_ff_math_frexp,
+  GLOB_ff_math_modf,
+  GLOB_ff_math_min,
+  GLOB_ff_math_max,
+  GLOB_ff_string_len,
+  GLOB_ff_string_byte,
+  GLOB_ff_string_char,
+  GLOB_fff_newstr,
+  GLOB_ff_string_sub,
+  GLOB_ff_string_rep,
+  GLOB_ff_string_reverse,
+  GLOB_ff_string_lower,
+  GLOB_ff_string_upper,
+  GLOB_ff_table_getn,
+  GLOB_ff_bit_band,
+  GLOB_fff_tobit_fb,
+  GLOB_fff_bitop_fb,
+  GLOB_ff_bit_bor,
+  GLOB_ff_bit_bxor,
+  GLOB_ff_bit_bswap,
+  GLOB_ff_bit_bnot,
+  GLOB_ff_bit_lshift,
+  GLOB_ff_bit_rshift,
+  GLOB_ff_bit_arshift,
+  GLOB_ff_bit_rol,
+  GLOB_ff_bit_ror,
+  GLOB_ff_bit_tobit,
+  GLOB_vm_record,
+  GLOB_vm_rethook,
+  GLOB_vm_inshook,
+  GLOB_cont_hook,
+  GLOB_vm_hotloop,
+  GLOB_vm_callhook,
+  GLOB_vm_hotcall,
+  GLOB_vm_exit_handler,
+  GLOB_vm_exit_interp,
+  GLOB_vm_floor,
+  GLOB_vm_ceil,
+  GLOB_vm_trunc,
+  GLOB_vm_modi,
+  GLOB_vm_foldarith,
+  GLOB_vm_ffi_callback,
+  GLOB_vm_ffi_call,
+  GLOB_BC_ISEQN_Z,
+  GLOB_BC_ISNEN_Z,
+  GLOB_BC_MODVN_Z,
+  GLOB_BC_TGETS_Z,
+  GLOB_BC_TSETS_Z,
+  GLOB_BC_RETV_Z,
+  GLOB__MAX
+};
+static const char *const globnames[] = {
+  "vm_returnp",
+  "cont_dispatch",
+  "vm_returnc",
+  "BC_RET_Z",
+  "vm_return",
+  "vm_leave_cp",
+  "vm_leave_unw",
+  "vm_unwind_c",
+  "vm_unwind_c_eh",
+  "vm_unwind_ff",
+  "vm_unwind_ff_eh",
+  "vm_growstack_c",
+  "vm_growstack_l",
+  "vm_resume",
+  "vm_pcall",
+  "vm_call",
+  "vm_call_dispatch",
+  "vmeta_call",
+  "vm_call_dispatch_f",
+  "vm_cpcall",
+  "cont_ffi_callback",
+  "vm_call_tail",
+  "cont_cat",
+  "BC_CAT_Z",
+  "cont_nop",
+  "vmeta_tgets1",
+  "vmeta_tgets",
+  "vmeta_tgetb",
+  "vmeta_tgetv",
+  "vmeta_tsets1",
+  "vmeta_tsets",
+  "vmeta_tsetb",
+  "vmeta_tsetv",
+  "vmeta_comp",
+  "vmeta_binop",
+  "cont_ra",
+  "cont_condt",
+  "cont_condf",
+  "vmeta_equal",
+  "vmeta_equal_cd",
+  "vmeta_arith_nv",
+  "vmeta_arith_nv2",
+  "vmeta_unm",
+  "vmeta_arith_vn",
+  "vmeta_arith_vv",
+  "vmeta_arith_vn2",
+  "vmeta_arith_vv2",
+  "vmeta_len",
+  "BC_LEN_Z",
+  "vmeta_callt",
+  "BC_CALLT_Z",
+  "vmeta_for",
+  "ff_assert",
+  "fff_fallback",
+  "fff_res",
+  "ff_type",
+  "fff_resn",
+  "ff_getmetatable",
+  "fff_restv",
+  "ff_setmetatable",
+  "ff_rawget",
+  "ff_tonumber",
+  "ff_tostring",
+  "fff_gcstep",
+  "ff_next",
+  "ff_pairs",
+  "ff_ipairs_aux",
+  "ff_ipairs",
+  "ff_pcall",
+  "ff_xpcall",
+  "ff_coroutine_resume",
+  "ff_coroutine_wrap_aux",
+  "ff_coroutine_yield",
+  "ff_math_abs",
+  "fff_resi",
+  "fff_res1",
+  "ff_math_floor",
+  "ff_math_ceil",
+  "ff_math_sqrt",
+  "ff_math_log",
+  "ff_math_log10",
+  "ff_math_exp",
+  "ff_math_sin",
+  "ff_math_cos",
+  "ff_math_tan",
+  "ff_math_asin",
+  "ff_math_acos",
+  "ff_math_atan",
+  "ff_math_sinh",
+  "ff_math_cosh",
+  "ff_math_tanh",
+  "ff_math_pow",
+  "ff_math_atan2",
+  "ff_math_fmod",
+  "ff_math_deg",
+  "ff_math_rad",
+  "ff_math_ldexp",
+  "ff_math_frexp",
+  "ff_math_modf",
+  "ff_math_min",
+  "ff_math_max",
+  "ff_string_len",
+  "ff_string_byte",
+  "ff_string_char",
+  "fff_newstr",
+  "ff_string_sub",
+  "ff_string_rep",
+  "ff_string_reverse",
+  "ff_string_lower",
+  "ff_string_upper",
+  "ff_table_getn",
+  "ff_bit_band",
+  "fff_tobit_fb",
+  "fff_bitop_fb",
+  "ff_bit_bor",
+  "ff_bit_bxor",
+  "ff_bit_bswap",
+  "ff_bit_bnot",
+  "ff_bit_lshift",
+  "ff_bit_rshift",
+  "ff_bit_arshift",
+  "ff_bit_rol",
+  "ff_bit_ror",
+  "ff_bit_tobit",
+  "vm_record",
+  "vm_rethook",
+  "vm_inshook",
+  "cont_hook",
+  "vm_hotloop",
+  "vm_callhook",
+  "vm_hotcall",
+  "vm_exit_handler",
+  "vm_exit_interp",
+  "vm_floor",
+  "vm_ceil",
+  "vm_trunc",
+  "vm_modi",
+  "vm_foldarith",
+  "vm_ffi_callback",
+  "vm_ffi_call",
+  "BC_ISEQN_Z",
+  "BC_ISNEN_Z",
+  "BC_MODVN_Z",
+  "BC_TGETS_Z",
+  "BC_TSETS_Z",
+  "BC_RETV_Z",
+  (const char *)0
+};
+static const char *const extnames[] = {
+  "lj_state_growstack",
+  "lj_meta_tget",
+  "lj_meta_tset",
+  "lj_meta_comp",
+  "lj_meta_equal",
+  "lj_meta_equal_cd",
+  "lj_meta_arith",
+  "lj_meta_len",
+  "lj_meta_call",
+  "lj_meta_for",
+  "lj_tab_get",
+  "lj_str_fromnumber",
+  "lj_str_fromnum",
+  "lj_tab_next",
+  "lj_tab_getinth",
+  "lj_ffh_coroutine_wrap_err",
+  "floor",
+  "ceil",
+  "sqrt",
+  "log",
+  "log10",
+  "exp",
+  "sin",
+  "cos",
+  "tan",
+  "asin",
+  "acos",
+  "atan",
+  "sinh",
+  "cosh",
+  "tanh",
+  "pow",
+  "atan2",
+  "fmod",
+  "ldexp",
+  "frexp",
+  "modf",
+  "lj_str_new",
+  "lj_tab_len",
+  "lj_gc_step",
+  "lj_dispatch_ins",
+  "lj_trace_hot",
+  "lj_dispatch_call",
+  "lj_trace_exit",
+  "lj_err_throw",
+  "trunc",
+  "lj_ccallback_enter",
+  "lj_ccallback_leave",
+  "lj_meta_cat",
+  "lj_gc_barrieruv",
+  "lj_func_closeuv",
+  "lj_func_newL_gc",
+  "lj_tab_new",
+  "lj_tab_dup",
+  "lj_gc_step_fixtop",
+  "lj_tab_newkey",
+  "lj_tab_reasize",
+  (const char *)0
+};
+#define Dt1(_V) (int)(ptrdiff_t)&(((lua_State *)0)_V)
+#define Dt2(_V) (int)(ptrdiff_t)&(((global_State *)0)_V)
+#define Dt3(_V) (int)(ptrdiff_t)&(((TValue *)0)_V)
+#define Dt4(_V) (int)(ptrdiff_t)&(((GCobj *)0)_V)
+#define Dt5(_V) (int)(ptrdiff_t)&(((GCstr *)0)_V)
+#define Dt6(_V) (int)(ptrdiff_t)&(((GCtab *)0)_V)
+#define Dt7(_V) (int)(ptrdiff_t)&(((GCfuncL *)0)_V)
+#define Dt8(_V) (int)(ptrdiff_t)&(((GCfuncC *)0)_V)
+#define Dt9(_V) (int)(ptrdiff_t)&(((GCproto *)0)_V)
+#define DtA(_V) (int)(ptrdiff_t)&(((GCupval *)0)_V)
+#define DtB(_V) (int)(ptrdiff_t)&(((Node *)0)_V)
+#define DtC(_V) (int)(ptrdiff_t)&(((int *)0)_V)
+#define DtD(_V) (int)(ptrdiff_t)&(((GCtrace *)0)_V)
+#define DISPATCH_GL(field)	(GG_DISP2G + (int)offsetof(global_State, field))
+#define DISPATCH_J(field)	(GG_DISP2J + (int)offsetof(jit_State, field))
+#define PC2PROTO(field)  ((int)offsetof(GCproto, field)-(int)sizeof(GCproto))
+
+/* Generate subroutines used by opcodes and other parts of the VM. */
+/* The .code_sub section should be last to help static branch prediction. */
+static void build_subroutines(BuildCtx *ctx)
+{
+  dasm_put(Dst, 0);
+  dasm_put(Dst, 1, FRAME_P, LJ_TTRUE, FRAME_TYPE, FRAME_C, ~LJ_VMST_C, Dt1(->base), DISPATCH_GL(vmstate), 31-3, Dt1(->top));
+  dasm_put(Dst, 55, Dt1(->cframe), 56+(14-14)*4, 128+(14-14)*8, 56+(15-14)*4, 128+(15-14)*8, 56+(16-14)*4, 128+(16-14)*8, 56+(17-14)*4, 128+(17-14)*8, 56+(18-14)*4, 128+(18-14)*8, 56+(19-14)*4, 128+(19-14)*8, 56+(20-14)*4, 128+(20-14)*8, 56+(21-14)*4, 128+(21-14)*8, 56+(22-14)*4, 128+(22-14)*8, 56+(23-14)*4, 128+(23-14)*8);
+  dasm_put(Dst, 105, 56+(24-14)*4, 128+(24-14)*8, 56+(25-14)*4, 128+(25-14)*8, 56+(26-14)*4, 128+(26-14)*8, 56+(27-14)*4, 128+(27-14)*8, 56+(28-14)*4, 128+(28-14)*8, 56+(29-14)*4, 128+(29-14)*8, 56+(30-14)*4, 128+(30-14)*8, 56+(31-14)*4, 128+(31-14)*8, Dt1(->maxstack));
+  dasm_put(Dst, 154, Dt1(->top), 31-3, Dt1(->top), ~LJ_VMST_C, Dt1(->glref), Dt2(->vmstate), LJ_TISNUM, Dt1(->base), Dt1(->glref), LJ_TFALSE, LJ_TNIL, ~LJ_VMST_INTERP, GG_G2DISP);
+  dasm_put(Dst, 217, DISPATCH_GL(vmstate), LUA_MINSTACK, Dt1(->base), Dt1(->top), 32-3, Dt1(->base), Dt1(->top), Dt7(->pc), 56+(14-14)*4, 128+(14-14)*8, 56+(15-14)*4, 128+(15-14)*8, 56+(16-14)*4, 128+(16-14)*8, 56+(17-14)*4);
+  dasm_put(Dst, 278, 128+(17-14)*8, 56+(18-14)*4, 128+(18-14)*8, 56+(19-14)*4, 128+(19-14)*8, 56+(20-14)*4, 128+(20-14)*8, 56+(21-14)*4, 128+(21-14)*8, 56+(22-14)*4, 128+(22-14)*8, 56+(23-14)*4, 128+(23-14)*8, 56+(24-14)*4, 128+(24-14)*8, 56+(25-14)*4, 128+(25-14)*8, 56+(26-14)*4, 128+(26-14)*8, 56+(27-14)*4, 128+(27-14)*8, 56+(28-14)*4);
+  dasm_put(Dst, 325, 128+(28-14)*8, 56+(29-14)*4, 128+(29-14)*8, 56+(30-14)*4, 128+(30-14)*8, 56+(31-14)*4, 128+(31-14)*8, Dt1(->glref), Dt1(->status), FRAME_CP, CFRAME_RESUME, GG_G2DISP, Dt1(->cframe), Dt1(->base), LJ_TISNUM, Dt1(->top), Dt1(->status), FRAME_TYPE, ~LJ_VMST_INTERP, LJ_TNIL, DISPATCH_GL(vmstate));
+  dasm_put(Dst, 393, 56+(14-14)*4, 128+(14-14)*8, 56+(15-14)*4, 128+(15-14)*8, 56+(16-14)*4, 128+(16-14)*8, 56+(17-14)*4, 128+(17-14)*8, 56+(18-14)*4, 128+(18-14)*8, 56+(19-14)*4, 128+(19-14)*8, 56+(20-14)*4, 128+(20-14)*8, 56+(21-14)*4, 128+(21-14)*8, 56+(22-14)*4, 128+(22-14)*8, 56+(23-14)*4);
+  dasm_put(Dst, 440, 128+(23-14)*8, 56+(24-14)*4, 128+(24-14)*8, 56+(25-14)*4, 128+(25-14)*8, 56+(26-14)*4, 128+(26-14)*8, 56+(27-14)*4, 128+(27-14)*8, 56+(28-14)*4, 128+(28-14)*8, 56+(29-14)*4, 128+(29-14)*8, 56+(30-14)*4, 128+(30-14)*8, 56+(31-14)*4, 128+(31-14)*8, FRAME_CP, 56+(14-14)*4, 128+(14-14)*8);
+  dasm_put(Dst, 488, 56+(15-14)*4, 128+(15-14)*8, 56+(16-14)*4, 128+(16-14)*8, 56+(17-14)*4, 128+(17-14)*8, 56+(18-14)*4, 128+(18-14)*8, 56+(19-14)*4, 128+(19-14)*8, 56+(20-14)*4, 128+(20-14)*8, 56+(21-14)*4, 128+(21-14)*8, 56+(22-14)*4, 128+(22-14)*8, 56+(23-14)*4, 128+(23-14)*8, 56+(24-14)*4, 128+(24-14)*8, 56+(25-14)*4, 128+(25-14)*8);
+  dasm_put(Dst, 535, 56+(26-14)*4, 128+(26-14)*8, 56+(27-14)*4, 128+(27-14)*8, 56+(28-14)*4, 128+(28-14)*8, 56+(29-14)*4, 128+(29-14)*8, 56+(30-14)*4, 128+(30-14)*8, 56+(31-14)*4, 128+(31-14)*8, FRAME_C, Dt1(->cframe), Dt1(->cframe), Dt1(->glref), GG_G2DISP, Dt1(->base), LJ_TISNUM, Dt1(->top));
+  dasm_put(Dst, 586, ~LJ_VMST_INTERP, LJ_TNIL, DISPATCH_GL(vmstate), LJ_TFUNC, Dt7(->pc), 56+(14-14)*4, 128+(14-14)*8, 56+(15-14)*4, 128+(15-14)*8, 56+(16-14)*4, 128+(16-14)*8, 56+(17-14)*4, 128+(17-14)*8, 56+(18-14)*4, 128+(18-14)*8, 56+(19-14)*4, 128+(19-14)*8, 56+(20-14)*4);
+  dasm_put(Dst, 653, 128+(20-14)*8, 56+(21-14)*4, 128+(21-14)*8, 56+(22-14)*4, 128+(22-14)*8, 56+(23-14)*4, 128+(23-14)*8, 56+(24-14)*4, 128+(24-14)*8, 56+(25-14)*4, 128+(25-14)*8, 56+(26-14)*4, 128+(26-14)*8, 56+(27-14)*4, 128+(27-14)*8, 56+(28-14)*4, 128+(28-14)*8, 56+(29-14)*4, 128+(29-14)*8, 56+(30-14)*4, 128+(30-14)*8, 56+(31-14)*4);
+  dasm_put(Dst, 700, 128+(31-14)*8, Dt1(->stack), Dt1(->top), Dt1(->cframe), Dt1(->cframe), Dt1(->glref), FRAME_CP, GG_G2DISP);
+#if LJ_HASFFI
+  dasm_put(Dst, 738);
+#endif
+  dasm_put(Dst, 740, Dt7(->pc));
+#if LJ_HASFFI
+  dasm_put(Dst, 746);
+#endif
+  dasm_put(Dst, 749, PC2PROTO(k));
+#if LJ_HASFFI
+  dasm_put(Dst, 754);
+#endif
+  dasm_put(Dst, 762, Dt1(->base), DISPATCH_GL(tmptv), LJ_TSTR, DISPATCH_GL(tmptv), LJ_TTAB, DISPATCH_GL(tmptv2), LJ_TSTR);
+  if (!LJ_DUALNUM) {
+    dasm_put(Dst, 807);
+  }
+  dasm_put(Dst, 811, DISPATCH_GL(tmptv));
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 816);
+  } else {
+    dasm_put(Dst, 819);
+  }
+  dasm_put(Dst, 821, Dt1(->base), FRAME_CONT, Dt1(->top), DISPATCH_GL(tmptv), LJ_TSTR, DISPATCH_GL(tmptv), LJ_TTAB, DISPATCH_GL(tmptv2), LJ_TSTR);
+  if (!LJ_DUALNUM) {
+    dasm_put(Dst, 889);
+  }
+  dasm_put(Dst, 893, DISPATCH_GL(tmptv));
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 898);
+  } else {
+    dasm_put(Dst, 901);
+  }
+  dasm_put(Dst, 903, Dt1(->base), FRAME_CONT, Dt1(->top));
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 948);
+  } else {
+    dasm_put(Dst, 950);
+  }
+  dasm_put(Dst, 952);
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 954);
+  } else {
+    dasm_put(Dst, 956);
+  }
+  dasm_put(Dst, 958, Dt1(->base), -(BCBIAS_J*4 >> 16), LJ_TTRUE, LJ_TTRUE, Dt1(->base));
+#if LJ_HASFFI
+  dasm_put(Dst, 1021, Dt1(->base));
+#endif
+  dasm_put(Dst, 1032);
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 1039);
+  }
+  dasm_put(Dst, 1044);
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 1058);
+  }
+  dasm_put(Dst, 1061);
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 1064);
+  }
+  dasm_put(Dst, 1067, Dt1(->base), FRAME_CONT);
+#ifdef LUAJIT_ENABLE_LUA52COMPAT
+  dasm_put(Dst, 1091);
+#endif
+  dasm_put(Dst, 1093, Dt1(->base));
+#ifdef LUAJIT_ENABLE_LUA52COMPAT
+  dasm_put(Dst, 1101);
+#else
+  dasm_put(Dst, 1108);
+#endif
+  dasm_put(Dst, 1111, Dt1(->base), Dt7(->pc), Dt1(->base), Dt1(->base));
+#if LJ_HASJIT
+  dasm_put(Dst, 1159);
+#endif
+  dasm_put(Dst, 1161);
+#if LJ_HASJIT
+  dasm_put(Dst, 1163, BC_JFORI);
+#endif
+  dasm_put(Dst, 1166);
+#if LJ_HASJIT
+  dasm_put(Dst, 1168, BC_JFORI);
+#endif
+  dasm_put(Dst, 1171, BC_FORI, LJ_TFALSE, ~LJ_TISNUM+1, 31-3, Dt8(->upvalue), LJ_TTAB, Dt6(->metatable));
+  dasm_put(Dst, 1234, LJ_TNIL, DISPATCH_GL(gcroot[GCROOT_MMNAME+MM_metatable]), Dt6(->hmask), LJ_TTAB, Dt5(->hash), Dt6(->node), 31-5, 31-3, DtB(->key), 4+offsetof(Node, key), DtB(->val), 4+offsetof(Node, val), LJ_TSTR, DtB(->next));
+  dasm_put(Dst, 1282, LJ_TNIL, LJ_TUDATA, ~LJ_TISNUM+1, 31-2, DISPATCH_GL(gcroot[GCROOT_BASEMT]), LJ_TTAB, Dt6(->metatable), LJ_TTAB, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable));
+  dasm_put(Dst, 1337, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist), LJ_TTAB, LJ_TSTR, DISPATCH_GL(gcroot[GCROOT_BASEMT_NUM]), Dt1(->base));
+  dasm_put(Dst, 1397, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 1407);
+  } else {
+    dasm_put(Dst, 1410);
+  }
+  dasm_put(Dst, 1413, LJ_TSTR, LJ_TTAB, Dt1(->base), Dt1(->top), LJ_TNIL, (2+1)*8, LJ_TTAB);
+#ifdef LUAJIT_ENABLE_LUA52COMPAT
+  dasm_put(Dst, 1464, Dt6(->metatable), Dt8(->upvalue[0]));
+#else
+  dasm_put(Dst, 1473, Dt8(->upvalue[0]));
+#endif
+  dasm_put(Dst, 1477, (3+1)*8);
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 1489);
+  } else {
+    dasm_put(Dst, 1491);
+  }
+  dasm_put(Dst, 1493, LJ_TTAB);
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 1500);
+  } else {
+    dasm_put(Dst, 1505);
+  }
+  dasm_put(Dst, 1517, Dt6(->asize), Dt6(->array));
+  if (!LJ_DUALNUM) {
+    dasm_put(Dst, 1522);
+  }
+  dasm_put(Dst, 1524);
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 1528, 31-3);
+  } else {
+    dasm_put(Dst, 1533, 31-3);
+  }
+  dasm_put(Dst, 1537, LJ_TNIL, (0+1)*8, (2+1)*8, Dt6(->hmask), (0+1)*8, (0+1)*8, LJ_TTAB);
+#ifdef LUAJIT_ENABLE_LUA52COMPAT
+  dasm_put(Dst, 1585, Dt6(->metatable), Dt8(->upvalue[0]));
+#else
+  dasm_put(Dst, 1594, Dt8(->upvalue[0]));
+#endif
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 1598);
+  } else {
+    dasm_put(Dst, 1600);
+  }
+  dasm_put(Dst, 1602, (3+1)*8, DISPATCH_GL(hookmask), 32-HOOK_ACTIVE_SHIFT, 8+FRAME_PCALL, DISPATCH_GL(hookmask), LJ_TFUNC, 32-HOOK_ACTIVE_SHIFT, 16+FRAME_PCALL, LJ_TTHREAD, Dt1(->status), Dt1(->cframe));
+  dasm_put(Dst, 1663, Dt1(->top), LUA_YIELD, Dt1(->base), Dt1(->maxstack), Dt1(->base), Dt1(->top), Dt1(->top), Dt1(->base), LUA_YIELD, Dt1(->top), ~LJ_VMST_INTERP, Dt1(->base), DISPATCH_GL(vmstate));
+  dasm_put(Dst, 1725, Dt1(->maxstack), Dt1(->top), FRAME_TYPE, LJ_TTRUE, FRAME_TYPE, LJ_TFALSE, Dt1(->top), (2+1)*8, 32-3);
+  dasm_put(Dst, 1788, Dt8(->upvalue[0].gcr), Dt1(->status), Dt1(->cframe), Dt1(->top), LUA_YIELD, Dt1(->base), Dt1(->maxstack), Dt1(->base), Dt1(->top), Dt1(->top), Dt1(->base), LUA_YIELD, Dt1(->top), ~LJ_VMST_INTERP);
+  dasm_put(Dst, 1847, Dt1(->base), DISPATCH_GL(vmstate), Dt1(->maxstack), Dt1(->top), FRAME_TYPE, 32-3, Dt1(->cframe));
+  dasm_put(Dst, 1904, Dt1(->base), CFRAME_RESUME, Dt1(->top), LUA_YIELD, Dt1(->cframe), Dt1(->status));
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 1929);
+  }
+  dasm_put(Dst, 1950, (1+1)*8, FRAME_TYPE);
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 1992, 31-11, 32-21, 31-11);
+    dasm_put(Dst, 2074, 31-11, 32-21, 31-11);
+  } else {
+    dasm_put(Dst, 2128);
+  }
+  dasm_put(Dst, 2155);
+  dasm_put(Dst, 2214);
+  dasm_put(Dst, 2272);
+  dasm_put(Dst, 2328, Dt8(->upvalue[0]));
+  dasm_put(Dst, 2394);
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 2398);
+  } else {
+    dasm_put(Dst, 2413);
+  }
+  dasm_put(Dst, 2431, DISPATCH_GL(tmptv), DISPATCH_GL(tmptv));
+  if (!LJ_DUALNUM) {
+    dasm_put(Dst, 2453);
+  }
+  dasm_put(Dst, 2458, (2+1)*8);
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 2462);
+  } else {
+    dasm_put(Dst, 2465);
+  }
+  dasm_put(Dst, 2467, (2+1)*8);
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 2489);
+  } else {
+  dasm_put(Dst, 2558);
+  }
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 2583);
+  } else {
+  dasm_put(Dst, 2652);
+  }
+  dasm_put(Dst, 2677, LJ_TSTR, Dt5(->len), LJ_TSTR, Dt5(->len));
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 2704, Dt5([1]), (0+1)*8);
+  } else {
+    dasm_put(Dst, 2716, Dt5([1]), 31-3);
+  }
+  dasm_put(Dst, 2732, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 2743);
+  } else {
+    dasm_put(Dst, 2751);
+  }
+  dasm_put(Dst, 2762, Dt1(->base), Dt1(->base), LJ_TSTR, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
+  if (!LJ_DUALNUM) {
+    dasm_put(Dst, 2790);
+  }
+  dasm_put(Dst, 2792);
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 2798);
+  } else {
+    dasm_put(Dst, 2800);
+  }
+  dasm_put(Dst, 2802);
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 2806);
+  } else {
+    dasm_put(Dst, 2815);
+  }
+  dasm_put(Dst, 2826, LJ_TSTR);
+  if (!LJ_DUALNUM) {
+    dasm_put(Dst, 2831);
+  }
+  dasm_put(Dst, 2835, Dt5(->len), sizeof(GCstr)-1, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 2885);
+  } else {
+    dasm_put(Dst, 2887);
+  }
+  dasm_put(Dst, 2889, LJ_TSTR);
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 2896);
+  } else {
+    dasm_put(Dst, 2900);
+  }
+  dasm_put(Dst, 2907, Dt5(->len), DISPATCH_GL(tmpbuf.sz), Dt5([1]), DISPATCH_GL(tmpbuf.buf), DISPATCH_GL(strempty), LJ_TSTR, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, DISPATCH_GL(tmpbuf.sz));
+  dasm_put(Dst, 2960, Dt5(->len), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, DISPATCH_GL(tmpbuf.sz), Dt5(->len), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf));
+  dasm_put(Dst, 3018, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, DISPATCH_GL(tmpbuf.sz), Dt5(->len), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf), LJ_TTAB);
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 3087);
+  } else {
+  dasm_put(Dst, 3097);
+  }
+  dasm_put(Dst, 3110);
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 3116);
+  } else {
+  dasm_put(Dst, 3118);
+  }
+  dasm_put(Dst, 3120);
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 3124);
+  } else {
+  dasm_put(Dst, 3127);
+  }
+  dasm_put(Dst, 3133);
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 3138);
+  } else {
+  dasm_put(Dst, 3148);
+  }
+  dasm_put(Dst, 3161);
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 3167);
+  } else {
+  dasm_put(Dst, 3169);
+  }
+  dasm_put(Dst, 3171);
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 3175);
+  } else {
+  dasm_put(Dst, 3178);
+  }
+  dasm_put(Dst, 3184);
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 3189);
+  } else {
+  dasm_put(Dst, 3199);
+  }
+  dasm_put(Dst, 3212);
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 3218);
+  } else {
+  dasm_put(Dst, 3220);
+  }
+  dasm_put(Dst, 3222);
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 3226);
+  } else {
+  dasm_put(Dst, 3229);
+  }
+  dasm_put(Dst, 3235);
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 3240);
+  } else {
+  dasm_put(Dst, 3250);
+  }
+  dasm_put(Dst, 3263);
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 3270);
+  } else {
+  dasm_put(Dst, 3280);
+  }
+  dasm_put(Dst, 3293);
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 3297);
+  } else {
+  dasm_put(Dst, 3312);
+  }
+  dasm_put(Dst, 3333);
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 3338);
+  } else {
+  dasm_put(Dst, 3353);
+  }
+  dasm_put(Dst, 3374);
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 3379);
+  } else {
+  dasm_put(Dst, 3394);
+  }
+  dasm_put(Dst, 3415);
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 3420);
+  } else {
+  dasm_put(Dst, 3435);
+  }
+  dasm_put(Dst, 3456);
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 3460);
+  } else {
+  dasm_put(Dst, 3475);
+  }
+  dasm_put(Dst, 3496);
+  if (LJ_DUALNUM) {
+  dasm_put(Dst, 3501);
+  } else {
+  dasm_put(Dst, 3511);
+  }
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 3524);
+  } else {
+    dasm_put(Dst, 3527);
+  }
+  dasm_put(Dst, 3533);
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 3541);
+  }
+  dasm_put(Dst, 3549);
+  if (LJ_DUALNUM) {
+    dasm_put(Dst, 3551);
+  }
+  dasm_put(Dst, 3559, Dt8(->f), 8*LUA_MINSTACK, Dt1(->maxstack), Dt1(->base), Dt1(->top), Dt1(->base), 31-3, Dt1(->top), Dt7(->pc), FRAME_TYPE, LUA_MINSTACK);
+  dasm_put(Dst, 3622, Dt1(->base), Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top));
+#if LJ_HASJIT
+  dasm_put(Dst, 3648, DISPATCH_GL(hookmask), HOOK_VMEVENT, DISPATCH_GL(hookcount), HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount));
+#endif
+  dasm_put(Dst, 3670, DISPATCH_GL(hookmask), HOOK_ACTIVE, GG_DISP2STATIC, DISPATCH_GL(hookmask), DISPATCH_GL(hookcount), HOOK_ACTIVE, 31-LUA_HOOKLINE, DISPATCH_GL(hookcount), Dt1(->base), Dt1(->base));
+  dasm_put(Dst, 3717, GG_DISP2STATIC);
+#if LJ_HASJIT
+  dasm_put(Dst, 3735, GG_DISP2J, Dt7(->pc), DISPATCH_J(L), PC2PROTO(framesize), Dt1(->base), 31-3, Dt1(->top));
+#endif
+  dasm_put(Dst, 3758);
+#if LJ_HASJIT
+  dasm_put(Dst, 3761);
+#endif
+  dasm_put(Dst, 3764);
+#if LJ_HASJIT
+  dasm_put(Dst, 3766);
+#endif
+  dasm_put(Dst, 3769, Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top));
+#if LJ_HASJIT
+  dasm_put(Dst, 3792, -(16+32*8+32*4), 16+32*8+2*4, -GG_DISP2G-32768, ~LJ_VMST_EXIT, 16+32*8+32*4, DISPATCH_GL(vmstate), 16+0*8, 16+1*8, 16+2*8, 16+3*8, 16+4*8, 16+5*8, 16+6*8, 16+7*8, 16+32*8+32*4, 16+8*8, 16+9*8, 16+10*8, 16+11*8, 16+32*8+1*4, 16+12*8, 16+13*8);
+  dasm_put(Dst, 3839, 16+14*8, 16+15*8, 16+16*8, 16+17*8, 16+18*8, 16+19*8, 16+32*8+0*4, 16+20*8, 16+21*8, 16+22*8, 16+23*8, 16+24*8, 16+25*8, 16+26*8, 16+27*8, DISPATCH_GL(jit_L), 16+28*8, 16+29*8, 16+30*8, 16+31*8, DISPATCH_GL(jit_base), 32-2);
+  dasm_put(Dst, 3888, DISPATCH_J(L), DISPATCH_GL(jit_L), DISPATCH_J(parent), Dt1(->base), GG_DISP2J, DISPATCH_J(exitno), Dt1(->cframe), Dt1(->base));
+#endif
+  dasm_put(Dst, 3916);
+#if LJ_HASJIT
+  dasm_put(Dst, 3918, -GG_DISP2G-32768, 31-3, Dt7(->pc), DISPATCH_GL(jit_L), PC2PROTO(k), LJ_TISNUM, LJ_TNIL, DISPATCH_GL(vmstate), BC_FUNCF*4);
+#endif
+  dasm_put(Dst, 3975);
+#if LJ_HASJIT
+  dasm_put(Dst, 3983);
+#endif
+  dasm_put(Dst, 3986);
+#if LJ_HASJIT
+  dasm_put(Dst, 4066);
+#else
+  dasm_put(Dst, 4088);
+#endif
+  dasm_put(Dst, 4090);
+#if LJ_HASFFI
+#define DtE(_V) (int)(ptrdiff_t)&(((CTState *)0)_V)
+  dasm_put(Dst, 4092, 56+(14-14)*4, 128+(14-14)*8, 56+(15-14)*4, 128+(15-14)*8, 56+(16-14)*4, 128+(16-14)*8, 56+(17-14)*4, 128+(17-14)*8, 56+(18-14)*4, 128+(18-14)*8, 56+(19-14)*4, 128+(19-14)*8, 56+(20-14)*4, 128+(20-14)*8, 56+(21-14)*4, 128+(21-14)*8, 56+(22-14)*4, 128+(22-14)*8, 56+(23-14)*4, 128+(23-14)*8, 56+(24-14)*4, 128+(24-14)*8);
+  dasm_put(Dst, 4140, 56+(25-14)*4, 128+(25-14)*8, 56+(26-14)*4, 128+(26-14)*8, 56+(27-14)*4, 128+(27-14)*8, 56+(28-14)*4, 128+(28-14)*8, 56+(29-14)*4, 128+(29-14)*8, 56+(30-14)*4, 128+(30-14)*8, 56+(31-14)*4, 128+(31-14)*8, Dt2(->ctype_state), GG_G2DISP, DtE(->cb.slot), DtE(->cb.gpr[0]), DtE(->cb.fpr[0]), DtE(->cb.gpr[1]), DtE(->cb.fpr[1]), DtE(->cb.gpr[2]));
+  dasm_put(Dst, 4187, DtE(->cb.fpr[2]), DtE(->cb.gpr[3]), DtE(->cb.fpr[3]), DtE(->cb.gpr[4]), DtE(->cb.fpr[4]), DtE(->cb.gpr[5]), DtE(->cb.fpr[5]), DtE(->cb.gpr[6]), DtE(->cb.fpr[6]), DtE(->cb.gpr[7]), DtE(->cb.fpr[7]), 272+8, DtE(->cb.stack), Dt1(->base), LJ_TISNUM, Dt1(->top), LJ_TNIL, ~LJ_VMST_INTERP, DISPATCH_GL(vmstate), Dt7(->pc));
+#endif
+  dasm_put(Dst, 4251);
+#if LJ_HASFFI
+  dasm_put(Dst, 4253, DISPATCH_GL(ctype_state), Dt1(->base), Dt1(->top), DtE(->L), DtE(->cb.gpr[0]), DtE(->cb.fpr[0]), DtE(->cb.gpr[1]));
+#endif
+  dasm_put(Dst, 4274);
+#if LJ_HASFFI
+#define DtF(_V) (int)(ptrdiff_t)&(((CCallState *)0)_V)
+  dasm_put(Dst, 4276, DtF(->spadj), DtF(->nsp), DtF(->nfpr), DtF(->stack), 31-2, DtF(->fpr[0]), DtF(->fpr[1]), DtF(->fpr[2]), DtF(->fpr[3]), DtF(->fpr[4]), DtF(->fpr[5]), DtF(->fpr[6]), DtF(->fpr[7]), DtF(->func), DtF(->gpr[1]), DtF(->gpr[2]));
+  dasm_put(Dst, 4334, DtF(->gpr[3]), DtF(->gpr[4]), DtF(->gpr[5]), DtF(->gpr[6]), DtF(->gpr[7]), DtF(->gpr[0]), DtF(->gpr[0]), DtF(->fpr[0]), DtF(->gpr[1]), DtF(->gpr[2]), DtF(->gpr[3]));
+#endif
+}
+
+/* Generate the code for a single instruction. */
+static void build_ins(BuildCtx *ctx, BCOp op, int defop)
+{
+  int vk = 0;
+  dasm_put(Dst, 4366, defop);
+
+  switch (op) {
+
+  /* -- Comparison ops ---------------------------------------------------- */
+
+  /* Remember: all ops branch for a true comparison, fall through otherwise. */
+
+  case BC_ISLT: case BC_ISGE: case BC_ISLE: case BC_ISGT:
+    if (LJ_DUALNUM) {
+      dasm_put(Dst, 4368, -(BCBIAS_J*4 >> 16));
+      if (op == BC_ISLT) {
+	dasm_put(Dst, 4385);
+      } else if (op == BC_ISGE) {
+	dasm_put(Dst, 4388);
+      } else if (op == BC_ISLE) {
+	dasm_put(Dst, 4391);
+      } else {
+	dasm_put(Dst, 4394);
+      }
+      dasm_put(Dst, 4397);
+      if (op == BC_ISLT) {
+	dasm_put(Dst, 4436);
+      } else if (op == BC_ISGE) {
+	dasm_put(Dst, 4439);
+      } else if (op == BC_ISLE) {
+	dasm_put(Dst, 4442);
+      } else {
+	dasm_put(Dst, 4446);
+      }
+      dasm_put(Dst, 4450);
+    } else {
+      dasm_put(Dst, 4453, -(BCBIAS_J*4 >> 16));
+      if (op == BC_ISLT) {
+	dasm_put(Dst, 4470);
+      } else if (op == BC_ISGE) {
+	dasm_put(Dst, 4473);
+      } else if (op == BC_ISLE) {
+	dasm_put(Dst, 4476);
+      } else {
+	dasm_put(Dst, 4480);
+      }
+      dasm_put(Dst, 4484);
+    }
+    break;
+
+  case BC_ISEQV: case BC_ISNEV:
+    vk = op == BC_ISEQV;
+    if (LJ_DUALNUM) {
+      dasm_put(Dst, 4497, -(BCBIAS_J*4 >> 16));
+      if (vk) {
+	dasm_put(Dst, 4510);
+      } else {
+	dasm_put(Dst, 4513);
+      }
+    } else {
+      dasm_put(Dst, 4516, -(BCBIAS_J*4 >> 16));
+      if (vk) {
+	dasm_put(Dst, 4533);
+      } else {
+	dasm_put(Dst, 4537);
+      }
+      dasm_put(Dst, 4541);
+    }
+    dasm_put(Dst, 4553);
+    if (!LJ_DUALNUM) {
+      dasm_put(Dst, 4555);
+    }
+    if (LJ_HASFFI) {
+      dasm_put(Dst, 4558, LJ_TCDATA, LJ_TCDATA);
+    }
+    dasm_put(Dst, 4563, ~LJ_TISPRI);
+    if (LJ_HASFFI) {
+      dasm_put(Dst, 4568);
+    }
+    dasm_put(Dst, 4570, ~LJ_TISTABUD);
+    if (LJ_HASFFI) {
+      dasm_put(Dst, 4573);
+    }
+    dasm_put(Dst, 4576);
+    if (vk) {
+      dasm_put(Dst, 4584);
+    } else {
+      dasm_put(Dst, 4589);
+    }
+    if (LJ_DUALNUM) {
+      dasm_put(Dst, 4594);
+    } else {
+      dasm_put(Dst, 4609);
+    }
+    dasm_put(Dst, 4612, Dt6(->metatable), 1-vk, Dt6(->nomm), 1<<MM_eq);
+    break;
+
+  case BC_ISEQS: case BC_ISNES:
+    vk = op == BC_ISEQS;
+    dasm_put(Dst, 4631, 32-1);
+    if (LJ_HASFFI) {
+      dasm_put(Dst, 4639, LJ_TCDATA);
+    }
+    dasm_put(Dst, 4642, LJ_TSTR);
+    if (LJ_HASFFI) {
+      dasm_put(Dst, 4646);
+    }
+    dasm_put(Dst, 4649, -(BCBIAS_J*4 >> 16));
+    if (vk) {
+      dasm_put(Dst, 4657);
+    } else {
+      dasm_put(Dst, 4659);
+    }
+    dasm_put(Dst, 4661);
+    break;
+
+  case BC_ISEQN: case BC_ISNEN:
+    vk = op == BC_ISEQN;
+    if (LJ_DUALNUM) {
+      dasm_put(Dst, 4673, -(BCBIAS_J*4 >> 16));
+      if (vk) {
+	dasm_put(Dst, 4685);
+      } else {
+	dasm_put(Dst, 4687);
+      }
+      dasm_put(Dst, 4689);
+    } else {
+      if (vk) {
+	dasm_put(Dst, 4696);
+      } else {
+	dasm_put(Dst, 4698);
+      }
+      dasm_put(Dst, 4700, -(BCBIAS_J*4 >> 16));
+    }
+    if (vk) {
+      dasm_put(Dst, 4713);
+      if (!LJ_HASFFI) {
+	dasm_put(Dst, 4718);
+      }
+    } else {
+      dasm_put(Dst, 4720);
+      if (!LJ_HASFFI) {
+	dasm_put(Dst, 4724);
+      }
+      dasm_put(Dst, 4726);
+    }
+    dasm_put(Dst, 4729);
+    if (LJ_HASFFI) {
+      dasm_put(Dst, 4740, LJ_TCDATA);
+    }
+    if (LJ_DUALNUM) {
+      dasm_put(Dst, 4748);
+    }
+    break;
+
+  case BC_ISEQP: case BC_ISNEP:
+    vk = op == BC_ISEQP;
+    dasm_put(Dst, 4772, 32-3);
+    if (LJ_HASFFI) {
+      dasm_put(Dst, 4779, LJ_TCDATA);
+    }
+    dasm_put(Dst, 4782);
+    if (LJ_HASFFI) {
+      dasm_put(Dst, 4784);
+    }
+    dasm_put(Dst, 4787, -(BCBIAS_J*4 >> 16));
+    if (vk) {
+      dasm_put(Dst, 4793);
+    } else {
+      dasm_put(Dst, 4795);
+    }
+    dasm_put(Dst, 4797);
+    break;
+
+  /* -- Unary test and copy ops ------------------------------------------- */
+
+  case BC_ISTC: case BC_ISFC: case BC_IST: case BC_ISF:
+    dasm_put(Dst, 4809);
+    if (op == BC_IST || op == BC_ISF) {
+      dasm_put(Dst, 4813, LJ_TTRUE, -(BCBIAS_J*4 >> 16));
+      if (op == BC_IST) {
+	dasm_put(Dst, 4820);
+      } else {
+	dasm_put(Dst, 4822);
+      }
+      dasm_put(Dst, 4824);
+    } else {
+      dasm_put(Dst, 4826, LJ_TFALSE);
+      if (op == BC_ISTC) {
+	dasm_put(Dst, 4831);
+      } else {
+	dasm_put(Dst, 4834);
+      }
+      dasm_put(Dst, 4837, -(BCBIAS_J*4 >> 16));
+    }
+    dasm_put(Dst, 4844);
+    break;
+
+  /* -- Unary ops --------------------------------------------------------- */
+
+  case BC_MOV:
+    dasm_put(Dst, 4855);
+    break;
+  case BC_NOT:
+    dasm_put(Dst, 4868, LJ_TTRUE);
+    break;
+  case BC_UNM:
+    dasm_put(Dst, 4884);
+    if (LJ_DUALNUM) {
+      dasm_put(Dst, 4888);
+    }
+    dasm_put(Dst, 4916);
+    if (LJ_DUALNUM) {
+      dasm_put(Dst, 4926);
+    } else {
+      dasm_put(Dst, 4929);
+    }
+    break;
+  case BC_LEN:
+    dasm_put(Dst, 4938, LJ_TSTR, Dt5(->len));
+    if (LJ_DUALNUM) {
+      dasm_put(Dst, 4948);
+    } else {
+      dasm_put(Dst, 4953);
+    }
+    dasm_put(Dst, 4960, LJ_TTAB);
+#ifdef LUAJIT_ENABLE_LUA52COMPAT
+    dasm_put(Dst, 4974, Dt6(->metatable));
+#endif
+    dasm_put(Dst, 4981);
+#ifdef LUAJIT_ENABLE_LUA52COMPAT
+    dasm_put(Dst, 4987, Dt6(->nomm), 1<<MM_len);
+#endif
+    break;
+
+  /* -- Binary ops -------------------------------------------------------- */
+
+
+  case BC_ADDVN: case BC_ADDNV: case BC_ADDVV:
+    if (LJ_DUALNUM) {
+    vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 4997);
+      break;
+    case 1:
+    dasm_put(Dst, 5003);
+      break;
+    default:
+    dasm_put(Dst, 5009);
+      break;
+    }
+    dasm_put(Dst, 5015);
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5042);
+      break;
+    case 1:
+    dasm_put(Dst, 5045);
+      break;
+    default:
+    dasm_put(Dst, 5048);
+      break;
+    }
+    dasm_put(Dst, 5051);
+    if (vk == 1) {
+    dasm_put(Dst, 5053);
+    } else {
+    dasm_put(Dst, 5057);
+    }
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5061);
+      break;
+    case 1:
+    dasm_put(Dst, 5064);
+      break;
+    default:
+    dasm_put(Dst, 5067);
+      break;
+    }
+    dasm_put(Dst, 5070);
+    } else {
+    vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5077);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5079);
+    }
+    dasm_put(Dst, 5081);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5084);
+    } else {
+    dasm_put(Dst, 5090);
+    }
+      break;
+    case 1:
+    dasm_put(Dst, 5094);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5096);
+    }
+    dasm_put(Dst, 5098);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5101);
+    } else {
+    dasm_put(Dst, 5107);
+    }
+      break;
+    default:
+    dasm_put(Dst, 5111);
+      break;
+    }
+    dasm_put(Dst, 5121);
+    }
+    break;
+  case BC_SUBVN: case BC_SUBNV: case BC_SUBVV:
+    if (LJ_DUALNUM) {
+    vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5134);
+      break;
+    case 1:
+    dasm_put(Dst, 5140);
+      break;
+    default:
+    dasm_put(Dst, 5146);
+      break;
+    }
+    dasm_put(Dst, 5152);
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5179);
+      break;
+    case 1:
+    dasm_put(Dst, 5182);
+      break;
+    default:
+    dasm_put(Dst, 5185);
+      break;
+    }
+    dasm_put(Dst, 5188);
+    if (vk == 1) {
+    dasm_put(Dst, 5190);
+    } else {
+    dasm_put(Dst, 5194);
+    }
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5198);
+      break;
+    case 1:
+    dasm_put(Dst, 5201);
+      break;
+    default:
+    dasm_put(Dst, 5204);
+      break;
+    }
+    dasm_put(Dst, 5207);
+    } else {
+    vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5214);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5216);
+    }
+    dasm_put(Dst, 5218);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5221);
+    } else {
+    dasm_put(Dst, 5227);
+    }
+      break;
+    case 1:
+    dasm_put(Dst, 5231);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5233);
+    }
+    dasm_put(Dst, 5235);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5238);
+    } else {
+    dasm_put(Dst, 5244);
+    }
+      break;
+    default:
+    dasm_put(Dst, 5248);
+      break;
+    }
+    dasm_put(Dst, 5258);
+    }
+    break;
+  case BC_MULVN: case BC_MULNV: case BC_MULVV:
+    if (LJ_DUALNUM) {
+    vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5271);
+      break;
+    case 1:
+    dasm_put(Dst, 5277);
+      break;
+    default:
+    dasm_put(Dst, 5283);
+      break;
+    }
+    dasm_put(Dst, 5289);
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5316);
+      break;
+    case 1:
+    dasm_put(Dst, 5319);
+      break;
+    default:
+    dasm_put(Dst, 5322);
+      break;
+    }
+    dasm_put(Dst, 5325);
+    if (vk == 1) {
+    dasm_put(Dst, 5327);
+    } else {
+    dasm_put(Dst, 5331);
+    }
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5335);
+      break;
+    case 1:
+    dasm_put(Dst, 5338);
+      break;
+    default:
+    dasm_put(Dst, 5341);
+      break;
+    }
+    dasm_put(Dst, 5344);
+    } else {
+    vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5351);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5353);
+    }
+    dasm_put(Dst, 5355);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5358);
+    } else {
+    dasm_put(Dst, 5364);
+    }
+      break;
+    case 1:
+    dasm_put(Dst, 5368);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5370);
+    }
+    dasm_put(Dst, 5372);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5375);
+    } else {
+    dasm_put(Dst, 5381);
+    }
+      break;
+    default:
+    dasm_put(Dst, 5385);
+      break;
+    }
+    dasm_put(Dst, 5395);
+    }
+    break;
+  case BC_DIVVN: case BC_DIVNV: case BC_DIVVV:
+    vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5408);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5410);
+    }
+    dasm_put(Dst, 5412);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5415);
+    } else {
+    dasm_put(Dst, 5421);
+    }
+      break;
+    case 1:
+    dasm_put(Dst, 5425);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5427);
+    }
+    dasm_put(Dst, 5429);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5432);
+    } else {
+    dasm_put(Dst, 5438);
+    }
+      break;
+    default:
+    dasm_put(Dst, 5442);
+      break;
+    }
+    dasm_put(Dst, 5452);
+    break;
+  case BC_MODVN:
+    if (LJ_DUALNUM) {
+    vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5465);
+      break;
+    case 1:
+    dasm_put(Dst, 5471);
+      break;
+    default:
+    dasm_put(Dst, 5477);
+      break;
+    }
+    dasm_put(Dst, 5483);
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5511);
+      break;
+    case 1:
+    dasm_put(Dst, 5514);
+      break;
+    default:
+    dasm_put(Dst, 5517);
+      break;
+    }
+    dasm_put(Dst, 5520);
+    if (vk == 1) {
+    dasm_put(Dst, 5522);
+    } else {
+    dasm_put(Dst, 5526);
+    }
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5530);
+      break;
+    case 1:
+    dasm_put(Dst, 5533);
+      break;
+    default:
+    dasm_put(Dst, 5536);
+      break;
+    }
+    dasm_put(Dst, 5539);
+    } else {
+    vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5551);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5553);
+    }
+    dasm_put(Dst, 5555);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5558);
+    } else {
+    dasm_put(Dst, 5564);
+    }
+      break;
+    case 1:
+    dasm_put(Dst, 5568);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5570);
+    }
+    dasm_put(Dst, 5572);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5575);
+    } else {
+    dasm_put(Dst, 5581);
+    }
+      break;
+    default:
+    dasm_put(Dst, 5585);
+      break;
+    }
+    dasm_put(Dst, 5595);
+    }
+    break;
+  case BC_MODNV: case BC_MODVV:
+    if (LJ_DUALNUM) {
+    vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5613);
+      break;
+    case 1:
+    dasm_put(Dst, 5619);
+      break;
+    default:
+    dasm_put(Dst, 5625);
+      break;
+    }
+    dasm_put(Dst, 5631);
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5659);
+      break;
+    case 1:
+    dasm_put(Dst, 5662);
+      break;
+    default:
+    dasm_put(Dst, 5665);
+      break;
+    }
+    dasm_put(Dst, 5668);
+    if (vk == 1) {
+    dasm_put(Dst, 5670);
+    } else {
+    dasm_put(Dst, 5674);
+    }
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5678);
+      break;
+    case 1:
+    dasm_put(Dst, 5681);
+      break;
+    default:
+    dasm_put(Dst, 5684);
+      break;
+    }
+    dasm_put(Dst, 5687);
+    } else {
+    vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
+    switch (vk) {
+    case 0:
+    dasm_put(Dst, 5690);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5692);
+    }
+    dasm_put(Dst, 5694);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5697);
+    } else {
+    dasm_put(Dst, 5703);
+    }
+      break;
+    case 1:
+    dasm_put(Dst, 5707);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5709);
+    }
+    dasm_put(Dst, 5711);
+    if (LJ_DUALNUM) {
+    dasm_put(Dst, 5714);
+    } else {
+    dasm_put(Dst, 5720);
+    }
+      break;
+    default:
+    dasm_put(Dst, 5724);
+      break;
+    }
+    dasm_put(Dst, 5734);
+    }
+    break;
+  case BC_POW:
+    dasm_put(Dst, 5737);
+    break;
+
+  case BC_CAT:
+    dasm_put(Dst, 5760, Dt1(->base), 32-3, Dt1(->base));
+    break;
+
+  /* -- Constant ops ------------------------------------------------------ */
+
+  case BC_KSTR:
+    dasm_put(Dst, 5790, 32-1, LJ_TSTR);
+    break;
+  case BC_KCDATA:
+#if LJ_HASFFI
+    dasm_put(Dst, 5809, 32-1, LJ_TCDATA);
+#endif
+    break;
+  case BC_KSHORT:
+    if (LJ_DUALNUM) {
+      dasm_put(Dst, 5828, 31-13);
+    } else {
+      dasm_put(Dst, 5844, 31-13, 31-20);
+    }
+    break;
+  case BC_KNUM:
+    dasm_put(Dst, 5872);
+    break;
+  case BC_KPRI:
+    dasm_put(Dst, 5885, 32-3);
+    break;
+  case BC_KNIL:
+    dasm_put(Dst, 5900);
+    break;
+
+  /* -- Upvalue and function ops ------------------------------------------ */
+
+  case BC_UGET:
+    dasm_put(Dst, 5919, 32-1, offsetof(GCfuncL, uvptr), DtA(->v));
+    break;
+  case BC_USETV:
+    dasm_put(Dst, 5940, 32-1, offsetof(GCfuncL, uvptr), DtA(->marked), DtA(->v), LJ_GC_BLACK, DtA(->closed), -(LJ_TISNUM+1), LJ_TISGCV - (LJ_TISNUM+1), Dt4(->gch.marked), LJ_GC_WHITES, GG_DISP2G);
+    break;
+  case BC_USETS:
+    dasm_put(Dst, 5993, 32-1, 32-1, offsetof(GCfuncL, uvptr), DtA(->marked), DtA(->v), LJ_GC_BLACK, Dt5(->marked), DtA(->closed), LJ_TSTR, LJ_GC_WHITES, GG_DISP2G);
+    break;
+  case BC_USETN:
+    dasm_put(Dst, 6044, 32-1, offsetof(GCfuncL, uvptr), DtA(->v));
+    break;
+  case BC_USETP:
+    dasm_put(Dst, 6065, 32-1, 32-3, offsetof(GCfuncL, uvptr), DtA(->v));
+    break;
+
+  case BC_UCLO:
+    dasm_put(Dst, 6088, Dt1(->openupval), 32-1, -(BCBIAS_J*4 >> 16), Dt1(->base), Dt1(->base));
+    break;
+
+  case BC_FNEW:
+    dasm_put(Dst, 6118, 32-1, Dt1(->base), Dt1(->base), LJ_TFUNC);
+    break;
+
+  /* -- Table ops --------------------------------------------------------- */
+
+  case BC_TNEW:
+  case BC_TDUP:
+    dasm_put(Dst, 6146, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base));
+    if (op == BC_TNEW) {
+      dasm_put(Dst, 6159);
+    } else {
+      dasm_put(Dst, 6168, 32-1);
+    }
+    dasm_put(Dst, 6175, Dt1(->base), LJ_TTAB);
+    if (op == BC_TNEW) {
+      dasm_put(Dst, 6192);
+    }
+    dasm_put(Dst, 6197);
+    break;
+
+  case BC_GGET:
+  case BC_GSET:
+    dasm_put(Dst, 6206, 32-1, Dt7(->env));
+    if (op == BC_GGET) {
+      dasm_put(Dst, 6214);
+    } else {
+      dasm_put(Dst, 6217);
+    }
+    break;
+
+  case BC_TGETV:
+    dasm_put(Dst, 6220);
+    if (LJ_DUALNUM) {
+      dasm_put(Dst, 6224);
+    } else {
+      dasm_put(Dst, 6226);
+    }
+    dasm_put(Dst, 6228, LJ_TTAB);
+    if (LJ_DUALNUM) {
+      dasm_put(Dst, 6234, Dt6(->asize), Dt6(->array), 31-3);
+    } else {
+      dasm_put(Dst, 6244, Dt6(->asize), Dt6(->array), 31-3);
+    }
+    dasm_put(Dst, 6261, LJ_TNIL, Dt6(->metatable), Dt6(->nomm), 1<<MM_index, LJ_TSTR);
+    if (!LJ_DUALNUM) {
+      dasm_put(Dst, 6301);
+    }
+    dasm_put(Dst, 6303);
+    break;
+  case BC_TGETS:
+    dasm_put(Dst, 6306, 32-1, LJ_TTAB, Dt6(->hmask), Dt5(->hash), Dt6(->node), 31-5, 31-3, DtB(->key), 4+offsetof(Node, key), DtB(->val), 4+offsetof(Node, val), LJ_TSTR, LJ_TNIL, DtB(->next));
+    dasm_put(Dst, 6367, LJ_TNIL, Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
+    break;
+  case BC_TGETB:
+    dasm_put(Dst, 6387, 32-3, LJ_TTAB, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
+    break;
+
+  case BC_TSETV:
+    dasm_put(Dst, 6435);
+    if (LJ_DUALNUM) {
+      dasm_put(Dst, 6439);
+    } else {
+      dasm_put(Dst, 6441);
+    }
+    dasm_put(Dst, 6443, LJ_TTAB);
+    if (LJ_DUALNUM) {
+      dasm_put(Dst, 6449, Dt6(->asize), Dt6(->array), 31-3);
+    } else {
+      dasm_put(Dst, 6459, Dt6(->asize), Dt6(->array), 31-3);
+    }
+    dasm_put(Dst, 6476, Dt6(->marked), LJ_TNIL, LJ_GC_BLACK, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, LJ_TSTR);
+    if (!LJ_DUALNUM) {
+      dasm_put(Dst, 6523);
+    }
+    dasm_put(Dst, 6525, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
+    break;
+    dasm_put(Dst, 6540, LJ_TSTR, LJ_TNIL);
+  case BC_TSETS:
+    dasm_put(Dst, 6566, 32-1, LJ_TTAB, Dt6(->hmask), Dt5(->hash), Dt6(->node), Dt6(->nomm), 31-5, 31-3, Dt6(->marked), DtB(->key), 4+offsetof(Node, key), DtB(->val), 4+offsetof(Node, val), LJ_TSTR, LJ_TNIL);
+    dasm_put(Dst, 6617, LJ_GC_BLACK, DtB(->val), Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, DtB(->next), Dt6(->metatable), DISPATCH_GL(tmptv), Dt1(->base), Dt6(->nomm), 1<<MM_newindex);
+    dasm_put(Dst, 6673, LJ_TSTR, Dt1(->base), DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
+    break;
+  case BC_TSETB:
+    dasm_put(Dst, 6698, 32-3, LJ_TTAB, Dt6(->asize), Dt6(->array), Dt6(->marked), LJ_TNIL, LJ_GC_BLACK, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, DISPATCH_GL(gc.grayagain));
+    dasm_put(Dst, 6756, DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
+    break;
+
+  case BC_TSETM:
+    dasm_put(Dst, 6766, 32-3, Dt6(->asize), 31-3, Dt6(->marked), Dt6(->array), LJ_GC_BLACK, Dt1(->base), DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
+    dasm_put(Dst, 6835);
+    break;
+
+  /* -- Calls and vararg handling ----------------------------------------- */
+
+  case BC_CALLM:
+    dasm_put(Dst, 6838);
+    break;
+  case BC_CALL:
+    dasm_put(Dst, 6840, LJ_TFUNC, Dt7(->pc));
+    break;
+
+  case BC_CALLMT:
+    dasm_put(Dst, 6861);
+    break;
+  case BC_CALLT:
+    dasm_put(Dst, 6863, LJ_TFUNC, FRAME_TYPE, Dt7(->ffid), FRAME_VARG, Dt7(->pc), -4-8, Dt7(->pc), PC2PROTO(k), FRAME_TYPEP);
+    dasm_put(Dst, 6927, FRAME_TYPE);
+    break;
+
+  case BC_ITERC:
+    dasm_put(Dst, 6936, LJ_TFUNC, Dt7(->pc));
+    break;
+
+  case BC_ITERN:
+#if LJ_HASJIT
+#endif
+    dasm_put(Dst, 6963, Dt6(->asize), Dt6(->array), 31-3, LJ_TNIL);
+    if (LJ_DUALNUM) {
+      dasm_put(Dst, 6985);
+    } else {
+      dasm_put(Dst, 6988);
+    }
+    dasm_put(Dst, 6992, -(BCBIAS_J*4 >> 16));
+    if (!LJ_DUALNUM) {
+      dasm_put(Dst, 7000);
+    }
+    dasm_put(Dst, 7002, Dt6(->hmask), Dt6(->node), 31-5, 31-3, LJ_TNIL, DtB(->key), -(BCBIAS_J*4 >> 16));
+    break;
+
+  case BC_ISNEXT:
+    dasm_put(Dst, 7058, LJ_TTAB, LJ_TFUNC, LJ_TNIL, Dt8(->ffid), FF_next_N, 32-1, -(BCBIAS_J*4 >> 16), BC_JMP, BC_ITERC, -(BCBIAS_J*4 >> 16));
+    break;
+
+  case BC_VARG:
+    dasm_put(Dst, 7108, FRAME_VARG, Dt1(->maxstack), Dt1(->top), Dt1(->base), 32-3, Dt1(->base));
+    dasm_put(Dst, 7188);
+    break;
+
+  /* -- Returns ----------------------------------------------------------- */
+
+  case BC_RETM:
+    dasm_put(Dst, 7194);
+    break;
+
+  case BC_RET:
+    dasm_put(Dst, 7196, FRAME_TYPE, FRAME_VARG, Dt7(->pc), PC2PROTO(k), FRAME_TYPEP);
+    break;
+
+  case BC_RET0: case BC_RET1:
+    dasm_put(Dst, 7266, FRAME_TYPE, FRAME_VARG);
+    if (op == BC_RET1) {
+      dasm_put(Dst, 7279);
+    }
+    dasm_put(Dst, 7282, Dt7(->pc), PC2PROTO(k));
+    break;
+
+  /* -- Loops and branches ------------------------------------------------ */
+
+  case BC_FORL:
+#if LJ_HASJIT
+    dasm_put(Dst, 7310, GG_DISP2HOT, -HOTCOUNT_LOOP);
+#endif
+    break;
+
+  case BC_JFORI:
+  case BC_JFORL:
+#if !LJ_HASJIT
+    break;
+#endif
+  case BC_FORI:
+  case BC_IFORL:
+    vk = (op == BC_IFORL || op == BC_JFORL);
+    if (LJ_DUALNUM) {
+      dasm_put(Dst, 7320, FORL_IDX*8+4);
+      if (vk) {
+	dasm_put(Dst, 7325, FORL_STEP*8+4, FORL_STOP*8+4, FORL_IDX*8+4);
+      } else {
+	dasm_put(Dst, 7339, FORL_STEP*8, FORL_STEP*8+4, FORL_STOP*8, FORL_STOP*8+4);
+      }
+      dasm_put(Dst, 7355, FORL_EXT*8);
+      if (op != BC_JFORL) {
+	dasm_put(Dst, 7362, 32-1);
+      }
+      dasm_put(Dst, 7365, FORL_EXT*8+4);
+      if (op != BC_JFORL) {
+	dasm_put(Dst, 7368);
+      }
+      if (op == BC_FORI) {
+	dasm_put(Dst, 7370);
+      } else if (op == BC_JFORI) {
+	dasm_put(Dst, 7373, -(BCBIAS_J*4 >> 16));
+      } else if (op == BC_IFORL) {
+	dasm_put(Dst, 7378, -(BCBIAS_J*4 >> 16));
+      } else {
+	dasm_put(Dst, 7383, BC_JLOOP);
+      }
+      dasm_put(Dst, 7386);
+      if (vk) {
+	dasm_put(Dst, 7402);
+      }
+    }
+    if (vk) {
+      if (LJ_DUALNUM) {
+	dasm_put(Dst, 7409, FORL_IDX*8);
+      } else {
+	dasm_put(Dst, 7413);
+      }
+      dasm_put(Dst, 7415, FORL_STEP*8, FORL_STOP*8, FORL_STEP*8, FORL_IDX*8);
+    } else {
+      if (LJ_DUALNUM) {
+	dasm_put(Dst, 7425);
+      } else {
+	dasm_put(Dst, 7427, FORL_STEP*8, FORL_STOP*8);
+      }
+      dasm_put(Dst, 7436, FORL_IDX*8, FORL_STEP*8, FORL_STOP*8);
+    }
+    dasm_put(Dst, 7447);
+    if (op != BC_JFORL) {
+      dasm_put(Dst, 7449, 32-1);
+    }
+    dasm_put(Dst, 7452, FORL_EXT*8);
+    if (op != BC_JFORL) {
+      dasm_put(Dst, 7455);
+    }
+    dasm_put(Dst, 7457);
+    if (op == BC_JFORI) {
+      dasm_put(Dst, 7459, -(BCBIAS_J*4 >> 16));
+    }
+    dasm_put(Dst, 7462);
+    if (op == BC_FORI) {
+      dasm_put(Dst, 7465);
+    } else if (op == BC_IFORL) {
+      if (LJ_DUALNUM) {
+	dasm_put(Dst, 7468);
+      } else {
+	dasm_put(Dst, 7471);
+      }
+      dasm_put(Dst, 7474, -(BCBIAS_J*4 >> 16));
+    } else if (op == BC_JFORI) {
+      dasm_put(Dst, 7478);
+    } else {
+      dasm_put(Dst, 7481, BC_JLOOP);
+    }
+    if (LJ_DUALNUM) {
+      dasm_put(Dst, 7484);
+    } else {
+      dasm_put(Dst, 7487);
+    }
+    dasm_put(Dst, 7499);
+    if (op == BC_FORI) {
+      dasm_put(Dst, 7501, -(BCBIAS_J*4 >> 16));
+    } else if (op == BC_IFORL) {
+      dasm_put(Dst, 7507);
+    } else if (op == BC_JFORI) {
+      dasm_put(Dst, 7510);
+    } else {
+      dasm_put(Dst, 7513, BC_JLOOP);
+    }
+    dasm_put(Dst, 7516);
+    if (op == BC_JFORI) {
+      dasm_put(Dst, 7519, BC_JLOOP);
+    }
+    break;
+
+  case BC_ITERL:
+#if LJ_HASJIT
+    dasm_put(Dst, 7525, GG_DISP2HOT, -HOTCOUNT_LOOP);
+#endif
+    break;
+
+  case BC_JITERL:
+#if !LJ_HASJIT
+    break;
+#endif
+  case BC_IITERL:
+    dasm_put(Dst, 7535, LJ_TNIL);
+    if (op == BC_JITERL) {
+      dasm_put(Dst, 7542, BC_JLOOP);
+    } else {
+      dasm_put(Dst, 7547, 32-1, -(BCBIAS_J*4 >> 16));
+    }
+    dasm_put(Dst, 7555);
+    break;
+
+  case BC_LOOP:
+#if LJ_HASJIT
+    dasm_put(Dst, 7567, GG_DISP2HOT, -HOTCOUNT_LOOP);
+#endif
+    break;
+
+  case BC_ILOOP:
+    dasm_put(Dst, 7577);
+    break;
+
+  case BC_JLOOP:
+#if LJ_HASJIT
+    dasm_put(Dst, 7588, DISPATCH_J(trace), 32-1, DISPATCH_GL(vmstate), DtD(->mcode), DISPATCH_GL(jit_base), DISPATCH_GL(jit_L), GG_DISP2G+32768);
+#endif
+    break;
+
+  case BC_JMP:
+    dasm_put(Dst, 7607, 32-1, -(BCBIAS_J*4 >> 16));
+    break;
+
+  /* -- Function headers -------------------------------------------------- */
+
+  case BC_FUNCF:
+#if LJ_HASJIT
+    dasm_put(Dst, 7623, GG_DISP2HOT, -HOTCOUNT_CALL);
+#endif
+  case BC_FUNCV:  /* NYI: compiled vararg functions. */
+    break;
+
+  case BC_JFUNCF:
+#if !LJ_HASJIT
+    break;
+#endif
+  case BC_IFUNCF:
+    dasm_put(Dst, 7633, Dt1(->maxstack), -4+PC2PROTO(numparams), -4+PC2PROTO(k), 31-3);
+    if (op != BC_JFUNCF) {
+      dasm_put(Dst, 7645);
+    }
+    dasm_put(Dst, 7648);
+    if (op == BC_JFUNCF) {
+      dasm_put(Dst, 7653, BC_JLOOP);
+    } else {
+      dasm_put(Dst, 7657);
+    }
+    dasm_put(Dst, 7666);
+    break;
+
+  case BC_JFUNCV:
+#if !LJ_HASJIT
+    break;
+#endif
+    dasm_put(Dst, 7672);
+    break;  /* NYI: compiled vararg functions. */
+
+  case BC_IFUNCV:
+    dasm_put(Dst, 7674, Dt1(->maxstack), 8+FRAME_VARG, -4+PC2PROTO(k), -4+PC2PROTO(numparams), LJ_TNIL);
+    break;
+
+  case BC_FUNCC:
+  case BC_FUNCCW:
+    if (op == BC_FUNCC) {
+      dasm_put(Dst, 7727, Dt8(->f));
+    } else {
+      dasm_put(Dst, 7730, DISPATCH_GL(wrapf));
+    }
+    dasm_put(Dst, 7733, Dt1(->maxstack), Dt1(->base), Dt1(->top), ~LJ_VMST_C);
+    if (op == BC_FUNCCW) {
+      dasm_put(Dst, 7746, Dt8(->f));
+    }
+    dasm_put(Dst, 7749, DISPATCH_GL(vmstate), Dt1(->base), 31-3, Dt1(->top), ~LJ_VMST_INTERP, DISPATCH_GL(vmstate));
+    break;
+
+  /* ---------------------------------------------------------------------- */
+
+  default:
+    fprintf(stderr, "Error: undefined opcode BC_%s\n", bc_names[op]);
+    exit(2);
+    break;
+  }
+}
+
+static int build_backend(BuildCtx *ctx)
+{
+  int op;
+
+  dasm_growpc(Dst, BC__MAX);
+
+  build_subroutines(ctx);
+
+  dasm_put(Dst, 7770);
+  for (op = 0; op < BC__MAX; op++)
+    build_ins(ctx, (BCOp)op, op);
+
+  return BC__MAX;
+}
+
+/* Emit pseudo frame-info for all assembler functions. */
+static void emit_asm_debug(BuildCtx *ctx)
+{
+  int fcofs = (int)((uint8_t *)ctx->glob[GLOB_vm_ffi_call] - ctx->code);
+  int i;
+  switch (ctx->mode) {
+  case BUILD_elfasm:
+    fprintf(ctx->fp, "\t.section .debug_frame,\"\",@progbits\n");
+    fprintf(ctx->fp,
+	".Lframe0:\n"
+	"\t.long .LECIE0-.LSCIE0\n"
+	".LSCIE0:\n"
+	"\t.long 0xffffffff\n"
+	"\t.byte 0x1\n"
+	"\t.string \"\"\n"
+	"\t.uleb128 0x1\n"
+	"\t.sleb128 -4\n"
+	"\t.byte 65\n"
+	"\t.byte 0xc\n\t.uleb128 1\n\t.uleb128 0\n"
+	"\t.align 2\n"
+	".LECIE0:\n\n");
+    fprintf(ctx->fp,
+	".LSFDE0:\n"
+	"\t.long .LEFDE0-.LASFDE0\n"
+	".LASFDE0:\n"
+	"\t.long .Lframe0\n"
+	"\t.long .Lbegin\n"
+	"\t.long %d\n"
+	"\t.byte 0xe\n\t.uleb128 %d\n"
+	"\t.byte 0x11\n\t.uleb128 65\n\t.sleb128 -1\n"
+	"\t.byte 0x5\n\t.uleb128 70\n\t.uleb128 55\n",
+	fcofs, CFRAME_SIZE);
+    for (i = 14; i <= 31; i++)
+      fprintf(ctx->fp,
+	"\t.byte %d\n\t.uleb128 %d\n"
+	"\t.byte %d\n\t.uleb128 %d\n",
+	0x80+i, 37+(31-i), 0x80+32+i, 2+2*(31-i));
+    fprintf(ctx->fp,
+	"\t.align 2\n"
+	".LEFDE0:\n\n");
+#if LJ_HASFFI
+    fprintf(ctx->fp,
+	".LSFDE1:\n"
+	"\t.long .LEFDE1-.LASFDE1\n"
+	".LASFDE1:\n"
+	"\t.long .Lframe0\n"
+	"\t.long lj_vm_ffi_call\n"
+	"\t.long %d\n"
+	"\t.byte 0x11\n\t.uleb128 65\n\t.sleb128 -1\n"
+	"\t.byte 0x8e\n\t.uleb128 2\n"
+	"\t.byte 0xd\n\t.uleb128 0xe\n"
+	"\t.align 2\n"
+	".LEFDE1:\n\n", (int)ctx->codesz - fcofs);
+#endif
+    fprintf(ctx->fp, "\t.section .eh_frame,\"a\",@progbits\n");
+    fprintf(ctx->fp,
+	".Lframe1:\n"
+	"\t.long .LECIE1-.LSCIE1\n"
+	".LSCIE1:\n"
+	"\t.long 0\n"
+	"\t.byte 0x1\n"
+	"\t.string \"zPR\"\n"
+	"\t.uleb128 0x1\n"
+	"\t.sleb128 -4\n"
+	"\t.byte 65\n"
+	"\t.uleb128 6\n"			/* augmentation length */
+	"\t.byte 0x1b\n"			/* pcrel|sdata4 */
+	"\t.long lj_err_unwind_dwarf-.\n"
+	"\t.byte 0x1b\n"			/* pcrel|sdata4 */
+	"\t.byte 0xc\n\t.uleb128 1\n\t.uleb128 0\n"
+	"\t.align 2\n"
+	".LECIE1:\n\n");
+    fprintf(ctx->fp,
+	".LSFDE2:\n"
+	"\t.long .LEFDE2-.LASFDE2\n"
+	".LASFDE2:\n"
+	"\t.long .LASFDE2-.Lframe1\n"
+	"\t.long .Lbegin-.\n"
+	"\t.long %d\n"
+	"\t.uleb128 0\n"			/* augmentation length */
+	"\t.byte 0xe\n\t.uleb128 %d\n"
+	"\t.byte 0x11\n\t.uleb128 65\n\t.sleb128 -1\n"
+	"\t.byte 0x5\n\t.uleb128 70\n\t.uleb128 55\n",
+	fcofs, CFRAME_SIZE);
+    for (i = 14; i <= 31; i++)
+      fprintf(ctx->fp,
+	"\t.byte %d\n\t.uleb128 %d\n"
+	"\t.byte %d\n\t.uleb128 %d\n",
+	0x80+i, 37+(31-i), 0x80+32+i, 2+2*(31-i));
+    fprintf(ctx->fp,
+	"\t.align 2\n"
+	".LEFDE2:\n\n");
+#if LJ_HASFFI
+    fprintf(ctx->fp,
+	".Lframe2:\n"
+	"\t.long .LECIE2-.LSCIE2\n"
+	".LSCIE2:\n"
+	"\t.long 0\n"
+	"\t.byte 0x1\n"
+	"\t.string \"zR\"\n"
+	"\t.uleb128 0x1\n"
+	"\t.sleb128 -4\n"
+	"\t.byte 65\n"
+	"\t.uleb128 1\n"			/* augmentation length */
+	"\t.byte 0x1b\n"			/* pcrel|sdata4 */
+	"\t.byte 0xc\n\t.uleb128 1\n\t.uleb128 0\n"
+	"\t.align 2\n"
+	".LECIE2:\n\n");
+    fprintf(ctx->fp,
+	".LSFDE3:\n"
+	"\t.long .LEFDE3-.LASFDE3\n"
+	".LASFDE3:\n"
+	"\t.long .LASFDE3-.Lframe2\n"
+	"\t.long lj_vm_ffi_call-.\n"
+	"\t.long %d\n"
+	"\t.uleb128 0\n"			/* augmentation length */
+	"\t.byte 0x11\n\t.uleb128 65\n\t.sleb128 -1\n"
+	"\t.byte 0x8e\n\t.uleb128 2\n"
+	"\t.byte 0xd\n\t.uleb128 0xe\n"
+	"\t.align 2\n"
+	".LEFDE3:\n\n", (int)ctx->codesz - fcofs);
+#endif
+    break;
+  default:
+    break;
+  }
+}
+
diff --git a/third_party/luajit/src/buildvm_ppcspe.dasc b/third_party/luajit/src/buildvm_ppcspe.dasc
new file mode 100644
index 0000000000000000000000000000000000000000..3ec36f76f11b4fbccdfab53423887827f2a6fdc7
--- /dev/null
+++ b/third_party/luajit/src/buildvm_ppcspe.dasc
@@ -0,0 +1,3704 @@
+|// Low-level VM code for PowerPC/e500 CPUs.
+|// Bytecode interpreter, fast functions and helper functions.
+|// Copyright (C) 2005-2011 Mike Pall. See Copyright Notice in luajit.h
+|
+|.arch ppc
+|.section code_op, code_sub
+|
+|.actionlist build_actionlist
+|.globals GLOB_
+|.globalnames globnames
+|.externnames extnames
+|
+|// Note: The ragged indentation of the instructions is intentional.
+|//       The starting columns indicate data dependencies.
+|
+|//-----------------------------------------------------------------------
+|
+|// Fixed register assignments for the interpreter.
+|// Don't use: r1 = sp, r2 and r13 = reserved and/or small data area ptr
+|
+|// The following must be C callee-save (but BASE is often refetched).
+|.define BASE,		r14	// Base of current Lua stack frame.
+|.define KBASE,		r15	// Constants of current Lua function.
+|.define PC,		r16	// Next PC.
+|.define DISPATCH,	r17	// Opcode dispatch table.
+|.define LREG,		r18	// Register holding lua_State (also in SAVE_L).
+|.define MULTRES,	r19	// Size of multi-result: (nresults+1)*8.
+|
+|// Constants for vectorized type-comparisons (hi+low GPR). C callee-save.
+|.define TISNUM,	r22
+|.define TISSTR,	r23
+|.define TISTAB,	r24
+|.define TISFUNC,	r25
+|.define TISNIL,	r26
+|.define TOBIT,		r27
+|.define ZERO,		TOBIT	// Zero in lo word.
+|
+|// The following temporaries are not saved across C calls, except for RA.
+|.define RA,		r20	// Callee-save.
+|.define RB,		r10
+|.define RC,		r11
+|.define RD,		r12
+|.define INS,		r7	// Overlaps CARG5.
+|
+|.define TMP0,		r0
+|.define TMP1,		r8
+|.define TMP2,		r9
+|.define TMP3,		r6	// Overlaps CARG4.
+|
+|// Saved temporaries.
+|.define SAVE0,		r21
+|
+|// Calling conventions.
+|.define CARG1,		r3
+|.define CARG2,		r4
+|.define CARG3,		r5
+|.define CARG4,		r6	// Overlaps TMP3.
+|.define CARG5,		r7	// Overlaps INS.
+|
+|.define CRET1,		r3
+|.define CRET2,		r4
+|
+|// Stack layout while in interpreter. Must match with lj_frame.h.
+|.define SAVE_LR,	188(sp)
+|.define CFRAME_SPACE,	184	// Delta for sp.
+|// Back chain for sp:	184(sp)	<-- sp entering interpreter
+|.define SAVE_r31,	176(sp)	// 64 bit register saves.
+|.define SAVE_r30,	168(sp)
+|.define SAVE_r29,	160(sp)
+|.define SAVE_r28,	152(sp)
+|.define SAVE_r27,	144(sp)
+|.define SAVE_r26,	136(sp)
+|.define SAVE_r25,	128(sp)
+|.define SAVE_r24,	120(sp)
+|.define SAVE_r23,	112(sp)
+|.define SAVE_r22,	104(sp)
+|.define SAVE_r21,	96(sp)
+|.define SAVE_r20,	88(sp)
+|.define SAVE_r19,	80(sp)
+|.define SAVE_r18,	72(sp)
+|.define SAVE_r17,	64(sp)
+|.define SAVE_r16,	56(sp)
+|.define SAVE_r15,	48(sp)
+|.define SAVE_r14,	40(sp)
+|.define SAVE_CR,	36(sp)
+|.define UNUSED1,	32(sp)
+|.define SAVE_ERRF,	28(sp)	// 32 bit C frame info.
+|.define SAVE_NRES,	24(sp)
+|.define SAVE_CFRAME,	20(sp)
+|.define SAVE_L,	16(sp)
+|.define SAVE_PC,	12(sp)
+|.define SAVE_MULTRES,	8(sp)
+|// Next frame lr:	4(sp)
+|// Back chain for sp:	0(sp)	<-- sp while in interpreter
+|
+|.macro save_, reg; evstdd reg, SAVE_..reg; .endmacro
+|.macro rest_, reg; evldd reg, SAVE_..reg; .endmacro
+|
+|.macro saveregs
+|  stwu sp, -CFRAME_SPACE(sp)
+|  save_ r14; save_ r15; save_ r16; save_ r17; save_ r18; save_ r19
+|  mflr r0; mfcr r12
+|  save_ r20; save_ r21; save_ r22; save_ r23; save_ r24; save_ r25
+|  stw  r0, SAVE_LR; stw r12, SAVE_CR
+|  save_ r26; save_ r27; save_ r28; save_ r29; save_ r30; save_ r31
+|.endmacro
+|
+|.macro restoreregs
+|  lwz r0, SAVE_LR; lwz r12, SAVE_CR
+|  rest_ r14; rest_ r15; rest_ r16; rest_ r17; rest_ r18; rest_ r19
+|  mtlr r0; mtcrf 0x38, r12
+|  rest_ r20; rest_ r21; rest_ r22; rest_ r23; rest_ r24; rest_ r25
+|  rest_ r26; rest_ r27; rest_ r28; rest_ r29; rest_ r30; rest_ r31
+|  addi sp, sp, CFRAME_SPACE
+|.endmacro
+|
+|// Type definitions. Some of these are only used for documentation.
+|.type L,		lua_State,	LREG
+|.type GL,		global_State
+|.type TVALUE,		TValue
+|.type GCOBJ,		GCobj
+|.type STR,		GCstr
+|.type TAB,		GCtab
+|.type LFUNC,		GCfuncL
+|.type CFUNC,		GCfuncC
+|.type PROTO,		GCproto
+|.type UPVAL,		GCupval
+|.type NODE,		Node
+|.type NARGS8,		int
+|.type TRACE,		GCtrace
+|
+|//-----------------------------------------------------------------------
+|
+|// These basic macros should really be part of DynASM.
+|.macro srwi, rx, ry, n; rlwinm rx, ry, 32-n, n, 31; .endmacro
+|.macro slwi, rx, ry, n; rlwinm rx, ry, n, 0, 31-n; .endmacro
+|.macro rotlwi, rx, ry, n; rlwinm rx, ry, n, 0, 31; .endmacro
+|.macro rotlw, rx, ry, rn; rlwnm rx, ry, rn, 0, 31; .endmacro
+|.macro subi, rx, ry, i; addi rx, ry, -i; .endmacro
+|
+|// Trap for not-yet-implemented parts.
+|.macro NYI; tw 4, sp, sp; .endmacro
+|
+|//-----------------------------------------------------------------------
+|
+|// Access to frame relative to BASE.
+|.define FRAME_PC,	-8
+|.define FRAME_FUNC,	-4
+|
+|// Instruction decode.
+|.macro decode_OP4, dst, ins; rlwinm dst, ins, 2, 22, 29; .endmacro
+|.macro decode_RA8, dst, ins; rlwinm dst, ins, 27, 21, 28; .endmacro
+|.macro decode_RB8, dst, ins; rlwinm dst, ins, 11, 21, 28; .endmacro
+|.macro decode_RC8, dst, ins; rlwinm dst, ins, 19, 21, 28; .endmacro
+|.macro decode_RD8, dst, ins; rlwinm dst, ins, 19, 13, 28; .endmacro
+|
+|.macro decode_OP1, dst, ins; rlwinm dst, ins, 0, 24, 31; .endmacro
+|.macro decode_RD4, dst, ins; rlwinm dst, ins, 18, 14, 29; .endmacro
+|
+|// Instruction fetch.
+|.macro ins_NEXT1
+|  lwz INS, 0(PC)
+|   addi PC, PC, 4
+|.endmacro
+|// Instruction decode+dispatch.
+|.macro ins_NEXT2
+|  decode_OP4 TMP1, INS
+|   decode_RB8 RB, INS
+|   decode_RD8 RD, INS
+|  lwzx TMP0, DISPATCH, TMP1
+|   decode_RA8 RA, INS
+|   decode_RC8 RC, INS
+|  mtctr TMP0
+|  bctr
+|.endmacro
+|.macro ins_NEXT
+|  ins_NEXT1
+|  ins_NEXT2
+|.endmacro
+|
+|// Instruction footer.
+|.if 1
+|  // Replicated dispatch. Less unpredictable branches, but higher I-Cache use.
+|  .define ins_next, ins_NEXT
+|  .define ins_next_, ins_NEXT
+|  .define ins_next1, ins_NEXT1
+|  .define ins_next2, ins_NEXT2
+|.else
+|  // Common dispatch. Lower I-Cache use, only one (very) unpredictable branch.
+|  // Affects only certain kinds of benchmarks (and only with -j off).
+|  .macro ins_next
+|    b ->ins_next
+|  .endmacro
+|  .macro ins_next1
+|  .endmacro
+|  .macro ins_next2
+|    b ->ins_next
+|  .endmacro
+|  .macro ins_next_
+|  ->ins_next:
+|    ins_NEXT
+|  .endmacro
+|.endif
+|
+|// Call decode and dispatch.
+|.macro ins_callt
+|  // BASE = new base, RB = LFUNC/CFUNC, RC = nargs*8, FRAME_PC(BASE) = PC
+|  lwz PC, LFUNC:RB->pc
+|  lwz INS, 0(PC)
+|   addi PC, PC, 4
+|  decode_OP4 TMP1, INS
+|   decode_RA8 RA, INS
+|  lwzx TMP0, DISPATCH, TMP1
+|   add RA, RA, BASE
+|  mtctr TMP0
+|  bctr
+|.endmacro
+|
+|.macro ins_call
+|  // BASE = new base, RB = LFUNC/CFUNC, RC = nargs*8, PC = caller PC
+|  stw PC, FRAME_PC(BASE)
+|  ins_callt
+|.endmacro
+|
+|//-----------------------------------------------------------------------
+|
+|// Macros to test operand types.
+|.macro checknum, reg; evcmpltu reg, TISNUM; .endmacro
+|.macro checkstr, reg; evcmpeq reg, TISSTR; .endmacro
+|.macro checktab, reg; evcmpeq reg, TISTAB; .endmacro
+|.macro checkfunc, reg; evcmpeq reg, TISFUNC; .endmacro
+|.macro checknil, reg; evcmpeq reg, TISNIL; .endmacro
+|.macro checkok, label; blt label; .endmacro
+|.macro checkfail, label; bge label; .endmacro
+|.macro checkanyfail, label; bns label; .endmacro
+|.macro checkallok, label; bso label; .endmacro
+|
+|.macro branch_RD
+|  srwi TMP0, RD, 1
+|  add PC, PC, TMP0
+|  addis PC, PC, -(BCBIAS_J*4 >> 16)
+|.endmacro
+|
+|// Assumes DISPATCH is relative to GL.
+#define DISPATCH_GL(field)	(GG_DISP2G + (int)offsetof(global_State, field))
+#define DISPATCH_J(field)	(GG_DISP2J + (int)offsetof(jit_State, field))
+|
+#define PC2PROTO(field)  ((int)offsetof(GCproto, field)-(int)sizeof(GCproto))
+|
+|.macro hotloop
+|  NYI
+|.endmacro
+|
+|.macro hotcall
+|  NYI
+|.endmacro
+|
+|// Set current VM state. Uses TMP0.
+|.macro li_vmstate, st; li TMP0, ~LJ_VMST_..st; .endmacro
+|.macro st_vmstate; stw TMP0, DISPATCH_GL(vmstate)(DISPATCH); .endmacro
+|
+|// Move table write barrier back. Overwrites mark and tmp.
+|.macro barrierback, tab, mark, tmp
+|  lwz tmp, DISPATCH_GL(gc.grayagain)(DISPATCH)
+|  // Assumes LJ_GC_BLACK is 0x04.
+|   rlwinm mark, mark, 0, 30, 28		// black2gray(tab)
+|  stw tab, DISPATCH_GL(gc.grayagain)(DISPATCH)
+|   stb mark, tab->marked
+|  stw tmp, tab->gclist
+|.endmacro
+|
+|//-----------------------------------------------------------------------
+
+/* Generate subroutines used by opcodes and other parts of the VM. */
+/* The .code_sub section should be last to help static branch prediction. */
+static void build_subroutines(BuildCtx *ctx)
+{
+  |.code_sub
+  |
+  |//-----------------------------------------------------------------------
+  |//-- Return handling ----------------------------------------------------
+  |//-----------------------------------------------------------------------
+  |
+  |->vm_returnp:
+  |  // See vm_return. Also: TMP2 = previous base.
+  |  andi. TMP0, PC, FRAME_P
+  |   evsplati TMP1, LJ_TTRUE
+  |  beq ->cont_dispatch
+  |
+  |  // Return from pcall or xpcall fast func.
+  |  lwz PC, FRAME_PC(TMP2)		// Fetch PC of previous frame.
+  |  mr BASE, TMP2			// Restore caller base.
+  |  // Prepending may overwrite the pcall frame, so do it at the end.
+  |   stwu TMP1, FRAME_PC(RA)		// Prepend true to results.
+  |
+  |->vm_returnc:
+  |  andi. TMP0, PC, FRAME_TYPE
+  |   addi RD, RD, 8			// RD = (nresults+1)*8.
+  |   mr MULTRES, RD
+  |  beq ->BC_RET_Z			// Handle regular return to Lua.
+  |
+  |->vm_return:
+  |  // BASE = base, RA = resultptr, RD/MULTRES = (nresults+1)*8, PC = return
+  |  // TMP0 = PC & FRAME_TYPE
+  |  cmpwi TMP0, FRAME_C
+  |   rlwinm TMP2, PC, 0, 0, 28
+  |    li_vmstate C
+  |   sub TMP2, BASE, TMP2		// TMP2 = previous base.
+  |  bne ->vm_returnp
+  |
+  |  addic. TMP1, RD, -8
+  |   stw TMP2, L->base
+  |   lwz TMP2, SAVE_NRES
+  |    subi BASE, BASE, 8
+  |    st_vmstate
+  |   slwi TMP2, TMP2, 3
+  |  beq >2
+  |1:
+  |  addic. TMP1, TMP1, -8
+  |   evldd TMP0, 0(RA)
+  |    addi RA, RA, 8
+  |   evstdd TMP0, 0(BASE)
+  |    addi BASE, BASE, 8
+  |  bne <1
+  |
+  |2:
+  |  cmpw TMP2, RD			// More/less results wanted?
+  |  bne >6
+  |3:
+  |  stw BASE, L->top			// Store new top.
+  |
+  |->vm_leave_cp:
+  |  lwz TMP0, SAVE_CFRAME		// Restore previous C frame.
+  |   li CRET1, 0			// Ok return status for vm_pcall.
+  |  stw TMP0, L->cframe
+  |
+  |->vm_leave_unw:
+  |  restoreregs
+  |  blr
+  |
+  |6:
+  |  ble >7				// Less results wanted?
+  |  // More results wanted. Check stack size and fill up results with nil.
+  |  lwz TMP1, L->maxstack
+  |  cmplw BASE, TMP1
+  |  bge >8
+  |  evstdd TISNIL, 0(BASE)
+  |  addi RD, RD, 8
+  |  addi BASE, BASE, 8
+  |  b <2
+  |
+  |7:  // Less results wanted.
+  |   sub TMP0, RD, TMP2
+  |  cmpwi TMP2, 0			// LUA_MULTRET+1 case?
+  |   sub TMP0, BASE, TMP0		// Subtract the difference.
+  |  iseleq BASE, BASE, TMP0		// Either keep top or shrink it.
+  |  b <3
+  |
+  |8:  // Corner case: need to grow stack for filling up results.
+  |  // This can happen if:
+  |  // - A C function grows the stack (a lot).
+  |  // - The GC shrinks the stack in between.
+  |  // - A return back from a lua_call() with (high) nresults adjustment.
+  |  stw BASE, L->top			// Save current top held in BASE (yes).
+  |   mr SAVE0, RD
+  |  mr CARG2, TMP2
+  |  mr CARG1, L
+  |  bl extern lj_state_growstack	// (lua_State *L, int n)
+  |    lwz TMP2, SAVE_NRES
+  |   mr RD, SAVE0
+  |    slwi TMP2, TMP2, 3
+  |  lwz BASE, L->top			// Need the (realloced) L->top in BASE.
+  |  b <2
+  |
+  |->vm_unwind_c:			// Unwind C stack, return from vm_pcall.
+  |  // (void *cframe, int errcode)
+  |  mr sp, CARG1
+  |  mr CRET1, CARG2
+  |->vm_unwind_c_eh:			// Landing pad for external unwinder.
+  |  lwz L, SAVE_L
+  |   li TMP0, ~LJ_VMST_C
+  |  lwz GL:TMP1, L->glref
+  |   stw TMP0, GL:TMP1->vmstate
+  |  b ->vm_leave_unw
+  |
+  |->vm_unwind_ff:			// Unwind C stack, return from ff pcall.
+  |  // (void *cframe)
+  |  rlwinm sp, CARG1, 0, 0, 29
+  |->vm_unwind_ff_eh:			// Landing pad for external unwinder.
+  |  lwz L, SAVE_L
+  |     evsplati TISNUM, LJ_TISNUM+1	// Setup type comparison constants.
+  |     evsplati TISFUNC, LJ_TFUNC
+  |     lus TOBIT, 0x4338
+  |     evsplati TISTAB, LJ_TTAB
+  |     li TMP0, 0
+  |  lwz BASE, L->base
+  |     evmergelo TOBIT, TOBIT, TMP0
+  |   lwz DISPATCH, L->glref		// Setup pointer to dispatch table.
+  |     evsplati TISSTR, LJ_TSTR
+  |  li TMP1, LJ_TFALSE
+  |     evsplati TISNIL, LJ_TNIL
+  |    li_vmstate INTERP
+  |  lwz PC, FRAME_PC(BASE)		// Fetch PC of previous frame.
+  |  la RA, -8(BASE)			// Results start at BASE-8.
+  |   addi DISPATCH, DISPATCH, GG_G2DISP
+  |  stw TMP1, 0(RA)			// Prepend false to error message.
+  |  li RD, 16				// 2 results: false + error message.
+  |    st_vmstate
+  |  b ->vm_returnc
+  |
+  |//-----------------------------------------------------------------------
+  |//-- Grow stack for calls -----------------------------------------------
+  |//-----------------------------------------------------------------------
+  |
+  |->vm_growstack_c:			// Grow stack for C function.
+  |  li CARG2, LUA_MINSTACK
+  |  b >2
+  |
+  |->vm_growstack_l:			// Grow stack for Lua function.
+  |  // BASE = new base, RA = BASE+framesize*8, RC = nargs*8, PC = first PC
+  |  add RC, BASE, RC
+  |   sub RA, RA, BASE
+  |  stw BASE, L->base
+  |   addi PC, PC, 4			// Must point after first instruction.
+  |  stw RC, L->top
+  |   srwi CARG2, RA, 3
+  |2:
+  |  // L->base = new base, L->top = top
+  |   stw PC, SAVE_PC
+  |  mr CARG1, L
+  |  bl extern lj_state_growstack	// (lua_State *L, int n)
+  |  lwz BASE, L->base
+  |  lwz RC, L->top
+  |  lwz LFUNC:RB, FRAME_FUNC(BASE)
+  |  sub RC, RC, BASE
+  |  // BASE = new base, RB = LFUNC/CFUNC, RC = nargs*8, FRAME_PC(BASE) = PC
+  |  ins_callt				// Just retry the call.
+  |
+  |//-----------------------------------------------------------------------
+  |//-- Entry points into the assembler VM ---------------------------------
+  |//-----------------------------------------------------------------------
+  |
+  |->vm_resume:				// Setup C frame and resume thread.
+  |  // (lua_State *L, TValue *base, int nres1 = 0, ptrdiff_t ef = 0)
+  |  saveregs
+  |  mr L, CARG1
+  |    lwz DISPATCH, L->glref		// Setup pointer to dispatch table.
+  |  mr BASE, CARG2
+  |    lbz TMP1, L->status
+  |   stw L, SAVE_L
+  |  li PC, FRAME_CP
+  |  addi TMP0, sp, CFRAME_RESUME
+  |    addi DISPATCH, DISPATCH, GG_G2DISP
+  |   stw CARG3, SAVE_NRES
+  |    cmplwi TMP1, 0
+  |   stw CARG3, SAVE_ERRF
+  |  stw TMP0, L->cframe
+  |   stw CARG3, SAVE_CFRAME
+  |   stw CARG1, SAVE_PC		// Any value outside of bytecode is ok.
+  |    beq >3
+  |
+  |  // Resume after yield (like a return).
+  |  mr RA, BASE
+  |   lwz BASE, L->base
+  |    evsplati TISNUM, LJ_TISNUM+1	// Setup type comparison constants.
+  |   lwz TMP1, L->top
+  |    evsplati TISFUNC, LJ_TFUNC
+  |    lus TOBIT, 0x4338
+  |    evsplati TISTAB, LJ_TTAB
+  |  lwz PC, FRAME_PC(BASE)
+  |    li TMP2, 0
+  |    evsplati TISSTR, LJ_TSTR
+  |   sub RD, TMP1, BASE
+  |    evmergelo TOBIT, TOBIT, TMP2
+  |    stb CARG3, L->status
+  |  andi. TMP0, PC, FRAME_TYPE
+  |    li_vmstate INTERP
+  |   addi RD, RD, 8
+  |    evsplati TISNIL, LJ_TNIL
+  |   mr MULTRES, RD
+  |    st_vmstate
+  |  beq ->BC_RET_Z
+  |  b ->vm_return
+  |
+  |->vm_pcall:				// Setup protected C frame and enter VM.
+  |  // (lua_State *L, TValue *base, int nres1, ptrdiff_t ef)
+  |  saveregs
+  |  li PC, FRAME_CP
+  |  stw CARG4, SAVE_ERRF
+  |  b >1
+  |
+  |->vm_call:				// Setup C frame and enter VM.
+  |  // (lua_State *L, TValue *base, int nres1)
+  |  saveregs
+  |  li PC, FRAME_C
+  |
+  |1:  // Entry point for vm_pcall above (PC = ftype).
+  |  lwz TMP1, L:CARG1->cframe
+  |   stw CARG3, SAVE_NRES
+  |    mr L, CARG1
+  |   stw CARG1, SAVE_L
+  |    mr BASE, CARG2
+  |  stw sp, L->cframe			// Add our C frame to cframe chain.
+  |    lwz DISPATCH, L->glref		// Setup pointer to dispatch table.
+  |   stw CARG1, SAVE_PC		// Any value outside of bytecode is ok.
+  |  stw TMP1, SAVE_CFRAME
+  |    addi DISPATCH, DISPATCH, GG_G2DISP
+  |
+  |3:  // Entry point for vm_cpcall/vm_resume (BASE = base, PC = ftype).
+  |  lwz TMP2, L->base			// TMP2 = old base (used in vmeta_call).
+  |    evsplati TISNUM, LJ_TISNUM+1	// Setup type comparison constants.
+  |   lwz TMP1, L->top
+  |    evsplati TISFUNC, LJ_TFUNC
+  |  add PC, PC, BASE
+  |    evsplati TISTAB, LJ_TTAB
+  |    lus TOBIT, 0x4338
+  |    li TMP0, 0
+  |  sub PC, PC, TMP2			// PC = frame delta + frame type
+  |    evsplati TISSTR, LJ_TSTR
+  |   sub NARGS8:RC, TMP1, BASE
+  |    evmergelo TOBIT, TOBIT, TMP0
+  |    li_vmstate INTERP
+  |    evsplati TISNIL, LJ_TNIL
+  |    st_vmstate
+  |
+  |->vm_call_dispatch:
+  |  // TMP2 = old base, BASE = new base, RC = nargs*8, PC = caller PC
+  |  li TMP0, -8
+  |  evlddx LFUNC:RB, BASE, TMP0
+  |  checkfunc LFUNC:RB
+  |  checkfail ->vmeta_call
+  |
+  |->vm_call_dispatch_f:
+  |  ins_call
+  |  // BASE = new base, RB = func, RC = nargs*8, PC = caller PC
+  |
+  |->vm_cpcall:				// Setup protected C frame, call C.
+  |  // (lua_State *L, lua_CFunction func, void *ud, lua_CPFunction cp)
+  |  saveregs
+  |  mr L, CARG1
+  |   lwz TMP0, L:CARG1->stack
+  |  stw CARG1, SAVE_L
+  |   lwz TMP1, L->top
+  |  stw CARG1, SAVE_PC			// Any value outside of bytecode is ok.
+  |   sub TMP0, TMP0, TMP1		// Compute -savestack(L, L->top).
+  |    lwz TMP1, L->cframe
+  |    stw sp, L->cframe		// Add our C frame to cframe chain.
+  |  li TMP2, 0
+  |   stw TMP0, SAVE_NRES		// Neg. delta means cframe w/o frame.
+  |  stw TMP2, SAVE_ERRF		// No error function.
+  |    stw TMP1, SAVE_CFRAME
+  |  mtctr CARG4
+  |  bctrl			// (lua_State *L, lua_CFunction func, void *ud)
+  |  mr. BASE, CRET1
+  |   lwz DISPATCH, L->glref		// Setup pointer to dispatch table.
+  |    li PC, FRAME_CP
+  |   addi DISPATCH, DISPATCH, GG_G2DISP
+  |  bne <3				// Else continue with the call.
+  |  b ->vm_leave_cp			// No base? Just remove C frame.
+  |
+  |//-----------------------------------------------------------------------
+  |//-- Metamethod handling ------------------------------------------------
+  |//-----------------------------------------------------------------------
+  |
+  |// The lj_meta_* functions (except for lj_meta_cat) don't reallocate the
+  |// stack, so BASE doesn't need to be reloaded across these calls.
+  |
+  |//-- Continuation dispatch ----------------------------------------------
+  |
+  |->cont_dispatch:
+  |  // BASE = meta base, RA = resultptr, RD = (nresults+1)*8
+  |  lwz TMP0, -12(BASE)		// Continuation.
+  |   mr RB, BASE
+  |   mr BASE, TMP2			// Restore caller BASE.
+  |    lwz LFUNC:TMP1, FRAME_FUNC(TMP2)
+  |  cmplwi TMP0, 0
+  |     lwz PC, -16(RB)			// Restore PC from [cont|PC].
+  |  beq >1
+  |   subi TMP2, RD, 8
+  |    lwz TMP1, LFUNC:TMP1->pc
+  |   evstddx TISNIL, RA, TMP2		// Ensure one valid arg.
+  |    lwz KBASE, PC2PROTO(k)(TMP1)
+  |  // BASE = base, RA = resultptr, RB = meta base
+  |  mtctr TMP0
+  |  bctr				// Jump to continuation.
+  |
+  |1:  // Tail call from C function.
+  |  subi TMP1, RB, 16
+  |  sub RC, TMP1, BASE
+  |  b ->vm_call_tail
+  |
+  |->cont_cat:				// RA = resultptr, RB = meta base
+  |  lwz INS, -4(PC)
+  |   subi CARG2, RB, 16
+  |  decode_RB8 SAVE0, INS
+  |   evldd TMP0, 0(RA)
+  |  add TMP1, BASE, SAVE0
+  |   stw BASE, L->base
+  |  cmplw TMP1, CARG2
+  |   sub CARG3, CARG2, TMP1
+  |  decode_RA8 RA, INS
+  |   evstdd TMP0, 0(CARG2)
+  |  bne ->BC_CAT_Z
+  |   evstddx TMP0, BASE, RA
+  |  b ->cont_nop
+  |
+  |//-- Table indexing metamethods -----------------------------------------
+  |
+  |->vmeta_tgets1:
+  |  evmergelo STR:RC, TISSTR, STR:RC
+  |  la CARG3, DISPATCH_GL(tmptv)(DISPATCH)
+  |   decode_RB8 RB, INS
+  |  evstdd STR:RC, 0(CARG3)
+  |   add CARG2, BASE, RB
+  |  b >1
+  |
+  |->vmeta_tgets:
+  |  evmergelo TAB:RB, TISTAB, TAB:RB
+  |  la CARG2, DISPATCH_GL(tmptv)(DISPATCH)
+  |   evmergelo STR:RC, TISSTR, STR:RC
+  |  evstdd TAB:RB, 0(CARG2)
+  |   la CARG3, DISPATCH_GL(tmptv2)(DISPATCH)
+  |   evstdd STR:RC, 0(CARG3)
+  |  b >1
+  |
+  |->vmeta_tgetb:			// TMP0 = index
+  |  efdcfsi TMP0, TMP0
+  |   decode_RB8 RB, INS
+  |  la CARG3, DISPATCH_GL(tmptv)(DISPATCH)
+  |   add CARG2, BASE, RB
+  |  evstdd TMP0, 0(CARG3)
+  |  b >1
+  |
+  |->vmeta_tgetv:
+  |  decode_RB8 RB, INS
+  |   decode_RC8 RC, INS
+  |  add CARG2, BASE, RB
+  |   add CARG3, BASE, RC
+  |1:
+  |  stw BASE, L->base
+  |  mr CARG1, L
+  |  stw PC, SAVE_PC
+  |  bl extern lj_meta_tget		// (lua_State *L, TValue *o, TValue *k)
+  |  // Returns TValue * (finished) or NULL (metamethod).
+  |  cmplwi CRET1, 0
+  |  beq >3
+  |  evldd TMP0, 0(CRET1)
+  |  evstddx TMP0, BASE, RA
+  |  ins_next
+  |
+  |3:  // Call __index metamethod.
+  |  // BASE = base, L->top = new base, stack = cont/func/t/k
+  |  subfic TMP1, BASE, FRAME_CONT
+  |  lwz BASE, L->top
+  |  stw PC, -16(BASE)			// [cont|PC]
+  |   add PC, TMP1, BASE
+  |  lwz LFUNC:RB, FRAME_FUNC(BASE)	// Guaranteed to be a function here.
+  |   li NARGS8:RC, 16			// 2 args for func(t, k).
+  |  b ->vm_call_dispatch_f
+  |
+  |//-----------------------------------------------------------------------
+  |
+  |->vmeta_tsets1:
+  |  evmergelo STR:RC, TISSTR, STR:RC
+  |  la CARG3, DISPATCH_GL(tmptv)(DISPATCH)
+  |   decode_RB8 RB, INS
+  |  evstdd STR:RC, 0(CARG3)
+  |   add CARG2, BASE, RB
+  |  b >1
+  |
+  |->vmeta_tsets:
+  |  evmergelo TAB:RB, TISTAB, TAB:RB
+  |  la CARG2, DISPATCH_GL(tmptv)(DISPATCH)
+  |   evmergelo STR:RC, TISSTR, STR:RC
+  |  evstdd TAB:RB, 0(CARG2)
+  |   la CARG3, DISPATCH_GL(tmptv2)(DISPATCH)
+  |   evstdd STR:RC, 0(CARG3)
+  |  b >1
+  |
+  |->vmeta_tsetb:			// TMP0 = index
+  |  efdcfsi TMP0, TMP0
+  |   decode_RB8 RB, INS
+  |  la CARG3, DISPATCH_GL(tmptv)(DISPATCH)
+  |   add CARG2, BASE, RB
+  |  evstdd TMP0, 0(CARG3)
+  |  b >1
+  |
+  |->vmeta_tsetv:
+  |  decode_RB8 RB, INS
+  |   decode_RC8 RC, INS
+  |  add CARG2, BASE, RB
+  |   add CARG3, BASE, RC
+  |1:
+  |  stw BASE, L->base
+  |  mr CARG1, L
+  |  stw PC, SAVE_PC
+  |  bl extern lj_meta_tset		// (lua_State *L, TValue *o, TValue *k)
+  |  // Returns TValue * (finished) or NULL (metamethod).
+  |  cmplwi CRET1, 0
+  |   evlddx TMP0, BASE, RA
+  |  beq >3
+  |  // NOBARRIER: lj_meta_tset ensures the table is not black.
+  |   evstdd TMP0, 0(CRET1)
+  |  ins_next
+  |
+  |3:  // Call __newindex metamethod.
+  |  // BASE = base, L->top = new base, stack = cont/func/t/k/(v)
+  |  subfic TMP1, BASE, FRAME_CONT
+  |  lwz BASE, L->top
+  |  stw PC, -16(BASE)			// [cont|PC]
+  |   add PC, TMP1, BASE
+  |  lwz LFUNC:RB, FRAME_FUNC(BASE)	// Guaranteed to be a function here.
+  |   li NARGS8:RC, 24			// 3 args for func(t, k, v)
+  |  evstdd TMP0, 16(BASE)		// Copy value to third argument.
+  |  b ->vm_call_dispatch_f
+  |
+  |//-- Comparison metamethods ---------------------------------------------
+  |
+  |->vmeta_comp:
+  |  mr CARG1, L
+  |   subi PC, PC, 4
+  |  add CARG2, BASE, RA
+  |   stw PC, SAVE_PC
+  |  add CARG3, BASE, RD
+  |   stw BASE, L->base
+  |  decode_OP1 CARG4, INS
+  |  bl extern lj_meta_comp  // (lua_State *L, TValue *o1, *o2, int op)
+  |  // Returns 0/1 or TValue * (metamethod).
+  |3:
+  |  cmplwi CRET1, 1
+  |  bgt ->vmeta_binop
+  |4:
+  |  lwz INS, 0(PC)
+  |   addi PC, PC, 4
+  |  decode_RD4 TMP2, INS
+  |  addis TMP3, PC, -(BCBIAS_J*4 >> 16)
+  |  add TMP2, TMP2, TMP3
+  |  isellt PC, PC, TMP2
+  |->cont_nop:
+  |  ins_next
+  |
+  |->cont_ra:				// RA = resultptr
+  |  lwz INS, -4(PC)
+  |   evldd TMP0, 0(RA)
+  |  decode_RA8 TMP1, INS
+  |   evstddx TMP0, BASE, TMP1
+  |  b ->cont_nop
+  |
+  |->cont_condt:			// RA = resultptr
+  |  lwz TMP0, 0(RA)
+  |   li TMP1, LJ_TTRUE
+  |  cmplw TMP1, TMP0			// Branch if result is true.
+  |  b <4
+  |
+  |->cont_condf:			// RA = resultptr
+  |  lwz TMP0, 0(RA)
+  |   li TMP1, LJ_TFALSE
+  |  cmplw TMP0, TMP1			// Branch if result is false.
+  |  b <4
+  |
+  |->vmeta_equal:
+  |  // CARG2, CARG3, CARG4 are already set by BC_ISEQV/BC_ISNEV.
+  |  subi PC, PC, 4
+  |   stw BASE, L->base
+  |  mr CARG1, L
+  |   stw PC, SAVE_PC
+  |  bl extern lj_meta_equal  // (lua_State *L, GCobj *o1, *o2, int ne)
+  |  // Returns 0/1 or TValue * (metamethod).
+  |  b <3
+  |
+  |//-- Arithmetic metamethods ---------------------------------------------
+  |
+  |->vmeta_arith_vn:
+  |  add CARG3, BASE, RB
+  |  add CARG4, KBASE, RC
+  |  b >1
+  |
+  |->vmeta_arith_nv:
+  |  add CARG3, KBASE, RC
+  |  add CARG4, BASE, RB
+  |  b >1
+  |
+  |->vmeta_unm:
+  |  add CARG3, BASE, RD
+  |  mr CARG4, CARG3
+  |  b >1
+  |
+  |->vmeta_arith_vv:
+  |  add CARG3, BASE, RB
+  |  add CARG4, BASE, RC
+  |1:
+  |  add CARG2, BASE, RA
+  |   stw BASE, L->base
+  |  mr CARG1, L
+  |   stw PC, SAVE_PC
+  |  decode_OP1 CARG5, INS		// Caveat: CARG5 overlaps INS.
+  |  bl extern lj_meta_arith  // (lua_State *L, TValue *ra,*rb,*rc, BCReg op)
+  |  // Returns NULL (finished) or TValue * (metamethod).
+  |  cmplwi CRET1, 0
+  |  beq ->cont_nop
+  |
+  |  // Call metamethod for binary op.
+  |->vmeta_binop:
+  |  // BASE = old base, CRET1 = new base, stack = cont/func/o1/o2
+  |  sub TMP1, CRET1, BASE
+  |   stw PC, -16(CRET1)		// [cont|PC]
+  |   mr TMP2, BASE
+  |  addi PC, TMP1, FRAME_CONT
+  |   mr BASE, CRET1
+  |  li NARGS8:RC, 16			// 2 args for func(o1, o2).
+  |  b ->vm_call_dispatch
+  |
+  |->vmeta_len:
+#ifdef LUAJIT_ENABLE_LUA52COMPAT
+  |  mr SAVE0, CARG1
+#endif
+  |  add CARG2, BASE, RD
+  |   stw BASE, L->base
+  |  mr CARG1, L
+  |   stw PC, SAVE_PC
+  |  bl extern lj_meta_len		// (lua_State *L, TValue *o)
+  |  // Returns NULL (retry) or TValue * (metamethod base).
+#ifdef LUAJIT_ENABLE_LUA52COMPAT
+  |  cmplwi CRET1, 0
+  |  bne ->vmeta_binop			// Binop call for compatibility.
+  |  mr CARG1, SAVE0
+  |  b ->BC_LEN_Z
+#else
+  |  b ->vmeta_binop			// Binop call for compatibility.
+#endif
+  |
+  |//-- Call metamethod ----------------------------------------------------
+  |
+  |->vmeta_call:			// Resolve and call __call metamethod.
+  |  // TMP2 = old base, BASE = new base, RC = nargs*8
+  |  mr CARG1, L
+  |   stw TMP2, L->base			// This is the callers base!
+  |  subi CARG2, BASE, 8
+  |   stw PC, SAVE_PC
+  |  add CARG3, BASE, RC
+  |   mr SAVE0, NARGS8:RC
+  |  bl extern lj_meta_call	// (lua_State *L, TValue *func, TValue *top)
+  |  lwz LFUNC:RB, FRAME_FUNC(BASE)	// Guaranteed to be a function here.
+  |   addi NARGS8:RC, SAVE0, 8		// Got one more argument now.
+  |  ins_call
+  |
+  |->vmeta_callt:			// Resolve __call for BC_CALLT.
+  |  // BASE = old base, RA = new base, RC = nargs*8
+  |  mr CARG1, L
+  |   stw BASE, L->base
+  |  subi CARG2, RA, 8
+  |   stw PC, SAVE_PC
+  |  add CARG3, RA, RC
+  |   mr SAVE0, NARGS8:RC
+  |  bl extern lj_meta_call	// (lua_State *L, TValue *func, TValue *top)
+  |  lwz TMP1, FRAME_PC(BASE)
+  |   addi NARGS8:RC, SAVE0, 8		// Got one more argument now.
+  |   lwz LFUNC:RB, FRAME_FUNC(RA)	// Guaranteed to be a function here.
+  |  b ->BC_CALLT_Z
+  |
+  |//-- Argument coercion for 'for' statement ------------------------------
+  |
+  |->vmeta_for:
+  |  mr CARG1, L
+  |   stw BASE, L->base
+  |  mr CARG2, RA
+  |   stw PC, SAVE_PC
+  |  mr SAVE0, INS
+  |  bl extern lj_meta_for	// (lua_State *L, TValue *base)
+#if LJ_HASJIT
+  |   decode_OP1 TMP0, SAVE0
+#endif
+  |  decode_RA8 RA, SAVE0
+#if LJ_HASJIT
+  |   cmpwi TMP0, BC_JFORI
+#endif
+  |  decode_RD8 RD, SAVE0
+#if LJ_HASJIT
+  |   beq =>BC_JFORI
+#endif
+  |  b =>BC_FORI
+  |
+  |//-----------------------------------------------------------------------
+  |//-- Fast functions -----------------------------------------------------
+  |//-----------------------------------------------------------------------
+  |
+  |.macro .ffunc, name
+  |->ff_ .. name:
+  |.endmacro
+  |
+  |.macro .ffunc_1, name
+  |->ff_ .. name:
+  |  cmplwi NARGS8:RC, 8
+  |   evldd CARG1, 0(BASE)
+  |  blt ->fff_fallback
+  |.endmacro
+  |
+  |.macro .ffunc_2, name
+  |->ff_ .. name:
+  |  cmplwi NARGS8:RC, 16
+  |   evldd CARG1, 0(BASE)
+  |   evldd CARG2, 8(BASE)
+  |  blt ->fff_fallback
+  |.endmacro
+  |
+  |.macro .ffunc_n, name
+  |  .ffunc_1 name
+  |  checknum CARG1
+  |  checkfail ->fff_fallback
+  |.endmacro
+  |
+  |.macro .ffunc_nn, name
+  |  .ffunc_2 name
+  |  evmergehi TMP0, CARG1, CARG2
+  |  checknum TMP0
+  |  checkanyfail ->fff_fallback
+  |.endmacro
+  |
+  |// Inlined GC threshold check. Caveat: uses TMP0 and TMP1.
+  |.macro ffgccheck
+  |  lwz TMP0, DISPATCH_GL(gc.total)(DISPATCH)
+  |  lwz TMP1, DISPATCH_GL(gc.threshold)(DISPATCH)
+  |  cmplw TMP0, TMP1
+  |  bgel ->fff_gcstep
+  |.endmacro
+  |
+  |//-- Base library: checks -----------------------------------------------
+  |
+  |.ffunc assert
+  |  cmplwi NARGS8:RC, 8
+  |   evldd TMP0, 0(BASE)
+  |  blt ->fff_fallback
+  |  evaddw TMP1, TISNIL, TISNIL	// Synthesize LJ_TFALSE.
+  |  la RA, -8(BASE)
+  |   evcmpltu cr1, TMP0, TMP1
+  |    lwz PC, FRAME_PC(BASE)
+  |  bge cr1, ->fff_fallback
+  |   evstdd TMP0, 0(RA)
+  |  addi RD, NARGS8:RC, 8		// Compute (nresults+1)*8.
+  |   beq ->fff_res			// Done if exactly 1 argument.
+  |  li TMP1, 8
+  |  subi RC, RC, 8
+  |1:
+  |  cmplw TMP1, RC
+  |   evlddx TMP0, BASE, TMP1
+  |   evstddx TMP0, RA, TMP1
+  |    addi TMP1, TMP1, 8
+  |  bne <1
+  |  b ->fff_res
+  |
+  |.ffunc type
+  |  cmplwi NARGS8:RC, 8
+  |   lwz CARG1, 0(BASE)
+  |  blt ->fff_fallback
+  |    li TMP2, ~LJ_TNUMX
+  |  cmplw CARG1, TISNUM
+  |  not TMP1, CARG1
+  |  isellt TMP1, TMP2, TMP1
+  |  slwi TMP1, TMP1, 3
+  |   la TMP2, CFUNC:RB->upvalue
+  |  evlddx STR:CRET1, TMP2, TMP1
+  |  b ->fff_restv
+  |
+  |//-- Base library: getters and setters ---------------------------------
+  |
+  |.ffunc_1 getmetatable
+  |  checktab CARG1
+  |   evmergehi TMP1, CARG1, CARG1
+  |  checkfail >6
+  |1:  // Field metatable must be at same offset for GCtab and GCudata!
+  |  lwz TAB:RB, TAB:CARG1->metatable
+  |2:
+  |  evmr CRET1, TISNIL
+  |   cmplwi TAB:RB, 0
+  |  lwz STR:RC, DISPATCH_GL(gcroot[GCROOT_MMNAME+MM_metatable])(DISPATCH)
+  |   beq ->fff_restv
+  |  lwz TMP0, TAB:RB->hmask
+  |   evmergelo CRET1, TISTAB, TAB:RB	// Use metatable as default result.
+  |  lwz TMP1, STR:RC->hash
+  |  lwz NODE:TMP2, TAB:RB->node
+  |   evmergelo STR:RC, TISSTR, STR:RC
+  |  and TMP1, TMP1, TMP0		// idx = str->hash & tab->hmask
+  |  slwi TMP0, TMP1, 5
+  |  slwi TMP1, TMP1, 3
+  |  sub TMP1, TMP0, TMP1
+  |  add NODE:TMP2, NODE:TMP2, TMP1	// node = tab->node + (idx*32-idx*8)
+  |3:  // Rearranged logic, because we expect _not_ to find the key.
+  |  evldd TMP0, NODE:TMP2->key
+  |   evldd TMP1, NODE:TMP2->val
+  |  evcmpeq TMP0, STR:RC
+  |   lwz NODE:TMP2, NODE:TMP2->next
+  |  checkallok >5
+  |   cmplwi NODE:TMP2, 0
+  |   beq ->fff_restv			// Not found, keep default result.
+  |   b <3
+  |5:
+  |  checknil TMP1
+  |  checkok ->fff_restv		// Ditto for nil value.
+  |  evmr CRET1, TMP1			// Return value of mt.__metatable.
+  |  b ->fff_restv
+  |
+  |6:
+  |  cmpwi TMP1, LJ_TUDATA
+  |   not TMP1, TMP1
+  |  beq <1
+  |  checknum CARG1
+  |   slwi TMP1, TMP1, 2
+  |   li TMP2, 4*~LJ_TNUMX
+  |  isellt TMP1, TMP2, TMP1
+  |   la TMP2, DISPATCH_GL(gcroot[GCROOT_BASEMT])(DISPATCH)
+  |  lwzx TAB:RB, TMP2, TMP1
+  |  b <2
+  |
+  |.ffunc_2 setmetatable
+  |  // Fast path: no mt for table yet and not clearing the mt.
+  |  evmergehi TMP0, TAB:CARG1, TAB:CARG2
+  |  checktab TMP0
+  |  checkanyfail ->fff_fallback
+  |  lwz TAB:TMP1, TAB:CARG1->metatable
+  |  cmplwi TAB:TMP1, 0
+  |   lbz TMP3, TAB:CARG1->marked
+  |  bne ->fff_fallback
+  |   andi. TMP0, TMP3, LJ_GC_BLACK	// isblack(table)
+  |    stw TAB:CARG2, TAB:CARG1->metatable
+  |   beq ->fff_restv
+  |  barrierback TAB:CARG1, TMP3, TMP0
+  |  b ->fff_restv
+  |
+  |.ffunc rawget
+  |  cmplwi NARGS8:RC, 16
+  |   evldd CARG2, 0(BASE)
+  |  blt ->fff_fallback
+  |  checktab CARG2
+  |   la CARG3, 8(BASE)
+  |  checkfail ->fff_fallback
+  |   mr CARG1, L
+  |  bl extern lj_tab_get  // (lua_State *L, GCtab *t, cTValue *key)
+  |  // Returns cTValue *.
+  |  evldd CRET1, 0(CRET1)
+  |  b ->fff_restv
+  |
+  |//-- Base library: conversions ------------------------------------------
+  |
+  |.ffunc tonumber
+  |  // Only handles the number case inline (without a base argument).
+  |  cmplwi NARGS8:RC, 8
+  |   evldd CARG1, 0(BASE)
+  |  bne ->fff_fallback			// Exactly one argument.
+  |  checknum CARG1
+  |  checkok ->fff_restv
+  |  b ->fff_fallback
+  |
+  |.ffunc_1 tostring
+  |  // Only handles the string or number case inline.
+  |  checkstr CARG1
+  |  // A __tostring method in the string base metatable is ignored.
+  |  checkok ->fff_restv		// String key?
+  |  // Handle numbers inline, unless a number base metatable is present.
+  |  lwz TMP0, DISPATCH_GL(gcroot[GCROOT_BASEMT_NUM])(DISPATCH)
+  |  checknum CARG1
+  |  cmplwi cr1, TMP0, 0
+  |   stw BASE, L->base			// Add frame since C call can throw.
+  |  crand 4*cr0+eq, 4*cr0+lt, 4*cr1+eq
+  |   stw PC, SAVE_PC			// Redundant (but a defined value).
+  |  bne ->fff_fallback
+  |  ffgccheck
+  |  mr CARG1, L
+  |  mr CARG2, BASE
+  |  bl extern lj_str_fromnum		// (lua_State *L, lua_Number *np)
+  |  // Returns GCstr *.
+  |  evmergelo STR:CRET1, TISSTR, STR:CRET1
+  |  b ->fff_restv
+  |
+  |//-- Base library: iterators -------------------------------------------
+  |
+  |.ffunc next
+  |  cmplwi NARGS8:RC, 8
+  |   evldd CARG2, 0(BASE)
+  |  blt ->fff_fallback
+  |   evstddx TISNIL, BASE, NARGS8:RC	// Set missing 2nd arg to nil.
+  |  checktab TAB:CARG2
+  |   lwz PC, FRAME_PC(BASE)
+  |  checkfail ->fff_fallback
+  |   stw BASE, L->base			// Add frame since C call can throw.
+  |  mr CARG1, L
+  |   stw BASE, L->top			// Dummy frame length is ok.
+  |  la CARG3, 8(BASE)
+  |   stw PC, SAVE_PC
+  |  bl extern lj_tab_next	// (lua_State *L, GCtab *t, TValue *key)
+  |  // Returns 0 at end of traversal.
+  |  cmplwi CRET1, 0
+  |   evmr CRET1, TISNIL
+  |  beq ->fff_restv			// End of traversal: return nil.
+  |  evldd TMP0, 8(BASE)		// Copy key and value to results.
+  |   la RA, -8(BASE)
+  |  evldd TMP1, 16(BASE)
+  |  evstdd TMP0, 0(RA)
+  |   li RD, (2+1)*8
+  |  evstdd TMP1, 8(RA)
+  |  b ->fff_res
+  |
+  |.ffunc_1 pairs
+  |  checktab TAB:CARG1
+  |   lwz PC, FRAME_PC(BASE)
+  |  checkfail ->fff_fallback
+#ifdef LUAJIT_ENABLE_LUA52COMPAT
+  |   lwz TAB:TMP2, TAB:CARG1->metatable
+  |  evldd CFUNC:TMP0, CFUNC:RB->upvalue[0]
+  |   cmplwi TAB:TMP2, 0
+  |  la RA, -8(BASE)
+  |   bne ->fff_fallback
+#else
+  |  evldd CFUNC:TMP0, CFUNC:RB->upvalue[0]
+  |  la RA, -8(BASE)
+#endif
+  |   evstdd TISNIL, 8(BASE)
+  |  li RD, (3+1)*8
+  |  evstdd CFUNC:TMP0, 0(RA)
+  |  b ->fff_res
+  |
+  |.ffunc_2 ipairs_aux
+  |  checktab TAB:CARG1
+  |   lwz PC, FRAME_PC(BASE)
+  |  checkfail ->fff_fallback
+  |  checknum CARG2
+  |    lus TMP3, 0x3ff0
+  |  checkfail ->fff_fallback
+  |  efdctsi TMP2, CARG2
+  |   lwz TMP0, TAB:CARG1->asize
+  |    evmergelo TMP3, TMP3, ZERO
+  |   lwz TMP1, TAB:CARG1->array
+  |  efdadd CARG2, CARG2, TMP3
+  |  addi TMP2, TMP2, 1
+  |   la RA, -8(BASE)
+  |  cmplw TMP0, TMP2
+  |   slwi TMP3, TMP2, 3
+  |  evstdd CARG2, 0(RA)
+  |  ble >2				// Not in array part?
+  |  evlddx TMP1, TMP1, TMP3
+  |1:
+  |  checknil TMP1
+  |   li RD, (0+1)*8
+  |  checkok ->fff_res			// End of iteration, return 0 results.
+  |   li RD, (2+1)*8
+  |  evstdd TMP1, 8(RA)
+  |  b ->fff_res
+  |2:  // Check for empty hash part first. Otherwise call C function.
+  |  lwz TMP0, TAB:CARG1->hmask
+  |  cmplwi TMP0, 0
+  |   li RD, (0+1)*8
+  |  beq ->fff_res
+  |   mr CARG2, TMP2
+  |  bl extern lj_tab_getinth		// (GCtab *t, int32_t key)
+  |  // Returns cTValue * or NULL.
+  |  cmplwi CRET1, 0
+  |   li RD, (0+1)*8
+  |  beq ->fff_res
+  |  evldd TMP1, 0(CRET1)
+  |  b <1
+  |
+  |.ffunc_1 ipairs
+  |  checktab TAB:CARG1
+  |   lwz PC, FRAME_PC(BASE)
+  |  checkfail ->fff_fallback
+#ifdef LUAJIT_ENABLE_LUA52COMPAT
+  |   lwz TAB:TMP2, TAB:CARG1->metatable
+  |  evldd CFUNC:TMP0, CFUNC:RB->upvalue[0]
+  |   cmplwi TAB:TMP2, 0
+  |  la RA, -8(BASE)
+  |   bne ->fff_fallback
+#else
+  |  evldd CFUNC:TMP0, CFUNC:RB->upvalue[0]
+  |  la RA, -8(BASE)
+#endif
+  |    evsplati TMP1, 0
+  |  li RD, (3+1)*8
+  |    evstdd TMP1, 8(BASE)
+  |  evstdd CFUNC:TMP0, 0(RA)
+  |  b ->fff_res
+  |
+  |//-- Base library: catch errors ----------------------------------------
+  |
+  |.ffunc pcall
+  |  cmplwi NARGS8:RC, 8
+  |   lbz TMP3, DISPATCH_GL(hookmask)(DISPATCH)
+  |  blt ->fff_fallback
+  |   mr TMP2, BASE
+  |   la BASE, 8(BASE)
+  |  // Remember active hook before pcall.
+  |  rlwinm TMP3, TMP3, 32-HOOK_ACTIVE_SHIFT, 31, 31
+  |   subi NARGS8:RC, NARGS8:RC, 8
+  |  addi PC, TMP3, 8+FRAME_PCALL
+  |  b ->vm_call_dispatch
+  |
+  |.ffunc_2 xpcall
+  |  lbz TMP3, DISPATCH_GL(hookmask)(DISPATCH)
+  |   mr TMP2, BASE
+  |  checkfunc CARG2			// Traceback must be a function.
+  |  checkfail ->fff_fallback
+  |   la BASE, 16(BASE)
+  |  // Remember active hook before pcall.
+  |  rlwinm TMP3, TMP3, 32-HOOK_ACTIVE_SHIFT, 31, 31
+  |   evstdd CARG2, 0(TMP2)		// Swap function and traceback.
+  |  subi NARGS8:RC, NARGS8:RC, 16
+  |   evstdd CARG1, 8(TMP2)
+  |  addi PC, TMP3, 16+FRAME_PCALL
+  |  b ->vm_call_dispatch
+  |
+  |//-- Coroutine library --------------------------------------------------
+  |
+  |.macro coroutine_resume_wrap, resume
+  |.if resume
+  |.ffunc_1 coroutine_resume
+  |  evmergehi TMP0, L:CARG1, L:CARG1
+  |.else
+  |.ffunc coroutine_wrap_aux
+  |  lwz L:CARG1, CFUNC:RB->upvalue[0].gcr
+  |.endif
+  |.if resume
+  |  cmpwi TMP0, LJ_TTHREAD
+  |  bne ->fff_fallback
+  |.endif
+  |  lbz TMP0, L:CARG1->status
+  |   lwz TMP1, L:CARG1->cframe
+  |    lwz CARG2, L:CARG1->top
+  |  cmplwi cr0, TMP0, LUA_YIELD
+  |    lwz TMP2, L:CARG1->base
+  |   cmplwi cr1, TMP1, 0
+  |   lwz TMP0, L:CARG1->maxstack
+  |    cmplw cr7, CARG2, TMP2
+  |   lwz PC, FRAME_PC(BASE)
+  |  crorc 4*cr6+lt, 4*cr0+gt, 4*cr1+eq		// st>LUA_YIELD || cframe!=0
+  |   add TMP2, CARG2, NARGS8:RC
+  |  crandc 4*cr6+gt, 4*cr7+eq, 4*cr0+eq	// base==top && st!=LUA_YIELD
+  |   cmplw cr1, TMP2, TMP0
+  |  cror 4*cr6+lt, 4*cr6+lt, 4*cr6+gt
+  |   stw PC, SAVE_PC
+  |  cror 4*cr6+lt, 4*cr6+lt, 4*cr1+gt		// cond1 || cond2 || stackov
+  |   stw BASE, L->base
+  |  blt cr6, ->fff_fallback
+  |1:
+  |.if resume
+  |  addi BASE, BASE, 8			// Keep resumed thread in stack for GC.
+  |  subi NARGS8:RC, NARGS8:RC, 8
+  |  subi TMP2, TMP2, 8
+  |.endif
+  |  stw TMP2, L:CARG1->top
+  |  li TMP1, 0
+  |  stw BASE, L->top
+  |2:  // Move args to coroutine.
+  |  cmpw TMP1, NARGS8:RC
+  |   evlddx TMP0, BASE, TMP1
+  |  beq >3
+  |   evstddx TMP0, CARG2, TMP1
+  |  addi TMP1, TMP1, 8
+  |  b <2
+  |3:
+  |  li CARG3, 0
+  |   mr L:SAVE0, L:CARG1
+  |  li CARG4, 0
+  |  bl ->vm_resume			// (lua_State *L, TValue *base, 0, 0)
+  |  // Returns thread status.
+  |4:
+  |  lwz TMP2, L:SAVE0->base
+  |   cmplwi CRET1, LUA_YIELD
+  |  lwz TMP3, L:SAVE0->top
+  |    li_vmstate INTERP
+  |  lwz BASE, L->base
+  |    st_vmstate
+  |   bgt >8
+  |  sub RD, TMP3, TMP2
+  |   lwz TMP0, L->maxstack
+  |  cmplwi RD, 0
+  |   add TMP1, BASE, RD
+  |  beq >6				// No results?
+  |  cmplw TMP1, TMP0
+  |   li TMP1, 0
+  |  bgt >9				// Need to grow stack?
+  |
+  |  subi TMP3, RD, 8
+  |   stw TMP2, L:SAVE0->top		// Clear coroutine stack.
+  |5:  // Move results from coroutine.
+  |  cmplw TMP1, TMP3
+  |   evlddx TMP0, TMP2, TMP1
+  |   evstddx TMP0, BASE, TMP1
+  |    addi TMP1, TMP1, 8
+  |  bne <5
+  |6:
+  |  andi. TMP0, PC, FRAME_TYPE
+  |.if resume
+  |  li TMP1, LJ_TTRUE
+  |   la RA, -8(BASE)
+  |  stw TMP1, -8(BASE)			// Prepend true to results.
+  |  addi RD, RD, 16
+  |.else
+  |  mr RA, BASE
+  |  addi RD, RD, 8
+  |.endif
+  |7:
+  |    stw PC, SAVE_PC
+  |   mr MULTRES, RD
+  |  beq ->BC_RET_Z
+  |  b ->vm_return
+  |
+  |8:  // Coroutine returned with error (at co->top-1).
+  |.if resume
+  |  andi. TMP0, PC, FRAME_TYPE
+  |  la TMP3, -8(TMP3)
+  |   li TMP1, LJ_TFALSE
+  |  evldd TMP0, 0(TMP3)
+  |   stw TMP3, L:SAVE0->top		// Remove error from coroutine stack.
+  |    li RD, (2+1)*8
+  |   stw TMP1, -8(BASE)		// Prepend false to results.
+  |    la RA, -8(BASE)
+  |  evstdd TMP0, 0(BASE)		// Copy error message.
+  |  b <7
+  |.else
+  |  mr CARG1, L
+  |  mr CARG2, L:SAVE0
+  |  bl extern lj_ffh_coroutine_wrap_err  // (lua_State *L, lua_State *co)
+  |.endif
+  |
+  |9:  // Handle stack expansion on return from yield.
+  |  mr CARG1, L
+  |  srwi CARG2, RD, 3
+  |  bl extern lj_state_growstack	// (lua_State *L, int n)
+  |  li CRET1, 0
+  |  b <4
+  |.endmacro
+  |
+  |  coroutine_resume_wrap 1		// coroutine.resume
+  |  coroutine_resume_wrap 0		// coroutine.wrap
+  |
+  |.ffunc coroutine_yield
+  |  lwz TMP0, L->cframe
+  |   add TMP1, BASE, NARGS8:RC
+  |   stw BASE, L->base
+  |  andi. TMP0, TMP0, CFRAME_RESUME
+  |   stw TMP1, L->top
+  |    li CRET1, LUA_YIELD
+  |  beq ->fff_fallback
+  |   stw ZERO, L->cframe
+  |    stb CRET1, L->status
+  |  b ->vm_leave_unw
+  |
+  |//-- Math library -------------------------------------------------------
+  |
+  |.ffunc_n math_abs
+  |  efdabs CRET1, CARG1
+  |  // Fallthrough.
+  |
+  |->fff_restv:
+  |  // CRET1 = TValue result.
+  |  lwz PC, FRAME_PC(BASE)
+  |   la RA, -8(BASE)
+  |  evstdd CRET1, 0(RA)
+  |->fff_res1:
+  |  // RA = results, PC = return.
+  |  li RD, (1+1)*8
+  |->fff_res:
+  |  // RA = results, RD = (nresults+1)*8, PC = return.
+  |  andi. TMP0, PC, FRAME_TYPE
+  |   mr MULTRES, RD
+  |  bne ->vm_return
+  |  lwz INS, -4(PC)
+  |  decode_RB8 RB, INS
+  |5:
+  |  cmplw RB, RD			// More results expected?
+  |   decode_RA8 TMP0, INS
+  |  bgt >6
+  |  ins_next1
+  |  // Adjust BASE. KBASE is assumed to be set for the calling frame.
+  |   sub BASE, RA, TMP0
+  |  ins_next2
+  |
+  |6:  // Fill up results with nil.
+  |  subi TMP1, RD, 8
+  |   addi RD, RD, 8
+  |  evstddx TISNIL, RA, TMP1
+  |  b <5
+  |
+  |.macro math_extern, func
+  |  .ffunc math_ .. func
+  |  cmplwi NARGS8:RC, 8
+  |   evldd CARG2, 0(BASE)
+  |  blt ->fff_fallback
+  |  checknum CARG2
+  |   evmergehi CARG1, CARG2, CARG2
+  |  checkfail ->fff_fallback
+  |  bl extern func
+  |  evmergelo CRET1, CRET1, CRET2
+  |  b ->fff_restv
+  |.endmacro
+  |
+  |.macro math_extern2, func
+  |  .ffunc math_ .. func
+  |  cmplwi NARGS8:RC, 16
+  |   evldd CARG2, 0(BASE)
+  |   evldd CARG4, 8(BASE)
+  |  blt ->fff_fallback
+  |  evmergehi CARG1, CARG4, CARG2
+  |  checknum CARG1
+  |   evmergehi CARG3, CARG4, CARG4
+  |  checkanyfail ->fff_fallback
+  |  bl extern func
+  |  evmergelo CRET1, CRET1, CRET2
+  |  b ->fff_restv
+  |.endmacro
+  |
+  |.macro math_round, func
+  |  .ffunc math_ .. func
+  |  cmplwi NARGS8:RC, 8
+  |   evldd CARG2, 0(BASE)
+  |  blt ->fff_fallback
+  |  checknum CARG2
+  |   evmergehi CARG1, CARG2, CARG2
+  |  checkfail ->fff_fallback
+  |   lwz PC, FRAME_PC(BASE)
+  |  bl ->vm_..func.._hilo;
+  |  la RA, -8(BASE)
+  |  evstdd CRET2, 0(RA)
+  |  b ->fff_res1
+  |.endmacro
+  |
+  |  math_round floor
+  |  math_round ceil
+  |
+  |  math_extern sqrt
+  |  math_extern log
+  |  math_extern log10
+  |  math_extern exp
+  |  math_extern sin
+  |  math_extern cos
+  |  math_extern tan
+  |  math_extern asin
+  |  math_extern acos
+  |  math_extern atan
+  |  math_extern sinh
+  |  math_extern cosh
+  |  math_extern tanh
+  |  math_extern2 pow
+  |  math_extern2 atan2
+  |  math_extern2 fmod
+  |
+  |->ff_math_deg:
+  |.ffunc_n math_rad
+  |  evldd CARG2, CFUNC:RB->upvalue[0]
+  |  efdmul CRET1, CARG1, CARG2
+  |  b ->fff_restv
+  |
+  |.ffunc math_ldexp
+  |  cmplwi NARGS8:RC, 16
+  |   evldd CARG2, 0(BASE)
+  |   evldd CARG4, 8(BASE)
+  |  blt ->fff_fallback
+  |  evmergehi CARG1, CARG4, CARG2
+  |  checknum CARG1
+  |  checkanyfail ->fff_fallback
+  |  efdctsi CARG3, CARG4
+  |  bl extern ldexp
+  |  evmergelo CRET1, CRET1, CRET2
+  |  b ->fff_restv
+  |
+  |.ffunc math_frexp
+  |  cmplwi NARGS8:RC, 8
+  |   evldd CARG2, 0(BASE)
+  |  blt ->fff_fallback
+  |  checknum CARG2
+  |   evmergehi CARG1, CARG2, CARG2
+  |  checkfail ->fff_fallback
+  |  la CARG3, DISPATCH_GL(tmptv)(DISPATCH)
+  |   lwz PC, FRAME_PC(BASE)
+  |  bl extern frexp
+  |   lwz TMP1, DISPATCH_GL(tmptv)(DISPATCH)
+  |  evmergelo CRET1, CRET1, CRET2
+  |   efdcfsi CRET2, TMP1
+  |   la RA, -8(BASE)
+  |  evstdd CRET1, 0(RA)
+  |  li RD, (2+1)*8
+  |   evstdd CRET2, 8(RA)
+  |  b ->fff_res
+  |
+  |.ffunc math_modf
+  |  cmplwi NARGS8:RC, 8
+  |   evldd CARG2, 0(BASE)
+  |  blt ->fff_fallback
+  |  checknum CARG2
+  |   evmergehi CARG1, CARG2, CARG2
+  |  checkfail ->fff_fallback
+  |  la CARG3, -8(BASE)
+  |   lwz PC, FRAME_PC(BASE)
+  |  bl extern modf
+  |  evmergelo CRET1, CRET1, CRET2
+  |   la RA, -8(BASE)
+  |  evstdd CRET1, 0(BASE)
+  |  li RD, (2+1)*8
+  |  b ->fff_res
+  |
+  |.macro math_minmax, name, cmpop
+  |  .ffunc_1 name
+  |  checknum CARG1
+  |   li TMP1, 8
+  |  checkfail ->fff_fallback
+  |1:
+  |  evlddx CARG2, BASE, TMP1
+  |  cmplw cr1, TMP1, NARGS8:RC
+  |   checknum CARG2
+  |  bge cr1, ->fff_restv		// Ok, since CRET1 = CARG1.
+  |   checkfail ->fff_fallback
+  |  cmpop CARG2, CARG1
+  |   addi TMP1, TMP1, 8
+  |  crmove 4*cr0+lt, 4*cr0+gt
+  |  evsel CARG1, CARG2, CARG1
+  |  b <1
+  |.endmacro
+  |
+  |  math_minmax math_min, efdtstlt
+  |  math_minmax math_max, efdtstgt
+  |
+  |//-- String library -----------------------------------------------------
+  |
+  |.ffunc_1 string_len
+  |  checkstr STR:CARG1
+  |  checkfail ->fff_fallback
+  |  lwz TMP0, STR:CARG1->len
+  |  efdcfsi CRET1, TMP0
+  |  b ->fff_restv
+  |
+  |.ffunc string_byte			// Only handle the 1-arg case here.
+  |  cmplwi NARGS8:RC, 8
+  |   evldd STR:CARG1, 0(BASE)
+  |  bne ->fff_fallback			// Need exactly 1 argument.
+  |  checkstr STR:CARG1
+  |   la RA, -8(BASE)
+  |  checkfail ->fff_fallback
+  |  lwz TMP0, STR:CARG1->len
+  |   li RD, (0+1)*8
+  |    lbz TMP1, STR:CARG1[1]		// Access is always ok (NUL at end).
+  |   li TMP2, (1+1)*8
+  |  cmplwi TMP0, 0
+  |   lwz PC, FRAME_PC(BASE)
+  |    efdcfsi CRET1, TMP1
+  |  iseleq RD, RD, TMP2
+  |    evstdd CRET1, 0(RA)
+  |  b ->fff_res
+  |
+  |.ffunc string_char			// Only handle the 1-arg case here.
+  |  ffgccheck
+  |  cmplwi NARGS8:RC, 8
+  |   evldd CARG1, 0(BASE)
+  |  bne ->fff_fallback			// Exactly 1 argument.
+  |  checknum CARG1
+  |   la CARG2, DISPATCH_GL(tmptv)(DISPATCH)
+  |  checkfail ->fff_fallback
+  |  efdctsiz TMP0, CARG1
+  |   li CARG3, 1
+  |  cmplwi TMP0, 255
+  |   stb TMP0, 0(CARG2)
+  |  bgt ->fff_fallback
+  |->fff_newstr:
+  |  mr CARG1, L
+  |  stw BASE, L->base
+  |  stw PC, SAVE_PC
+  |  bl extern lj_str_new		// (lua_State *L, char *str, size_t l)
+  |  // Returns GCstr *.
+  |  lwz BASE, L->base
+  |   evmergelo STR:CRET1, TISSTR, STR:CRET1
+  |  b ->fff_restv
+  |
+  |.ffunc string_sub
+  |  ffgccheck
+  |  cmplwi NARGS8:RC, 16
+  |   evldd CARG3, 16(BASE)
+  |   evldd STR:CARG1, 0(BASE)
+  |  blt ->fff_fallback
+  |   evldd CARG2, 8(BASE)
+  |   li TMP2, -1
+  |  beq >1
+  |  checknum CARG3
+  |  checkfail ->fff_fallback
+  |  efdctsiz TMP2, CARG3
+  |1:
+  |  checknum CARG2
+  |  checkfail ->fff_fallback
+  |  checkstr STR:CARG1
+  |   efdctsiz TMP1, CARG2
+  |  checkfail ->fff_fallback
+  |   lwz TMP0, STR:CARG1->len
+  |  cmplw TMP0, TMP2			// len < end? (unsigned compare)
+  |   add TMP3, TMP2, TMP0
+  |  blt >5
+  |2:
+  |  cmpwi TMP1, 0			// start <= 0?
+  |   add TMP3, TMP1, TMP0
+  |  ble >7
+  |3:
+  |  sub. CARG3, TMP2, TMP1
+  |    addi CARG2, STR:CARG1, #STR-1
+  |   addi CARG3, CARG3, 1
+  |    add CARG2, CARG2, TMP1
+  |  isellt CARG3, r0, CARG3
+  |  b ->fff_newstr
+  |
+  |5:  // Negative end or overflow.
+  |  cmpw TMP0, TMP2
+  |   addi TMP3, TMP3, 1
+  |  iselgt TMP2, TMP3, TMP0		// end = end > len ? len : end+len+1
+  |  b <2
+  |
+  |7:  // Negative start or underflow.
+  |   cmpwi cr1, TMP3, 0
+  |  iseleq TMP1, r0, TMP3
+  |   isel TMP1, r0, TMP1, 4*cr1+lt
+  |  addi TMP1, TMP1, 1			// start = 1 + (start ? start+len : 0)
+  |  b <3
+  |
+  |.ffunc string_rep			// Only handle the 1-char case inline.
+  |  ffgccheck
+  |  cmplwi NARGS8:RC, 16
+  |   evldd CARG1, 0(BASE)
+  |   evldd CARG2, 8(BASE)
+  |  blt ->fff_fallback
+  |  checknum CARG2
+  |  checkfail ->fff_fallback
+  |  checkstr STR:CARG1
+  |   efdctsiz CARG3, CARG2
+  |  checkfail ->fff_fallback
+  |   lwz TMP0, STR:CARG1->len
+  |  cmpwi CARG3, 0
+  |   lwz TMP1, DISPATCH_GL(tmpbuf.sz)(DISPATCH)
+  |  ble >2				// Count <= 0? (or non-int)
+  |   cmplwi TMP0, 1
+  |  subi TMP2, CARG3, 1
+  |   blt >2				// Zero length string?
+  |  cmplw cr1, TMP1, CARG3
+  |   bne ->fff_fallback		// Fallback for > 1-char strings.
+  |   lbz TMP0, STR:CARG1[1]
+  |   lwz CARG2, DISPATCH_GL(tmpbuf.buf)(DISPATCH)
+  |  blt cr1, ->fff_fallback
+  |1:  // Fill buffer with char. Yes, this is suboptimal code (do you care?).
+  |  cmplwi TMP2, 0
+  |   stbx TMP0, CARG2, TMP2
+  |   subi TMP2, TMP2, 1
+  |  bne <1
+  |  b ->fff_newstr
+  |2:  // Return empty string.
+  |  la STR:CRET1, DISPATCH_GL(strempty)(DISPATCH)
+  |  evmergelo CRET1, TISSTR, STR:CRET1
+  |  b ->fff_restv
+  |
+  |.ffunc string_reverse
+  |  ffgccheck
+  |  cmplwi NARGS8:RC, 8
+  |   evldd CARG1, 0(BASE)
+  |  blt ->fff_fallback
+  |  checkstr STR:CARG1
+  |   lwz TMP1, DISPATCH_GL(tmpbuf.sz)(DISPATCH)
+  |  checkfail ->fff_fallback
+  |  lwz CARG3, STR:CARG1->len
+  |   la CARG1, #STR(STR:CARG1)
+  |   lwz CARG2, DISPATCH_GL(tmpbuf.buf)(DISPATCH)
+  |   li TMP2, 0
+  |  cmplw TMP1, CARG3
+  |   subi TMP3, CARG3, 1
+  |  blt ->fff_fallback
+  |1:  // Reverse string copy.
+  |  cmpwi TMP3, 0
+  |   lbzx TMP1, CARG1, TMP2
+  |  blt ->fff_newstr
+  |   stbx TMP1, CARG2, TMP3
+  |  subi TMP3, TMP3, 1
+  |  addi TMP2, TMP2, 1
+  |  b <1
+  |
+  |.macro ffstring_case, name, lo
+  |  .ffunc name
+  |  ffgccheck
+  |  cmplwi NARGS8:RC, 8
+  |   evldd CARG1, 0(BASE)
+  |  blt ->fff_fallback
+  |  checkstr STR:CARG1
+  |   lwz TMP1, DISPATCH_GL(tmpbuf.sz)(DISPATCH)
+  |  checkfail ->fff_fallback
+  |  lwz CARG3, STR:CARG1->len
+  |   la CARG1, #STR(STR:CARG1)
+  |   lwz CARG2, DISPATCH_GL(tmpbuf.buf)(DISPATCH)
+  |  cmplw TMP1, CARG3
+  |   li TMP2, 0
+  |  blt ->fff_fallback
+  |1:  // ASCII case conversion.
+  |  cmplw TMP2, CARG3
+  |   lbzx TMP1, CARG1, TMP2
+  |  bge ->fff_newstr
+  |   subi TMP0, TMP1, lo
+  |    xori TMP3, TMP1, 0x20
+  |   cmplwi TMP0, 26
+  |   isellt TMP1, TMP3, TMP1
+  |   stbx TMP1, CARG2, TMP2
+  |  addi TMP2, TMP2, 1
+  |  b <1
+  |.endmacro
+  |
+  |ffstring_case string_lower, 65
+  |ffstring_case string_upper, 97
+  |
+  |//-- Table library ------------------------------------------------------
+  |
+  |.ffunc_1 table_getn
+  |  checktab CARG1
+  |  checkfail ->fff_fallback
+  |  bl extern lj_tab_len		// (GCtab *t)
+  |  // Returns uint32_t (but less than 2^31).
+  |  efdcfsi CRET1, CRET1
+  |  b ->fff_restv
+  |
+  |//-- Bit library --------------------------------------------------------
+  |
+  |.macro .ffunc_bit, name
+  |  .ffunc_n bit_..name
+  |  efdadd CARG1, CARG1, TOBIT
+  |.endmacro
+  |
+  |.ffunc_bit tobit
+  |->fff_resbit:
+  |  efdcfsi CRET1, CARG1
+  |  b ->fff_restv
+  |
+  |.macro .ffunc_bit_op, name, ins
+  |  .ffunc_bit name
+  |   li TMP1, 8
+  |1:
+  |  evlddx CARG2, BASE, TMP1
+  |  cmplw cr1, TMP1, NARGS8:RC
+  |   checknum CARG2
+  |  bge cr1, ->fff_resbit
+  |   checkfail ->fff_fallback
+  |  efdadd CARG2, CARG2, TOBIT
+  |  ins CARG1, CARG1, CARG2
+  |   addi TMP1, TMP1, 8
+  |  b <1
+  |.endmacro
+  |
+  |.ffunc_bit_op band, and
+  |.ffunc_bit_op bor, or
+  |.ffunc_bit_op bxor, xor
+  |
+  |.ffunc_bit bswap
+  |  rotlwi TMP0, CARG1, 8
+  |  rlwimi TMP0, CARG1, 24, 0, 7
+  |  rlwimi TMP0, CARG1, 24, 16, 23
+  |  efdcfsi CRET1, TMP0
+  |  b ->fff_restv
+  |
+  |.ffunc_bit bnot
+  |  not TMP0, CARG1
+  |  efdcfsi CRET1, TMP0
+  |  b ->fff_restv
+  |
+  |.macro .ffunc_bit_sh, name, ins, shmod
+  |  .ffunc_nn bit_..name
+  |  efdadd CARG2, CARG2, TOBIT
+  |   efdadd CARG1, CARG1, TOBIT
+  |.if shmod == 1
+  |  rlwinm CARG2, CARG2, 0, 27, 31
+  |.elif shmod == 2
+  |  neg CARG2, CARG2
+  |.endif
+  |  ins TMP0, CARG1, CARG2
+  |  efdcfsi CRET1, TMP0
+  |  b ->fff_restv
+  |.endmacro
+  |
+  |.ffunc_bit_sh lshift, slw, 1
+  |.ffunc_bit_sh rshift, srw, 1
+  |.ffunc_bit_sh arshift, sraw, 1
+  |.ffunc_bit_sh rol, rotlw, 0
+  |.ffunc_bit_sh ror, rotlw, 2
+  |
+  |//-----------------------------------------------------------------------
+  |
+  |->fff_fallback:			// Call fast function fallback handler.
+  |  // BASE = new base, RB = CFUNC, RC = nargs*8
+  |  lwz TMP3, CFUNC:RB->f
+  |    add TMP1, BASE, NARGS8:RC
+  |   lwz PC, FRAME_PC(BASE)		// Fallback may overwrite PC.
+  |    addi TMP0, TMP1, 8*LUA_MINSTACK
+  |     lwz TMP2, L->maxstack
+  |   stw PC, SAVE_PC			// Redundant (but a defined value).
+  |  cmplw TMP0, TMP2
+  |     stw BASE, L->base
+  |    stw TMP1, L->top
+  |   mr CARG1, L
+  |  bgt >5				// Need to grow stack.
+  |  mtctr TMP3
+  |  bctrl				// (lua_State *L)
+  |  // Either throws an error, or recovers and returns -1, 0 or nresults+1.
+  |  lwz BASE, L->base
+  |  cmpwi CRET1, 0
+  |   slwi RD, CRET1, 3
+  |   la RA, -8(BASE)
+  |  bgt ->fff_res			// Returned nresults+1?
+  |1:  // Returned 0 or -1: retry fast path.
+  |  lwz TMP0, L->top
+  |   lwz LFUNC:RB, FRAME_FUNC(BASE)
+  |  sub NARGS8:RC, TMP0, BASE
+  |  bne ->vm_call_tail			// Returned -1?
+  |  ins_callt				// Returned 0: retry fast path.
+  |
+  |// Reconstruct previous base for vmeta_call during tailcall.
+  |->vm_call_tail:
+  |  andi. TMP0, PC, FRAME_TYPE
+  |   rlwinm TMP1, PC, 0, 0, 28
+  |  bne >3
+  |  lwz INS, -4(PC)
+  |  decode_RA8 TMP1, INS
+  |3:
+  |  sub TMP2, BASE, TMP1
+  |  b ->vm_call_dispatch		// Resolve again for tailcall.
+  |
+  |5:  // Grow stack for fallback handler.
+  |  li CARG2, LUA_MINSTACK
+  |  bl extern lj_state_growstack	// (lua_State *L, int n)
+  |  lwz BASE, L->base
+  |  cmpw TMP0, TMP0			// Set 4*cr0+eq to force retry.
+  |  b <1
+  |
+  |->fff_gcstep:			// Call GC step function.
+  |  // BASE = new base, RC = nargs*8
+  |  mflr SAVE0
+  |   stw BASE, L->base
+  |  add TMP0, BASE, NARGS8:RC
+  |   stw PC, SAVE_PC			// Redundant (but a defined value).
+  |  stw TMP0, L->top
+  |  mr CARG1, L
+  |  bl extern lj_gc_step		// (lua_State *L)
+  |   lwz BASE, L->base
+  |  mtlr SAVE0
+  |    lwz TMP0, L->top
+  |   sub NARGS8:RC, TMP0, BASE
+  |   lwz CFUNC:RB, FRAME_FUNC(BASE)
+  |  blr
+  |
+  |//-----------------------------------------------------------------------
+  |//-- Special dispatch targets -------------------------------------------
+  |//-----------------------------------------------------------------------
+  |
+  |->vm_record:				// Dispatch target for recording phase.
+#if LJ_HASJIT
+  |  NYI
+#endif
+  |
+  |->vm_rethook:			// Dispatch target for return hooks.
+  |  lbz TMP3, DISPATCH_GL(hookmask)(DISPATCH)
+  |  andi. TMP0, TMP3, HOOK_ACTIVE	// Hook already active?
+  |  beq >1
+  |5:  // Re-dispatch to static ins.
+  |  addi TMP1, TMP1, GG_DISP2STATIC	// Assumes decode_OP4 TMP1, INS.
+  |  lwzx TMP0, DISPATCH, TMP1
+  |  mtctr TMP0
+  |  bctr
+  |
+  |->vm_inshook:			// Dispatch target for instr/line hooks.
+  |  lbz TMP3, DISPATCH_GL(hookmask)(DISPATCH)
+  |  lwz TMP2, DISPATCH_GL(hookcount)(DISPATCH)
+  |  andi. TMP0, TMP3, HOOK_ACTIVE	// Hook already active?
+  |   rlwinm TMP0, TMP3, 31-LUA_HOOKLINE, 31, 0
+  |  bne <5
+  |
+  |   cmpwi cr1, TMP0, 0
+  |  addic. TMP2, TMP2, -1
+  |   beq cr1, <5
+  |  stw TMP2, DISPATCH_GL(hookcount)(DISPATCH)
+  |  beq >1
+  |   bge cr1, <5
+  |1:
+  |  mr CARG1, L
+  |   stw MULTRES, SAVE_MULTRES
+  |  mr CARG2, PC
+  |   stw BASE, L->base
+  |  // SAVE_PC must hold the _previous_ PC. The callee updates it with PC.
+  |  bl extern lj_dispatch_ins		// (lua_State *L, const BCIns *pc)
+  |3:
+  |  lwz BASE, L->base
+  |4:  // Re-dispatch to static ins.
+  |  lwz INS, -4(PC)
+  |  decode_OP4 TMP1, INS
+  |   decode_RB8 RB, INS
+  |  addi TMP1, TMP1, GG_DISP2STATIC
+  |   decode_RD8 RD, INS
+  |  lwzx TMP0, DISPATCH, TMP1
+  |   decode_RA8 RA, INS
+  |   decode_RC8 RC, INS
+  |  mtctr TMP0
+  |  bctr
+  |
+  |->cont_hook:				// Continue from hook yield.
+  |  addi PC, PC, 4
+  |  lwz MULTRES, -20(RB)		// Restore MULTRES for *M ins.
+  |  b <4
+  |
+  |->vm_hotloop:			// Hot loop counter underflow.
+#if LJ_HASJIT
+  |  NYI
+#endif
+  |
+  |->vm_callhook:			// Dispatch target for call hooks.
+  |  mr CARG2, PC
+#if LJ_HASJIT
+  |  b >1
+#endif
+  |
+  |->vm_hotcall:			// Hot call counter underflow.
+#if LJ_HASJIT
+  |  ori CARG2, PC, 1
+  |1:
+#endif
+  |  add TMP0, BASE, RC
+  |   stw PC, SAVE_PC
+  |  mr CARG1, L
+  |   stw BASE, L->base
+  |  sub RA, RA, BASE
+  |   stw TMP0, L->top
+  |  bl extern lj_dispatch_call		// (lua_State *L, const BCIns *pc)
+  |  // Returns ASMFunction.
+  |  lwz BASE, L->base
+  |   lwz TMP0, L->top
+  |   stw ZERO, SAVE_PC			// Invalidate for subsequent line hook.
+  |  sub NARGS8:RC, TMP0, BASE
+  |  add RA, BASE, RA
+  |  lwz LFUNC:RB, FRAME_FUNC(BASE)
+  |  mtctr CRET1
+  |  bctr
+  |
+  |//-----------------------------------------------------------------------
+  |//-- Trace exit handler -------------------------------------------------
+  |//-----------------------------------------------------------------------
+  |
+  |->vm_exit_handler:
+#if LJ_HASJIT
+  |  NYI
+#endif
+  |->vm_exit_interp:
+#if LJ_HASJIT
+  |  NYI
+#endif
+  |
+  |//-----------------------------------------------------------------------
+  |//-- Math helper functions ----------------------------------------------
+  |//-----------------------------------------------------------------------
+  |
+  |// FP value rounding. Called by math.floor/math.ceil fast functions
+  |// and from JIT code.
+  |//
+  |// This can be inlined if the CPU has the frin/friz/frip/frim instructions.
+  |// The alternative hard-float approaches have a deep dependency chain.
+  |// The resulting latency is at least 3x-7x the double-precision FP latency
+  |// (e500v2: 6cy, e600: 5cy, Cell: 10cy) or around 20-70 cycles.
+  |//
+  |// The soft-float approach is tedious, but much faster (e500v2: ~11cy/~6cy).
+  |// However it relies on a fast way to transfer the FP value to GPRs
+  |// (e500v2: 0cy for lo-word, 1cy for hi-word).
+  |//
+  |.macro vm_round, name, mode
+  |  // Used temporaries: TMP0, TMP1, TMP2, TMP3.
+  |->name.._efd:			// Input: CARG2, output: CRET2
+  |  evmergehi CARG1, CARG2, CARG2
+  |->name.._hilo:
+  |  // Input: CARG1 (hi), CARG2 (hi, lo), output: CRET2
+  |  rlwinm TMP2, CARG1, 12, 21, 31
+  |  addic. TMP2, TMP2, -1023		// exp = exponent(x) - 1023
+  |   li TMP1, -1
+  |  cmplwi cr1, TMP2, 51		// 0 <= exp <= 51?
+  |   subfic TMP0, TMP2, 52
+  |  bgt cr1, >1
+  |   lus TMP3, 0xfff0
+  |  slw TMP0, TMP1, TMP0		// lomask = -1 << (52-exp)
+  |   sraw TMP1, TMP3, TMP2		// himask = (int32_t)0xfff00000 >> exp
+  |.if mode == 2		// trunc(x):
+  |  evmergelo TMP0, TMP1, TMP0
+  |  evand CRET2, CARG2, TMP0		// hi &= himask, lo &= lomask
+  |.else
+  |  andc TMP2, CARG2, TMP0
+  |   andc TMP3, CARG1, TMP1
+  |  or TMP2, TMP2, TMP3		// ztest = (hi&~himask) | (lo&~lomask)
+  |   srawi TMP3, CARG1, 31		// signmask = (int32_t)hi >> 31
+  |.if mode == 0		// floor(x):
+  |  and. TMP2, TMP2, TMP3		// iszero = ((ztest & signmask) == 0)
+  |.else			// ceil(x):
+  |  andc. TMP2, TMP2, TMP3		// iszero = ((ztest & ~signmask) == 0)
+  |.endif
+  |  and CARG2, CARG2, TMP0		// lo &= lomask
+  |  and CARG1, CARG1, TMP1		// hi &= himask
+  |   subc TMP0, CARG2, TMP0
+  |  iseleq TMP0, CARG2, TMP0		// lo = iszero ? lo : lo-lomask
+  |   sube TMP1, CARG1, TMP1
+  |  iseleq TMP1, CARG1, TMP1		// hi = iszero ? hi : hi-himask+carry
+  |  evmergelo CRET2, TMP1, TMP0
+  |.endif
+  |  blr
+  |1:
+  |  bgtlr				// Already done if >=2^52, +-inf or nan.
+  |.if mode == 2		// trunc(x):
+  |  rlwinm TMP1, CARG1, 0, 0, 0	// hi = sign(x)
+  |  li TMP0, 0
+  |  evmergelo CRET2, TMP1, TMP0
+  |.else
+  |  rlwinm TMP2, CARG1, 0, 1, 31
+  |  srawi TMP0, CARG1, 31		// signmask = (int32_t)hi >> 31
+  |  or TMP2, TMP2, CARG2		// ztest = abs(hi) | lo
+  |   lus TMP1, 0x3ff0
+  |.if mode == 0		// floor(x):
+  |  and. TMP2, TMP2, TMP0		// iszero = ((ztest & signmask) == 0)
+  |.else			// ceil(x):
+  |  andc. TMP2, TMP2, TMP0		// iszero = ((ztest & ~signmask) == 0)
+  |.endif
+  |   li TMP0, 0
+  |  iseleq TMP1, r0, TMP1
+  |  rlwimi CARG1, TMP1, 0, 1, 31	// hi = sign(x) | (iszero ? 0.0 : 1.0)
+  |  evmergelo CRET2, CARG1, TMP0
+  |.endif
+  |  blr
+  |.endmacro
+  |
+  |->vm_floor:
+  |  mflr CARG3
+  |  bl ->vm_floor_hilo
+  |  mtlr CARG3
+  |  evmergehi CRET1, CRET2, CRET2
+  |  blr
+  |
+  |  vm_round vm_floor, 0
+  |  vm_round vm_ceil,  1
+#if LJ_HASJIT
+  |  vm_round vm_trunc, 2
+#else
+  |->vm_trunc_efd:
+  |->vm_trunc_hilo:
+#endif
+  |
+  |// Callable from C: double lj_vm_foldarith(double x, double y, int op)
+  |// Compute x op y for basic arithmetic operators (+ - * / % ^ and unary -)
+  |// and basic math functions. ORDER ARITH
+  |->vm_foldarith:
+  |  evmergelo CARG2, CARG1, CARG2
+  |   cmplwi CARG5, 1
+  |  evmergelo CARG4, CARG3, CARG4
+  |   beq >1; bgt >2
+  |  efdadd CRET2, CARG2, CARG4; evmergehi CRET1, CRET2, CRET2; blr
+  |1:
+  |  efdsub CRET2, CARG2, CARG4; evmergehi CRET1, CRET2, CRET2; blr
+  |2:
+  |   cmplwi CARG5, 3; beq >1; bgt >2
+  |  efdmul CRET2, CARG2, CARG4; evmergehi CRET1, CRET2, CRET2; blr
+  |1:
+  |  efddiv CRET2, CARG2, CARG4; evmergehi CRET1, CRET2, CRET2; blr
+  |2:
+  |   cmplwi CARG5, 5; beq >1; bgt >2
+  |  evmr CARG3, CARG2; efddiv CRET2, CARG2, CARG4; evmr RB, CARG4
+  |  mflr RC; bl ->vm_floor_efd; mtlr RC
+  |  efdmul CRET2, CRET2, RB; efdsub CRET2, CARG3, CRET2
+  |  evmergehi CRET1, CRET2, CRET2; blr
+  |1:
+  |  b extern pow
+  |2:
+  |   cmplwi CARG5, 7; beq >1; bgt >2
+  |  xoris CARG1, CARG1, 0x8000; blr
+  |1:
+  |  rlwinm CARG1, CARG1, 0, 1, 31; blr
+  |2:
+  |  NYI  // Other operations only needed by JIT compiler.
+  |
+  |//-----------------------------------------------------------------------
+  |//-- Miscellaneous functions --------------------------------------------
+  |//-----------------------------------------------------------------------
+  |
+  |//-----------------------------------------------------------------------
+  |//-- FFI helper functions -----------------------------------------------
+  |//-----------------------------------------------------------------------
+  |
+  |->vm_ffi_call:
+#if LJ_HASFFI
+  |  NYI
+#endif
+  |
+  |//-----------------------------------------------------------------------
+}
+
+/* Generate the code for a single instruction. */
+static void build_ins(BuildCtx *ctx, BCOp op, int defop)
+{
+  int vk = 0;
+  |=>defop:
+
+  switch (op) {
+
+  /* -- Comparison ops ---------------------------------------------------- */
+
+  /* Remember: all ops branch for a true comparison, fall through otherwise. */
+
+  case BC_ISLT: case BC_ISGE: case BC_ISLE: case BC_ISGT:
+    |  // RA = src1*8, RD = src2*8, JMP with RD = target
+    |  evlddx TMP0, BASE, RA
+    |   addi PC, PC, 4
+    |  evlddx TMP1, BASE, RD
+    |   addis TMP3, PC, -(BCBIAS_J*4 >> 16)
+    |   lwz TMP2, -4(PC)
+    |  evmergehi RB, TMP0, TMP1
+    |   decode_RD4 TMP2, TMP2
+    |  checknum RB
+    |   add TMP2, TMP2, TMP3
+    |  checkanyfail ->vmeta_comp
+    |  efdcmplt TMP0, TMP1
+    if (op == BC_ISLE || op == BC_ISGT) {
+      |  efdcmpeq cr1, TMP0, TMP1
+      |  cror 4*cr0+gt, 4*cr0+gt, 4*cr1+gt
+    }
+    if (op == BC_ISLT || op == BC_ISLE) {
+      |  iselgt PC, TMP2, PC
+    } else {
+      |  iselgt PC, PC, TMP2
+    }
+    |  ins_next
+    break;
+
+  case BC_ISEQV: case BC_ISNEV:
+    vk = op == BC_ISEQV;
+    |  // RA = src1*8, RD = src2*8, JMP with RD = target
+    |  evlddx CARG2, BASE, RA
+    |   addi PC, PC, 4
+    |  evlddx CARG3, BASE, RD
+    |   addis TMP3, PC, -(BCBIAS_J*4 >> 16)
+    |   lwz TMP2, -4(PC)
+    |  evmergehi RB, CARG2, CARG3
+    |   decode_RD4 TMP2, TMP2
+    |  checknum RB
+    |   add TMP2, TMP2, TMP3
+    |  checkanyfail >5
+    |  efdcmpeq CARG2, CARG3
+    if (vk) {
+      |  iselgt PC, TMP2, PC
+    } else {
+      |  iselgt PC, PC, TMP2
+    }
+    |1:
+    |  ins_next
+    |
+    |5:  // Either or both types are not numbers.
+    |  evcmpeq CARG2, CARG3
+    |   not TMP3, RB
+    |   cmplwi cr1, TMP3, ~LJ_TISPRI		// Primitive?
+    |  crorc 4*cr7+lt, 4*cr0+so, 4*cr0+lt	// 1: Same tv or different type.
+    |   cmplwi cr6, TMP3, ~LJ_TISTABUD		// Table or userdata?
+    |  crandc 4*cr7+gt, 4*cr0+lt, 4*cr1+gt	// 2: Same type and primitive.
+    |   mr SAVE0, PC
+    if (vk) {
+      |  isel PC, TMP2, PC, 4*cr7+gt
+    } else {
+      |  isel TMP2, PC, TMP2, 4*cr7+gt
+    }
+    |  cror 4*cr7+lt, 4*cr7+lt, 4*cr7+gt	// 1 or 2.
+    if (vk) {
+      |  isel PC, TMP2, PC, 4*cr0+so
+    } else {
+      |  isel PC, PC, TMP2, 4*cr0+so
+    }
+    |  blt cr7, <1			// Done if 1 or 2.
+    |  blt cr6, <1			// Done if not tab/ud.
+    |
+    |  // Different tables or userdatas. Need to check __eq metamethod.
+    |  // Field metatable must be at same offset for GCtab and GCudata!
+    |  lwz TAB:TMP2, TAB:CARG2->metatable
+    |   li CARG4, 1-vk			// ne = 0 or 1.
+    |  cmplwi TAB:TMP2, 0
+    |  beq <1				// No metatable?
+    |  lbz TMP2, TAB:TMP2->nomm
+    |  andi. TMP2, TMP2, 1<<MM_eq
+    |  bne <1				// Or 'no __eq' flag set?
+    |  mr PC, SAVE0			// Restore old PC.
+    |  b ->vmeta_equal			// Handle __eq metamethod.
+    break;
+
+  case BC_ISEQS: case BC_ISNES:
+    vk = op == BC_ISEQS;
+    |  // RA = src*8, RD = str_const*8 (~), JMP with RD = target
+    |  evlddx TMP0, BASE, RA
+    |   srwi RD, RD, 1
+    |    lwz INS, 0(PC)
+    |   subfic RD, RD, -4
+    |    addi PC, PC, 4
+    |   lwzx STR:TMP1, KBASE, RD	// KBASE-4-str_const*4
+    |    addis TMP3, PC, -(BCBIAS_J*4 >> 16)
+    |    decode_RD4 TMP2, INS
+    |   evmergelo STR:TMP1, TISSTR, STR:TMP1
+    |    add TMP2, TMP2, TMP3
+    |  evcmpeq TMP0, STR:TMP1
+    if (vk) {
+      |  isel PC, TMP2, PC, 4*cr0+so
+    } else {
+      |  isel PC, PC, TMP2, 4*cr0+so
+    }
+    |  ins_next
+    break;
+
+  case BC_ISEQN: case BC_ISNEN:
+    vk = op == BC_ISEQN;
+    |  // RA = src*8, RD = num_const*8, JMP with RD = target
+    |  evlddx TMP0, BASE, RA
+    |   addi PC, PC, 4
+    |  evlddx TMP1, KBASE, RD
+    |   addis TMP3, PC, -(BCBIAS_J*4 >> 16)
+    |   lwz INS, -4(PC)
+    |  checknum TMP0
+    |  checkfail >5
+    |  efdcmpeq TMP0, TMP1
+    |1:
+    |   decode_RD4 TMP2, INS
+    |   add TMP2, TMP2, TMP3
+    if (vk) {
+      |  iselgt PC, TMP2, PC
+      |5:
+    } else {
+      |  iselgt PC, PC, TMP2
+    }
+    |3:
+    |  ins_next
+    if (!vk) {
+      |5:
+      |  decode_RD4 TMP2, INS
+      |  add PC, TMP2, TMP3
+      |  b <3
+    }
+    break;
+
+  case BC_ISEQP: case BC_ISNEP:
+    vk = op == BC_ISEQP;
+    |  // RA = src*8, RD = primitive_type*8 (~), JMP with RD = target
+    |  lwzx TMP0, BASE, RA
+    |   srwi TMP1, RD, 3
+    |    lwz INS, 0(PC)
+    |    addi PC, PC, 4
+    |   not TMP1, TMP1
+    |    addis TMP3, PC, -(BCBIAS_J*4 >> 16)
+    |  cmplw TMP0, TMP1
+    |    decode_RD4 TMP2, INS
+    |    add TMP2, TMP2, TMP3
+    if (vk) {
+      |  iseleq PC, TMP2, PC
+    } else {
+      |  iseleq PC, PC, TMP2
+    }
+    |  ins_next
+    break;
+
+  /* -- Unary test and copy ops ------------------------------------------- */
+
+  case BC_ISTC: case BC_ISFC: case BC_IST: case BC_ISF:
+    |  // RA = dst*8 or unused, RD = src*8, JMP with RD = target
+    |  evlddx TMP0, BASE, RD
+    |   evaddw TMP1, TISNIL, TISNIL	// Synthesize LJ_TFALSE.
+    |   lwz INS, 0(PC)
+    |  evcmpltu TMP0, TMP1
+    |   addi PC, PC, 4
+    if (op == BC_IST || op == BC_ISF) {
+      |  addis TMP3, PC, -(BCBIAS_J*4 >> 16)
+      |  decode_RD4 TMP2, INS
+      |  add TMP2, TMP2, TMP3
+      if (op == BC_IST) {
+	|  isellt PC, TMP2, PC
+      } else {
+	|  isellt PC, PC, TMP2
+      }
+    } else {
+      if (op == BC_ISTC) {
+	|  checkfail >1
+      } else {
+	|  checkok >1
+      }
+      |  addis PC, PC, -(BCBIAS_J*4 >> 16)
+      |  decode_RD4 TMP2, INS
+      |   evstddx TMP0, BASE, RA
+      |  add PC, PC, TMP2
+      |1:
+    }
+    |  ins_next
+    break;
+
+  /* -- Unary ops --------------------------------------------------------- */
+
+  case BC_MOV:
+    |  // RA = dst*8, RD = src*8
+    |  ins_next1
+    |  evlddx TMP0, BASE, RD
+    |  evstddx TMP0, BASE, RA
+    |  ins_next2
+    break;
+  case BC_NOT:
+    |  // RA = dst*8, RD = src*8
+    |  ins_next1
+    |  lwzx TMP0, BASE, RD
+    |  subfic TMP1, TMP0, LJ_TTRUE
+    |  adde TMP0, TMP0, TMP1
+    |  stwx TMP0, BASE, RA
+    |  ins_next2
+    break;
+  case BC_UNM:
+    |  // RA = dst*8, RD = src*8
+    |  evlddx TMP0, BASE, RD
+    |  checknum TMP0
+    |  checkfail ->vmeta_unm
+    |  efdneg TMP0, TMP0
+    |  ins_next1
+    |  evstddx TMP0, BASE, RA
+    |  ins_next2
+    break;
+  case BC_LEN:
+    |  // RA = dst*8, RD = src*8
+    |  evlddx CARG1, BASE, RD
+    |  checkstr CARG1
+    |  checkfail >2
+    |  lwz CRET1, STR:CARG1->len
+    |1:
+    |  ins_next1
+    |  efdcfsi TMP0, CRET1
+    |  evstddx TMP0, BASE, RA
+    |  ins_next2
+    |2:
+    |  checktab CARG1
+    |  checkfail ->vmeta_len
+#ifdef LUAJIT_ENABLE_LUA52COMPAT
+    |  lwz TAB:TMP2, TAB:CARG1->metatable
+    |  cmplwi TAB:TMP2, 0
+    |  bne >9
+    |3:
+#endif
+    |->BC_LEN_Z:
+    |  bl extern lj_tab_len		// (GCtab *t)
+    |  // Returns uint32_t (but less than 2^31).
+    |  b <1
+#ifdef LUAJIT_ENABLE_LUA52COMPAT
+    |9:
+    |  lbz TMP0, TAB:TMP2->nomm
+    |  andi. TMP0, TMP0, 1<<MM_len
+    |  bne <3				// 'no __len' flag set: done.
+    |  b ->vmeta_len
+#endif
+    break;
+
+  /* -- Binary ops -------------------------------------------------------- */
+
+    |.macro ins_arithpre, t0, t1
+    |  // RA = dst*8, RB = src1*8, RC = src2*8 | num_const*8
+    ||vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
+    ||switch (vk) {
+    ||case 0:
+    |   evlddx t0, BASE, RB
+    |    checknum t0
+    |   evlddx t1, KBASE, RC
+    |    checkfail ->vmeta_arith_vn
+    ||  break;
+    ||case 1:
+    |   evlddx t1, BASE, RB
+    |    checknum t1
+    |   evlddx t0, KBASE, RC
+    |    checkfail ->vmeta_arith_nv
+    ||  break;
+    ||default:
+    |   evlddx t0, BASE, RB
+    |   evlddx t1, BASE, RC
+    |    evmergehi TMP2, t0, t1
+    |    checknum TMP2
+    |    checkanyfail ->vmeta_arith_vv
+    ||  break;
+    ||}
+    |.endmacro
+    |
+    |.macro ins_arith, ins
+    |  ins_arithpre TMP0, TMP1
+    |  ins_next1
+    |  ins TMP0, TMP0, TMP1
+    |  evstddx TMP0, BASE, RA
+    |  ins_next2
+    |.endmacro
+
+  case BC_ADDVN: case BC_ADDNV: case BC_ADDVV:
+    |  ins_arith efdadd
+    break;
+  case BC_SUBVN: case BC_SUBNV: case BC_SUBVV:
+    |  ins_arith efdsub
+    break;
+  case BC_MULVN: case BC_MULNV: case BC_MULVV:
+    |  ins_arith efdmul
+    break;
+  case BC_DIVVN: case BC_DIVNV: case BC_DIVVV:
+    |  ins_arith efddiv
+    break;
+  case BC_MODVN:
+    |  ins_arithpre RD, SAVE0
+    |->BC_MODVN_Z:
+    |  efddiv CARG2, RD, SAVE0
+    |  bl ->vm_floor_efd		// floor(b/c)
+    |  efdmul TMP0, CRET2, SAVE0
+    |  ins_next1
+    |  efdsub TMP0, RD, TMP0		// b - floor(b/c)*c
+    |  evstddx TMP0, BASE, RA
+    |  ins_next2
+    break;
+  case BC_MODNV: case BC_MODVV:
+    |  ins_arithpre RD, SAVE0
+    |  b ->BC_MODVN_Z			// Avoid 3 copies. It's slow anyway.
+    break;
+  case BC_POW:
+    |  evlddx CARG2, BASE, RB
+    |  evlddx CARG4, BASE, RC
+    |  evmergehi CARG1, CARG4, CARG2
+    |  checknum CARG1
+    |   evmergehi CARG3, CARG4, CARG4
+    |  checkanyfail ->vmeta_arith_vv
+    |  bl extern pow
+    |  evmergelo CRET2, CRET1, CRET2
+    |  evstddx CRET2, BASE, RA
+    |  ins_next
+    break;
+
+  case BC_CAT:
+    |  // RA = dst*8, RB = src_start*8, RC = src_end*8
+    |  sub CARG3, RC, RB
+    |   stw BASE, L->base
+    |  add CARG2, BASE, RC
+    |  mr SAVE0, RB
+    |->BC_CAT_Z:
+    |   stw PC, SAVE_PC
+    |  mr CARG1, L
+    |  srwi CARG3, CARG3, 3
+    |  bl extern lj_meta_cat		// (lua_State *L, TValue *top, int left)
+    |  // Returns NULL (finished) or TValue * (metamethod).
+    |  cmplwi CRET1, 0
+    |   lwz BASE, L->base
+    |  bne ->vmeta_binop
+    |  evlddx TMP0, BASE, SAVE0		// Copy result from RB to RA.
+    |  evstddx TMP0, BASE, RA
+    |  ins_next
+    break;
+
+  /* -- Constant ops ------------------------------------------------------ */
+
+  case BC_KSTR:
+    |  // RA = dst*8, RD = str_const*8 (~)
+    |  ins_next1
+    |  srwi TMP1, RD, 1
+    |  subfic TMP1, TMP1, -4
+    |  lwzx TMP0, KBASE, TMP1		// KBASE-4-str_const*4
+    |  evmergelo TMP0, TISSTR, TMP0
+    |  evstddx TMP0, BASE, RA
+    |  ins_next2
+    break;
+  case BC_KCDATA:
+#if LJ_HASFFI
+    |  // RA = dst*8, RD = cdata_const*8 (~)
+    |  ins_next1
+    |  srwi TMP1, RD, 1
+    |  subfic TMP1, TMP1, -4
+    |  lwzx TMP0, KBASE, TMP1		// KBASE-4-cdata_const*4
+    |  li TMP2, LJ_TCDATA
+    |  evmergelo TMP0, TMP2, TMP0
+    |  evstddx TMP0, BASE, RA
+    |  ins_next2
+#endif
+    break;
+  case BC_KSHORT:
+    |  // RA = dst*8, RD = int16_literal*8
+    |  srwi TMP1, RD, 3
+    |  extsh TMP1, TMP1
+    |  ins_next1
+    |  efdcfsi TMP0, TMP1
+    |  evstddx TMP0, BASE, RA
+    |  ins_next2
+    break;
+  case BC_KNUM:
+    |  // RA = dst*8, RD = num_const*8
+    |  evlddx TMP0, KBASE, RD
+    |  ins_next1
+    |  evstddx TMP0, BASE, RA
+    |  ins_next2
+    break;
+  case BC_KPRI:
+    |  // RA = dst*8, RD = primitive_type*8 (~)
+    |  srwi TMP1, RD, 3
+    |  not TMP0, TMP1
+    |  ins_next1
+    |  stwx TMP0, BASE, RA
+    |  ins_next2
+    break;
+  case BC_KNIL:
+    |  // RA = base*8, RD = end*8
+    |  evstddx TISNIL, BASE, RA
+    |   addi RA, RA, 8
+    |1:
+    |  evstddx TISNIL, BASE, RA
+    |  cmpw RA, RD
+    |   addi RA, RA, 8
+    |  blt <1
+    |  ins_next_
+    break;
+
+  /* -- Upvalue and function ops ------------------------------------------ */
+
+  case BC_UGET:
+    |  // RA = dst*8, RD = uvnum*8
+    |  ins_next1
+    |  lwz LFUNC:RB, FRAME_FUNC(BASE)
+    |   srwi RD, RD, 1
+    |   addi RD, RD, offsetof(GCfuncL, uvptr)
+    |  lwzx UPVAL:RB, LFUNC:RB, RD
+    |  lwz TMP1, UPVAL:RB->v
+    |  evldd TMP0, 0(TMP1)
+    |  evstddx TMP0, BASE, RA
+    |  ins_next2
+    break;
+  case BC_USETV:
+    |  // RA = uvnum*8, RD = src*8
+    |  lwz LFUNC:RB, FRAME_FUNC(BASE)
+    |    srwi RA, RA, 1
+    |    addi RA, RA, offsetof(GCfuncL, uvptr)
+    |   evlddx TMP1, BASE, RD
+    |  lwzx UPVAL:RB, LFUNC:RB, RA
+    |  lbz TMP3, UPVAL:RB->marked
+    |   lwz CARG2, UPVAL:RB->v
+    |  andi. TMP3, TMP3, LJ_GC_BLACK	// isblack(uv)
+    |    lbz TMP0, UPVAL:RB->closed
+    |   evmergehi TMP2, TMP1, TMP1
+    |   evstdd TMP1, 0(CARG2)
+    |    cmplwi cr1, TMP0, 0
+    |  cror 4*cr0+eq, 4*cr0+eq, 4*cr1+eq
+    |   subi TMP2, TMP2, (LJ_TISNUM+1)
+    |  bne >2				// Upvalue is closed and black?
+    |1:
+    |  ins_next
+    |
+    |2:  // Check if new value is collectable.
+    |  cmplwi TMP2, LJ_TISGCV - (LJ_TISNUM+1)
+    |  bge <1				// tvisgcv(v)
+    |  lbz TMP3, GCOBJ:TMP1->gch.marked
+    |  andi. TMP3, TMP3, LJ_GC_WHITES	// iswhite(v)
+    |   la CARG1, GG_DISP2G(DISPATCH)
+    |  // Crossed a write barrier. Move the barrier forward.
+    |  beq <1
+    |  bl extern lj_gc_barrieruv	// (global_State *g, TValue *tv)
+    |  b <1
+    break;
+  case BC_USETS:
+    |  // RA = uvnum*8, RD = str_const*8 (~)
+    |  lwz LFUNC:RB, FRAME_FUNC(BASE)
+    |   srwi TMP1, RD, 1
+    |    srwi RA, RA, 1
+    |   subfic TMP1, TMP1, -4
+    |    addi RA, RA, offsetof(GCfuncL, uvptr)
+    |   lwzx STR:TMP1, KBASE, TMP1	// KBASE-4-str_const*4
+    |  lwzx UPVAL:RB, LFUNC:RB, RA
+    |   evmergelo STR:TMP1, TISSTR, STR:TMP1
+    |  lbz TMP3, UPVAL:RB->marked
+    |   lwz CARG2, UPVAL:RB->v
+    |  andi. TMP3, TMP3, LJ_GC_BLACK	// isblack(uv)
+    |   lbz TMP3, STR:TMP1->marked
+    |   lbz TMP2, UPVAL:RB->closed
+    |   evstdd STR:TMP1, 0(CARG2)
+    |  bne >2
+    |1:
+    |  ins_next
+    |
+    |2:  // Check if string is white and ensure upvalue is closed.
+    |  andi. TMP3, TMP3, LJ_GC_WHITES	// iswhite(str)
+    |   cmplwi cr1, TMP2, 0
+    |  cror 4*cr0+eq, 4*cr0+eq, 4*cr1+eq
+    |   la CARG1, GG_DISP2G(DISPATCH)
+    |  // Crossed a write barrier. Move the barrier forward.
+    |  beq <1
+    |  bl extern lj_gc_barrieruv	// (global_State *g, TValue *tv)
+    |  b <1
+    break;
+  case BC_USETN:
+    |  // RA = uvnum*8, RD = num_const*8
+    |  ins_next1
+    |  lwz LFUNC:RB, FRAME_FUNC(BASE)
+    |   srwi RA, RA, 1
+    |   addi RA, RA, offsetof(GCfuncL, uvptr)
+    |    evlddx TMP0, KBASE, RD
+    |  lwzx UPVAL:RB, LFUNC:RB, RA
+    |  lwz TMP1, UPVAL:RB->v
+    |  evstdd TMP0, 0(TMP1)
+    |  ins_next2
+    break;
+  case BC_USETP:
+    |  // RA = uvnum*8, RD = primitive_type*8 (~)
+    |  ins_next1
+    |  lwz LFUNC:RB, FRAME_FUNC(BASE)
+    |   srwi RA, RA, 1
+    |   addi RA, RA, offsetof(GCfuncL, uvptr)
+    |    srwi TMP0, RD, 3
+    |  lwzx UPVAL:RB, LFUNC:RB, RA
+    |    not TMP0, TMP0
+    |  lwz TMP1, UPVAL:RB->v
+    |  stw TMP0, 0(TMP1)
+    |  ins_next2
+    break;
+
+  case BC_UCLO:
+    |  // RA = level*8, RD = target
+    |  lwz TMP1, L->openupval
+    |  branch_RD			// Do this first since RD is not saved.
+    |   stw BASE, L->base
+    |  cmplwi TMP1, 0
+    |   mr CARG1, L
+    |  beq >1
+    |   add CARG2, BASE, RA
+    |  bl extern lj_func_closeuv	// (lua_State *L, TValue *level)
+    |  lwz BASE, L->base
+    |1:
+    |  ins_next
+    break;
+
+  case BC_FNEW:
+    |  // RA = dst*8, RD = proto_const*8 (~) (holding function prototype)
+    |  srwi TMP1, RD, 1
+    |   stw BASE, L->base
+    |  subfic TMP1, TMP1, -4
+    |   stw PC, SAVE_PC
+    |  lwzx CARG2, KBASE, TMP1		// KBASE-4-tab_const*4
+    |   mr CARG1, L
+    |  lwz CARG3, FRAME_FUNC(BASE)
+    |  // (lua_State *L, GCproto *pt, GCfuncL *parent)
+    |  bl extern lj_func_newL_gc
+    |  // Returns GCfuncL *.
+    |  lwz BASE, L->base
+    |  evmergelo LFUNC:CRET1, TISFUNC, LFUNC:CRET1
+    |  evstddx LFUNC:CRET1, BASE, RA
+    |  ins_next
+    break;
+
+  /* -- Table ops --------------------------------------------------------- */
+
+  case BC_TNEW:
+  case BC_TDUP:
+    |  // RA = dst*8, RD = (hbits|asize)*8 | tab_const*8 (~)
+    |  lwz TMP0, DISPATCH_GL(gc.total)(DISPATCH)
+    |   mr CARG1, L
+    |  lwz TMP1, DISPATCH_GL(gc.threshold)(DISPATCH)
+    |   stw BASE, L->base
+    |  cmplw TMP0, TMP1
+    |   stw PC, SAVE_PC
+    |  bge >5
+    |1:
+    if (op == BC_TNEW) {
+      |  rlwinm CARG2, RD, 29, 21, 31
+      |  rlwinm CARG3, RD, 18, 27, 31
+      |  cmpwi CARG2, 0x7ff
+      |   li TMP1, 0x801
+      |  iseleq CARG2, TMP1, CARG2
+      |  bl extern lj_tab_new  // (lua_State *L, int32_t asize, uint32_t hbits)
+      |  // Returns Table *.
+    } else {
+      |  srwi TMP1, RD, 1
+      |  subfic TMP1, TMP1, -4
+      |  lwzx CARG2, KBASE, TMP1		// KBASE-4-tab_const*4
+      |  bl extern lj_tab_dup  // (lua_State *L, Table *kt)
+      |  // Returns Table *.
+    }
+    |  lwz BASE, L->base
+    |  evmergelo TAB:CRET1, TISTAB, TAB:CRET1
+    |  evstddx TAB:CRET1, BASE, RA
+    |  ins_next
+    |5:
+    |  mr SAVE0, RD
+    |  bl extern lj_gc_step_fixtop  // (lua_State *L)
+    |  mr RD, SAVE0
+    |  mr CARG1, L
+    |  b <1
+    break;
+
+  case BC_GGET:
+    |  // RA = dst*8, RD = str_const*8 (~)
+  case BC_GSET:
+    |  // RA = src*8, RD = str_const*8 (~)
+    |  lwz LFUNC:TMP2, FRAME_FUNC(BASE)
+    |   srwi TMP1, RD, 1
+    |  lwz TAB:RB, LFUNC:TMP2->env
+    |   subfic TMP1, TMP1, -4
+    |   lwzx STR:RC, KBASE, TMP1	// KBASE-4-str_const*4
+    if (op == BC_GGET) {
+      |  b ->BC_TGETS_Z
+    } else {
+      |  b ->BC_TSETS_Z
+    }
+    break;
+
+  case BC_TGETV:
+    |  // RA = dst*8, RB = table*8, RC = key*8
+    |  evlddx TAB:RB, BASE, RB
+    |   evlddx RC, BASE, RC
+    |  checktab TAB:RB
+    |  checkfail ->vmeta_tgetv
+    |  checknum RC
+    |  checkfail >5
+    |  // Convert number key to integer
+    |  efdctsi TMP2, RC
+    |   lwz TMP0, TAB:RB->asize
+    |  efdcfsi TMP1, TMP2
+    |   cmplw cr0, TMP0, TMP2
+    |  efdcmpeq cr1, RC, TMP1
+    |   lwz TMP1, TAB:RB->array
+    |  crand 4*cr0+gt, 4*cr0+gt, 4*cr1+gt
+    |   slwi TMP2, TMP2, 3
+    |  ble ->vmeta_tgetv		// Integer key and in array part?
+    |  evlddx TMP1, TMP1, TMP2
+    |  checknil TMP1
+    |  checkok >2
+    |1:
+    |  evstddx TMP1, BASE, RA
+    |  ins_next
+    |
+    |2:  // Check for __index if table value is nil.
+    |  lwz TAB:TMP2, TAB:RB->metatable
+    |  cmplwi TAB:TMP2, 0
+    |  beq <1				// No metatable: done.
+    |  lbz TMP0, TAB:TMP2->nomm
+    |  andi. TMP0, TMP0, 1<<MM_index
+    |  bne <1				// 'no __index' flag set: done.
+    |  b ->vmeta_tgetv
+    |
+    |5:
+    |  checkstr STR:RC			// String key?
+    |  checkok ->BC_TGETS_Z
+    |  b ->vmeta_tgetv
+    break;
+  case BC_TGETS:
+    |  // RA = dst*8, RB = table*8, RC = str_const*8 (~)
+    |  evlddx TAB:RB, BASE, RB
+    |   srwi TMP1, RC, 1
+    |  checktab TAB:RB
+    |   subfic TMP1, TMP1, -4
+    |   lwzx STR:RC, KBASE, TMP1	// KBASE-4-str_const*4
+    |  checkfail ->vmeta_tgets1
+    |->BC_TGETS_Z:
+    |  // TAB:RB = GCtab *, STR:RC = GCstr *, RA = dst*8
+    |  lwz TMP0, TAB:RB->hmask
+    |  lwz TMP1, STR:RC->hash
+    |  lwz NODE:TMP2, TAB:RB->node
+    |   evmergelo STR:RC, TISSTR, STR:RC
+    |  and TMP1, TMP1, TMP0		// idx = str->hash & tab->hmask
+    |  slwi TMP0, TMP1, 5
+    |  slwi TMP1, TMP1, 3
+    |  sub TMP1, TMP0, TMP1
+    |  add NODE:TMP2, NODE:TMP2, TMP1	// node = tab->node + (idx*32-idx*8)
+    |1:
+    |  evldd TMP0, NODE:TMP2->key
+    |   evldd TMP1, NODE:TMP2->val
+    |  evcmpeq TMP0, STR:RC
+    |  checkanyfail >4
+    |   checknil TMP1
+    |   checkok >5			// Key found, but nil value?
+    |3:
+    |   evstddx TMP1, BASE, RA
+    |  ins_next
+    |
+    |4:  // Follow hash chain.
+    |  lwz NODE:TMP2, NODE:TMP2->next
+    |  cmplwi NODE:TMP2, 0
+    |  bne <1
+    |  // End of hash chain: key not found, nil result.
+    |   evmr TMP1, TISNIL
+    |
+    |5:  // Check for __index if table value is nil.
+    |  lwz TAB:TMP2, TAB:RB->metatable
+    |  cmplwi TAB:TMP2, 0
+    |  beq <3				// No metatable: done.
+    |  lbz TMP0, TAB:TMP2->nomm
+    |  andi. TMP0, TMP0, 1<<MM_index
+    |  bne <3				// 'no __index' flag set: done.
+    |  b ->vmeta_tgets
+    break;
+  case BC_TGETB:
+    |  // RA = dst*8, RB = table*8, RC = index*8
+    |  evlddx TAB:RB, BASE, RB
+    |   srwi TMP0, RC, 3
+    |  checktab TAB:RB
+    |  checkfail ->vmeta_tgetb
+    |  lwz TMP1, TAB:RB->asize
+    |   lwz TMP2, TAB:RB->array
+    |  cmplw TMP0, TMP1
+    |  bge ->vmeta_tgetb
+    |  evlddx TMP1, TMP2, RC
+    |  checknil TMP1
+    |  checkok >5
+    |1:
+    |  ins_next1
+    |  evstddx TMP1, BASE, RA
+    |  ins_next2
+    |
+    |5:  // Check for __index if table value is nil.
+    |  lwz TAB:TMP2, TAB:RB->metatable
+    |  cmplwi TAB:TMP2, 0
+    |  beq <1				// No metatable: done.
+    |  lbz TMP2, TAB:TMP2->nomm
+    |  andi. TMP2, TMP2, 1<<MM_index
+    |  bne <1				// 'no __index' flag set: done.
+    |  b ->vmeta_tgetb			// Caveat: preserve TMP0!
+    break;
+
+  case BC_TSETV:
+    |  // RA = src*8, RB = table*8, RC = key*8
+    |  evlddx TAB:RB, BASE, RB
+    |   evlddx RC, BASE, RC
+    |  checktab TAB:RB
+    |  checkfail ->vmeta_tsetv
+    |  checknum RC
+    |  checkfail >5
+    |  // Convert number key to integer
+    |  efdctsi TMP2, RC
+    |    evlddx SAVE0, BASE, RA
+    |   lwz TMP0, TAB:RB->asize
+    |  efdcfsi TMP1, TMP2
+    |   cmplw cr0, TMP0, TMP2
+    |  efdcmpeq cr1, RC, TMP1
+    |   lwz TMP1, TAB:RB->array
+    |  crand 4*cr0+gt, 4*cr0+gt, 4*cr1+gt
+    |   slwi TMP0, TMP2, 3
+    |  ble ->vmeta_tsetv		// Integer key and in array part?
+    |   lbz TMP3, TAB:RB->marked
+    |  evlddx TMP2, TMP1, TMP0
+    |  checknil TMP2
+    |  checkok >3
+    |1:
+    |  andi. TMP2, TMP3, LJ_GC_BLACK	// isblack(table)
+    |   evstddx SAVE0, TMP1, TMP0
+    |  bne >7
+    |2:
+    |  ins_next
+    |
+    |3:  // Check for __newindex if previous value is nil.
+    |  lwz TAB:TMP2, TAB:RB->metatable
+    |  cmplwi TAB:TMP2, 0
+    |  beq <1				// No metatable: done.
+    |  lbz TMP2, TAB:TMP2->nomm
+    |  andi. TMP2, TMP2, 1<<MM_newindex
+    |  bne <1				// 'no __newindex' flag set: done.
+    |  b ->vmeta_tsetv
+    |
+    |5:
+    |  checkstr STR:RC			// String key?
+    |  checkok ->BC_TSETS_Z
+    |  b ->vmeta_tsetv
+    |
+    |7:  // Possible table write barrier for the value. Skip valiswhite check.
+    |  barrierback TAB:RB, TMP3, TMP0
+    |  b <2
+    break;
+  case BC_TSETS:
+    |  // RA = src*8, RB = table*8, RC = str_const*8 (~)
+    |  evlddx TAB:RB, BASE, RB
+    |   srwi TMP1, RC, 1
+    |  checktab TAB:RB
+    |   subfic TMP1, TMP1, -4
+    |   lwzx STR:RC, KBASE, TMP1	// KBASE-4-str_const*4
+    |  checkfail ->vmeta_tsets1
+    |->BC_TSETS_Z:
+    |  // TAB:RB = GCtab *, STR:RC = GCstr *, RA = src*8
+    |  lwz TMP0, TAB:RB->hmask
+    |  lwz TMP1, STR:RC->hash
+    |  lwz NODE:TMP2, TAB:RB->node
+    |   evmergelo STR:RC, TISSTR, STR:RC
+    |    stb ZERO, TAB:RB->nomm		// Clear metamethod cache.
+    |  and TMP1, TMP1, TMP0		// idx = str->hash & tab->hmask
+    |    evlddx SAVE0, BASE, RA
+    |  slwi TMP0, TMP1, 5
+    |  slwi TMP1, TMP1, 3
+    |  sub TMP1, TMP0, TMP1
+    |    lbz TMP3, TAB:RB->marked
+    |  add NODE:TMP2, NODE:TMP2, TMP1	// node = tab->node + (idx*32-idx*8)
+    |1:
+    |  evldd TMP0, NODE:TMP2->key
+    |   evldd TMP1, NODE:TMP2->val
+    |  evcmpeq TMP0, STR:RC
+    |  checkanyfail >5
+    |   checknil TMP1
+    |   checkok >4			// Key found, but nil value?
+    |2:
+    |  andi. TMP0, TMP3, LJ_GC_BLACK	// isblack(table)
+    |    evstdd SAVE0, NODE:TMP2->val
+    |  bne >7
+    |3:
+    |  ins_next
+    |
+    |4:  // Check for __newindex if previous value is nil.
+    |  lwz TAB:TMP1, TAB:RB->metatable
+    |  cmplwi TAB:TMP1, 0
+    |  beq <2				// No metatable: done.
+    |  lbz TMP0, TAB:TMP1->nomm
+    |  andi. TMP0, TMP0, 1<<MM_newindex
+    |  bne <2				// 'no __newindex' flag set: done.
+    |  b ->vmeta_tsets
+    |
+    |5:  // Follow hash chain.
+    |  lwz NODE:TMP2, NODE:TMP2->next
+    |  cmplwi NODE:TMP2, 0
+    |  bne <1
+    |  // End of hash chain: key not found, add a new one.
+    |
+    |  // But check for __newindex first.
+    |  lwz TAB:TMP1, TAB:RB->metatable
+    |   la CARG3, DISPATCH_GL(tmptv)(DISPATCH)
+    |   stw PC, SAVE_PC
+    |   mr CARG1, L
+    |  cmplwi TAB:TMP1, 0
+    |   stw BASE, L->base
+    |  beq >6				// No metatable: continue.
+    |  lbz TMP0, TAB:TMP1->nomm
+    |  andi. TMP0, TMP0, 1<<MM_newindex
+    |  beq ->vmeta_tsets		// 'no __newindex' flag NOT set: check.
+    |6:
+    |  mr CARG2, TAB:RB
+    |  evstdd STR:RC, 0(CARG3)
+    |  bl extern lj_tab_newkey		// (lua_State *L, GCtab *t, TValue *k)
+    |  // Returns TValue *.
+    |  lwz BASE, L->base
+    |  evstdd SAVE0, 0(CRET1)
+    |  b <3				// No 2nd write barrier needed.
+    |
+    |7:  // Possible table write barrier for the value. Skip valiswhite check.
+    |  barrierback TAB:RB, TMP3, TMP0
+    |  b <3
+    break;
+  case BC_TSETB:
+    |  // RA = src*8, RB = table*8, RC = index*8
+    |  evlddx TAB:RB, BASE, RB
+    |   srwi TMP0, RC, 3
+    |  checktab TAB:RB
+    |  checkfail ->vmeta_tsetb
+    |  lwz TMP1, TAB:RB->asize
+    |   lwz TMP2, TAB:RB->array
+    |    lbz TMP3, TAB:RB->marked
+    |  cmplw TMP0, TMP1
+    |   evlddx SAVE0, BASE, RA
+    |  bge ->vmeta_tsetb
+    |  evlddx TMP1, TMP2, RC
+    |  checknil TMP1
+    |  checkok >5
+    |1:
+    |  andi. TMP0, TMP3, LJ_GC_BLACK	// isblack(table)
+    |   evstddx SAVE0, TMP2, RC
+    |  bne >7
+    |2:
+    |  ins_next
+    |
+    |5:  // Check for __newindex if previous value is nil.
+    |  lwz TAB:TMP1, TAB:RB->metatable
+    |  cmplwi TAB:TMP1, 0
+    |  beq <1				// No metatable: done.
+    |  lbz TMP1, TAB:TMP1->nomm
+    |  andi. TMP1, TMP1, 1<<MM_newindex
+    |  bne <1				// 'no __newindex' flag set: done.
+    |  b ->vmeta_tsetb			// Caveat: preserve TMP0!
+    |
+    |7:  // Possible table write barrier for the value. Skip valiswhite check.
+    |  barrierback TAB:RB, TMP3, TMP0
+    |  b <2
+    break;
+
+  case BC_TSETM:
+    |  // RA = base*8 (table at base-1), RD = num_const*8 (start index)
+    |  add RA, BASE, RA
+    |1:
+    |   add TMP3, KBASE, RD
+    |  lwz TAB:CARG2, -4(RA)		// Guaranteed to be a table.
+    |    addic. TMP0, MULTRES, -8
+    |   lwz TMP3, 4(TMP3)		// Integer constant is in lo-word.
+    |    srwi CARG3, TMP0, 3
+    |    beq >4				// Nothing to copy?
+    |  add CARG3, CARG3, TMP3
+    |  lwz TMP2, TAB:CARG2->asize
+    |   slwi TMP1, TMP3, 3
+    |    lbz TMP3, TAB:CARG2->marked
+    |  cmplw CARG3, TMP2
+    |   add TMP2, RA, TMP0
+    |   lwz TMP0, TAB:CARG2->array
+    |  bgt >5
+    |   add TMP1, TMP1, TMP0
+    |    andi. TMP0, TMP3, LJ_GC_BLACK	// isblack(table)
+    |3:  // Copy result slots to table.
+    |   evldd TMP0, 0(RA)
+    |  addi RA, RA, 8
+    |  cmpw cr1, RA, TMP2
+    |   evstdd TMP0, 0(TMP1)
+    |    addi TMP1, TMP1, 8
+    |  blt cr1, <3
+    |  bne >7
+    |4:
+    |  ins_next
+    |
+    |5:  // Need to resize array part.
+    |   stw BASE, L->base
+    |  mr CARG1, L
+    |   stw PC, SAVE_PC
+    |  mr SAVE0, RD
+    |  bl extern lj_tab_reasize		// (lua_State *L, GCtab *t, int nasize)
+    |  // Must not reallocate the stack.
+    |  mr RD, SAVE0
+    |  b <1
+    |
+    |7:  // Possible table write barrier for any value. Skip valiswhite check.
+    |  barrierback TAB:CARG2, TMP3, TMP0
+    |  b <4
+    break;
+
+  /* -- Calls and vararg handling ----------------------------------------- */
+
+  case BC_CALLM:
+    |  // RA = base*8, (RB = (nresults+1)*8,) RC = extra_nargs*8
+    |  add NARGS8:RC, NARGS8:RC, MULTRES
+    |  // Fall through. Assumes BC_CALL follows.
+    break;
+  case BC_CALL:
+    |  // RA = base*8, (RB = (nresults+1)*8,) RC = (nargs+1)*8
+    |  evlddx LFUNC:RB, BASE, RA
+    |   mr TMP2, BASE
+    |   add BASE, BASE, RA
+    |    subi NARGS8:RC, NARGS8:RC, 8
+    |  checkfunc LFUNC:RB
+    |   addi BASE, BASE, 8
+    |  checkfail ->vmeta_call
+    |  ins_call
+    break;
+
+  case BC_CALLMT:
+    |  // RA = base*8, (RB = 0,) RC = extra_nargs*8
+    |  add NARGS8:RC, NARGS8:RC, MULTRES
+    |  // Fall through. Assumes BC_CALLT follows.
+    break;
+  case BC_CALLT:
+    |  // RA = base*8, (RB = 0,) RC = (nargs+1)*8
+    |  evlddx LFUNC:RB, BASE, RA
+    |   add RA, BASE, RA
+    |    lwz TMP1, FRAME_PC(BASE)
+    |    subi NARGS8:RC, NARGS8:RC, 8
+    |  checkfunc LFUNC:RB
+    |   addi RA, RA, 8
+    |  checkfail ->vmeta_callt
+    |->BC_CALLT_Z:
+    |  andi. TMP0, TMP1, FRAME_TYPE	// Caveat: preserve cr0 until the crand.
+    |   lbz TMP3, LFUNC:RB->ffid
+    |    xori TMP2, TMP1, FRAME_VARG
+    |    cmplwi cr1, NARGS8:RC, 0
+    |  bne >7
+    |1:
+    |  stw LFUNC:RB, FRAME_FUNC(BASE)	// Copy function down, but keep PC.
+    |  li TMP2, 0
+    |   cmplwi cr7, TMP3, 1		// (> FF_C) Calling a fast function?
+    |    beq cr1, >3
+    |2:
+    |  addi TMP3, TMP2, 8
+    |   evlddx TMP0, RA, TMP2
+    |  cmplw cr1, TMP3, NARGS8:RC
+    |   evstddx TMP0, BASE, TMP2
+    |  mr TMP2, TMP3
+    |  bne cr1, <2
+    |3:
+    |  crand 4*cr0+eq, 4*cr0+eq, 4*cr7+gt
+    |  beq >5
+    |4:
+    |  ins_callt
+    |
+    |5:  // Tailcall to a fast function with a Lua frame below.
+    |  lwz INS, -4(TMP1)
+    |  decode_RA8 RA, INS
+    |  sub TMP1, BASE, RA
+    |  lwz LFUNC:TMP1, FRAME_FUNC-8(TMP1)
+    |  lwz TMP1, LFUNC:TMP1->pc
+    |  lwz KBASE, PC2PROTO(k)(TMP1)	// Need to prepare KBASE.
+    |  b <4
+    |
+    |7:  // Tailcall from a vararg function.
+    |  andi. TMP0, TMP2, FRAME_TYPEP
+    |  bne <1				// Vararg frame below?
+    |  sub BASE, BASE, TMP2		// Relocate BASE down.
+    |  lwz TMP1, FRAME_PC(BASE)
+    |  andi. TMP0, TMP1, FRAME_TYPE
+    |  b <1
+    break;
+
+  case BC_ITERC:
+    |  // RA = base*8, (RB = (nresults+1)*8, RC = (nargs+1)*8 ((2+1)*8))
+    |  subi RA, RA, 24			// evldd doesn't support neg. offsets.
+    |   mr TMP2, BASE
+    |  evlddx LFUNC:RB, BASE, RA
+    |   add BASE, BASE, RA
+    |   evldd TMP0, 8(BASE)
+    |    evldd TMP1, 16(BASE)
+    |  evstdd LFUNC:RB, 24(BASE)	// Copy callable.
+    |  checkfunc LFUNC:RB
+    |   evstdd TMP0, 32(BASE)		// Copy state.
+    |     li NARGS8:RC, 16		// Iterators get 2 arguments.
+    |    evstdd TMP1, 40(BASE)		// Copy control var.
+    |     addi BASE, BASE, 32
+    |  checkfail ->vmeta_call
+    |  ins_call
+    break;
+
+  case BC_ITERN:
+    |  // RA = base*8, (RB = (nresults+1)*8, RC = (nargs+1)*8 (2+1)*8)
+#if LJ_HASJIT
+    |  // NYI: add hotloop, record BC_ITERN.
+#endif
+    |  add RA, BASE, RA
+    |  lwz TAB:RB, -12(RA)
+    |  lwz RC, -4(RA)			// Get index from control var.
+    |  lwz TMP0, TAB:RB->asize
+    |  lwz TMP1, TAB:RB->array
+    |   addi PC, PC, 4
+    |1:  // Traverse array part.
+    |  cmplw RC, TMP0
+    |   slwi TMP3, RC, 3
+    |  bge >5				// Index points after array part?
+    |  evlddx TMP2, TMP1, TMP3
+    |  checknil TMP2
+    |     lwz INS, -4(PC)
+    |  checkok >4
+    |   efdcfsi TMP0, RC
+    |    addi RC, RC, 1
+    |     addis TMP3, PC, -(BCBIAS_J*4 >> 16)
+    |  evstdd TMP2, 8(RA)
+    |     decode_RD4 TMP1, INS
+    |    stw RC, -4(RA)			// Update control var.
+    |     add PC, TMP1, TMP3
+    |   evstdd TMP0, 0(RA)
+    |3:
+    |  ins_next
+    |
+    |4:  // Skip holes in array part.
+    |  addi RC, RC, 1
+    |  b <1
+    |
+    |5:  // Traverse hash part.
+    |  lwz TMP1, TAB:RB->hmask
+    |  sub RC, RC, TMP0
+    |   lwz TMP2, TAB:RB->node
+    |6:
+    |  cmplw RC, TMP1			// End of iteration? Branch to ITERL+1.
+    |   slwi TMP3, RC, 5
+    |  bgt <3
+    |   slwi RB, RC, 3
+    |   sub TMP3, TMP3, RB
+    |  evlddx RB, TMP2, TMP3
+    |   add NODE:TMP3, TMP2, TMP3
+    |  checknil RB
+    |     lwz INS, -4(PC)
+    |  checkok >7
+    |   evldd TMP3, NODE:TMP3->key
+    |     addis TMP2, PC, -(BCBIAS_J*4 >> 16)
+    |  evstdd RB, 8(RA)
+    |    add RC, RC, TMP0
+    |     decode_RD4 TMP1, INS
+    |   evstdd TMP3, 0(RA)
+    |    addi RC, RC, 1
+    |     add PC, TMP1, TMP2
+    |    stw RC, -4(RA)			// Update control var.
+    |  b <3
+    |
+    |7:  // Skip holes in hash part.
+    |  addi RC, RC, 1
+    |  b <6
+    break;
+
+  case BC_ISNEXT:
+    |  // RA = base*8, RD = target (points to ITERN)
+    |  add RA, BASE, RA
+    |   li TMP2, -24
+    |  evlddx CFUNC:TMP1, RA, TMP2
+    |   lwz TMP2, -16(RA)
+    |    lwz TMP3, -8(RA)
+    |  evmergehi TMP0, CFUNC:TMP1, CFUNC:TMP1
+    |   cmpwi cr0, TMP2, LJ_TTAB
+    |  cmpwi cr1, TMP0, LJ_TFUNC
+    |    cmpwi cr6, TMP3, LJ_TNIL
+    |  bne cr1, >5
+    |  lbz TMP1, CFUNC:TMP1->ffid
+    |   crand 4*cr0+eq, 4*cr0+eq, 4*cr6+eq
+    |  cmpwi cr7, TMP1, FF_next_N
+    |    srwi TMP0, RD, 1
+    |  crand 4*cr0+eq, 4*cr0+eq, 4*cr7+eq
+    |    add TMP3, PC, TMP0
+    |  bne cr0, >5
+    |  stw ZERO, -4(RA)			// Initialize control var.
+    |    addis PC, TMP3, -(BCBIAS_J*4 >> 16)
+    |1:
+    |  ins_next
+    |5:  // Despecialize bytecode if any of the checks fail.
+    |  li TMP0, BC_JMP
+    |   li TMP1, BC_ITERC
+    |  stb TMP0, -1(PC)
+    |    addis PC, TMP3, -(BCBIAS_J*4 >> 16)
+    |   stb TMP1, 3(PC)
+    |  b <1
+    break;
+
+  case BC_VARG:
+    |  // RA = base*8, RB = (nresults+1)*8, RC = numparams*8
+    |  lwz TMP0, FRAME_PC(BASE)
+    |  add RC, BASE, RC
+    |   add RA, BASE, RA
+    |  addi RC, RC, FRAME_VARG
+    |   add TMP2, RA, RB
+    |  subi TMP3, BASE, 8		// TMP3 = vtop
+    |  sub RC, RC, TMP0			// RC = vbase
+    |  // Note: RC may now be even _above_ BASE if nargs was < numparams.
+    |  cmplwi cr1, RB, 0
+    |   sub. TMP1, TMP3, RC
+    |  beq cr1, >5			// Copy all varargs?
+    |   subi TMP2, TMP2, 16
+    |   ble >2				// No vararg slots?
+    |1:  // Copy vararg slots to destination slots.
+    |  evldd TMP0, 0(RC)
+    |   addi RC, RC, 8
+    |  evstdd TMP0, 0(RA)
+    |  cmplw RA, TMP2
+    |   cmplw cr1, RC, TMP3
+    |  bge >3				// All destination slots filled?
+    |    addi RA, RA, 8
+    |   blt cr1, <1			// More vararg slots?
+    |2:  // Fill up remainder with nil.
+    |  evstdd TISNIL, 0(RA)
+    |  cmplw RA, TMP2
+    |   addi RA, RA, 8
+    |  blt <2
+    |3:
+    |  ins_next
+    |
+    |5:  // Copy all varargs.
+    |  lwz TMP0, L->maxstack
+    |   li MULTRES, 8			// MULTRES = (0+1)*8
+    |  ble <3				// No vararg slots?
+    |  add TMP2, RA, TMP1
+    |  cmplw TMP2, TMP0
+    |   addi MULTRES, TMP1, 8
+    |  bgt >7
+    |6:
+    |  evldd TMP0, 0(RC)
+    |   addi RC, RC, 8
+    |  evstdd TMP0, 0(RA)
+    |  cmplw RC, TMP3
+    |   addi RA, RA, 8
+    |  blt <6				// More vararg slots?
+    |  b <3
+    |
+    |7:  // Grow stack for varargs.
+    |  mr CARG1, L
+    |   stw RA, L->top
+    |  sub SAVE0, RC, BASE		// Need delta, because BASE may change.
+    |   stw BASE, L->base
+    |  sub RA, RA, BASE
+    |   stw PC, SAVE_PC
+    |  srwi CARG2, TMP1, 3
+    |  bl extern lj_state_growstack	// (lua_State *L, int n)
+    |  lwz BASE, L->base
+    |  add RA, BASE, RA
+    |  add RC, BASE, SAVE0
+    |  subi TMP3, BASE, 8
+    |  b <6
+    break;
+
+  /* -- Returns ----------------------------------------------------------- */
+
+  case BC_RETM:
+    |  // RA = results*8, RD = extra_nresults*8
+    |  add RD, RD, MULTRES		// MULTRES >= 8, so RD >= 8.
+    |  // Fall through. Assumes BC_RET follows.
+    break;
+
+  case BC_RET:
+    |  // RA = results*8, RD = (nresults+1)*8
+    |  lwz PC, FRAME_PC(BASE)
+    |   add RA, BASE, RA
+    |    mr MULTRES, RD
+    |1:
+    |  andi. TMP0, PC, FRAME_TYPE
+    |   xori TMP1, PC, FRAME_VARG
+    |  bne ->BC_RETV_Z
+    |
+    |->BC_RET_Z:
+    |  // BASE = base, RA = resultptr, RD = (nresults+1)*8, PC = return
+    |   lwz INS, -4(PC)
+    |  cmpwi RD, 8
+    |   subi TMP2, BASE, 8
+    |   subi RC, RD, 8
+    |   decode_RB8 RB, INS
+    |  beq >3
+    |   li TMP1, 0
+    |2:
+    |  addi TMP3, TMP1, 8
+    |   evlddx TMP0, RA, TMP1
+    |  cmpw TMP3, RC
+    |   evstddx TMP0, TMP2, TMP1
+    |  beq >3
+    |  addi TMP1, TMP3, 8
+    |   evlddx TMP0, RA, TMP3
+    |  cmpw TMP1, RC
+    |   evstddx TMP0, TMP2, TMP3
+    |  bne <2
+    |3:
+    |5:
+    |  cmplw RB, RD
+    |   decode_RA8 RA, INS
+    |  bgt >6
+    |   sub BASE, TMP2, RA
+    |  lwz LFUNC:TMP1, FRAME_FUNC(BASE)
+    |  ins_next1
+    |  lwz TMP1, LFUNC:TMP1->pc
+    |  lwz KBASE, PC2PROTO(k)(TMP1)
+    |  ins_next2
+    |
+    |6:  // Fill up results with nil.
+    |  subi TMP1, RD, 8
+    |   addi RD, RD, 8
+    |  evstddx TISNIL, TMP2, TMP1
+    |  b <5
+    |
+    |->BC_RETV_Z:  // Non-standard return case.
+    |  andi. TMP2, TMP1, FRAME_TYPEP
+    |  bne ->vm_return
+    |  // Return from vararg function: relocate BASE down.
+    |  sub BASE, BASE, TMP1
+    |  lwz PC, FRAME_PC(BASE)
+    |  b <1
+    break;
+
+  case BC_RET0: case BC_RET1:
+    |  // RA = results*8, RD = (nresults+1)*8
+    |  lwz PC, FRAME_PC(BASE)
+    |   add RA, BASE, RA
+    |    mr MULTRES, RD
+    |  andi. TMP0, PC, FRAME_TYPE
+    |   xori TMP1, PC, FRAME_VARG
+    |  bne ->BC_RETV_Z
+    |
+    |  lwz INS, -4(PC)
+    |   subi TMP2, BASE, 8
+    |  decode_RB8 RB, INS
+    if (op == BC_RET1) {
+      |  evldd TMP0, 0(RA)
+      |  evstdd TMP0, 0(TMP2)
+    }
+    |5:
+    |  cmplw RB, RD
+    |   decode_RA8 RA, INS
+    |  bgt >6
+    |   sub BASE, TMP2, RA
+    |  lwz LFUNC:TMP1, FRAME_FUNC(BASE)
+    |  ins_next1
+    |  lwz TMP1, LFUNC:TMP1->pc
+    |  lwz KBASE, PC2PROTO(k)(TMP1)
+    |  ins_next2
+    |
+    |6:  // Fill up results with nil.
+    |  subi TMP1, RD, 8
+    |   addi RD, RD, 8
+    |  evstddx TISNIL, TMP2, TMP1
+    |  b <5
+    break;
+
+  /* -- Loops and branches ------------------------------------------------ */
+
+  case BC_FORL:
+#if LJ_HASJIT
+    |  hotloop
+#endif
+    |  // Fall through. Assumes BC_IFORL follows.
+    break;
+
+  case BC_JFORI:
+  case BC_JFORL:
+#if !LJ_HASJIT
+    break;
+#endif
+  case BC_FORI:
+  case BC_IFORL:
+    |  // RA = base*8, RD = target (after end of loop or start of loop)
+    vk = (op == BC_IFORL || op == BC_JFORL);
+    |  add RA, BASE, RA
+    |  evldd TMP1, FORL_IDX*8(RA)
+    |  evldd TMP3, FORL_STEP*8(RA)
+    |  evldd TMP2, FORL_STOP*8(RA)
+    if (!vk) {
+      |  evcmpgtu cr0, TMP1, TISNUM
+      |  evcmpgtu cr7, TMP3, TISNUM
+      |  evcmpgtu cr1, TMP2, TISNUM
+      |  cror 4*cr0+lt, 4*cr0+lt, 4*cr7+lt
+      |  cror 4*cr0+lt, 4*cr0+lt, 4*cr1+lt
+      |  blt ->vmeta_for
+    }
+    if (vk) {
+      |  efdadd TMP1, TMP1, TMP3
+      |  evstdd TMP1, FORL_IDX*8(RA)
+    }
+    |   evcmpgts TMP3, TISNIL
+    |  evstdd TMP1, FORL_EXT*8(RA)
+    |   bge >2
+    |  efdcmpgt TMP1, TMP2
+    |1:
+    if (op != BC_JFORL) {
+      |  srwi RD, RD, 1
+      |  add RD, PC, RD
+      if (op == BC_JFORI) {
+	|  addis PC, RD, -(BCBIAS_J*4 >> 16)
+      } else {
+	|  addis RD, RD, -(BCBIAS_J*4 >> 16)
+      }
+    }
+    if (op == BC_FORI) {
+      |  iselgt PC, RD, PC
+    } else if (op == BC_IFORL) {
+      |  iselgt PC, PC, RD
+    } else {
+      |  ble =>BC_JLOOP
+    }
+    |  ins_next
+    |2:
+    |  efdcmpgt TMP2, TMP1
+    |  b <1
+    break;
+
+  case BC_ITERL:
+#if LJ_HASJIT
+    |  hotloop
+#endif
+    |  // Fall through. Assumes BC_IITERL follows.
+    break;
+
+  case BC_JITERL:
+#if !LJ_HASJIT
+    break;
+#endif
+  case BC_IITERL:
+    |  // RA = base*8, RD = target
+    |  evlddx TMP1, BASE, RA
+    |   subi RA, RA, 8
+    |  checknil TMP1
+    |  checkok >1			// Stop if iterator returned nil.
+    if (op == BC_JITERL) {
+      |  NYI
+    } else {
+      |  branch_RD			// Otherwise save control var + branch.
+      |  evstddx TMP1, BASE, RA
+    }
+    |1:
+    |  ins_next
+    break;
+
+  case BC_LOOP:
+    |  // RA = base*8, RD = target (loop extent)
+    |  // Note: RA/RD is only used by trace recorder to determine scope/extent
+    |  // This opcode does NOT jump, it's only purpose is to detect a hot loop.
+#if LJ_HASJIT
+    |  hotloop
+#endif
+    |  // Fall through. Assumes BC_ILOOP follows.
+    break;
+
+  case BC_ILOOP:
+    |  // RA = base*8, RD = target (loop extent)
+    |  ins_next
+    break;
+
+  case BC_JLOOP:
+#if LJ_HASJIT
+    |  NYI
+#endif
+    break;
+
+  case BC_JMP:
+    |  // RA = base*8 (only used by trace recorder), RD = target
+    |  branch_RD
+    |  ins_next
+    break;
+
+  /* -- Function headers -------------------------------------------------- */
+
+  case BC_FUNCF:
+#if LJ_HASJIT
+    |  hotcall
+#endif
+  case BC_FUNCV:  /* NYI: compiled vararg functions. */
+    |  // Fall through. Assumes BC_IFUNCF/BC_IFUNCV follow.
+    break;
+
+  case BC_JFUNCF:
+#if !LJ_HASJIT
+    break;
+#endif
+  case BC_IFUNCF:
+    |  // BASE = new base, RA = BASE+framesize*8, RB = LFUNC, RC = nargs*8
+    |  lwz TMP2, L->maxstack
+    |   lbz TMP1, -4+PC2PROTO(numparams)(PC)
+    |    lwz KBASE, -4+PC2PROTO(k)(PC)
+    |  cmplw RA, TMP2
+    |   slwi TMP1, TMP1, 3
+    |  bgt ->vm_growstack_l
+    |  ins_next1
+    |2:
+    |  cmplw NARGS8:RC, TMP1		// Check for missing parameters.
+    |  ble >3
+    if (op == BC_JFUNCF) {
+      |  NYI
+    } else {
+      |  ins_next2
+    }
+    |
+    |3:  // Clear missing parameters.
+    |  evstddx TISNIL, BASE, NARGS8:RC
+    |  addi NARGS8:RC, NARGS8:RC, 8
+    |  b <2
+    break;
+
+  case BC_JFUNCV:
+#if !LJ_HASJIT
+    break;
+#endif
+    |  NYI  // NYI: compiled vararg functions
+    break;  /* NYI: compiled vararg functions. */
+
+  case BC_IFUNCV:
+    |  // BASE = new base, RA = BASE+framesize*8, RB = LFUNC, RC = nargs*8
+    |  lwz TMP2, L->maxstack
+    |   add TMP1, BASE, RC
+    |  add TMP0, RA, RC
+    |   stw LFUNC:RB, 4(TMP1)		// Store copy of LFUNC.
+    |   addi TMP3, RC, 8+FRAME_VARG
+    |    lwz KBASE, -4+PC2PROTO(k)(PC)
+    |  cmplw TMP0, TMP2
+    |   stw TMP3, 0(TMP1)		// Store delta + FRAME_VARG.
+    |  bge ->vm_growstack_l
+    |  lbz TMP2, -4+PC2PROTO(numparams)(PC)
+    |   mr RA, BASE
+    |   mr RC, TMP1
+    |  ins_next1
+    |  cmpwi TMP2, 0
+    |   addi BASE, TMP1, 8
+    |  beq >3
+    |1:
+    |  cmplw RA, RC			// Less args than parameters?
+    |   evldd TMP0, 0(RA)
+    |  bge >4
+    |    evstdd TISNIL, 0(RA)		// Clear old fixarg slot (help the GC).
+    |    addi RA, RA, 8
+    |2:
+    |  addic. TMP2, TMP2, -1
+    |   evstdd TMP0, 8(TMP1)
+    |    addi TMP1, TMP1, 8
+    |  bne <1
+    |3:
+    |  ins_next2
+    |
+    |4:  // Clear missing parameters.
+    |  evmr TMP0, TISNIL
+    |  b <2
+    break;
+
+  case BC_FUNCC:
+  case BC_FUNCCW:
+    |  // BASE = new base, RA = BASE+framesize*8, RB = CFUNC, RC = nargs*8
+    if (op == BC_FUNCC) {
+      |  lwz TMP3, CFUNC:RB->f
+    } else {
+      |  lwz TMP3, DISPATCH_GL(wrapf)(DISPATCH)
+    }
+    |   add TMP1, RA, NARGS8:RC
+    |   lwz TMP2, L->maxstack
+    |    add RC, BASE, NARGS8:RC
+    |   stw BASE, L->base
+    |   cmplw TMP1, TMP2
+    |    stw RC, L->top
+    |     li_vmstate C
+    |  mtctr TMP3
+    if (op == BC_FUNCCW) {
+      |  lwz CARG2, CFUNC:RB->f
+    }
+    |  mr CARG1, L
+    |   bgt ->vm_growstack_c		// Need to grow stack.
+    |     st_vmstate
+    |  bctrl				// (lua_State *L [, lua_CFunction f])
+    |  // Returns nresults.
+    |  lwz TMP1, L->top
+    |   slwi RD, CRET1, 3
+    |  lwz BASE, L->base
+    |    li_vmstate INTERP
+    |  lwz PC, FRAME_PC(BASE)		// Fetch PC of caller.
+    |   sub RA, TMP1, RD		// RA = L->top - nresults*8
+    |    st_vmstate
+    |  b ->vm_returnc
+    break;
+
+  /* ---------------------------------------------------------------------- */
+
+  default:
+    fprintf(stderr, "Error: undefined opcode BC_%s\n", bc_names[op]);
+    exit(2);
+    break;
+  }
+}
+
+static int build_backend(BuildCtx *ctx)
+{
+  int op;
+
+  dasm_growpc(Dst, BC__MAX);
+
+  build_subroutines(ctx);
+
+  |.code_op
+  for (op = 0; op < BC__MAX; op++)
+    build_ins(ctx, (BCOp)op, op);
+
+  return BC__MAX;
+}
+
+/* Emit pseudo frame-info for all assembler functions. */
+static void emit_asm_debug(BuildCtx *ctx)
+{
+  int i;
+  switch (ctx->mode) {
+  case BUILD_elfasm:
+    fprintf(ctx->fp, "\t.section .debug_frame,\"\",@progbits\n");
+    fprintf(ctx->fp,
+	".Lframe0:\n"
+	"\t.long .LECIE0-.LSCIE0\n"
+	".LSCIE0:\n"
+	"\t.long 0xffffffff\n"
+	"\t.byte 0x1\n"
+	"\t.string \"\"\n"
+	"\t.uleb128 0x1\n"
+	"\t.sleb128 -4\n"
+	"\t.byte 65\n"
+	"\t.byte 0xc\n\t.uleb128 1\n\t.uleb128 0\n"
+	"\t.align 2\n"
+	".LECIE0:\n\n");
+    fprintf(ctx->fp,
+	".LSFDE0:\n"
+	"\t.long .LEFDE0-.LASFDE0\n"
+	".LASFDE0:\n"
+	"\t.long .Lframe0\n"
+	"\t.long .Lbegin\n"
+	"\t.long %d\n"
+	"\t.byte 0xe\n\t.uleb128 %d\n"
+	"\t.byte 0x11\n\t.uleb128 65\n\t.sleb128 -1\n"
+	"\t.byte 0x5\n\t.uleb128 70\n\t.sleb128 37\n",
+	(int)ctx->codesz, CFRAME_SIZE);
+    for (i = 14; i <= 31; i++)
+      fprintf(ctx->fp,
+	"\t.byte %d\n\t.uleb128 %d\n"
+	"\t.byte 5\n\t.uleb128 %d\n\t.uleb128 %d\n",
+	0x80+i, 1+2*(31-i), 1200+i, 2+2*(31-i));
+    fprintf(ctx->fp,
+	"\t.align 2\n"
+	".LEFDE0:\n\n");
+    fprintf(ctx->fp, "\t.section .eh_frame,\"a\",@progbits\n");
+    fprintf(ctx->fp,
+	".Lframe1:\n"
+	"\t.long .LECIE1-.LSCIE1\n"
+	".LSCIE1:\n"
+	"\t.long 0\n"
+	"\t.byte 0x1\n"
+	"\t.string \"zPR\"\n"
+	"\t.uleb128 0x1\n"
+	"\t.sleb128 -4\n"
+	"\t.byte 65\n"
+	"\t.uleb128 6\n"			/* augmentation length */
+	"\t.byte 0x1b\n"			/* pcrel|sdata4 */
+	"\t.long lj_err_unwind_dwarf-.\n"
+	"\t.byte 0x1b\n"			/* pcrel|sdata4 */
+	"\t.byte 0xc\n\t.uleb128 1\n\t.uleb128 0\n"
+	"\t.align 2\n"
+	".LECIE1:\n\n");
+    fprintf(ctx->fp,
+	".LSFDE1:\n"
+	"\t.long .LEFDE1-.LASFDE1\n"
+	".LASFDE1:\n"
+	"\t.long .LASFDE1-.Lframe1\n"
+	"\t.long .Lbegin-.\n"
+	"\t.long %d\n"
+	"\t.uleb128 0\n"			/* augmentation length */
+	"\t.byte 0xe\n\t.uleb128 %d\n"
+	"\t.byte 0x11\n\t.uleb128 65\n\t.sleb128 -1\n"
+	"\t.byte 0x5\n\t.uleb128 70\n\t.sleb128 37\n",
+	(int)ctx->codesz, CFRAME_SIZE);
+    for (i = 14; i <= 31; i++)
+      fprintf(ctx->fp,
+	"\t.byte %d\n\t.uleb128 %d\n"
+	"\t.byte 5\n\t.uleb128 %d\n\t.uleb128 %d\n",
+	0x80+i, 1+2*(31-i), 1200+i, 2+2*(31-i));
+    fprintf(ctx->fp,
+	"\t.align 2\n"
+	".LEFDE1:\n\n");
+    break;
+  default:
+    break;
+  }
+}
+
diff --git a/third_party/luajit/src/buildvm_ppcspe.h b/third_party/luajit/src/buildvm_ppcspe.h
index 257fe353c6c6ac98bdab69a01205de8c94e93d52..32571ebe9611d29f7ccde14480bbbf5396f2962f 100644
--- a/third_party/luajit/src/buildvm_ppcspe.h
+++ b/third_party/luajit/src/buildvm_ppcspe.h
@@ -2,7 +2,7 @@
 ** This file has been pre-processed with DynASM.
 ** http://luajit.org/dynasm.html
 ** DynASM version 1.3.0, DynASM ppc version 1.3.0
-** DO NOT EDIT! The original file is in "buildvm_ppc.dasc".
+** DO NOT EDIT! The original file is in "buildvm_ppcspe.dasc".
 */
 
 #if DASM_VERSION != 10300
@@ -12,7 +12,7 @@
 #define DASM_SECTION_CODE_OP	0
 #define DASM_SECTION_CODE_SUB	1
 #define DASM_MAXSECTION		2
-static const unsigned int build_actionlist[4992] = {
+static const unsigned int build_actionlist[4995] = {
 0x00010001,
 0x00060014,
 0x72000000,
@@ -73,27 +73,29 @@ static const unsigned int build_actionlist[4992] = {
 0x90120000,
 0x00098200,
 0x0006001a,
-0x800100b4,
-0x11c12301,
-0x11e12b01,
-0x12013301,
-0x12213b01,
-0x12414301,
-0x12614b01,
+0x800100bc,
+0x81810024,
+0x11c12b01,
+0x11e13301,
+0x12013b01,
+0x12214301,
+0x12414b01,
+0x12615301,
 0x7c0803a6,
-0x12815301,
-0x12a15b01,
-0x12c16301,
-0x12e16b01,
-0x13017301,
-0x13217b01,
-0x13418301,
-0x13618b01,
-0x13819301,
-0x13a19b01,
-0x13c1a301,
-0x13e1ab01,
-0x382100b0,
+0x7d838120,
+0x12815b01,
+0x12a16301,
+0x12c16b01,
+0x12e17301,
+0x13017b01,
+0x13218301,
+0x13418b01,
+0x13619301,
+0x13819b01,
+0x13a1a301,
+0x13c1ab01,
+0x13e1b301,
+0x382100b8,
 0x4e800020,
 0x00060010,
 0x40810000,
@@ -218,27 +220,29 @@ static const unsigned int build_actionlist[4992] = {
 0x7c0903a6,
 0x4e800420,
 0x00060021,
-0x9421ff50,
-0x11c12321,
-0x11e12b21,
-0x12013321,
-0x12213b21,
-0x12414321,
-0x12614b21,
+0x9421ff48,
+0x11c12b21,
+0x11e13321,
+0x12013b21,
+0x12214321,
+0x12414b21,
+0x12615321,
 0x7c0802a6,
-0x12815321,
-0x12a15b21,
-0x12c16321,
-0x12e16b21,
-0x13017321,
-0x13217b21,
-0x900100b4,
-0x13418321,
-0x13618b21,
-0x13819321,
-0x13a19b21,
-0x13c1a321,
-0x13e1ab21,
+0x7d800026,
+0x12815b21,
+0x12a16321,
+0x12c16b21,
+0x12e17321,
+0x13017b21,
+0x13218321,
+0x900100bc,
+0x91810024,
+0x13418b21,
+0x13619321,
+0x13819b21,
+0x13a1a321,
+0x13c1ab21,
+0x13e1b321,
 0x7c721b78,
 0x82320000,
 0x00098200,
@@ -297,54 +301,58 @@ static const unsigned int build_actionlist[4992] = {
 0x48000000,
 0x00050018,
 0x00060022,
-0x9421ff50,
-0x11c12321,
-0x11e12b21,
-0x12013321,
-0x12213b21,
-0x12414321,
-0x12614b21,
+0x9421ff48,
+0x11c12b21,
+0x11e13321,
+0x12013b21,
+0x12214321,
+0x12414b21,
+0x12615321,
 0x7c0802a6,
-0x12815321,
-0x12a15b21,
-0x12c16321,
-0x12e16b21,
-0x13017321,
-0x13217b21,
-0x900100b4,
-0x13418321,
-0x13618b21,
-0x13819321,
-0x13a19b21,
-0x13c1a321,
-0x13e1ab21,
+0x7d800026,
+0x12815b21,
+0x12a16321,
+0x12c16b21,
+0x12e17321,
+0x13017b21,
+0x13218321,
+0x900100bc,
+0x91810024,
+0x13418b21,
+0x13619321,
+0x13819b21,
+0x13a1a321,
+0x13c1ab21,
+0x13e1b321,
 0x3a000000,
 0x00098200,
 0x90c1001c,
 0x48000000,
 0x00050001,
 0x00060023,
-0x9421ff50,
-0x11c12321,
-0x11e12b21,
-0x12013321,
-0x12213b21,
-0x12414321,
-0x12614b21,
+0x9421ff48,
+0x11c12b21,
+0x11e13321,
+0x12013b21,
+0x12214321,
+0x12414b21,
+0x12615321,
 0x7c0802a6,
-0x12815321,
-0x12a15b21,
-0x12c16321,
-0x12e16b21,
-0x13017321,
-0x13217b21,
-0x900100b4,
-0x13418321,
-0x13618b21,
-0x13819321,
-0x13a19b21,
-0x13c1a321,
-0x13e1ab21,
+0x7d800026,
+0x12815b21,
+0x12a16321,
+0x12c16b21,
+0x12e17321,
+0x13017b21,
+0x13218321,
+0x900100bc,
+0x91810024,
+0x13418b21,
+0x13619321,
+0x13819b21,
+0x13a1a321,
+0x13c1ab21,
+0x13e1b321,
 0x3a000000,
 0x00098200,
 0x0006000b,
@@ -407,27 +415,29 @@ static const unsigned int build_actionlist[4992] = {
 0x7c0903a6,
 0x4e800420,
 0x00060027,
-0x9421ff50,
-0x11c12321,
-0x11e12b21,
-0x12013321,
-0x12213b21,
-0x12414321,
-0x12614b21,
+0x9421ff48,
+0x11c12b21,
+0x11e13321,
+0x12013b21,
+0x12214321,
+0x12414b21,
+0x12615321,
 0x7c0802a6,
-0x12815321,
-0x12a15b21,
-0x12c16321,
-0x12e16b21,
-0x13017321,
-0x13217b21,
-0x900100b4,
-0x13418321,
-0x13618b21,
-0x13819321,
-0x13a19b21,
-0x13c1a321,
-0x13e1ab21,
+0x7d800026,
+0x12815b21,
+0x12a16321,
+0x12c16b21,
+0x12e17321,
+0x13017b21,
+0x13218321,
+0x900100bc,
+0x91810024,
+0x13418b21,
+0x13619321,
+0x13819b21,
+0x13a1a321,
+0x13c1ab21,
+0x13e1b321,
 0x7c721b78,
 0x80030000,
 0x00098200,
@@ -733,6 +743,7 @@ static const unsigned int build_actionlist[4992] = {
 0x00060035,
 0x7d0e1850,
 0x9203fff0,
+0x7dc97378,
 0x3a080000,
 0x00098200,
 0x7c6e1b78,
@@ -2759,14 +2770,6 @@ static const unsigned int build_actionlist[4992] = {
 0x00060097,
 0x00000000,
 0x00060098,
-0x00000000,
-0x7c810808,
-0x00000000,
-0x00060099,
-0x00000000,
-0x7c810808,
-0x00000000,
-0x0006009a,
 0x1083222d,
 0x28070001,
 0x10c5322d,
@@ -2827,7 +2830,7 @@ static const unsigned int build_actionlist[4992] = {
 0x4e800020,
 0x0006000c,
 0x7c810808,
-0x0006009b,
+0x00060099,
 0x00000000,
 0x7c810808,
 0x00000000,
@@ -3308,7 +3311,7 @@ static const unsigned int build_actionlist[4992] = {
 0x40830000,
 0x0005083d,
 0x00000000,
-0x0006009c,
+0x0006009a,
 0x108caae9,
 0x48000001,
 0x00050094,
@@ -3346,7 +3349,7 @@ static const unsigned int build_actionlist[4992] = {
 0x0005083d,
 0x00000000,
 0x48000000,
-0x0005009c,
+0x0005009a,
 0x00000000,
 0x108e5300,
 0x10ce5b00,
@@ -3572,8 +3575,6 @@ static const unsigned int build_actionlist[4992] = {
 0x48000000,
 0x0005000b,
 0x00000000,
-0x80f00000,
-0x3a100004,
 0x814efffc,
 0x5588007e,
 0x000900ab,
@@ -3599,6 +3600,8 @@ static const unsigned int build_actionlist[4992] = {
 0x40820000,
 0x00050802,
 0x0006000b,
+0x80f00000,
+0x3a100004,
 0x54e815ba,
 0x54ea5d78,
 0x54ec9b78,
@@ -3781,10 +3784,10 @@ static const unsigned int build_actionlist[4992] = {
 0x7d6f402e,
 0x00000000,
 0x48000000,
-0x0005009d,
+0x0005009b,
 0x00000000,
 0x48000000,
-0x0005009e,
+0x0005009c,
 0x00000000,
 0x114e5300,
 0x116e5b00,
@@ -3840,7 +3843,7 @@ static const unsigned int build_actionlist[4992] = {
 0x0006000f,
 0x100bba34,
 0x41800000,
-0x0005089d,
+0x0005089b,
 0x48000000,
 0x0005002f,
 0x00000000,
@@ -3852,7 +3855,7 @@ static const unsigned int build_actionlist[4992] = {
 0x7d6f402e,
 0x40800000,
 0x0005082c,
-0x0006009d,
+0x0006009b,
 0x800a0000,
 0x00098200,
 0x810b0000,
@@ -4019,7 +4022,7 @@ static const unsigned int build_actionlist[4992] = {
 0x0006000f,
 0x100bba34,
 0x41800000,
-0x0005089e,
+0x0005089c,
 0x48000000,
 0x00050033,
 0x00060011,
@@ -4044,7 +4047,7 @@ static const unsigned int build_actionlist[4992] = {
 0x7d6f402e,
 0x40800000,
 0x00050830,
-0x0006009e,
+0x0006009c,
 0x800a0000,
 0x00098200,
 0x810b0000,
@@ -4282,11 +4285,11 @@ static const unsigned int build_actionlist[4992] = {
 0x80110000,
 0x00098200,
 0x54c607b8,
-0x91510000,
+0x90910000,
 0x00098200,
-0x98ca0000,
+0x98c40000,
 0x00098200,
-0x900a0000,
+0x90040000,
 0x00098200,
 0x00000000,
 0x48000000,
@@ -4645,7 +4648,7 @@ static const unsigned int build_actionlist[4992] = {
 0x6a080000,
 0x00090200,
 0x40820000,
-0x0005089f,
+0x0005089d,
 0x00060017,
 0x80f0fffc,
 0x2c0c0008,
@@ -4696,7 +4699,7 @@ static const unsigned int build_actionlist[4992] = {
 0x13494320,
 0x48000000,
 0x0005000f,
-0x0006009f,
+0x0006009d,
 0x71090000,
 0x00090200,
 0x40820000,
@@ -4714,7 +4717,7 @@ static const unsigned int build_actionlist[4992] = {
 0x6a080000,
 0x00090200,
 0x40820000,
-0x0005089f,
+0x0005089d,
 0x80f0fffc,
 0x392efff8,
 0x54ea5d78,
@@ -5140,8 +5143,6 @@ enum {
   GLOB_vm_ceil_efd,
   GLOB_vm_trunc_efd,
   GLOB_vm_trunc_hilo,
-  GLOB_vm_powi,
-  GLOB_vm_foldfpm,
   GLOB_vm_foldarith,
   GLOB_vm_ffi_call,
   GLOB_BC_MODVN_Z,
@@ -5283,8 +5284,6 @@ static const char *const globnames[] = {
   "vm_ceil_efd",
   "vm_trunc_efd",
   "vm_trunc_hilo",
-  "vm_powi",
-  "vm_foldfpm",
   "vm_foldarith",
   "vm_ffi_call",
   "BC_MODVN_Z",
@@ -5367,113 +5366,105 @@ static void build_subroutines(BuildCtx *ctx)
   dasm_put(Dst, 0);
   dasm_put(Dst, 1, FRAME_P, LJ_TTRUE, FRAME_TYPE, FRAME_C, ~LJ_VMST_C, Dt1(->base), DISPATCH_GL(vmstate), 31-3, Dt1(->top));
   dasm_put(Dst, 55, Dt1(->cframe), Dt1(->maxstack), Dt1(->top), 31-3, Dt1(->top), ~LJ_VMST_C, Dt1(->glref), Dt2(->vmstate));
-  dasm_put(Dst, 133, LJ_TISNUM+1, LJ_TFUNC, LJ_TTAB, Dt1(->base), Dt1(->glref), LJ_TSTR, LJ_TFALSE, LJ_TNIL, ~LJ_VMST_INTERP, GG_G2DISP, DISPATCH_GL(vmstate), LUA_MINSTACK, Dt1(->base), Dt1(->top), 32-3);
-  dasm_put(Dst, 188, Dt1(->base), Dt1(->top), Dt7(->pc), Dt1(->glref), Dt1(->status), FRAME_CP, CFRAME_RESUME, GG_G2DISP, Dt1(->cframe), Dt1(->base), LJ_TISNUM+1, Dt1(->top), LJ_TFUNC, LJ_TTAB, LJ_TSTR, Dt1(->status), FRAME_TYPE, ~LJ_VMST_INTERP, LJ_TNIL, DISPATCH_GL(vmstate));
-  dasm_put(Dst, 279, FRAME_CP, FRAME_C, Dt1(->cframe), Dt1(->cframe), Dt1(->glref), GG_G2DISP, Dt1(->base), LJ_TISNUM+1, Dt1(->top), LJ_TFUNC, LJ_TTAB, LJ_TSTR, ~LJ_VMST_INTERP, LJ_TNIL, DISPATCH_GL(vmstate));
-  dasm_put(Dst, 376, Dt7(->pc), Dt1(->stack), Dt1(->top), Dt1(->cframe), Dt1(->cframe), Dt1(->glref), FRAME_CP, GG_G2DISP, Dt7(->pc), PC2PROTO(k), Dt1(->base));
-  dasm_put(Dst, 481, DISPATCH_GL(tmptv), DISPATCH_GL(tmptv), DISPATCH_GL(tmptv2), DISPATCH_GL(tmptv), Dt1(->base), FRAME_CONT, Dt1(->top), DISPATCH_GL(tmptv));
-  dasm_put(Dst, 556, DISPATCH_GL(tmptv), DISPATCH_GL(tmptv2), DISPATCH_GL(tmptv), Dt1(->base), FRAME_CONT, Dt1(->top), Dt1(->base));
-  dasm_put(Dst, 637, -(BCBIAS_J*4 >> 16), LJ_TTRUE, LJ_TFALSE, Dt1(->base));
-  dasm_put(Dst, 706, Dt1(->base), FRAME_CONT);
+  dasm_put(Dst, 135, LJ_TISNUM+1, LJ_TFUNC, LJ_TTAB, Dt1(->base), Dt1(->glref), LJ_TSTR, LJ_TFALSE, LJ_TNIL, ~LJ_VMST_INTERP, GG_G2DISP, DISPATCH_GL(vmstate), LUA_MINSTACK, Dt1(->base), Dt1(->top), 32-3);
+  dasm_put(Dst, 190, Dt1(->base), Dt1(->top), Dt7(->pc), Dt1(->glref), Dt1(->status), FRAME_CP, CFRAME_RESUME, GG_G2DISP, Dt1(->cframe), Dt1(->base), LJ_TISNUM+1, Dt1(->top), LJ_TFUNC, LJ_TTAB, LJ_TSTR, Dt1(->status), FRAME_TYPE, ~LJ_VMST_INTERP, LJ_TNIL, DISPATCH_GL(vmstate));
+  dasm_put(Dst, 283, FRAME_CP, FRAME_C, Dt1(->cframe), Dt1(->cframe), Dt1(->glref), GG_G2DISP, Dt1(->base), LJ_TISNUM+1, Dt1(->top), LJ_TFUNC, LJ_TTAB, LJ_TSTR, ~LJ_VMST_INTERP, LJ_TNIL, DISPATCH_GL(vmstate));
+  dasm_put(Dst, 384, Dt7(->pc), Dt1(->stack), Dt1(->top), Dt1(->cframe), Dt1(->cframe), Dt1(->glref), FRAME_CP, GG_G2DISP, Dt7(->pc), PC2PROTO(k), Dt1(->base));
+  dasm_put(Dst, 491, DISPATCH_GL(tmptv), DISPATCH_GL(tmptv), DISPATCH_GL(tmptv2), DISPATCH_GL(tmptv), Dt1(->base), FRAME_CONT, Dt1(->top), DISPATCH_GL(tmptv));
+  dasm_put(Dst, 566, DISPATCH_GL(tmptv), DISPATCH_GL(tmptv2), DISPATCH_GL(tmptv), Dt1(->base), FRAME_CONT, Dt1(->top), Dt1(->base));
+  dasm_put(Dst, 647, -(BCBIAS_J*4 >> 16), LJ_TTRUE, LJ_TFALSE, Dt1(->base));
+  dasm_put(Dst, 716, Dt1(->base), FRAME_CONT);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-  dasm_put(Dst, 728);
+  dasm_put(Dst, 739);
 #endif
-  dasm_put(Dst, 730, Dt1(->base));
+  dasm_put(Dst, 741, Dt1(->base));
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-  dasm_put(Dst, 738);
+  dasm_put(Dst, 749);
 #else
-  dasm_put(Dst, 745);
+  dasm_put(Dst, 756);
 #endif
-  dasm_put(Dst, 748, Dt1(->base), Dt7(->pc), Dt1(->base), Dt1(->base));
+  dasm_put(Dst, 759, Dt1(->base), Dt7(->pc), Dt1(->base), Dt1(->base));
 #if LJ_HASJIT
-  dasm_put(Dst, 796);
+  dasm_put(Dst, 807);
 #endif
-  dasm_put(Dst, 798);
+  dasm_put(Dst, 809);
 #if LJ_HASJIT
-  dasm_put(Dst, 800, BC_JFORI);
+  dasm_put(Dst, 811, BC_JFORI);
 #endif
-  dasm_put(Dst, 803);
+  dasm_put(Dst, 814);
 #if LJ_HASJIT
-  dasm_put(Dst, 805, BC_JFORI);
+  dasm_put(Dst, 816, BC_JFORI);
 #endif
-  dasm_put(Dst, 808, BC_FORI, ~LJ_TNUMX, 31-3, Dt8(->upvalue), Dt6(->metatable), DISPATCH_GL(gcroot[GCROOT_MMNAME+MM_metatable]));
-  dasm_put(Dst, 873, Dt6(->hmask), Dt5(->hash), Dt6(->node), 31-5, 31-3, DtB(->key), DtB(->val), DtB(->next), LJ_TUDATA, 31-2, 4*~LJ_TNUMX, DISPATCH_GL(gcroot[GCROOT_BASEMT]));
-  dasm_put(Dst, 929, Dt6(->metatable), Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
-  dasm_put(Dst, 989, DISPATCH_GL(gcroot[GCROOT_BASEMT_NUM]), Dt1(->base), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), Dt1(->top), (2+1)*8);
+  dasm_put(Dst, 819, BC_FORI, ~LJ_TNUMX, 31-3, Dt8(->upvalue), Dt6(->metatable), DISPATCH_GL(gcroot[GCROOT_MMNAME+MM_metatable]));
+  dasm_put(Dst, 884, Dt6(->hmask), Dt5(->hash), Dt6(->node), 31-5, 31-3, DtB(->key), DtB(->val), DtB(->next), LJ_TUDATA, 31-2, 4*~LJ_TNUMX, DISPATCH_GL(gcroot[GCROOT_BASEMT]));
+  dasm_put(Dst, 940, Dt6(->metatable), Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
+  dasm_put(Dst, 1000, DISPATCH_GL(gcroot[GCROOT_BASEMT_NUM]), Dt1(->base), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), Dt1(->top), (2+1)*8);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-  dasm_put(Dst, 1062, Dt6(->metatable), Dt8(->upvalue[0]));
+  dasm_put(Dst, 1073, Dt6(->metatable), Dt8(->upvalue[0]));
 #else
-  dasm_put(Dst, 1071, Dt8(->upvalue[0]));
+  dasm_put(Dst, 1082, Dt8(->upvalue[0]));
 #endif
-  dasm_put(Dst, 1075, (3+1)*8, Dt6(->asize), Dt6(->array), 31-3, (0+1)*8, (2+1)*8, Dt6(->hmask), (0+1)*8, (0+1)*8);
-  dasm_put(Dst, 1139);
+  dasm_put(Dst, 1086, (3+1)*8, Dt6(->asize), Dt6(->array), 31-3, (0+1)*8, (2+1)*8, Dt6(->hmask), (0+1)*8, (0+1)*8);
+  dasm_put(Dst, 1150);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-  dasm_put(Dst, 1152, Dt6(->metatable), Dt8(->upvalue[0]));
+  dasm_put(Dst, 1163, Dt6(->metatable), Dt8(->upvalue[0]));
 #else
-  dasm_put(Dst, 1161, Dt8(->upvalue[0]));
+  dasm_put(Dst, 1172, Dt8(->upvalue[0]));
 #endif
-  dasm_put(Dst, 1165, (3+1)*8, DISPATCH_GL(hookmask), 32-HOOK_ACTIVE_SHIFT, 8+FRAME_PCALL, DISPATCH_GL(hookmask), 32-HOOK_ACTIVE_SHIFT, 16+FRAME_PCALL, LJ_TTHREAD, Dt1(->status), Dt1(->cframe), Dt1(->top));
-  dasm_put(Dst, 1226, LUA_YIELD, Dt1(->base), Dt1(->maxstack), Dt1(->base), Dt1(->top), Dt1(->top), Dt1(->base), LUA_YIELD, Dt1(->top), ~LJ_VMST_INTERP, Dt1(->base), DISPATCH_GL(vmstate), Dt1(->maxstack));
-  dasm_put(Dst, 1289, Dt1(->top), FRAME_TYPE, LJ_TTRUE, FRAME_TYPE, LJ_TFALSE, Dt1(->top), (2+1)*8, 32-3);
-  dasm_put(Dst, 1349, Dt8(->upvalue[0].gcr), Dt1(->status), Dt1(->cframe), Dt1(->top), LUA_YIELD, Dt1(->base), Dt1(->maxstack), Dt1(->base), Dt1(->top), Dt1(->top), Dt1(->base), LUA_YIELD, Dt1(->top), ~LJ_VMST_INTERP);
-  dasm_put(Dst, 1408, Dt1(->base), DISPATCH_GL(vmstate), Dt1(->maxstack), Dt1(->top), FRAME_TYPE, 32-3, Dt1(->cframe));
-  dasm_put(Dst, 1465, Dt1(->base), CFRAME_RESUME, Dt1(->top), LUA_YIELD, Dt1(->cframe), Dt1(->status), (1+1)*8, FRAME_TYPE);
-  dasm_put(Dst, 1530);
-  dasm_put(Dst, 1599);
-  dasm_put(Dst, 1662);
-  dasm_put(Dst, 1727);
-  dasm_put(Dst, 1797, Dt8(->upvalue[0]), DISPATCH_GL(tmptv), DISPATCH_GL(tmptv), (2+1)*8, (2+1)*8);
-  dasm_put(Dst, 1869, Dt5(->len));
-  dasm_put(Dst, 1936, Dt5(->len), (0+1)*8, Dt5([1]), (1+1)*8, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), DISPATCH_GL(tmptv), Dt1(->base), Dt1(->base), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
-  dasm_put(Dst, 1996, Dt5(->len), sizeof(GCstr)-1, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
-  dasm_put(Dst, 2062, Dt5(->len), DISPATCH_GL(tmpbuf.sz), Dt5([1]), DISPATCH_GL(tmpbuf.buf), DISPATCH_GL(strempty), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
-  dasm_put(Dst, 2121, DISPATCH_GL(tmpbuf.sz), Dt5(->len), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), DISPATCH_GL(tmpbuf.sz), Dt5(->len), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf));
-  dasm_put(Dst, 2180, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), DISPATCH_GL(tmpbuf.sz), Dt5(->len), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf));
-  dasm_put(Dst, 2247);
-  dasm_put(Dst, 2318);
-  dasm_put(Dst, 2406, Dt8(->f), 8*LUA_MINSTACK, Dt1(->maxstack), Dt1(->base), Dt1(->top), Dt1(->base), 31-3, Dt1(->top), Dt7(->pc));
-  dasm_put(Dst, 2485, FRAME_TYPE, LUA_MINSTACK, Dt1(->base), Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top));
+  dasm_put(Dst, 1176, (3+1)*8, DISPATCH_GL(hookmask), 32-HOOK_ACTIVE_SHIFT, 8+FRAME_PCALL, DISPATCH_GL(hookmask), 32-HOOK_ACTIVE_SHIFT, 16+FRAME_PCALL, LJ_TTHREAD, Dt1(->status), Dt1(->cframe), Dt1(->top));
+  dasm_put(Dst, 1237, LUA_YIELD, Dt1(->base), Dt1(->maxstack), Dt1(->base), Dt1(->top), Dt1(->top), Dt1(->base), LUA_YIELD, Dt1(->top), ~LJ_VMST_INTERP, Dt1(->base), DISPATCH_GL(vmstate), Dt1(->maxstack));
+  dasm_put(Dst, 1300, Dt1(->top), FRAME_TYPE, LJ_TTRUE, FRAME_TYPE, LJ_TFALSE, Dt1(->top), (2+1)*8, 32-3);
+  dasm_put(Dst, 1360, Dt8(->upvalue[0].gcr), Dt1(->status), Dt1(->cframe), Dt1(->top), LUA_YIELD, Dt1(->base), Dt1(->maxstack), Dt1(->base), Dt1(->top), Dt1(->top), Dt1(->base), LUA_YIELD, Dt1(->top), ~LJ_VMST_INTERP);
+  dasm_put(Dst, 1419, Dt1(->base), DISPATCH_GL(vmstate), Dt1(->maxstack), Dt1(->top), FRAME_TYPE, 32-3, Dt1(->cframe));
+  dasm_put(Dst, 1476, Dt1(->base), CFRAME_RESUME, Dt1(->top), LUA_YIELD, Dt1(->cframe), Dt1(->status), (1+1)*8, FRAME_TYPE);
+  dasm_put(Dst, 1541);
+  dasm_put(Dst, 1610);
+  dasm_put(Dst, 1673);
+  dasm_put(Dst, 1738);
+  dasm_put(Dst, 1808, Dt8(->upvalue[0]), DISPATCH_GL(tmptv), DISPATCH_GL(tmptv), (2+1)*8, (2+1)*8);
+  dasm_put(Dst, 1880, Dt5(->len));
+  dasm_put(Dst, 1947, Dt5(->len), (0+1)*8, Dt5([1]), (1+1)*8, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), DISPATCH_GL(tmptv), Dt1(->base), Dt1(->base), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
+  dasm_put(Dst, 2007, Dt5(->len), sizeof(GCstr)-1, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
+  dasm_put(Dst, 2073, Dt5(->len), DISPATCH_GL(tmpbuf.sz), Dt5([1]), DISPATCH_GL(tmpbuf.buf), DISPATCH_GL(strempty), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
+  dasm_put(Dst, 2132, DISPATCH_GL(tmpbuf.sz), Dt5(->len), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), DISPATCH_GL(tmpbuf.sz), Dt5(->len), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf));
+  dasm_put(Dst, 2191, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), DISPATCH_GL(tmpbuf.sz), Dt5(->len), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf));
+  dasm_put(Dst, 2258);
+  dasm_put(Dst, 2329);
+  dasm_put(Dst, 2417, Dt8(->f), 8*LUA_MINSTACK, Dt1(->maxstack), Dt1(->base), Dt1(->top), Dt1(->base), 31-3, Dt1(->top), Dt7(->pc));
+  dasm_put(Dst, 2496, FRAME_TYPE, LUA_MINSTACK, Dt1(->base), Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top));
 #if LJ_HASJIT
-  dasm_put(Dst, 2527);
+  dasm_put(Dst, 2538);
 #endif
-  dasm_put(Dst, 2529, DISPATCH_GL(hookmask), HOOK_ACTIVE, GG_DISP2STATIC, DISPATCH_GL(hookmask), DISPATCH_GL(hookcount), HOOK_ACTIVE, 31-LUA_HOOKLINE, DISPATCH_GL(hookcount), Dt1(->base), Dt1(->base));
-  dasm_put(Dst, 2576, GG_DISP2STATIC);
+  dasm_put(Dst, 2540, DISPATCH_GL(hookmask), HOOK_ACTIVE, GG_DISP2STATIC, DISPATCH_GL(hookmask), DISPATCH_GL(hookcount), HOOK_ACTIVE, 31-LUA_HOOKLINE, DISPATCH_GL(hookcount), Dt1(->base), Dt1(->base));
+  dasm_put(Dst, 2587, GG_DISP2STATIC);
 #if LJ_HASJIT
-  dasm_put(Dst, 2594);
+  dasm_put(Dst, 2605);
 #endif
-  dasm_put(Dst, 2596);
+  dasm_put(Dst, 2607);
 #if LJ_HASJIT
-  dasm_put(Dst, 2599);
+  dasm_put(Dst, 2610);
 #endif
-  dasm_put(Dst, 2602);
+  dasm_put(Dst, 2613);
 #if LJ_HASJIT
-  dasm_put(Dst, 2604);
+  dasm_put(Dst, 2615);
 #endif
-  dasm_put(Dst, 2607, Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top));
+  dasm_put(Dst, 2618, Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top));
 #if LJ_HASJIT
-  dasm_put(Dst, 2629);
+  dasm_put(Dst, 2640);
 #endif
-  dasm_put(Dst, 2631);
+  dasm_put(Dst, 2642);
 #if LJ_HASJIT
-  dasm_put(Dst, 2633);
+  dasm_put(Dst, 2644);
 #endif
-  dasm_put(Dst, 2635);
+  dasm_put(Dst, 2646);
 #if LJ_HASJIT
-  dasm_put(Dst, 2719);
+  dasm_put(Dst, 2730);
 #else
-  dasm_put(Dst, 2742);
-#endif
-  dasm_put(Dst, 2745);
-#if LJ_HASJIT
-  dasm_put(Dst, 2747);
-#endif
-  dasm_put(Dst, 2749);
-#if LJ_HASJIT
-  dasm_put(Dst, 2751);
-#endif
   dasm_put(Dst, 2753);
+#endif
+  dasm_put(Dst, 2756);
 #if LJ_HASFFI
-  dasm_put(Dst, 2816);
+  dasm_put(Dst, 2819);
 #endif
 }
 
@@ -5481,7 +5472,7 @@ static void build_subroutines(BuildCtx *ctx)
 static void build_ins(BuildCtx *ctx, BCOp op, int defop)
 {
   int vk = 0;
-  dasm_put(Dst, 2818, defop);
+  dasm_put(Dst, 2821, defop);
 
   switch (op) {
 
@@ -5490,118 +5481,118 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
   /* Remember: all ops branch for a true comparison, fall through otherwise. */
 
   case BC_ISLT: case BC_ISGE: case BC_ISLE: case BC_ISGT:
-    dasm_put(Dst, 2820, -(BCBIAS_J*4 >> 16));
+    dasm_put(Dst, 2823, -(BCBIAS_J*4 >> 16));
     if (op == BC_ISLE || op == BC_ISGT) {
-      dasm_put(Dst, 2834);
+      dasm_put(Dst, 2837);
     }
     if (op == BC_ISLT || op == BC_ISLE) {
-      dasm_put(Dst, 2837);
+      dasm_put(Dst, 2840);
     } else {
-      dasm_put(Dst, 2839);
+      dasm_put(Dst, 2842);
     }
-    dasm_put(Dst, 2841);
+    dasm_put(Dst, 2844);
     break;
 
   case BC_ISEQV: case BC_ISNEV:
     vk = op == BC_ISEQV;
-    dasm_put(Dst, 2852, -(BCBIAS_J*4 >> 16));
+    dasm_put(Dst, 2855, -(BCBIAS_J*4 >> 16));
     if (vk) {
-      dasm_put(Dst, 2866);
+      dasm_put(Dst, 2869);
     } else {
-      dasm_put(Dst, 2868);
+      dasm_put(Dst, 2871);
     }
-    dasm_put(Dst, 2870, ~LJ_TISPRI, ~LJ_TISTABUD);
+    dasm_put(Dst, 2873, ~LJ_TISPRI, ~LJ_TISTABUD);
     if (vk) {
-      dasm_put(Dst, 2892);
+      dasm_put(Dst, 2895);
     } else {
-      dasm_put(Dst, 2894);
+      dasm_put(Dst, 2897);
     }
-    dasm_put(Dst, 2896);
+    dasm_put(Dst, 2899);
     if (vk) {
-      dasm_put(Dst, 2898);
+      dasm_put(Dst, 2901);
     } else {
-      dasm_put(Dst, 2900);
+      dasm_put(Dst, 2903);
     }
-    dasm_put(Dst, 2902, Dt6(->metatable), 1-vk, Dt6(->nomm), 1<<MM_eq);
+    dasm_put(Dst, 2905, Dt6(->metatable), 1-vk, Dt6(->nomm), 1<<MM_eq);
     break;
 
   case BC_ISEQS: case BC_ISNES:
     vk = op == BC_ISEQS;
-    dasm_put(Dst, 2923, 32-1, -(BCBIAS_J*4 >> 16));
+    dasm_put(Dst, 2926, 32-1, -(BCBIAS_J*4 >> 16));
     if (vk) {
-      dasm_put(Dst, 2937);
+      dasm_put(Dst, 2940);
     } else {
-      dasm_put(Dst, 2939);
+      dasm_put(Dst, 2942);
     }
-    dasm_put(Dst, 2941);
+    dasm_put(Dst, 2944);
     break;
 
   case BC_ISEQN: case BC_ISNEN:
     vk = op == BC_ISEQN;
-    dasm_put(Dst, 2952, -(BCBIAS_J*4 >> 16));
+    dasm_put(Dst, 2955, -(BCBIAS_J*4 >> 16));
     if (vk) {
-      dasm_put(Dst, 2966);
-    } else {
       dasm_put(Dst, 2969);
+    } else {
+      dasm_put(Dst, 2972);
     }
-    dasm_put(Dst, 2971);
+    dasm_put(Dst, 2974);
     if (!vk) {
-      dasm_put(Dst, 2983);
+      dasm_put(Dst, 2986);
     }
     break;
 
   case BC_ISEQP: case BC_ISNEP:
     vk = op == BC_ISEQP;
-    dasm_put(Dst, 2989, 32-3, -(BCBIAS_J*4 >> 16));
+    dasm_put(Dst, 2992, 32-3, -(BCBIAS_J*4 >> 16));
     if (vk) {
-      dasm_put(Dst, 3001);
+      dasm_put(Dst, 3004);
     } else {
-      dasm_put(Dst, 3003);
+      dasm_put(Dst, 3006);
     }
-    dasm_put(Dst, 3005);
+    dasm_put(Dst, 3008);
     break;
 
   /* -- Unary test and copy ops ------------------------------------------- */
 
   case BC_ISTC: case BC_ISFC: case BC_IST: case BC_ISF:
-    dasm_put(Dst, 3016);
+    dasm_put(Dst, 3019);
     if (op == BC_IST || op == BC_ISF) {
-      dasm_put(Dst, 3022, -(BCBIAS_J*4 >> 16));
+      dasm_put(Dst, 3025, -(BCBIAS_J*4 >> 16));
       if (op == BC_IST) {
-	dasm_put(Dst, 3027);
+	dasm_put(Dst, 3030);
       } else {
-	dasm_put(Dst, 3029);
+	dasm_put(Dst, 3032);
       }
     } else {
       if (op == BC_ISTC) {
-	dasm_put(Dst, 3031);
-      } else {
 	dasm_put(Dst, 3034);
+      } else {
+	dasm_put(Dst, 3037);
       }
-      dasm_put(Dst, 3037, -(BCBIAS_J*4 >> 16));
+      dasm_put(Dst, 3040, -(BCBIAS_J*4 >> 16));
     }
-    dasm_put(Dst, 3044);
+    dasm_put(Dst, 3047);
     break;
 
   /* -- Unary ops --------------------------------------------------------- */
 
   case BC_MOV:
-    dasm_put(Dst, 3055);
+    dasm_put(Dst, 3058);
     break;
   case BC_NOT:
-    dasm_put(Dst, 3068, LJ_TTRUE);
+    dasm_put(Dst, 3071, LJ_TTRUE);
     break;
   case BC_UNM:
-    dasm_put(Dst, 3084);
+    dasm_put(Dst, 3087);
     break;
   case BC_LEN:
-    dasm_put(Dst, 3101, Dt5(->len));
+    dasm_put(Dst, 3104, Dt5(->len));
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-    dasm_put(Dst, 3125, Dt6(->metatable));
+    dasm_put(Dst, 3128, Dt6(->metatable));
 #endif
-    dasm_put(Dst, 3132);
+    dasm_put(Dst, 3135);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-    dasm_put(Dst, 3138, Dt6(->nomm), 1<<MM_len);
+    dasm_put(Dst, 3141, Dt6(->nomm), 1<<MM_len);
 #endif
     break;
 
@@ -5612,262 +5603,262 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 3148);
+    dasm_put(Dst, 3151);
       break;
     case 1:
-    dasm_put(Dst, 3154);
+    dasm_put(Dst, 3157);
       break;
     default:
-    dasm_put(Dst, 3160);
+    dasm_put(Dst, 3163);
       break;
     }
-    dasm_put(Dst, 3167);
+    dasm_put(Dst, 3170);
     break;
   case BC_SUBVN: case BC_SUBNV: case BC_SUBVV:
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 3180);
+    dasm_put(Dst, 3183);
       break;
     case 1:
-    dasm_put(Dst, 3186);
+    dasm_put(Dst, 3189);
       break;
     default:
-    dasm_put(Dst, 3192);
+    dasm_put(Dst, 3195);
       break;
     }
-    dasm_put(Dst, 3199);
+    dasm_put(Dst, 3202);
     break;
   case BC_MULVN: case BC_MULNV: case BC_MULVV:
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 3212);
+    dasm_put(Dst, 3215);
       break;
     case 1:
-    dasm_put(Dst, 3218);
+    dasm_put(Dst, 3221);
       break;
     default:
-    dasm_put(Dst, 3224);
+    dasm_put(Dst, 3227);
       break;
     }
-    dasm_put(Dst, 3231);
+    dasm_put(Dst, 3234);
     break;
   case BC_DIVVN: case BC_DIVNV: case BC_DIVVV:
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 3244);
+    dasm_put(Dst, 3247);
       break;
     case 1:
-    dasm_put(Dst, 3250);
+    dasm_put(Dst, 3253);
       break;
     default:
-    dasm_put(Dst, 3256);
+    dasm_put(Dst, 3259);
       break;
     }
-    dasm_put(Dst, 3263);
+    dasm_put(Dst, 3266);
     break;
   case BC_MODVN:
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 3276);
+    dasm_put(Dst, 3279);
       break;
     case 1:
-    dasm_put(Dst, 3282);
+    dasm_put(Dst, 3285);
       break;
     default:
-    dasm_put(Dst, 3288);
+    dasm_put(Dst, 3291);
       break;
     }
-    dasm_put(Dst, 3295);
+    dasm_put(Dst, 3298);
     break;
   case BC_MODNV: case BC_MODVV:
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 3313);
+    dasm_put(Dst, 3316);
       break;
     case 1:
-    dasm_put(Dst, 3319);
+    dasm_put(Dst, 3322);
       break;
     default:
-    dasm_put(Dst, 3325);
+    dasm_put(Dst, 3328);
       break;
     }
-    dasm_put(Dst, 3332);
+    dasm_put(Dst, 3335);
     break;
   case BC_POW:
-    dasm_put(Dst, 3335);
+    dasm_put(Dst, 3338);
     break;
 
   case BC_CAT:
-    dasm_put(Dst, 3357, Dt1(->base), 32-3, Dt1(->base));
+    dasm_put(Dst, 3360, Dt1(->base), 32-3, Dt1(->base));
     break;
 
   /* -- Constant ops ------------------------------------------------------ */
 
   case BC_KSTR:
-    dasm_put(Dst, 3387, 32-1);
+    dasm_put(Dst, 3390, 32-1);
     break;
   case BC_KCDATA:
 #if LJ_HASFFI
-    dasm_put(Dst, 3404, 32-1, LJ_TCDATA);
+    dasm_put(Dst, 3407, 32-1, LJ_TCDATA);
 #endif
     break;
   case BC_KSHORT:
-    dasm_put(Dst, 3423, 32-3);
+    dasm_put(Dst, 3426, 32-3);
     break;
   case BC_KNUM:
-    dasm_put(Dst, 3439);
+    dasm_put(Dst, 3442);
     break;
   case BC_KPRI:
-    dasm_put(Dst, 3452, 32-3);
+    dasm_put(Dst, 3455, 32-3);
     break;
   case BC_KNIL:
-    dasm_put(Dst, 3467);
+    dasm_put(Dst, 3470);
     break;
 
   /* -- Upvalue and function ops ------------------------------------------ */
 
   case BC_UGET:
-    dasm_put(Dst, 3486, 32-1, offsetof(GCfuncL, uvptr), DtA(->v));
+    dasm_put(Dst, 3489, 32-1, offsetof(GCfuncL, uvptr), DtA(->v));
     break;
   case BC_USETV:
-    dasm_put(Dst, 3507, 32-1, offsetof(GCfuncL, uvptr), DtA(->marked), DtA(->v), LJ_GC_BLACK, DtA(->closed), -(LJ_TISNUM+1), LJ_TISGCV - (LJ_TISNUM+1), Dt4(->gch.marked), LJ_GC_WHITES, GG_DISP2G);
+    dasm_put(Dst, 3510, 32-1, offsetof(GCfuncL, uvptr), DtA(->marked), DtA(->v), LJ_GC_BLACK, DtA(->closed), -(LJ_TISNUM+1), LJ_TISGCV - (LJ_TISNUM+1), Dt4(->gch.marked), LJ_GC_WHITES, GG_DISP2G);
     break;
   case BC_USETS:
-    dasm_put(Dst, 3559, 32-1, 32-1, offsetof(GCfuncL, uvptr), DtA(->marked), DtA(->v), LJ_GC_BLACK, Dt5(->marked), DtA(->closed), LJ_GC_WHITES, GG_DISP2G);
+    dasm_put(Dst, 3562, 32-1, 32-1, offsetof(GCfuncL, uvptr), DtA(->marked), DtA(->v), LJ_GC_BLACK, Dt5(->marked), DtA(->closed), LJ_GC_WHITES, GG_DISP2G);
     break;
   case BC_USETN:
-    dasm_put(Dst, 3608, 32-1, offsetof(GCfuncL, uvptr), DtA(->v));
+    dasm_put(Dst, 3611, 32-1, offsetof(GCfuncL, uvptr), DtA(->v));
     break;
   case BC_USETP:
-    dasm_put(Dst, 3629, 32-1, offsetof(GCfuncL, uvptr), 32-3, DtA(->v));
+    dasm_put(Dst, 3632, 32-1, offsetof(GCfuncL, uvptr), 32-3, DtA(->v));
     break;
 
   case BC_UCLO:
-    dasm_put(Dst, 3652, Dt1(->openupval), 32-1, -(BCBIAS_J*4 >> 16), Dt1(->base), Dt1(->base));
+    dasm_put(Dst, 3655, Dt1(->openupval), 32-1, -(BCBIAS_J*4 >> 16), Dt1(->base), Dt1(->base));
     break;
 
   case BC_FNEW:
-    dasm_put(Dst, 3682, 32-1, Dt1(->base), Dt1(->base));
+    dasm_put(Dst, 3685, 32-1, Dt1(->base), Dt1(->base));
     break;
 
   /* -- Table ops --------------------------------------------------------- */
 
   case BC_TNEW:
   case BC_TDUP:
-    dasm_put(Dst, 3708, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base));
+    dasm_put(Dst, 3711, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base));
     if (op == BC_TNEW) {
-      dasm_put(Dst, 3721);
+      dasm_put(Dst, 3724);
     } else {
-      dasm_put(Dst, 3729, 32-1);
+      dasm_put(Dst, 3732, 32-1);
     }
-    dasm_put(Dst, 3736, Dt1(->base));
+    dasm_put(Dst, 3739, Dt1(->base));
     break;
 
   case BC_GGET:
   case BC_GSET:
-    dasm_put(Dst, 3759, 32-1, Dt7(->env));
+    dasm_put(Dst, 3762, 32-1, Dt7(->env));
     if (op == BC_GGET) {
-      dasm_put(Dst, 3767);
-    } else {
       dasm_put(Dst, 3770);
+    } else {
+      dasm_put(Dst, 3773);
     }
     break;
 
   case BC_TGETV:
-    dasm_put(Dst, 3773, Dt6(->asize), Dt6(->array), 31-3, Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
+    dasm_put(Dst, 3776, Dt6(->asize), Dt6(->array), 31-3, Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
     break;
   case BC_TGETS:
-    dasm_put(Dst, 3831, 32-1, Dt6(->hmask), Dt5(->hash), Dt6(->node), 31-5, 31-3, DtB(->key), DtB(->val), DtB(->next), Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
-    dasm_put(Dst, 3895);
+    dasm_put(Dst, 3834, 32-1, Dt6(->hmask), Dt5(->hash), Dt6(->node), 31-5, 31-3, DtB(->key), DtB(->val), DtB(->next), Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
+    dasm_put(Dst, 3898);
     break;
   case BC_TGETB:
-    dasm_put(Dst, 3900, 32-3, Dt6(->asize), Dt6(->array), Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
+    dasm_put(Dst, 3903, 32-3, Dt6(->asize), Dt6(->array), Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
     break;
 
   case BC_TSETV:
-    dasm_put(Dst, 3944, Dt6(->asize), Dt6(->array), 31-3, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex);
-    dasm_put(Dst, 4011, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
+    dasm_put(Dst, 3947, Dt6(->asize), Dt6(->array), 31-3, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex);
+    dasm_put(Dst, 4014, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
     break;
   case BC_TSETS:
-    dasm_put(Dst, 4023, 32-1, Dt6(->hmask), Dt5(->hash), Dt6(->node), Dt6(->nomm), 31-5, 31-3, Dt6(->marked), DtB(->key), DtB(->val), LJ_GC_BLACK, DtB(->val), Dt6(->metatable));
-    dasm_put(Dst, 4084, Dt6(->nomm), 1<<MM_newindex, DtB(->next), Dt6(->metatable), DISPATCH_GL(tmptv), Dt1(->base), Dt6(->nomm), 1<<MM_newindex, Dt1(->base), DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain));
-    dasm_put(Dst, 4135, Dt6(->marked), Dt6(->gclist));
+    dasm_put(Dst, 4026, 32-1, Dt6(->hmask), Dt5(->hash), Dt6(->node), Dt6(->nomm), 31-5, 31-3, Dt6(->marked), DtB(->key), DtB(->val), LJ_GC_BLACK, DtB(->val), Dt6(->metatable));
+    dasm_put(Dst, 4087, Dt6(->nomm), 1<<MM_newindex, DtB(->next), Dt6(->metatable), DISPATCH_GL(tmptv), Dt1(->base), Dt6(->nomm), 1<<MM_newindex, Dt1(->base), DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain));
+    dasm_put(Dst, 4138, Dt6(->marked), Dt6(->gclist));
     break;
   case BC_TSETB:
-    dasm_put(Dst, 4142, 32-3, Dt6(->asize), Dt6(->array), Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->marked));
-    dasm_put(Dst, 4202, Dt6(->gclist));
+    dasm_put(Dst, 4145, 32-3, Dt6(->asize), Dt6(->array), Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->marked));
+    dasm_put(Dst, 4205, Dt6(->gclist));
     break;
 
   case BC_TSETM:
-    dasm_put(Dst, 4207, 32-3, Dt6(->asize), 31-3, Dt6(->marked), Dt6(->array), LJ_GC_BLACK, Dt1(->base), DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
-    dasm_put(Dst, 4276);
+    dasm_put(Dst, 4210, 32-3, Dt6(->asize), 31-3, Dt6(->marked), Dt6(->array), LJ_GC_BLACK, Dt1(->base), DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->marked), Dt6(->gclist));
+    dasm_put(Dst, 4279);
     break;
 
   /* -- Calls and vararg handling ----------------------------------------- */
 
   case BC_CALLM:
-    dasm_put(Dst, 4279);
+    dasm_put(Dst, 4282);
     break;
   case BC_CALL:
-    dasm_put(Dst, 4281, Dt7(->pc));
+    dasm_put(Dst, 4284, Dt7(->pc));
     break;
 
   case BC_CALLMT:
-    dasm_put(Dst, 4301);
+    dasm_put(Dst, 4304);
     break;
   case BC_CALLT:
-    dasm_put(Dst, 4303, FRAME_TYPE, Dt7(->ffid), FRAME_VARG, Dt7(->pc), -4-8, Dt7(->pc), PC2PROTO(k), FRAME_TYPEP);
-    dasm_put(Dst, 4368, FRAME_TYPE);
+    dasm_put(Dst, 4306, FRAME_TYPE, Dt7(->ffid), FRAME_VARG, Dt7(->pc), -4-8, Dt7(->pc), PC2PROTO(k), FRAME_TYPEP);
+    dasm_put(Dst, 4371, FRAME_TYPE);
     break;
 
   case BC_ITERC:
-    dasm_put(Dst, 4375, Dt7(->pc));
+    dasm_put(Dst, 4378, Dt7(->pc));
     break;
 
   case BC_ITERN:
 #if LJ_HASJIT
 #endif
-    dasm_put(Dst, 4401, Dt6(->asize), Dt6(->array), 31-3, -(BCBIAS_J*4 >> 16), Dt6(->hmask), Dt6(->node), 31-5, 31-3, DtB(->key), -(BCBIAS_J*4 >> 16));
-    dasm_put(Dst, 4480);
+    dasm_put(Dst, 4404, Dt6(->asize), Dt6(->array), 31-3, -(BCBIAS_J*4 >> 16), Dt6(->hmask), Dt6(->node), 31-5, 31-3, DtB(->key), -(BCBIAS_J*4 >> 16));
+    dasm_put(Dst, 4483);
     break;
 
   case BC_ISNEXT:
-    dasm_put(Dst, 4484, LJ_TTAB, LJ_TFUNC, LJ_TNIL, Dt8(->ffid), FF_next_N, 32-1, -(BCBIAS_J*4 >> 16), BC_JMP, BC_ITERC, -(BCBIAS_J*4 >> 16));
+    dasm_put(Dst, 4487, LJ_TTAB, LJ_TFUNC, LJ_TNIL, Dt8(->ffid), FF_next_N, 32-1, -(BCBIAS_J*4 >> 16), BC_JMP, BC_ITERC, -(BCBIAS_J*4 >> 16));
     break;
 
   case BC_VARG:
-    dasm_put(Dst, 4535, FRAME_VARG, Dt1(->maxstack), Dt1(->top), Dt1(->base), 32-3, Dt1(->base));
-    dasm_put(Dst, 4615);
+    dasm_put(Dst, 4538, FRAME_VARG, Dt1(->maxstack), Dt1(->top), Dt1(->base), 32-3, Dt1(->base));
+    dasm_put(Dst, 4618);
     break;
 
   /* -- Returns ----------------------------------------------------------- */
 
   case BC_RETM:
-    dasm_put(Dst, 4621);
+    dasm_put(Dst, 4624);
     break;
 
   case BC_RET:
-    dasm_put(Dst, 4623, FRAME_TYPE, FRAME_VARG, Dt7(->pc), PC2PROTO(k), FRAME_TYPEP);
+    dasm_put(Dst, 4626, FRAME_TYPE, FRAME_VARG, Dt7(->pc), PC2PROTO(k), FRAME_TYPEP);
     break;
 
   case BC_RET0: case BC_RET1:
-    dasm_put(Dst, 4693, FRAME_TYPE, FRAME_VARG);
+    dasm_put(Dst, 4696, FRAME_TYPE, FRAME_VARG);
     if (op == BC_RET1) {
-      dasm_put(Dst, 4706);
+      dasm_put(Dst, 4709);
     }
-    dasm_put(Dst, 4709, Dt7(->pc), PC2PROTO(k));
+    dasm_put(Dst, 4712, Dt7(->pc), PC2PROTO(k));
     break;
 
   /* -- Loops and branches ------------------------------------------------ */
 
   case BC_FORL:
 #if LJ_HASJIT
-    dasm_put(Dst, 4737);
+    dasm_put(Dst, 4740);
 #endif
     break;
 
@@ -5879,35 +5870,35 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
   case BC_FORI:
   case BC_IFORL:
     vk = (op == BC_IFORL || op == BC_JFORL);
-    dasm_put(Dst, 4739, FORL_IDX*8, FORL_STEP*8, FORL_STOP*8);
+    dasm_put(Dst, 4742, FORL_IDX*8, FORL_STEP*8, FORL_STOP*8);
     if (!vk) {
-      dasm_put(Dst, 4747);
+      dasm_put(Dst, 4750);
     }
     if (vk) {
-      dasm_put(Dst, 4755, FORL_IDX*8);
+      dasm_put(Dst, 4758, FORL_IDX*8);
     }
-    dasm_put(Dst, 4759, FORL_EXT*8);
+    dasm_put(Dst, 4762, FORL_EXT*8);
     if (op != BC_JFORL) {
-      dasm_put(Dst, 4767, 32-1);
+      dasm_put(Dst, 4770, 32-1);
       if (op == BC_JFORI) {
-	dasm_put(Dst, 4771, -(BCBIAS_J*4 >> 16));
-      } else {
 	dasm_put(Dst, 4774, -(BCBIAS_J*4 >> 16));
+      } else {
+	dasm_put(Dst, 4777, -(BCBIAS_J*4 >> 16));
       }
     }
     if (op == BC_FORI) {
-      dasm_put(Dst, 4777);
+      dasm_put(Dst, 4780);
     } else if (op == BC_IFORL) {
-      dasm_put(Dst, 4779);
+      dasm_put(Dst, 4782);
     } else {
-      dasm_put(Dst, 4781, BC_JLOOP);
+      dasm_put(Dst, 4784, BC_JLOOP);
     }
-    dasm_put(Dst, 4784);
+    dasm_put(Dst, 4787);
     break;
 
   case BC_ITERL:
 #if LJ_HASJIT
-    dasm_put(Dst, 4799);
+    dasm_put(Dst, 4802);
 #endif
     break;
 
@@ -5916,40 +5907,40 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     break;
 #endif
   case BC_IITERL:
-    dasm_put(Dst, 4801);
+    dasm_put(Dst, 4804);
     if (op == BC_JITERL) {
-      dasm_put(Dst, 4807);
+      dasm_put(Dst, 4810);
     } else {
-      dasm_put(Dst, 4809, 32-1, -(BCBIAS_J*4 >> 16));
+      dasm_put(Dst, 4812, 32-1, -(BCBIAS_J*4 >> 16));
     }
-    dasm_put(Dst, 4816);
+    dasm_put(Dst, 4819);
     break;
 
   case BC_LOOP:
 #if LJ_HASJIT
-    dasm_put(Dst, 4828);
+    dasm_put(Dst, 4831);
 #endif
     break;
 
   case BC_ILOOP:
-    dasm_put(Dst, 4830);
+    dasm_put(Dst, 4833);
     break;
 
   case BC_JLOOP:
 #if LJ_HASJIT
-    dasm_put(Dst, 4841);
+    dasm_put(Dst, 4844);
 #endif
     break;
 
   case BC_JMP:
-    dasm_put(Dst, 4843, 32-1, -(BCBIAS_J*4 >> 16));
+    dasm_put(Dst, 4846, 32-1, -(BCBIAS_J*4 >> 16));
     break;
 
   /* -- Function headers -------------------------------------------------- */
 
   case BC_FUNCF:
 #if LJ_HASJIT
-    dasm_put(Dst, 4859);
+    dasm_put(Dst, 4862);
 #endif
   case BC_FUNCV:  /* NYI: compiled vararg functions. */
     break;
@@ -5959,38 +5950,38 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop)
     break;
 #endif
   case BC_IFUNCF:
-    dasm_put(Dst, 4861, Dt1(->maxstack), -4+PC2PROTO(numparams), -4+PC2PROTO(k), 31-3);
+    dasm_put(Dst, 4864, Dt1(->maxstack), -4+PC2PROTO(numparams), -4+PC2PROTO(k), 31-3);
     if (op == BC_JFUNCF) {
-      dasm_put(Dst, 4879);
+      dasm_put(Dst, 4882);
     } else {
-      dasm_put(Dst, 4881);
+      dasm_put(Dst, 4884);
     }
-    dasm_put(Dst, 4890);
+    dasm_put(Dst, 4893);
     break;
 
   case BC_JFUNCV:
 #if !LJ_HASJIT
     break;
 #endif
-    dasm_put(Dst, 4896);
+    dasm_put(Dst, 4899);
     break;  /* NYI: compiled vararg functions. */
 
   case BC_IFUNCV:
-    dasm_put(Dst, 4898, Dt1(->maxstack), 8+FRAME_VARG, -4+PC2PROTO(k), -4+PC2PROTO(numparams));
+    dasm_put(Dst, 4901, Dt1(->maxstack), 8+FRAME_VARG, -4+PC2PROTO(k), -4+PC2PROTO(numparams));
     break;
 
   case BC_FUNCC:
   case BC_FUNCCW:
     if (op == BC_FUNCC) {
-      dasm_put(Dst, 4948, Dt8(->f));
+      dasm_put(Dst, 4951, Dt8(->f));
     } else {
-      dasm_put(Dst, 4951, DISPATCH_GL(wrapf));
+      dasm_put(Dst, 4954, DISPATCH_GL(wrapf));
     }
-    dasm_put(Dst, 4954, Dt1(->maxstack), Dt1(->base), Dt1(->top), ~LJ_VMST_C);
+    dasm_put(Dst, 4957, Dt1(->maxstack), Dt1(->base), Dt1(->top), ~LJ_VMST_C);
     if (op == BC_FUNCCW) {
-      dasm_put(Dst, 4967, Dt8(->f));
+      dasm_put(Dst, 4970, Dt8(->f));
     }
-    dasm_put(Dst, 4970, DISPATCH_GL(vmstate), Dt1(->top), 31-3, Dt1(->base), ~LJ_VMST_INTERP, DISPATCH_GL(vmstate));
+    dasm_put(Dst, 4973, DISPATCH_GL(vmstate), Dt1(->top), 31-3, Dt1(->base), ~LJ_VMST_INTERP, DISPATCH_GL(vmstate));
     break;
 
   /* ---------------------------------------------------------------------- */
@@ -6010,7 +6001,7 @@ static int build_backend(BuildCtx *ctx)
 
   build_subroutines(ctx);
 
-  dasm_put(Dst, 4991);
+  dasm_put(Dst, 4994);
   for (op = 0; op < BC__MAX; op++)
     build_ins(ctx, (BCOp)op, op);
 
@@ -6045,17 +6036,14 @@ static void emit_asm_debug(BuildCtx *ctx)
 	"\t.long .Lbegin\n"
 	"\t.long %d\n"
 	"\t.byte 0xe\n\t.uleb128 %d\n"
-	"\t.byte 0x11\n\t.uleb128 65\n\t.sleb128 -1\n",
+	"\t.byte 0x11\n\t.uleb128 65\n\t.sleb128 -1\n"
+	"\t.byte 0x5\n\t.uleb128 70\n\t.sleb128 37\n",
 	(int)ctx->codesz, CFRAME_SIZE);
     for (i = 14; i <= 31; i++)
-#if LJ_TARGET_PPCSPE
       fprintf(ctx->fp,
 	"\t.byte %d\n\t.uleb128 %d\n"
 	"\t.byte 5\n\t.uleb128 %d\n\t.uleb128 %d\n",
 	0x80+i, 1+2*(31-i), 1200+i, 2+2*(31-i));
-#else
-#error "missing frame info for saved registers"
-#endif
     fprintf(ctx->fp,
 	"\t.align 2\n"
 	".LEFDE0:\n\n");
@@ -6086,17 +6074,14 @@ static void emit_asm_debug(BuildCtx *ctx)
 	"\t.long %d\n"
 	"\t.uleb128 0\n"			/* augmentation length */
 	"\t.byte 0xe\n\t.uleb128 %d\n"
-	"\t.byte 0x11\n\t.uleb128 65\n\t.sleb128 -1\n",
+	"\t.byte 0x11\n\t.uleb128 65\n\t.sleb128 -1\n"
+	"\t.byte 0x5\n\t.uleb128 70\n\t.sleb128 37\n",
 	(int)ctx->codesz, CFRAME_SIZE);
     for (i = 14; i <= 31; i++)
-#if LJ_TARGET_PPCSPE
       fprintf(ctx->fp,
 	"\t.byte %d\n\t.uleb128 %d\n"
 	"\t.byte 5\n\t.uleb128 %d\n\t.uleb128 %d\n",
 	0x80+i, 1+2*(31-i), 1200+i, 2+2*(31-i));
-#else
-#error "missing frame info for saved registers"
-#endif
     fprintf(ctx->fp,
 	"\t.align 2\n"
 	".LEFDE1:\n\n");
diff --git a/third_party/luajit/src/buildvm_x64.h b/third_party/luajit/src/buildvm_x64.h
index f6ed666c73d6ed6b5d769d4aacaa1258cddc9ba0..55b22b2e842e6fc5758a412c79e8ac94cc497325 100644
--- a/third_party/luajit/src/buildvm_x64.h
+++ b/third_party/luajit/src/buildvm_x64.h
@@ -12,7 +12,7 @@
 #define DASM_SECTION_CODE_OP	0
 #define DASM_SECTION_CODE_SUB	1
 #define DASM_MAXSECTION		2
-static const unsigned char build_actionlist[16156] = {
+static const unsigned char build_actionlist[16378] = {
   254,1,248,10,252,247,195,237,15,132,244,11,131,227,252,248,41,218,72,141,
   76,25,252,248,139,90,252,252,199,68,10,4,237,248,12,131,192,1,137,68,36,4,
   252,247,195,237,15,132,244,13,248,14,129,252,243,239,252,247,195,237,15,133,
@@ -52,426 +52,427 @@ static const unsigned char build_actionlist[16156] = {
   68,137,124,36,16,76,139,189,233,76,137,124,36,32,72,137,165,233,252,255,209,
   133,192,15,132,244,15,137,193,187,237,252,233,244,2,248,11,1,209,131,227,
   252,248,137,213,41,218,199,68,193,252,252,237,137,200,139,93,252,244,72,99,
-  77,252,240,133,201,15,132,244,247,255,76,141,61,245,76,1,252,249,68,139,122,
-  252,248,69,139,191,233,69,139,191,233,252,255,225,248,1,41,213,193,252,237,
-  3,141,69,252,255,252,233,244,32,248,33,15,182,75,252,255,131,252,237,16,141,
-  12,202,41,252,233,15,132,244,34,252,247,217,193,252,233,3,139,124,36,24,137,
-  151,233,137,202,72,139,8,72,137,77,0,137,252,238,252,233,244,35,248,36,137,
-  4,36,199,68,36,4,237,72,141,4,36,128,123,252,252,235,15,133,244,247,65,141,
-  142,233,137,41,199,65,4,237,255,137,205,252,233,244,248,248,37,15,182,67,
-  252,254,255,199,68,36,4,237,137,4,36,255,252,242,15,42,192,252,242,15,17,
-  4,36,255,72,141,4,36,252,233,244,247,248,38,15,182,67,252,254,141,4,194,248,
-  1,15,182,107,252,255,141,44,252,234,248,2,139,124,36,24,137,151,233,137,252,
-  238,72,137,194,137,252,253,137,92,36,28,232,251,1,2,139,149,233,133,192,15,
-  132,244,249,248,34,15,182,75,252,253,72,139,40,72,137,44,202,139,3,15,182,
-  204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,248,3,139,141,233,
-  137,89,252,244,141,153,233,41,211,139,105,252,248,184,237,252,233,244,30,
-  248,39,137,4,36,199,68,36,4,237,72,141,4,36,128,123,252,252,235,15,133,244,
-  247,255,65,141,142,233,137,41,199,65,4,237,137,205,252,233,244,248,248,40,
-  15,182,67,252,254,255,72,141,4,36,252,233,244,247,248,41,15,182,67,252,254,
-  141,4,194,248,1,15,182,107,252,255,141,44,252,234,248,2,139,124,36,24,137,
-  151,233,137,252,238,72,137,194,137,252,253,137,92,36,28,232,251,1,3,139,149,
-  233,133,192,15,132,244,249,15,182,75,252,253,72,139,44,202,72,137,40,248,
-  42,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,
-  248,3,139,141,233,137,89,252,244,15,182,67,252,253,72,139,44,194,72,137,105,
-  16,141,153,233,41,211,139,105,252,248,184,237,252,233,244,30,248,43,139,108,
-  36,24,137,149,233,141,52,202,141,20,194,137,252,239,15,182,75,252,252,137,
-  92,36,28,232,251,1,4,248,3,139,149,233,255,131,252,248,1,15,135,244,44,248,
-  4,141,91,4,15,130,244,252,248,5,15,183,67,252,254,141,156,253,131,233,248,
-  6,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,
-  248,45,131,195,4,129,120,253,4,239,15,130,244,5,252,233,244,6,248,46,129,
-  120,253,4,239,252,233,244,4,248,47,131,252,235,4,137,206,137,252,233,139,
-  108,36,24,137,149,233,255,137,194,137,252,239,137,92,36,28,232,251,1,5,252,
-  233,244,3,248,48,255,131,252,235,4,139,108,36,24,137,149,233,137,252,239,
-  139,115,252,252,137,92,36,28,232,251,1,6,252,233,244,3,255,248,49,255,15,
-  182,107,252,255,255,248,50,65,141,4,199,252,233,244,247,248,51,255,248,52,
-  65,141,4,199,141,44,252,234,149,252,233,244,248,248,53,141,4,194,137,197,
-  252,233,244,248,248,54,255,248,55,141,4,194,248,1,141,44,252,234,248,2,141,
-  12,202,68,15,182,67,252,252,137,206,137,193,139,124,36,24,137,151,233,137,
-  252,234,137,252,253,137,92,36,28,232,251,1,7,139,149,233,133,192,15,132,244,
-  42,248,44,137,193,41,208,137,89,252,244,141,152,233,184,237,252,233,244,28,
-  248,56,139,108,36,24,137,149,233,141,52,194,137,252,239,137,92,36,28,232,
-  251,1,8,139,149,233,255,133,192,15,133,244,44,15,183,67,252,254,139,60,194,
-  252,233,244,57,255,252,233,244,44,255,248,58,141,76,202,8,248,29,137,76,36,
-  4,137,4,36,131,252,233,8,139,108,36,24,137,149,233,137,206,141,20,193,137,
-  252,239,137,92,36,28,232,251,1,9,139,149,233,139,76,36,4,139,4,36,139,105,
-  252,248,131,192,1,65,57,215,15,132,244,59,137,202,137,90,252,252,139,157,
-  233,139,11,15,182,252,233,15,182,205,131,195,4,65,252,255,36,252,238,248,
-  60,139,108,36,24,137,149,233,137,206,137,252,239,137,92,36,28,232,251,1,10,
-  139,149,233,139,67,252,252,15,182,204,15,182,232,193,232,16,65,252,255,164,
-  253,252,238,233,248,61,129,252,248,239,15,130,244,62,139,106,4,129,252,253,
-  239,15,131,244,62,139,90,252,252,137,68,36,4,137,106,252,252,139,42,137,106,
-  252,248,131,232,2,15,132,244,248,255,137,209,248,1,131,193,8,72,139,41,72,
-  137,105,252,248,131,232,1,15,133,244,1,248,2,139,68,36,4,252,233,244,63,248,
-  64,129,252,248,239,15,130,244,62,139,106,4,137,252,233,193,252,249,15,131,
-  252,249,252,254,15,132,244,249,184,237,252,247,213,57,232,255,15,71,197,255,
-  15,134,244,247,137,232,248,1,255,248,2,139,106,252,248,139,132,253,197,233,
-  139,90,252,252,199,66,252,252,237,137,66,252,248,252,233,244,65,248,3,184,
-  237,252,233,244,2,248,66,129,252,248,239,15,130,244,62,139,106,4,139,90,252,
-  252,129,252,253,239,15,133,244,252,248,1,139,42,139,173,233,248,2,133,252,
-  237,199,66,252,252,237,255,15,132,244,65,65,139,134,233,199,66,252,252,237,
-  137,106,252,248,139,141,233,35,136,233,105,201,239,3,141,233,248,3,129,185,
-  233,239,15,133,244,250,57,129,233,15,132,244,251,248,4,139,137,233,133,201,
-  15,133,244,3,255,252,233,244,65,248,5,139,105,4,129,252,253,239,15,132,244,
-  65,139,1,137,106,252,252,137,66,252,248,252,233,244,65,248,6,129,252,253,
-  239,15,132,244,1,129,252,253,239,15,135,244,254,129,252,253,239,15,134,244,
-  253,189,237,252,233,244,254,248,7,255,189,237,248,8,252,247,213,65,139,172,
-  253,174,233,252,233,244,2,248,67,129,252,248,239,15,130,244,62,129,122,253,
-  4,239,15,133,244,62,139,42,131,189,233,0,15,133,244,62,129,122,253,12,239,
-  15,133,244,62,139,66,8,137,133,233,139,90,252,252,199,66,252,252,237,255,
-  137,106,252,248,252,246,133,233,235,15,132,244,247,128,165,233,235,65,139,
-  134,233,65,137,174,233,137,133,233,248,1,252,233,244,65,248,68,129,252,248,
-  239,15,130,244,62,129,122,253,4,239,15,133,244,62,137,213,139,50,141,82,8,
-  139,124,36,24,232,251,1,11,137,252,234,72,139,40,139,90,252,252,72,137,106,
-  252,248,252,233,244,65,248,69,255,129,252,248,239,15,133,244,62,129,122,253,
-  4,239,255,15,133,244,247,139,42,252,233,244,70,248,1,15,135,244,62,255,15,
-  131,244,62,255,252,242,15,16,2,252,233,244,71,255,221,2,252,233,244,72,255,
-  248,73,129,252,248,239,15,130,244,62,139,90,252,252,129,122,253,4,239,15,
-  133,244,249,139,2,248,2,199,66,252,252,237,137,66,252,248,252,233,244,65,
-  248,3,129,122,253,4,239,15,135,244,62,65,131,190,233,0,15,133,244,62,65,139,
-  174,233,65,59,174,233,255,15,130,244,247,232,244,74,248,1,139,108,36,24,137,
-  149,233,137,92,36,28,137,214,137,252,239,255,232,251,1,12,255,232,251,1,13,
-  255,139,149,233,252,233,244,2,248,75,129,252,248,239,15,130,244,62,15,132,
-  244,248,248,1,129,122,253,4,239,15,133,244,62,139,108,36,24,137,149,233,137,
-  149,233,139,90,252,252,139,50,141,82,8,137,252,239,137,92,36,28,232,251,1,
-  14,139,149,233,133,192,15,132,244,249,72,139,106,8,72,139,66,16,72,137,106,
-  252,248,72,137,2,248,76,184,237,255,252,233,244,77,248,2,199,66,12,237,252,
-  233,244,1,248,3,199,66,252,252,237,252,233,244,65,248,78,129,252,248,239,
-  15,130,244,62,139,42,129,122,253,4,239,15,133,244,62,255,131,189,233,0,15,
-  133,244,62,255,139,106,252,248,139,133,233,139,90,252,252,199,66,252,252,
-  237,137,66,252,248,199,66,12,237,184,237,252,233,244,77,248,79,129,252,248,
-  239,15,130,244,62,129,122,253,4,239,15,133,244,62,129,122,253,12,239,255,
-  139,90,252,252,255,139,66,8,131,192,1,199,66,252,252,237,137,66,252,248,255,
-  252,242,15,16,66,8,72,189,237,237,102,72,15,110,205,252,242,15,88,193,252,
-  242,15,45,192,252,242,15,17,66,252,248,255,139,42,59,133,233,15,131,244,248,
-  193,224,3,3,133,233,248,1,129,120,253,4,239,15,132,244,80,72,139,40,72,137,
-  42,252,233,244,76,248,2,131,189,233,0,15,132,244,80,137,252,239,137,213,137,
-  198,232,251,1,15,137,252,234,133,192,15,133,244,1,248,80,184,237,252,233,
-  244,77,248,81,255,139,106,252,248,139,133,233,139,90,252,252,199,66,252,252,
-  237,137,66,252,248,255,199,66,12,237,199,66,8,0,0,0,0,255,15,87,192,252,242,
-  15,17,66,8,255,217,252,238,221,90,8,255,184,237,252,233,244,77,248,82,129,
-  252,248,239,15,130,244,62,141,74,8,131,232,1,187,237,248,1,65,15,182,174,
-  233,193,252,237,235,131,229,1,1,252,235,252,233,244,28,248,83,129,252,248,
-  239,15,130,244,62,129,122,253,12,239,15,133,244,62,255,139,106,4,137,106,
-  12,199,66,4,237,139,42,139,90,8,137,106,8,137,26,141,74,16,131,232,2,187,
-  237,252,233,244,1,248,84,129,252,248,239,15,130,244,62,139,42,139,90,252,
-  252,137,92,36,28,137,44,36,129,122,253,4,239,15,133,244,62,72,131,189,233,
-  0,15,133,244,62,128,189,233,235,15,135,244,62,139,141,233,15,132,244,247,
-  255,59,141,233,15,132,244,62,248,1,141,92,193,252,240,59,157,233,15,135,244,
-  62,137,157,233,139,108,36,24,137,149,233,131,194,8,137,149,233,141,108,194,
-  232,72,41,221,57,203,15,132,244,249,248,2,72,139,4,43,72,137,67,252,248,131,
-  252,235,8,57,203,15,133,244,2,248,3,137,206,139,60,36,232,244,25,65,199,134,
-  233,237,255,139,108,36,24,139,28,36,139,149,233,129,252,248,239,15,135,244,
-  254,248,4,139,139,233,68,139,187,233,137,139,233,68,137,252,251,41,203,15,
-  132,244,252,141,4,26,193,252,235,3,59,133,233,15,135,244,255,137,213,72,41,
-  205,248,5,72,139,1,72,137,4,41,131,193,8,68,57,252,249,15,133,244,5,248,6,
-  141,67,2,199,66,252,252,237,248,7,139,92,36,28,137,68,36,4,72,199,193,252,
-  248,252,255,252,255,252,255,252,247,195,237,255,15,132,244,13,252,233,244,
-  14,248,8,199,66,252,252,237,139,139,233,131,252,233,8,137,139,233,72,139,
-  1,72,137,2,184,237,252,233,244,7,248,9,139,12,36,68,137,185,233,137,222,137,
-  252,239,232,251,1,0,139,28,36,139,149,233,252,233,244,4,248,85,139,106,252,
-  248,139,173,233,139,90,252,252,137,92,36,28,137,44,36,72,131,189,233,0,15,
-  133,244,62,255,128,189,233,235,15,135,244,62,139,141,233,15,132,244,247,59,
-  141,233,15,132,244,62,248,1,141,92,193,252,248,59,157,233,15,135,244,62,137,
-  157,233,139,108,36,24,137,149,233,137,149,233,141,108,194,252,240,72,41,221,
-  57,203,15,132,244,249,248,2,255,72,139,4,43,72,137,67,252,248,131,252,235,
-  8,57,203,15,133,244,2,248,3,137,206,139,60,36,232,244,25,65,199,134,233,237,
-  139,108,36,24,139,28,36,139,149,233,129,252,248,239,15,135,244,254,248,4,
-  139,139,233,68,139,187,233,137,139,233,68,137,252,251,41,203,15,132,244,252,
-  141,4,26,193,252,235,3,59,133,233,15,135,244,255,255,137,213,72,41,205,248,
-  5,72,139,1,72,137,4,41,131,193,8,68,57,252,249,15,133,244,5,248,6,141,67,
-  1,248,7,139,92,36,28,137,68,36,4,49,201,252,247,195,237,15,132,244,13,252,
-  233,244,14,248,8,137,222,137,252,239,232,251,1,16,248,9,139,12,36,68,137,
-  185,233,137,222,137,252,239,232,251,1,0,139,28,36,139,149,233,252,233,244,
-  4,248,86,139,108,36,24,72,252,247,133,233,237,15,132,244,62,255,137,149,233,
-  141,68,194,252,248,137,133,233,49,192,72,137,133,233,176,235,136,133,233,
-  252,233,244,16,255,248,70,255,248,72,139,90,252,252,221,90,252,248,252,233,
-  244,65,255,248,87,129,252,248,239,15,130,244,62,255,129,122,253,4,239,15,
-  133,244,248,139,42,131,252,253,0,15,137,244,70,252,247,221,15,136,244,247,
-  248,88,248,70,139,90,252,252,199,66,252,252,237,137,106,252,248,252,233,244,
-  65,248,1,139,90,252,252,199,66,252,252,0,0,224,65,199,66,252,248,0,0,0,0,
-  252,233,244,65,248,2,15,135,244,62,255,129,122,253,4,239,15,131,244,62,255,
-  252,242,15,16,2,72,184,237,237,102,72,15,110,200,15,84,193,248,71,139,90,
-  252,252,252,242,15,17,66,252,248,255,221,2,217,225,248,71,248,72,139,90,252,
-  252,221,90,252,248,255,248,65,184,237,248,77,137,68,36,4,248,63,252,247,195,
-  237,15,133,244,253,248,5,56,67,252,255,15,135,244,252,15,182,75,252,253,72,
-  252,247,209,141,20,202,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,
-  252,255,36,252,238,248,6,199,68,194,252,244,237,131,192,1,252,233,244,5,248,
-  7,72,199,193,252,248,252,255,252,255,252,255,252,233,244,14,248,89,255,129,
-  122,253,4,239,15,133,244,247,139,42,252,233,244,70,248,1,15,135,244,62,255,
-  252,242,15,16,2,232,244,90,255,252,242,15,45,232,129,252,253,0,0,0,128,15,
-  133,244,70,252,242,15,42,205,102,15,46,193,15,138,244,71,15,132,244,70,255,
-  221,2,232,244,90,255,248,91,255,252,242,15,16,2,232,244,92,255,221,2,232,
-  244,92,255,248,93,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,
-  244,62,252,242,15,81,2,252,233,244,71,255,248,93,129,252,248,239,15,130,244,
-  62,129,122,253,4,239,15,131,244,62,221,2,217,252,250,252,233,244,72,255,248,
-  94,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,217,252,
-  237,221,2,217,252,241,252,233,244,72,248,95,129,252,248,239,15,130,244,62,
-  129,122,253,4,239,15,131,244,62,217,252,236,221,2,217,252,241,252,233,244,
-  72,248,96,129,252,248,239,255,15,130,244,62,129,122,253,4,239,15,131,244,
-  62,221,2,232,244,97,252,233,244,72,248,98,129,252,248,239,15,130,244,62,129,
-  122,253,4,239,15,131,244,62,221,2,217,252,254,252,233,244,72,248,99,129,252,
-  248,239,255,15,130,244,62,129,122,253,4,239,15,131,244,62,221,2,217,252,255,
-  252,233,244,72,248,100,129,252,248,239,15,130,244,62,129,122,253,4,239,15,
-  131,244,62,221,2,217,252,242,221,216,252,233,244,72,248,101,129,252,248,239,
-  15,130,244,62,255,129,122,253,4,239,15,131,244,62,221,2,217,192,216,200,217,
-  232,222,225,217,252,250,217,252,243,252,233,244,72,248,102,129,252,248,239,
-  15,130,244,62,129,122,253,4,239,15,131,244,62,221,2,217,192,216,200,217,232,
-  222,225,217,252,250,217,201,217,252,243,252,233,244,72,248,103,129,252,248,
-  239,15,130,244,62,129,122,253,4,239,15,131,244,62,255,221,2,217,232,217,252,
-  243,252,233,244,72,255,248,104,129,252,248,239,15,130,244,62,129,122,253,
-  4,239,15,131,244,62,252,242,15,16,2,255,137,213,232,251,1,17,137,252,234,
-  252,233,244,71,255,248,105,129,252,248,239,15,130,244,62,129,122,253,4,239,
-  15,131,244,62,252,242,15,16,2,255,137,213,232,251,1,18,137,252,234,252,233,
-  244,71,255,248,106,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,
-  244,62,252,242,15,16,2,255,137,213,232,251,1,19,137,252,234,252,233,244,71,
-  248,107,255,248,108,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,
-  244,62,252,242,15,16,2,139,106,252,248,252,242,15,89,133,233,252,233,244,
-  71,255,248,108,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,
-  62,221,2,139,106,252,248,220,141,233,252,233,244,72,255,248,109,129,252,248,
-  239,15,130,244,62,129,122,253,4,239,15,131,244,62,129,122,253,12,239,15,131,
-  244,62,221,2,221,66,8,217,252,243,252,233,244,72,248,110,129,252,248,239,
-  15,130,244,62,129,122,253,4,239,15,131,244,62,129,122,253,12,239,255,15,131,
-  244,62,221,66,8,221,2,217,252,253,221,217,252,233,244,72,248,111,129,252,
-  248,239,15,130,244,62,139,106,4,129,252,253,239,15,131,244,62,139,90,252,
-  252,139,2,137,106,252,252,137,66,252,248,209,229,129,252,253,0,0,224,252,
-  255,15,131,244,249,9,232,15,132,244,249,184,252,254,3,0,0,129,252,253,0,0,
-  32,0,15,130,244,250,248,1,193,252,237,21,41,197,255,252,242,15,42,197,255,
-  137,44,36,219,4,36,255,139,106,252,252,129,229,252,255,252,255,15,128,129,
-  205,0,0,224,63,137,106,252,252,248,2,255,252,242,15,17,2,255,221,26,255,184,
-  237,252,233,244,77,248,3,255,15,87,192,252,233,244,2,255,217,252,238,252,
-  233,244,2,255,248,4,255,252,242,15,16,2,72,189,237,237,102,72,15,110,205,
-  252,242,15,89,193,252,242,15,17,66,252,248,255,221,2,199,4,36,0,0,128,90,
-  216,12,36,221,90,252,248,255,139,106,252,252,184,52,4,0,0,209,229,252,233,
-  244,1,255,248,112,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,
-  244,62,252,242,15,16,2,255,248,112,129,252,248,239,15,130,244,62,129,122,
-  253,4,239,15,131,244,62,221,2,255,139,106,4,139,90,252,252,209,229,129,252,
-  253,0,0,224,252,255,15,132,244,250,255,15,40,224,232,244,113,252,242,15,92,
-  224,248,1,252,242,15,17,66,252,248,252,242,15,17,34,255,217,192,232,244,113,
-  220,252,233,248,1,221,90,252,248,221,26,255,139,66,252,252,139,106,4,49,232,
-  15,136,244,249,248,2,184,237,252,233,244,77,248,3,129,252,245,0,0,0,128,137,
-  106,4,252,233,244,2,248,4,255,15,87,228,252,233,244,1,255,217,252,238,217,
-  201,252,233,244,1,255,248,114,129,252,248,239,15,130,244,62,129,122,253,4,
-  239,15,131,244,62,129,122,253,12,239,15,131,244,62,221,66,8,221,2,248,1,217,
-  252,248,223,224,158,15,138,244,1,221,217,252,233,244,72,255,248,115,129,252,
-  248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,129,122,253,12,239,
-  15,131,244,62,252,242,15,16,2,252,242,15,16,74,8,232,244,116,252,233,244,
-  71,255,248,115,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,
-  62,129,122,253,12,239,15,131,244,62,221,2,221,66,8,232,244,116,252,233,244,
-  72,255,248,117,185,2,0,0,0,129,122,253,4,239,255,15,133,244,250,139,42,248,
-  1,57,193,15,131,244,70,129,124,253,202,252,252,239,15,133,244,249,59,108,
-  202,252,248,15,79,108,202,252,248,131,193,1,252,233,244,1,248,3,15,135,244,
-  62,255,252,233,244,252,248,4,15,135,244,62,255,252,242,15,16,2,248,5,57,193,
-  15,131,244,71,129,124,253,202,252,252,239,255,15,130,244,252,15,135,244,62,
-  252,242,15,42,76,202,252,248,252,233,244,253,255,248,6,252,242,15,16,76,202,
-  252,248,248,7,252,242,15,93,193,131,193,1,252,233,244,5,255,248,118,185,2,
-  0,0,0,129,122,253,4,239,255,15,133,244,250,139,42,248,1,57,193,15,131,244,
-  70,129,124,253,202,252,252,239,15,133,244,249,59,108,202,252,248,15,76,108,
-  202,252,248,131,193,1,252,233,244,1,248,3,15,135,244,62,255,248,6,252,242,
-  15,16,76,202,252,248,248,7,252,242,15,95,193,131,193,1,252,233,244,5,255,
-  248,9,221,216,252,233,244,62,255,248,119,129,252,248,239,15,130,244,62,129,
-  122,253,4,239,15,133,244,62,139,42,255,139,173,233,252,233,244,70,255,252,
-  242,15,42,133,233,252,233,244,71,255,219,133,233,252,233,244,72,255,248,120,
-  129,252,248,239,15,133,244,62,129,122,253,4,239,15,133,244,62,139,42,139,
-  90,252,252,131,189,233,1,15,130,244,80,15,182,173,233,255,252,242,15,42,197,
-  252,233,244,71,255,137,44,36,219,4,36,252,233,244,72,255,248,121,65,139,174,
-  233,65,59,174,233,15,130,244,247,232,244,74,248,1,129,252,248,239,15,133,
-  244,62,129,122,253,4,239,255,15,133,244,62,139,42,129,252,253,252,255,0,0,
-  0,15,135,244,62,137,108,36,4,255,15,131,244,62,252,242,15,44,42,129,252,253,
-  252,255,0,0,0,15,135,244,62,137,108,36,4,255,15,131,244,62,221,2,219,92,36,
-  4,129,124,36,4,252,255,0,0,0,15,135,244,62,255,199,68,36,8,1,0,0,0,72,141,
-  68,36,4,248,122,139,108,36,24,137,149,233,139,84,36,8,72,137,198,137,252,
-  239,137,92,36,28,232,251,1,20,139,149,233,139,90,252,252,199,66,252,252,237,
-  137,66,252,248,252,233,244,65,248,123,65,139,174,233,65,59,174,233,15,130,
-  244,247,232,244,74,248,1,199,68,36,4,252,255,252,255,252,255,252,255,129,
-  252,248,239,15,130,244,62,15,134,244,247,129,122,253,20,239,255,15,133,244,
-  62,139,106,16,137,108,36,4,255,15,131,244,62,252,242,15,44,106,16,137,108,
-  36,4,255,15,131,244,62,221,66,16,219,92,36,4,255,248,1,129,122,253,4,239,
-  15,133,244,62,129,122,253,12,239,255,139,42,137,108,36,8,139,173,233,255,
-  139,74,8,255,252,242,15,44,74,8,255,139,68,36,4,57,197,15,130,244,251,248,
-  2,133,201,15,142,244,253,248,3,139,108,36,8,41,200,15,140,244,124,141,172,
-  253,13,233,131,192,1,248,4,137,68,36,8,137,232,252,233,244,122,248,5,15,140,
-  244,252,141,68,40,1,252,233,244,2,248,6,137,232,252,233,244,2,248,7,255,15,
-  132,244,254,1,252,233,131,193,1,15,143,244,3,248,8,185,1,0,0,0,252,233,244,
-  3,248,124,49,192,252,233,244,4,248,125,129,252,248,239,15,130,244,62,65,139,
-  174,233,65,59,174,233,15,130,244,247,232,244,74,248,1,255,129,122,253,4,239,
-  15,133,244,62,129,122,253,12,239,139,42,255,15,133,244,62,139,66,8,255,15,
-  131,244,62,252,242,15,44,66,8,255,15,131,244,62,221,66,8,219,92,36,4,139,
-  68,36,4,255,133,192,15,142,244,124,131,189,233,1,15,130,244,124,15,133,244,
-  126,65,57,134,233,15,130,244,126,15,182,141,233,65,139,174,233,137,68,36,
-  8,248,1,136,77,0,131,197,1,131,232,1,15,133,244,1,65,139,134,233,252,233,
-  244,122,248,127,129,252,248,239,255,15,130,244,62,65,139,174,233,65,59,174,
-  233,15,130,244,247,232,244,74,248,1,129,122,253,4,239,15,133,244,62,139,42,
-  139,133,233,133,192,15,132,244,124,65,57,134,233,15,130,244,128,129,197,239,
-  137,92,36,4,137,68,36,8,65,139,158,233,248,1,255,15,182,77,0,131,197,1,131,
-  232,1,136,12,3,15,133,244,1,137,216,139,92,36,4,252,233,244,122,248,129,129,
-  252,248,239,15,130,244,62,65,139,174,233,65,59,174,233,15,130,244,247,232,
-  244,74,248,1,129,122,253,4,239,15,133,244,62,139,42,139,133,233,65,57,134,
-  233,255,15,130,244,128,129,197,239,137,92,36,4,137,68,36,8,65,139,158,233,
-  252,233,244,249,248,1,15,182,76,5,0,131,252,249,65,15,130,244,248,131,252,
-  249,90,15,135,244,248,131,252,241,32,248,2,136,12,3,248,3,131,232,1,15,137,
-  244,1,137,216,139,92,36,4,252,233,244,122,248,130,129,252,248,239,15,130,
-  244,62,255,65,139,174,233,65,59,174,233,15,130,244,247,232,244,74,248,1,129,
-  122,253,4,239,15,133,244,62,139,42,139,133,233,65,57,134,233,15,130,244,128,
-  129,197,239,137,92,36,4,137,68,36,8,65,139,158,233,252,233,244,249,248,1,
-  15,182,76,5,0,131,252,249,97,15,130,244,248,255,131,252,249,122,15,135,244,
-  248,131,252,241,32,248,2,136,12,3,248,3,131,232,1,15,137,244,1,137,216,139,
-  92,36,4,252,233,244,122,248,131,129,252,248,239,15,130,244,62,129,122,253,
-  4,239,15,133,244,62,137,213,139,58,232,251,1,21,137,252,234,255,137,197,252,
-  233,244,70,255,252,242,15,42,192,252,233,244,71,255,248,132,129,252,248,239,
-  15,130,244,62,129,122,253,4,239,255,15,133,244,247,139,42,252,233,244,88,
-  248,1,15,135,244,62,255,252,242,15,16,2,72,189,237,237,102,72,15,110,205,
-  252,242,15,88,193,102,15,126,197,255,252,233,244,88,255,248,133,129,252,248,
-  239,15,130,244,62,255,72,189,237,237,102,72,15,110,205,255,199,4,36,0,0,192,
-  89,255,15,133,244,247,139,42,252,233,244,248,248,1,15,135,244,62,255,252,
-  242,15,16,2,252,242,15,88,193,102,15,126,197,255,248,2,137,68,36,4,141,68,
-  194,252,240,248,1,57,208,15,134,244,88,129,120,253,4,239,255,15,133,244,248,
-  35,40,131,232,8,252,233,244,1,248,2,15,135,244,134,255,15,131,244,134,255,
-  252,242,15,16,0,252,242,15,88,193,102,15,126,193,33,205,255,131,232,8,252,
-  233,244,1,248,135,129,252,248,239,15,130,244,62,255,15,133,244,248,11,40,
-  131,232,8,252,233,244,1,248,2,15,135,244,134,255,252,242,15,16,0,252,242,
-  15,88,193,102,15,126,193,9,205,255,131,232,8,252,233,244,1,248,136,129,252,
-  248,239,15,130,244,62,255,15,133,244,248,51,40,131,232,8,252,233,244,1,248,
-  2,15,135,244,134,255,252,242,15,16,0,252,242,15,88,193,102,15,126,193,49,
-  205,255,131,232,8,252,233,244,1,248,137,129,252,248,239,15,130,244,62,129,
-  122,253,4,239,255,248,2,15,205,252,233,244,88,248,138,129,252,248,239,15,
-  130,244,62,129,122,253,4,239,255,248,2,252,247,213,255,248,88,252,242,15,
-  42,197,252,233,244,71,255,248,134,139,68,36,4,252,233,244,62,255,248,139,
-  129,252,248,239,15,130,244,62,129,122,253,4,239,255,248,2,129,122,253,12,
-  239,15,133,244,62,139,74,8,255,248,139,129,252,248,239,15,130,244,62,129,
-  122,253,4,239,15,131,244,62,129,122,253,12,239,15,131,244,62,252,242,15,16,
-  2,252,242,15,16,74,8,72,189,237,237,102,72,15,110,213,252,242,15,88,194,252,
-  242,15,88,202,102,15,126,197,102,15,126,201,255,211,229,252,233,244,88,255,
-  248,140,129,252,248,239,15,130,244,62,129,122,253,4,239,255,248,140,129,252,
-  248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,129,122,253,12,239,
-  15,131,244,62,252,242,15,16,2,252,242,15,16,74,8,72,189,237,237,102,72,15,
-  110,213,252,242,15,88,194,252,242,15,88,202,102,15,126,197,102,15,126,201,
-  255,211,252,237,252,233,244,88,255,248,141,129,252,248,239,15,130,244,62,
-  129,122,253,4,239,255,248,141,129,252,248,239,15,130,244,62,129,122,253,4,
-  239,15,131,244,62,129,122,253,12,239,15,131,244,62,252,242,15,16,2,252,242,
-  15,16,74,8,72,189,237,237,102,72,15,110,213,252,242,15,88,194,252,242,15,
-  88,202,102,15,126,197,102,15,126,201,255,211,252,253,252,233,244,88,255,248,
-  142,129,252,248,239,15,130,244,62,129,122,253,4,239,255,248,142,129,252,248,
-  239,15,130,244,62,129,122,253,4,239,15,131,244,62,129,122,253,12,239,15,131,
-  244,62,252,242,15,16,2,252,242,15,16,74,8,72,189,237,237,102,72,15,110,213,
-  252,242,15,88,194,252,242,15,88,202,102,15,126,197,102,15,126,201,255,211,
-  197,252,233,244,88,255,248,143,129,252,248,239,15,130,244,62,129,122,253,
-  4,239,255,248,143,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,
-  244,62,129,122,253,12,239,15,131,244,62,252,242,15,16,2,252,242,15,16,74,
+  77,252,240,255,131,252,249,1,15,134,244,247,255,76,141,61,245,76,1,252,249,
+  255,68,139,122,252,248,69,139,191,233,69,139,191,233,252,255,225,255,248,
+  1,15,132,244,32,41,213,193,252,237,3,141,69,252,255,252,233,244,33,255,248,
+  34,15,182,75,252,255,131,252,237,16,141,12,202,41,252,233,15,132,244,35,252,
+  247,217,193,252,233,3,139,124,36,24,137,151,233,137,202,72,139,8,72,137,77,
+  0,137,252,238,252,233,244,36,248,37,137,4,36,199,68,36,4,237,72,141,4,36,
+  128,123,252,252,235,15,133,244,247,65,141,142,233,137,41,199,65,4,237,137,
+  205,252,233,244,248,248,38,15,182,67,252,254,255,199,68,36,4,237,137,4,36,
+  255,252,242,15,42,192,252,242,15,17,4,36,255,72,141,4,36,252,233,244,247,
+  248,39,15,182,67,252,254,141,4,194,248,1,15,182,107,252,255,141,44,252,234,
+  248,2,139,124,36,24,137,151,233,137,252,238,72,137,194,137,252,253,137,92,
+  36,28,232,251,1,2,139,149,233,133,192,15,132,244,249,248,35,15,182,75,252,
+  253,72,139,40,72,137,44,202,139,3,15,182,204,15,182,232,131,195,4,193,232,
+  16,65,252,255,36,252,238,248,3,139,141,233,137,89,252,244,141,153,233,41,
+  211,139,105,252,248,184,237,252,233,244,30,248,40,137,4,36,199,68,36,4,237,
+  72,141,4,36,128,123,252,252,235,15,133,244,247,255,65,141,142,233,137,41,
+  199,65,4,237,137,205,252,233,244,248,248,41,15,182,67,252,254,255,72,141,
+  4,36,252,233,244,247,248,42,15,182,67,252,254,141,4,194,248,1,15,182,107,
+  252,255,141,44,252,234,248,2,139,124,36,24,137,151,233,137,252,238,72,137,
+  194,137,252,253,137,92,36,28,232,251,1,3,139,149,233,133,192,15,132,244,249,
+  15,182,75,252,253,72,139,44,202,72,137,40,248,43,139,3,15,182,204,15,182,
+  232,131,195,4,193,232,16,65,252,255,36,252,238,248,3,139,141,233,137,89,252,
+  244,15,182,67,252,253,72,139,44,194,72,137,105,16,141,153,233,41,211,139,
+  105,252,248,184,237,252,233,244,30,248,44,139,108,36,24,137,149,233,141,52,
+  202,141,20,194,137,252,239,15,182,75,252,252,137,92,36,28,232,251,1,4,248,
+  3,139,149,233,255,131,252,248,1,15,135,244,45,248,4,141,91,4,15,130,244,252,
+  248,5,15,183,67,252,254,141,156,253,131,233,248,6,139,3,15,182,204,15,182,
+  232,131,195,4,193,232,16,65,252,255,36,252,238,248,46,131,195,4,129,120,253,
+  4,239,15,130,244,5,252,233,244,6,248,47,129,120,253,4,239,252,233,244,4,248,
+  48,131,252,235,4,137,206,137,252,233,139,108,36,24,137,149,233,255,137,194,
+  137,252,239,137,92,36,28,232,251,1,5,252,233,244,3,248,49,255,131,252,235,
+  4,139,108,36,24,137,149,233,137,252,239,139,115,252,252,137,92,36,28,232,
+  251,1,6,252,233,244,3,255,248,50,255,15,182,107,252,255,255,248,51,65,141,
+  4,199,252,233,244,247,248,52,255,248,53,65,141,4,199,141,44,252,234,149,252,
+  233,244,248,248,54,141,4,194,137,197,252,233,244,248,248,55,255,248,56,141,
+  4,194,248,1,141,44,252,234,248,2,141,12,202,68,15,182,67,252,252,137,206,
+  137,193,139,124,36,24,137,151,233,137,252,234,137,252,253,137,92,36,28,232,
+  251,1,7,139,149,233,133,192,15,132,244,43,248,45,137,193,41,208,137,89,252,
+  244,141,152,233,184,237,252,233,244,28,248,57,139,108,36,24,137,149,233,141,
+  52,194,137,252,239,137,92,36,28,232,251,1,8,139,149,233,255,133,192,15,133,
+  244,45,15,183,67,252,254,139,60,194,252,233,244,58,255,252,233,244,45,255,
+  248,59,141,76,202,8,248,29,137,76,36,4,137,4,36,131,252,233,8,139,108,36,
+  24,137,149,233,137,206,141,20,193,137,252,239,137,92,36,28,232,251,1,9,139,
+  149,233,139,76,36,4,139,4,36,139,105,252,248,131,192,1,65,57,215,15,132,244,
+  60,137,202,137,90,252,252,139,157,233,139,11,15,182,252,233,15,182,205,131,
+  195,4,65,252,255,36,252,238,248,61,139,108,36,24,137,149,233,137,206,137,
+  252,239,137,92,36,28,232,251,1,10,139,149,233,139,67,252,252,15,182,204,15,
+  182,232,193,232,16,65,252,255,164,253,252,238,233,248,62,129,252,248,239,
+  15,130,244,63,139,106,4,129,252,253,239,15,131,244,63,139,90,252,252,137,
+  68,36,4,137,106,252,252,139,42,137,106,252,248,131,232,2,15,132,244,248,255,
+  137,209,248,1,131,193,8,72,139,41,72,137,105,252,248,131,232,1,15,133,244,
+  1,248,2,139,68,36,4,252,233,244,64,248,65,129,252,248,239,15,130,244,63,139,
+  106,4,137,252,233,193,252,249,15,131,252,249,252,254,15,132,244,249,184,237,
+  252,247,213,57,232,255,15,71,197,255,15,134,244,247,137,232,248,1,255,248,
+  2,139,106,252,248,139,132,253,197,233,139,90,252,252,199,66,252,252,237,137,
+  66,252,248,252,233,244,66,248,3,184,237,252,233,244,2,248,67,129,252,248,
+  239,15,130,244,63,139,106,4,139,90,252,252,129,252,253,239,15,133,244,252,
+  248,1,139,42,139,173,233,248,2,133,252,237,199,66,252,252,237,255,15,132,
+  244,66,65,139,134,233,199,66,252,252,237,137,106,252,248,139,141,233,35,136,
+  233,105,201,239,3,141,233,248,3,129,185,233,239,15,133,244,250,57,129,233,
+  15,132,244,251,248,4,139,137,233,133,201,15,133,244,3,255,252,233,244,66,
+  248,5,139,105,4,129,252,253,239,15,132,244,66,139,1,137,106,252,252,137,66,
+  252,248,252,233,244,66,248,6,129,252,253,239,15,132,244,1,129,252,253,239,
+  15,135,244,254,129,252,253,239,15,134,244,253,189,237,252,233,244,254,248,
+  7,255,189,237,248,8,252,247,213,65,139,172,253,174,233,252,233,244,2,248,
+  68,129,252,248,239,15,130,244,63,129,122,253,4,239,15,133,244,63,139,42,131,
+  189,233,0,15,133,244,63,129,122,253,12,239,15,133,244,63,139,66,8,137,133,
+  233,139,90,252,252,199,66,252,252,237,255,137,106,252,248,252,246,133,233,
+  235,15,132,244,247,128,165,233,235,65,139,134,233,65,137,174,233,137,133,
+  233,248,1,252,233,244,66,248,69,129,252,248,239,15,130,244,63,129,122,253,
+  4,239,15,133,244,63,137,213,139,50,141,82,8,139,124,36,24,232,251,1,11,137,
+  252,234,72,139,40,139,90,252,252,72,137,106,252,248,252,233,244,66,248,70,
+  255,129,252,248,239,15,133,244,63,129,122,253,4,239,255,15,133,244,247,139,
+  42,252,233,244,71,248,1,15,135,244,63,255,15,131,244,63,255,252,242,15,16,
+  2,252,233,244,72,255,221,2,252,233,244,73,255,248,74,129,252,248,239,15,130,
+  244,63,139,90,252,252,129,122,253,4,239,15,133,244,249,139,2,248,2,199,66,
+  252,252,237,137,66,252,248,252,233,244,66,248,3,129,122,253,4,239,15,135,
+  244,63,65,131,190,233,0,15,133,244,63,65,139,174,233,65,59,174,233,255,15,
+  130,244,247,232,244,75,248,1,139,108,36,24,137,149,233,137,92,36,28,137,214,
+  137,252,239,255,232,251,1,12,255,232,251,1,13,255,139,149,233,252,233,244,
+  2,248,76,129,252,248,239,15,130,244,63,15,132,244,248,248,1,129,122,253,4,
+  239,15,133,244,63,139,108,36,24,137,149,233,137,149,233,139,90,252,252,139,
+  50,141,82,8,137,252,239,137,92,36,28,232,251,1,14,139,149,233,133,192,15,
+  132,244,249,72,139,106,8,72,139,66,16,72,137,106,252,248,72,137,2,248,77,
+  184,237,255,252,233,244,78,248,2,199,66,12,237,252,233,244,1,248,3,199,66,
+  252,252,237,252,233,244,66,248,79,129,252,248,239,15,130,244,63,139,42,129,
+  122,253,4,239,15,133,244,63,255,131,189,233,0,15,133,244,63,255,139,106,252,
+  248,139,133,233,139,90,252,252,199,66,252,252,237,137,66,252,248,199,66,12,
+  237,184,237,252,233,244,78,248,80,129,252,248,239,15,130,244,63,129,122,253,
+  4,239,15,133,244,63,129,122,253,12,239,255,139,90,252,252,255,139,66,8,131,
+  192,1,199,66,252,252,237,137,66,252,248,255,252,242,15,16,66,8,72,189,237,
+  237,102,72,15,110,205,252,242,15,88,193,252,242,15,45,192,252,242,15,17,66,
+  252,248,255,139,42,59,133,233,15,131,244,248,193,224,3,3,133,233,248,1,129,
+  120,253,4,239,15,132,244,81,72,139,40,72,137,42,252,233,244,77,248,2,131,
+  189,233,0,15,132,244,81,137,252,239,137,213,137,198,232,251,1,15,137,252,
+  234,133,192,15,133,244,1,248,81,184,237,252,233,244,78,248,82,255,139,106,
+  252,248,139,133,233,139,90,252,252,199,66,252,252,237,137,66,252,248,255,
+  199,66,12,237,199,66,8,0,0,0,0,255,15,87,192,252,242,15,17,66,8,255,217,252,
+  238,221,90,8,255,184,237,252,233,244,78,248,83,129,252,248,239,15,130,244,
+  63,141,74,8,131,232,1,187,237,248,1,65,15,182,174,233,193,252,237,235,131,
+  229,1,1,252,235,252,233,244,28,248,84,129,252,248,239,15,130,244,63,129,122,
+  253,12,239,15,133,244,63,255,139,106,4,137,106,12,199,66,4,237,139,42,139,
+  90,8,137,106,8,137,26,141,74,16,131,232,2,187,237,252,233,244,1,248,85,129,
+  252,248,239,15,130,244,63,139,42,139,90,252,252,137,92,36,28,137,44,36,129,
+  122,253,4,239,15,133,244,63,72,131,189,233,0,15,133,244,63,128,189,233,235,
+  15,135,244,63,139,141,233,15,132,244,247,255,59,141,233,15,132,244,63,248,
+  1,141,92,193,252,240,59,157,233,15,135,244,63,137,157,233,139,108,36,24,137,
+  149,233,131,194,8,137,149,233,141,108,194,232,72,41,221,57,203,15,132,244,
+  249,248,2,72,139,4,43,72,137,67,252,248,131,252,235,8,57,203,15,133,244,2,
+  248,3,137,206,139,60,36,232,244,25,65,199,134,233,237,255,139,108,36,24,139,
+  28,36,139,149,233,129,252,248,239,15,135,244,254,248,4,139,139,233,68,139,
+  187,233,137,139,233,68,137,252,251,41,203,15,132,244,252,141,4,26,193,252,
+  235,3,59,133,233,15,135,244,255,137,213,72,41,205,248,5,72,139,1,72,137,4,
+  41,131,193,8,68,57,252,249,15,133,244,5,248,6,141,67,2,199,66,252,252,237,
+  248,7,139,92,36,28,137,68,36,4,72,199,193,252,248,252,255,252,255,252,255,
+  252,247,195,237,255,15,132,244,13,252,233,244,14,248,8,199,66,252,252,237,
+  139,139,233,131,252,233,8,137,139,233,72,139,1,72,137,2,184,237,252,233,244,
+  7,248,9,139,12,36,68,137,185,233,137,222,137,252,239,232,251,1,0,139,28,36,
+  139,149,233,252,233,244,4,248,86,139,106,252,248,139,173,233,139,90,252,252,
+  137,92,36,28,137,44,36,72,131,189,233,0,15,133,244,63,255,128,189,233,235,
+  15,135,244,63,139,141,233,15,132,244,247,59,141,233,15,132,244,63,248,1,141,
+  92,193,252,248,59,157,233,15,135,244,63,137,157,233,139,108,36,24,137,149,
+  233,137,149,233,141,108,194,252,240,72,41,221,57,203,15,132,244,249,248,2,
+  255,72,139,4,43,72,137,67,252,248,131,252,235,8,57,203,15,133,244,2,248,3,
+  137,206,139,60,36,232,244,25,65,199,134,233,237,139,108,36,24,139,28,36,139,
+  149,233,129,252,248,239,15,135,244,254,248,4,139,139,233,68,139,187,233,137,
+  139,233,68,137,252,251,41,203,15,132,244,252,141,4,26,193,252,235,3,59,133,
+  233,15,135,244,255,255,137,213,72,41,205,248,5,72,139,1,72,137,4,41,131,193,
+  8,68,57,252,249,15,133,244,5,248,6,141,67,1,248,7,139,92,36,28,137,68,36,
+  4,49,201,252,247,195,237,15,132,244,13,252,233,244,14,248,8,137,222,137,252,
+  239,232,251,1,16,248,9,139,12,36,68,137,185,233,137,222,137,252,239,232,251,
+  1,0,139,28,36,139,149,233,252,233,244,4,248,87,139,108,36,24,72,252,247,133,
+  233,237,15,132,244,63,255,137,149,233,141,68,194,252,248,137,133,233,49,192,
+  72,137,133,233,176,235,136,133,233,252,233,244,16,255,248,71,255,248,73,139,
+  90,252,252,221,90,252,248,252,233,244,66,255,248,88,129,252,248,239,15,130,
+  244,63,255,129,122,253,4,239,15,133,244,248,139,42,131,252,253,0,15,137,244,
+  71,252,247,221,15,136,244,247,248,89,248,71,139,90,252,252,199,66,252,252,
+  237,137,106,252,248,252,233,244,66,248,1,139,90,252,252,199,66,252,252,0,
+  0,224,65,199,66,252,248,0,0,0,0,252,233,244,66,248,2,15,135,244,63,255,129,
+  122,253,4,239,15,131,244,63,255,252,242,15,16,2,72,184,237,237,102,72,15,
+  110,200,15,84,193,248,72,139,90,252,252,252,242,15,17,66,252,248,255,221,
+  2,217,225,248,72,248,73,139,90,252,252,221,90,252,248,255,248,66,184,237,
+  248,78,137,68,36,4,248,64,252,247,195,237,15,133,244,253,248,5,56,67,252,
+  255,15,135,244,252,15,182,75,252,253,72,252,247,209,141,20,202,139,3,15,182,
+  204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,248,6,199,68,194,
+  252,244,237,131,192,1,252,233,244,5,248,7,72,199,193,252,248,252,255,252,
+  255,252,255,252,233,244,14,248,90,255,129,122,253,4,239,15,133,244,247,139,
+  42,252,233,244,71,248,1,15,135,244,63,255,252,242,15,16,2,232,244,91,255,
+  252,242,15,45,232,129,252,253,0,0,0,128,15,133,244,71,252,242,15,42,205,102,
+  15,46,193,15,138,244,72,15,132,244,71,255,221,2,232,244,91,255,248,92,255,
+  252,242,15,16,2,232,244,93,255,221,2,232,244,93,255,248,94,129,252,248,239,
+  15,130,244,63,129,122,253,4,239,15,131,244,63,252,242,15,81,2,252,233,244,
+  72,255,248,94,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,
+  63,221,2,217,252,250,252,233,244,73,255,248,95,129,252,248,239,15,130,244,
+  63,129,122,253,4,239,15,131,244,63,217,252,237,221,2,217,252,241,252,233,
+  244,73,248,96,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,
+  63,217,252,236,221,2,217,252,241,252,233,244,73,248,97,129,252,248,239,255,
+  15,130,244,63,129,122,253,4,239,15,131,244,63,221,2,232,244,98,252,233,244,
+  73,248,99,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,221,
+  2,217,252,254,252,233,244,73,248,100,129,252,248,239,255,15,130,244,63,129,
+  122,253,4,239,15,131,244,63,221,2,217,252,255,252,233,244,73,248,101,129,
+  252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,221,2,217,252,242,
+  221,216,252,233,244,73,248,102,129,252,248,239,15,130,244,63,255,129,122,
+  253,4,239,15,131,244,63,221,2,217,192,216,200,217,232,222,225,217,252,250,
+  217,252,243,252,233,244,73,248,103,129,252,248,239,15,130,244,63,129,122,
+  253,4,239,15,131,244,63,221,2,217,192,216,200,217,232,222,225,217,252,250,
+  217,201,217,252,243,252,233,244,73,248,104,129,252,248,239,15,130,244,63,
+  129,122,253,4,239,15,131,244,63,255,221,2,217,232,217,252,243,252,233,244,
+  73,255,248,105,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,
+  63,252,242,15,16,2,255,137,213,232,251,1,17,137,252,234,252,233,244,72,255,
+  248,106,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,252,
+  242,15,16,2,255,137,213,232,251,1,18,137,252,234,252,233,244,72,255,248,107,
+  129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,252,242,15,
+  16,2,255,137,213,232,251,1,19,137,252,234,252,233,244,72,248,108,255,248,
+  109,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,252,242,
+  15,16,2,139,106,252,248,252,242,15,89,133,233,252,233,244,72,255,248,109,
+  129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,221,2,139,106,
+  252,248,220,141,233,252,233,244,73,255,248,110,129,252,248,239,15,130,244,
+  63,129,122,253,4,239,15,131,244,63,129,122,253,12,239,15,131,244,63,221,2,
+  221,66,8,217,252,243,252,233,244,73,248,111,129,252,248,239,15,130,244,63,
+  129,122,253,4,239,15,131,244,63,129,122,253,12,239,255,15,131,244,63,221,
+  66,8,221,2,217,252,253,221,217,252,233,244,73,248,112,129,252,248,239,15,
+  130,244,63,139,106,4,129,252,253,239,15,131,244,63,139,90,252,252,139,2,137,
+  106,252,252,137,66,252,248,209,229,129,252,253,0,0,224,252,255,15,131,244,
+  249,9,232,15,132,244,249,184,252,254,3,0,0,129,252,253,0,0,32,0,15,130,244,
+  250,248,1,193,252,237,21,41,197,255,252,242,15,42,197,255,137,44,36,219,4,
+  36,255,139,106,252,252,129,229,252,255,252,255,15,128,129,205,0,0,224,63,
+  137,106,252,252,248,2,255,252,242,15,17,2,255,221,26,255,184,237,252,233,
+  244,78,248,3,255,15,87,192,252,233,244,2,255,217,252,238,252,233,244,2,255,
+  248,4,255,252,242,15,16,2,72,189,237,237,102,72,15,110,205,252,242,15,89,
+  193,252,242,15,17,66,252,248,255,221,2,199,4,36,0,0,128,90,216,12,36,221,
+  90,252,248,255,139,106,252,252,184,52,4,0,0,209,229,252,233,244,1,255,248,
+  113,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,252,242,
+  15,16,2,255,248,113,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,
+  244,63,221,2,255,139,106,4,139,90,252,252,209,229,129,252,253,0,0,224,252,
+  255,15,132,244,250,255,15,40,224,232,244,114,252,242,15,92,224,248,1,252,
+  242,15,17,66,252,248,252,242,15,17,34,255,217,192,232,244,114,220,252,233,
+  248,1,221,90,252,248,221,26,255,139,66,252,252,139,106,4,49,232,15,136,244,
+  249,248,2,184,237,252,233,244,78,248,3,129,252,245,0,0,0,128,137,106,4,252,
+  233,244,2,248,4,255,15,87,228,252,233,244,1,255,217,252,238,217,201,252,233,
+  244,1,255,248,115,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,
+  244,63,129,122,253,12,239,15,131,244,63,221,66,8,221,2,248,1,217,252,248,
+  223,224,158,15,138,244,1,221,217,252,233,244,73,255,248,116,129,252,248,239,
+  15,130,244,63,129,122,253,4,239,15,131,244,63,129,122,253,12,239,15,131,244,
+  63,252,242,15,16,2,252,242,15,16,74,8,232,244,117,252,233,244,72,255,248,
+  116,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,129,122,
+  253,12,239,15,131,244,63,221,2,221,66,8,232,244,117,252,233,244,73,255,248,
+  118,185,2,0,0,0,129,122,253,4,239,255,15,133,244,250,139,42,248,1,57,193,
+  15,131,244,71,129,124,253,202,252,252,239,15,133,244,249,59,108,202,252,248,
+  15,79,108,202,252,248,131,193,1,252,233,244,1,248,3,15,135,244,63,255,252,
+  233,244,252,248,4,15,135,244,63,255,252,242,15,16,2,248,5,57,193,15,131,244,
+  72,129,124,253,202,252,252,239,255,15,130,244,252,15,135,244,63,252,242,15,
+  42,76,202,252,248,252,233,244,253,255,248,6,252,242,15,16,76,202,252,248,
+  248,7,252,242,15,93,193,131,193,1,252,233,244,5,255,248,119,185,2,0,0,0,129,
+  122,253,4,239,255,15,133,244,250,139,42,248,1,57,193,15,131,244,71,129,124,
+  253,202,252,252,239,15,133,244,249,59,108,202,252,248,15,76,108,202,252,248,
+  131,193,1,252,233,244,1,248,3,15,135,244,63,255,248,6,252,242,15,16,76,202,
+  252,248,248,7,252,242,15,95,193,131,193,1,252,233,244,5,255,248,9,221,216,
+  252,233,244,63,255,248,120,129,252,248,239,15,130,244,63,129,122,253,4,239,
+  15,133,244,63,139,42,255,139,173,233,252,233,244,71,255,252,242,15,42,133,
+  233,252,233,244,72,255,219,133,233,252,233,244,73,255,248,121,129,252,248,
+  239,15,133,244,63,129,122,253,4,239,15,133,244,63,139,42,139,90,252,252,131,
+  189,233,1,15,130,244,81,15,182,173,233,255,252,242,15,42,197,252,233,244,
+  72,255,137,44,36,219,4,36,252,233,244,73,255,248,122,65,139,174,233,65,59,
+  174,233,15,130,244,247,232,244,75,248,1,129,252,248,239,15,133,244,63,129,
+  122,253,4,239,255,15,133,244,63,139,42,129,252,253,252,255,0,0,0,15,135,244,
+  63,137,108,36,4,255,15,131,244,63,252,242,15,44,42,129,252,253,252,255,0,
+  0,0,15,135,244,63,137,108,36,4,255,15,131,244,63,221,2,219,92,36,4,129,124,
+  36,4,252,255,0,0,0,15,135,244,63,255,199,68,36,8,1,0,0,0,72,141,68,36,4,248,
+  123,139,108,36,24,137,149,233,139,84,36,8,72,137,198,137,252,239,137,92,36,
+  28,232,251,1,20,139,149,233,139,90,252,252,199,66,252,252,237,137,66,252,
+  248,252,233,244,66,248,124,65,139,174,233,65,59,174,233,15,130,244,247,232,
+  244,75,248,1,199,68,36,4,252,255,252,255,252,255,252,255,129,252,248,239,
+  15,130,244,63,15,134,244,247,129,122,253,20,239,255,15,133,244,63,139,106,
+  16,137,108,36,4,255,15,131,244,63,252,242,15,44,106,16,137,108,36,4,255,15,
+  131,244,63,221,66,16,219,92,36,4,255,248,1,129,122,253,4,239,15,133,244,63,
+  129,122,253,12,239,255,139,42,137,108,36,8,139,173,233,255,139,74,8,255,252,
+  242,15,44,74,8,255,139,68,36,4,57,197,15,130,244,251,248,2,133,201,15,142,
+  244,253,248,3,139,108,36,8,41,200,15,140,244,125,141,172,253,13,233,131,192,
+  1,248,4,137,68,36,8,137,232,252,233,244,123,248,5,15,140,244,252,141,68,40,
+  1,252,233,244,2,248,6,137,232,252,233,244,2,248,7,255,15,132,244,254,1,252,
+  233,131,193,1,15,143,244,3,248,8,185,1,0,0,0,252,233,244,3,248,125,49,192,
+  252,233,244,4,248,126,129,252,248,239,15,130,244,63,65,139,174,233,65,59,
+  174,233,15,130,244,247,232,244,75,248,1,255,129,122,253,4,239,15,133,244,
+  63,129,122,253,12,239,139,42,255,15,133,244,63,139,66,8,255,15,131,244,63,
+  252,242,15,44,66,8,255,15,131,244,63,221,66,8,219,92,36,4,139,68,36,4,255,
+  133,192,15,142,244,125,131,189,233,1,15,130,244,125,15,133,244,127,65,57,
+  134,233,15,130,244,127,15,182,141,233,65,139,174,233,137,68,36,8,248,1,136,
+  77,0,131,197,1,131,232,1,15,133,244,1,65,139,134,233,252,233,244,123,248,
+  128,129,252,248,239,255,15,130,244,63,65,139,174,233,65,59,174,233,15,130,
+  244,247,232,244,75,248,1,129,122,253,4,239,15,133,244,63,139,42,139,133,233,
+  133,192,15,132,244,125,65,57,134,233,15,130,244,129,129,197,239,137,92,36,
+  4,137,68,36,8,65,139,158,233,248,1,255,15,182,77,0,131,197,1,131,232,1,136,
+  12,3,15,133,244,1,137,216,139,92,36,4,252,233,244,123,248,130,129,252,248,
+  239,15,130,244,63,65,139,174,233,65,59,174,233,15,130,244,247,232,244,75,
+  248,1,129,122,253,4,239,15,133,244,63,139,42,139,133,233,65,57,134,233,255,
+  15,130,244,129,129,197,239,137,92,36,4,137,68,36,8,65,139,158,233,252,233,
+  244,249,248,1,15,182,76,5,0,131,252,249,65,15,130,244,248,131,252,249,90,
+  15,135,244,248,131,252,241,32,248,2,136,12,3,248,3,131,232,1,15,137,244,1,
+  137,216,139,92,36,4,252,233,244,123,248,131,129,252,248,239,15,130,244,63,
+  255,65,139,174,233,65,59,174,233,15,130,244,247,232,244,75,248,1,129,122,
+  253,4,239,15,133,244,63,139,42,139,133,233,65,57,134,233,15,130,244,129,129,
+  197,239,137,92,36,4,137,68,36,8,65,139,158,233,252,233,244,249,248,1,15,182,
+  76,5,0,131,252,249,97,15,130,244,248,255,131,252,249,122,15,135,244,248,131,
+  252,241,32,248,2,136,12,3,248,3,131,232,1,15,137,244,1,137,216,139,92,36,
+  4,252,233,244,123,248,132,129,252,248,239,15,130,244,63,129,122,253,4,239,
+  15,133,244,63,137,213,139,58,232,251,1,21,137,252,234,255,137,197,252,233,
+  244,71,255,252,242,15,42,192,252,233,244,72,255,248,133,129,252,248,239,15,
+  130,244,63,129,122,253,4,239,255,15,133,244,247,139,42,252,233,244,89,248,
+  1,15,135,244,63,255,252,242,15,16,2,72,189,237,237,102,72,15,110,205,252,
+  242,15,88,193,102,15,126,197,255,252,233,244,89,255,248,134,129,252,248,239,
+  15,130,244,63,255,72,189,237,237,102,72,15,110,205,255,199,4,36,0,0,192,89,
+  255,15,133,244,247,139,42,252,233,244,248,248,1,15,135,244,63,255,252,242,
+  15,16,2,252,242,15,88,193,102,15,126,197,255,248,2,137,68,36,4,141,68,194,
+  252,240,248,1,57,208,15,134,244,89,129,120,253,4,239,255,15,133,244,248,35,
+  40,131,232,8,252,233,244,1,248,2,15,135,244,135,255,15,131,244,135,255,252,
+  242,15,16,0,252,242,15,88,193,102,15,126,193,33,205,255,131,232,8,252,233,
+  244,1,248,136,129,252,248,239,15,130,244,63,255,15,133,244,248,11,40,131,
+  232,8,252,233,244,1,248,2,15,135,244,135,255,252,242,15,16,0,252,242,15,88,
+  193,102,15,126,193,9,205,255,131,232,8,252,233,244,1,248,137,129,252,248,
+  239,15,130,244,63,255,15,133,244,248,51,40,131,232,8,252,233,244,1,248,2,
+  15,135,244,135,255,252,242,15,16,0,252,242,15,88,193,102,15,126,193,49,205,
+  255,131,232,8,252,233,244,1,248,138,129,252,248,239,15,130,244,63,129,122,
+  253,4,239,255,248,2,15,205,252,233,244,89,248,139,129,252,248,239,15,130,
+  244,63,129,122,253,4,239,255,248,2,252,247,213,255,248,89,252,242,15,42,197,
+  252,233,244,72,255,248,135,139,68,36,4,252,233,244,63,255,248,140,129,252,
+  248,239,15,130,244,63,129,122,253,4,239,255,248,2,129,122,253,12,239,15,133,
+  244,63,139,74,8,255,248,140,129,252,248,239,15,130,244,63,129,122,253,4,239,
+  15,131,244,63,129,122,253,12,239,15,131,244,63,252,242,15,16,2,252,242,15,
+  16,74,8,72,189,237,237,102,72,15,110,213,252,242,15,88,194,252,242,15,88,
+  202,102,15,126,197,102,15,126,201,255,211,229,252,233,244,89,255,248,141,
+  129,252,248,239,15,130,244,63,129,122,253,4,239,255,248,141,129,252,248,239,
+  15,130,244,63,129,122,253,4,239,15,131,244,63,129,122,253,12,239,15,131,244,
+  63,252,242,15,16,2,252,242,15,16,74,8,72,189,237,237,102,72,15,110,213,252,
+  242,15,88,194,252,242,15,88,202,102,15,126,197,102,15,126,201,255,211,252,
+  237,252,233,244,89,255,248,142,129,252,248,239,15,130,244,63,129,122,253,
+  4,239,255,248,142,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,
+  244,63,129,122,253,12,239,15,131,244,63,252,242,15,16,2,252,242,15,16,74,
   8,72,189,237,237,102,72,15,110,213,252,242,15,88,194,252,242,15,88,202,102,
-  15,126,197,102,15,126,201,255,211,205,252,233,244,88,248,126,184,237,252,
-  233,244,62,248,128,184,237,248,62,139,108,36,24,139,90,252,252,137,92,36,
-  28,137,149,233,141,68,194,252,248,141,136,233,137,133,233,139,66,252,248,
-  59,141,233,15,135,244,251,137,252,239,252,255,144,233,139,149,233,133,192,
-  15,143,244,77,248,1,255,139,141,233,41,209,193,252,233,3,133,192,141,65,1,
-  139,106,252,248,15,133,244,32,139,157,233,139,11,15,182,252,233,15,182,205,
-  131,195,4,65,252,255,36,252,238,248,32,137,209,252,247,195,237,15,133,244,
-  249,15,182,107,252,253,72,252,247,213,141,20,252,234,252,233,244,28,248,3,
-  137,221,131,229,252,248,41,252,234,252,233,244,28,248,5,190,237,137,252,239,
-  232,251,1,0,139,149,233,49,192,252,233,244,1,248,74,93,72,137,108,36,8,139,
-  108,36,24,137,92,36,28,137,149,233,255,141,68,194,252,248,137,252,239,137,
-  133,233,232,251,1,22,139,149,233,139,133,233,41,208,193,232,3,131,192,1,72,
-  139,108,36,8,85,195,248,144,255,65,15,182,134,233,168,235,15,133,244,251,
-  168,235,15,133,244,247,168,235,15,132,244,247,65,252,255,142,233,252,233,
-  244,247,255,248,145,65,15,182,134,233,168,235,15,133,244,251,252,233,244,
-  247,248,146,65,15,182,134,233,168,235,15,133,244,251,168,235,15,132,244,251,
-  65,252,255,142,233,15,132,244,247,168,235,15,132,244,251,248,1,255,139,108,
-  36,24,137,149,233,137,222,137,252,239,232,251,1,23,248,3,139,149,233,248,
-  4,15,182,75,252,253,248,5,15,182,107,252,252,15,183,67,252,254,65,252,255,
-  164,253,252,238,233,248,147,131,195,4,139,77,232,137,76,36,4,252,233,244,
-  4,248,148,255,139,106,252,248,139,173,233,15,182,133,233,141,4,194,139,108,
-  36,24,137,149,233,137,133,233,137,222,65,141,190,233,73,137,174,233,137,92,
-  36,28,232,251,1,24,252,233,244,3,255,248,149,137,92,36,28,255,248,150,255,
-  137,92,36,28,131,203,1,248,1,255,141,68,194,252,248,139,108,36,24,137,149,
-  233,137,133,233,137,222,137,252,239,232,251,1,25,199,68,36,28,0,0,0,0,255,
-  131,227,252,254,255,139,149,233,72,137,193,139,133,233,41,208,72,137,205,
-  15,182,75,252,253,193,232,3,131,192,1,252,255,229,248,151,255,65,85,65,84,
-  65,83,65,82,65,81,65,80,87,86,85,72,141,108,36,88,85,83,82,81,80,15,182,69,
-  252,248,138,101,252,240,76,137,125,252,248,76,137,117,252,240,68,139,117,
-  0,65,139,142,233,65,199,134,233,237,65,137,134,233,65,137,142,233,72,129,
-  252,236,239,72,131,197,128,252,242,68,15,17,125,252,248,252,242,68,15,17,
-  117,252,240,252,242,68,15,17,109,232,252,242,68,15,17,101,224,252,242,68,
-  15,17,93,216,252,242,68,15,17,85,208,252,242,68,15,17,77,200,252,242,68,15,
-  17,69,192,252,242,15,17,125,184,252,242,15,17,117,176,252,242,15,17,109,168,
-  252,242,15,17,101,160,252,242,15,17,93,152,252,242,15,17,85,144,252,242,15,
-  17,77,136,252,242,15,17,69,128,65,139,174,233,65,139,150,233,73,137,174,233,
-  65,199,134,233,0,0,0,0,137,149,233,72,137,230,65,141,190,233,232,251,1,26,
-  72,139,141,233,72,129,225,239,72,137,204,137,169,233,139,149,233,139,153,
-  233,252,233,244,247,255,248,152,255,72,131,196,16,248,1,76,139,108,36,8,76,
-  139,36,36,133,192,15,136,244,249,137,68,36,4,68,139,122,252,248,69,139,191,
-  233,69,139,191,233,65,199,134,233,0,0,0,0,65,199,134,233,237,139,3,15,182,
-  204,15,182,232,131,195,4,193,232,16,129,252,253,239,15,130,244,248,139,68,
-  36,4,248,2,65,252,255,36,252,238,248,3,252,247,216,137,252,239,137,198,232,
-  251,1,1,255,248,90,255,217,124,36,4,137,68,36,8,102,184,0,4,102,11,68,36,
-  4,102,37,252,255,252,247,102,137,68,36,6,217,108,36,6,217,252,252,217,108,
-  36,4,139,68,36,8,195,255,248,153,72,184,237,237,102,72,15,110,208,72,184,
+  15,126,197,102,15,126,201,255,211,252,253,252,233,244,89,255,248,143,129,
+  252,248,239,15,130,244,63,129,122,253,4,239,255,248,143,129,252,248,239,15,
+  130,244,63,129,122,253,4,239,15,131,244,63,129,122,253,12,239,15,131,244,
+  63,252,242,15,16,2,252,242,15,16,74,8,72,189,237,237,102,72,15,110,213,252,
+  242,15,88,194,252,242,15,88,202,102,15,126,197,102,15,126,201,255,211,197,
+  252,233,244,89,255,248,144,129,252,248,239,15,130,244,63,129,122,253,4,239,
+  255,248,144,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,
+  129,122,253,12,239,15,131,244,63,252,242,15,16,2,252,242,15,16,74,8,72,189,
+  237,237,102,72,15,110,213,252,242,15,88,194,252,242,15,88,202,102,15,126,
+  197,102,15,126,201,255,211,205,252,233,244,89,248,127,184,237,252,233,244,
+  63,248,129,184,237,248,63,139,108,36,24,139,90,252,252,137,92,36,28,137,149,
+  233,141,68,194,252,248,141,136,233,137,133,233,139,66,252,248,59,141,233,
+  15,135,244,251,137,252,239,252,255,144,233,139,149,233,133,192,15,143,244,
+  78,248,1,255,139,141,233,41,209,193,252,233,3,133,192,141,65,1,139,106,252,
+  248,15,133,244,33,139,157,233,139,11,15,182,252,233,15,182,205,131,195,4,
+  65,252,255,36,252,238,248,33,137,209,252,247,195,237,15,133,244,249,15,182,
+  107,252,253,72,252,247,213,141,20,252,234,252,233,244,28,248,3,137,221,131,
+  229,252,248,41,252,234,252,233,244,28,248,5,190,237,137,252,239,232,251,1,
+  0,139,149,233,49,192,252,233,244,1,248,75,93,72,137,108,36,8,139,108,36,24,
+  137,92,36,28,137,149,233,255,141,68,194,252,248,137,252,239,137,133,233,232,
+  251,1,22,139,149,233,139,133,233,41,208,193,232,3,131,192,1,72,139,108,36,
+  8,85,195,248,145,255,65,15,182,134,233,168,235,15,133,244,251,168,235,15,
+  133,244,247,168,235,15,132,244,247,65,252,255,142,233,252,233,244,247,255,
+  248,146,65,15,182,134,233,168,235,15,133,244,251,252,233,244,247,248,147,
+  65,15,182,134,233,168,235,15,133,244,251,168,235,15,132,244,251,65,252,255,
+  142,233,15,132,244,247,168,235,15,132,244,251,248,1,255,139,108,36,24,137,
+  149,233,137,222,137,252,239,232,251,1,23,248,3,139,149,233,248,4,15,182,75,
+  252,253,248,5,15,182,107,252,252,15,183,67,252,254,65,252,255,164,253,252,
+  238,233,248,148,131,195,4,139,77,232,137,76,36,4,252,233,244,4,248,149,255,
+  139,106,252,248,139,173,233,15,182,133,233,141,4,194,139,108,36,24,137,149,
+  233,137,133,233,137,222,65,141,190,233,73,137,174,233,137,92,36,28,232,251,
+  1,24,252,233,244,3,255,248,150,137,92,36,28,255,248,151,255,137,92,36,28,
+  131,203,1,248,1,255,141,68,194,252,248,139,108,36,24,137,149,233,137,133,
+  233,137,222,137,252,239,232,251,1,25,199,68,36,28,0,0,0,0,255,131,227,252,
+  254,255,139,149,233,72,137,193,139,133,233,41,208,72,137,205,15,182,75,252,
+  253,193,232,3,131,192,1,252,255,229,248,152,255,65,85,65,84,65,83,65,82,65,
+  81,65,80,87,86,85,72,141,108,36,88,85,83,82,81,80,15,182,69,252,248,138,101,
+  252,240,76,137,125,252,248,76,137,117,252,240,68,139,117,0,65,139,142,233,
+  65,199,134,233,237,65,137,134,233,65,137,142,233,72,129,252,236,239,72,131,
+  197,128,252,242,68,15,17,125,252,248,252,242,68,15,17,117,252,240,252,242,
+  68,15,17,109,232,252,242,68,15,17,101,224,252,242,68,15,17,93,216,252,242,
+  68,15,17,85,208,252,242,68,15,17,77,200,252,242,68,15,17,69,192,252,242,15,
+  17,125,184,252,242,15,17,117,176,252,242,15,17,109,168,252,242,15,17,101,
+  160,252,242,15,17,93,152,252,242,15,17,85,144,252,242,15,17,77,136,252,242,
+  15,17,69,128,65,139,174,233,65,139,150,233,73,137,174,233,65,199,134,233,
+  0,0,0,0,137,149,233,72,137,230,65,141,190,233,232,251,1,26,72,139,141,233,
+  72,129,225,239,72,137,204,137,169,233,139,149,233,139,153,233,252,233,244,
+  247,255,248,153,255,72,131,196,16,248,1,76,139,108,36,8,76,139,36,36,133,
+  192,15,136,244,249,137,68,36,4,68,139,122,252,248,69,139,191,233,69,139,191,
+  233,65,199,134,233,0,0,0,0,65,199,134,233,237,139,3,15,182,204,15,182,232,
+  131,195,4,193,232,16,129,252,253,239,15,130,244,248,139,68,36,4,248,2,65,
+  252,255,36,252,238,248,3,252,247,216,137,252,239,137,198,232,251,1,1,255,
+  248,91,255,217,124,36,4,137,68,36,8,102,184,0,4,102,11,68,36,4,102,37,252,
+  255,252,247,102,137,68,36,6,217,108,36,6,217,252,252,217,108,36,4,139,68,
+  36,8,195,255,248,154,72,184,237,237,102,72,15,110,208,72,184,237,237,102,
+  72,15,110,216,15,40,200,102,15,84,202,102,15,46,217,15,134,244,247,102,15,
+  85,208,252,242,15,88,203,252,242,15,92,203,102,15,86,202,72,184,237,237,102,
+  72,15,110,208,252,242,15,194,193,1,102,15,84,194,252,242,15,92,200,15,40,
+  193,248,1,195,248,93,255,217,124,36,4,137,68,36,8,102,184,0,8,102,11,68,36,
+  4,102,37,252,255,252,251,102,137,68,36,6,217,108,36,6,217,252,252,217,108,
+  36,4,139,68,36,8,195,255,248,155,72,184,237,237,102,72,15,110,208,72,184,
   237,237,102,72,15,110,216,15,40,200,102,15,84,202,102,15,46,217,15,134,244,
   247,102,15,85,208,252,242,15,88,203,252,242,15,92,203,102,15,86,202,72,184,
-  237,237,102,72,15,110,208,252,242,15,194,193,1,102,15,84,194,252,242,15,92,
-  200,15,40,193,248,1,195,248,92,255,217,124,36,4,137,68,36,8,102,184,0,8,102,
-  11,68,36,4,102,37,252,255,252,251,102,137,68,36,6,217,108,36,6,217,252,252,
-  217,108,36,4,139,68,36,8,195,255,248,154,72,184,237,237,102,72,15,110,208,
-  72,184,237,237,102,72,15,110,216,15,40,200,102,15,84,202,102,15,46,217,15,
-  134,244,247,102,15,85,208,252,242,15,88,203,252,242,15,92,203,102,15,86,202,
-  72,184,237,237,102,72,15,110,208,252,242,15,194,193,6,102,15,84,194,252,242,
-  15,92,200,15,40,193,248,1,195,248,113,255,217,124,36,4,137,68,36,8,102,184,
-  0,12,102,11,68,36,4,102,137,68,36,6,217,108,36,6,217,252,252,217,108,36,4,
-  139,68,36,8,195,255,248,155,72,184,237,237,102,72,15,110,208,72,184,237,237,
-  102,72,15,110,216,15,40,200,102,15,84,202,102,15,46,217,15,134,244,247,102,
-  15,85,208,15,40,193,252,242,15,88,203,252,242,15,92,203,72,184,237,237,102,
-  72,15,110,216,252,242,15,194,193,1,102,15,84,195,252,242,15,92,200,102,15,
-  86,202,15,40,193,248,1,195,248,156,255,15,40,232,252,242,15,94,193,72,184,
-  237,237,102,72,15,110,208,72,184,237,237,102,72,15,110,216,15,40,224,102,
-  15,84,226,102,15,46,220,15,134,244,247,102,15,85,208,252,242,15,88,227,252,
-  242,15,92,227,102,15,86,226,72,184,237,237,102,72,15,110,208,252,242,15,194,
-  196,1,102,15,84,194,252,242,15,92,224,15,40,197,252,242,15,89,204,252,242,
-  15,92,193,195,248,1,252,242,15,89,200,15,40,197,252,242,15,92,193,195,255,
-  217,193,216,252,241,217,124,36,4,102,184,0,4,102,11,68,36,4,102,37,252,255,
-  252,247,102,137,68,36,6,217,108,36,6,217,252,252,217,108,36,4,222,201,222,
-  252,233,195,255,248,97,217,252,234,222,201,248,157,217,84,36,252,248,129,
-  124,36,252,248,0,0,128,127,15,132,244,247,129,124,36,252,248,0,0,128,252,
-  255,15,132,244,248,248,158,217,192,217,252,252,220,252,233,217,201,217,252,
-  240,217,232,222,193,217,252,253,221,217,248,1,195,248,2,221,216,217,252,238,
-  195,255,248,116,255,248,159,252,242,15,45,193,252,242,15,42,208,102,15,46,
-  202,15,133,244,254,15,138,244,255,248,160,131,252,248,1,15,142,244,252,248,
-  1,169,1,0,0,0,15,133,244,248,252,242,15,89,192,209,232,252,233,244,1,248,
-  2,209,232,15,132,244,251,15,40,200,248,3,252,242,15,89,192,209,232,15,132,
-  244,250,15,131,244,3,255,252,242,15,89,200,252,233,244,3,248,4,252,242,15,
-  89,193,248,5,195,248,6,15,132,244,5,15,130,244,253,252,247,216,232,244,1,
-  72,184,237,237,102,72,15,110,200,252,242,15,94,200,15,40,193,195,248,7,72,
-  184,237,237,102,72,15,110,192,195,248,8,102,72,15,126,200,72,209,224,72,193,
-  192,12,72,61,252,254,15,0,0,15,132,244,248,102,72,15,126,192,72,209,224,15,
-  132,244,250,255,72,193,192,12,72,61,252,254,15,0,0,15,132,244,251,252,242,
-  15,17,76,36,252,240,252,242,15,17,68,36,252,248,221,68,36,252,240,221,68,
-  36,252,248,217,252,241,217,192,217,252,252,220,252,233,217,201,217,252,240,
-  217,232,222,193,217,252,253,221,217,221,92,36,252,248,252,242,15,16,68,36,
-  252,248,195,248,9,72,184,237,237,102,72,15,110,208,102,15,46,194,15,132,244,
-  247,15,40,193,248,1,195,248,2,72,184,237,237,102,72,15,110,208,102,15,84,
-  194,72,184,237,237,102,72,15,110,208,102,15,46,194,15,132,244,1,102,15,80,
-  193,15,87,192,136,196,15,146,208,48,224,15,133,244,1,248,3,72,184,237,237,
-  255,102,72,15,110,192,195,248,4,102,15,80,193,133,192,15,133,244,3,15,87,
-  192,195,248,5,102,15,80,193,133,192,15,132,244,3,15,87,192,195,248,161,255,
-  131,252,255,1,15,130,244,90,15,132,244,92,131,252,255,3,15,130,244,113,15,
-  135,244,248,252,242,15,81,192,195,248,2,252,242,15,17,68,36,252,248,221,68,
-  36,252,248,131,252,255,5,15,135,244,248,15,132,244,247,232,244,97,252,233,
-  244,253,248,1,232,244,157,255,252,233,244,253,248,2,131,252,255,7,15,132,
-  244,247,15,135,244,248,217,252,237,217,201,217,252,241,252,233,244,253,248,
-  1,217,232,217,201,217,252,241,252,233,244,253,248,2,131,252,255,9,15,132,
-  244,247,15,135,244,248,217,252,236,217,201,217,252,241,252,233,244,253,248,
-  1,255,217,252,254,252,233,244,253,248,2,131,252,255,11,15,132,244,247,15,
-  135,244,255,217,252,255,252,233,244,253,248,1,217,252,242,221,216,248,7,221,
-  92,36,252,248,252,242,15,16,68,36,252,248,195,255,139,124,36,12,221,68,36,
-  4,131,252,255,1,15,130,244,90,15,132,244,92,131,252,255,3,15,130,244,113,
-  15,135,244,248,217,252,250,195,248,2,131,252,255,5,15,130,244,97,15,132,244,
-  157,131,252,255,7,15,132,244,247,15,135,244,248,217,252,237,217,201,217,252,
+  237,237,102,72,15,110,208,252,242,15,194,193,6,102,15,84,194,252,242,15,92,
+  200,15,40,193,248,1,195,248,114,255,217,124,36,4,137,68,36,8,102,184,0,12,
+  102,11,68,36,4,102,137,68,36,6,217,108,36,6,217,252,252,217,108,36,4,139,
+  68,36,8,195,255,248,156,72,184,237,237,102,72,15,110,208,72,184,237,237,102,
+  72,15,110,216,15,40,200,102,15,84,202,102,15,46,217,15,134,244,247,102,15,
+  85,208,15,40,193,252,242,15,88,203,252,242,15,92,203,72,184,237,237,102,72,
+  15,110,216,252,242,15,194,193,1,102,15,84,195,252,242,15,92,200,102,15,86,
+  202,15,40,193,248,1,195,248,157,255,15,40,232,252,242,15,94,193,72,184,237,
+  237,102,72,15,110,208,72,184,237,237,102,72,15,110,216,15,40,224,102,15,84,
+  226,102,15,46,220,15,134,244,247,102,15,85,208,252,242,15,88,227,252,242,
+  15,92,227,102,15,86,226,72,184,237,237,102,72,15,110,208,252,242,15,194,196,
+  1,102,15,84,194,252,242,15,92,224,15,40,197,252,242,15,89,204,252,242,15,
+  92,193,195,248,1,252,242,15,89,200,15,40,197,252,242,15,92,193,195,255,217,
+  193,216,252,241,217,124,36,4,102,184,0,4,102,11,68,36,4,102,37,252,255,252,
+  247,102,137,68,36,6,217,108,36,6,217,252,252,217,108,36,4,222,201,222,252,
+  233,195,255,248,98,217,252,234,222,201,248,158,217,84,36,252,248,129,124,
+  36,252,248,0,0,128,127,15,132,244,247,129,124,36,252,248,0,0,128,252,255,
+  15,132,244,248,248,159,217,192,217,252,252,220,252,233,217,201,217,252,240,
+  217,232,222,193,217,252,253,221,217,248,1,195,248,2,221,216,217,252,238,195,
+  255,248,117,255,248,160,252,242,15,45,193,252,242,15,42,208,102,15,46,202,
+  15,133,244,254,15,138,244,255,248,161,131,252,248,1,15,142,244,252,248,1,
+  169,1,0,0,0,15,133,244,248,252,242,15,89,192,209,232,252,233,244,1,248,2,
+  209,232,15,132,244,251,15,40,200,248,3,252,242,15,89,192,209,232,15,132,244,
+  250,15,131,244,3,255,252,242,15,89,200,252,233,244,3,248,4,252,242,15,89,
+  193,248,5,195,248,6,15,132,244,5,15,130,244,253,252,247,216,232,244,1,72,
+  184,237,237,102,72,15,110,200,252,242,15,94,200,15,40,193,195,248,7,72,184,
+  237,237,102,72,15,110,192,195,248,8,102,72,15,126,200,72,209,224,72,193,192,
+  12,72,61,252,254,15,0,0,15,132,244,248,102,72,15,126,192,72,209,224,15,132,
+  244,250,255,72,193,192,12,72,61,252,254,15,0,0,15,132,244,251,252,242,15,
+  17,76,36,252,240,252,242,15,17,68,36,252,248,221,68,36,252,240,221,68,36,
+  252,248,217,252,241,217,192,217,252,252,220,252,233,217,201,217,252,240,217,
+  232,222,193,217,252,253,221,217,221,92,36,252,248,252,242,15,16,68,36,252,
+  248,195,248,9,72,184,237,237,102,72,15,110,208,102,15,46,194,15,132,244,247,
+  15,40,193,248,1,195,248,2,72,184,237,237,102,72,15,110,208,102,15,84,194,
+  72,184,237,237,102,72,15,110,208,102,15,46,194,15,132,244,1,102,15,80,193,
+  15,87,192,136,196,15,146,208,48,224,15,133,244,1,248,3,72,184,237,237,255,
+  102,72,15,110,192,195,248,4,102,15,80,193,133,192,15,133,244,3,15,87,192,
+  195,248,5,102,15,80,193,133,192,15,132,244,3,15,87,192,195,248,162,255,131,
+  252,255,1,15,130,244,91,15,132,244,93,131,252,255,3,15,130,244,114,15,135,
+  244,248,252,242,15,81,192,195,248,2,252,242,15,17,68,36,252,248,221,68,36,
+  252,248,131,252,255,5,15,135,244,248,15,132,244,247,232,244,98,252,233,244,
+  253,248,1,232,244,158,255,252,233,244,253,248,2,131,252,255,7,15,132,244,
+  247,15,135,244,248,217,252,237,217,201,217,252,241,252,233,244,253,248,1,
+  217,232,217,201,217,252,241,252,233,244,253,248,2,131,252,255,9,15,132,244,
+  247,15,135,244,248,217,252,236,217,201,217,252,241,252,233,244,253,248,1,
+  255,217,252,254,252,233,244,253,248,2,131,252,255,11,15,132,244,247,15,135,
+  244,255,217,252,255,252,233,244,253,248,1,217,252,242,221,216,248,7,221,92,
+  36,252,248,252,242,15,16,68,36,252,248,195,255,139,124,36,12,221,68,36,4,
+  131,252,255,1,15,130,244,91,15,132,244,93,131,252,255,3,15,130,244,114,15,
+  135,244,248,217,252,250,195,248,2,131,252,255,5,15,130,244,98,15,132,244,
+  158,131,252,255,7,15,132,244,247,15,135,244,248,217,252,237,217,201,217,252,
   241,195,248,1,217,232,217,201,217,252,241,195,248,2,131,252,255,9,15,132,
   244,247,255,15,135,244,248,217,252,236,217,201,217,252,241,195,248,1,217,
   252,254,195,248,2,131,252,255,11,15,132,244,247,15,135,244,255,217,252,255,
-  195,248,1,217,252,242,221,216,195,255,248,9,204,255,248,162,255,131,252,255,
+  195,248,1,217,252,242,221,216,195,255,248,9,204,255,248,163,255,131,252,255,
   1,15,132,244,247,15,135,244,248,252,242,15,88,193,195,248,1,252,242,15,92,
   193,195,248,2,131,252,255,3,15,132,244,247,15,135,244,248,252,242,15,89,193,
-  195,248,1,252,242,15,94,193,195,248,2,131,252,255,5,15,130,244,156,15,132,
-  244,116,131,252,255,7,15,132,244,247,15,135,244,248,72,184,237,237,255,102,
+  195,248,1,252,242,15,94,193,195,248,2,131,252,255,5,15,130,244,157,15,132,
+  244,117,131,252,255,7,15,132,244,247,15,135,244,248,72,184,237,237,255,102,
   72,15,110,200,15,87,193,195,248,1,72,184,237,237,102,72,15,110,200,15,84,
   193,195,248,2,131,252,255,9,15,135,244,248,252,242,15,17,68,36,252,248,252,
   242,15,17,76,36,252,240,221,68,36,252,248,221,68,36,252,240,15,132,244,247,
@@ -481,318 +482,328 @@ static const unsigned char build_actionlist[16156] = {
   9,204,255,139,68,36,20,221,68,36,4,221,68,36,12,131,252,248,1,15,132,244,
   247,15,135,244,248,222,193,195,248,1,222,252,233,195,248,2,131,252,248,3,
   15,132,244,247,15,135,244,248,222,201,195,248,1,222,252,249,195,248,2,131,
-  252,248,5,15,130,244,156,15,132,244,116,131,252,248,7,15,132,244,247,15,135,
+  252,248,5,15,130,244,157,15,132,244,117,131,252,248,7,15,132,244,247,15,135,
   244,248,255,221,216,217,224,195,248,1,221,216,217,225,195,248,2,131,252,248,
   9,15,132,244,247,15,135,244,248,217,252,243,195,248,1,217,201,217,252,253,
   221,217,195,248,2,131,252,248,11,15,132,244,247,15,135,244,255,255,219,252,
   233,219,209,221,217,195,248,1,219,252,233,218,209,221,217,195,255,221,225,
   223,224,252,246,196,1,15,132,244,248,217,201,248,2,221,216,195,248,1,221,
   225,223,224,252,246,196,1,15,133,244,248,217,201,248,2,221,216,195,255,248,
-  163,137,252,248,83,15,162,137,6,137,94,4,137,78,8,137,86,12,91,195,248,164,
-  255,85,72,137,229,83,72,137,252,251,139,131,233,72,41,196,255,15,182,139,
-  233,131,252,233,1,15,136,244,248,248,1,72,139,132,253,203,233,72,137,132,
-  253,204,233,131,252,233,1,15,137,244,1,248,2,15,182,131,233,72,139,187,233,
-  72,139,179,233,72,139,147,233,72,139,139,233,76,139,131,233,76,139,139,233,
-  133,192,15,132,244,251,15,40,131,233,15,40,139,233,255,15,40,147,233,15,40,
-  155,233,131,252,248,4,15,134,244,251,15,40,163,233,15,40,171,233,15,40,179,
-  233,15,40,187,233,248,5,252,255,147,233,72,137,131,233,15,41,131,233,72,137,
-  147,233,15,41,139,233,255,72,139,93,252,248,201,195,255,248,165,255,249,255,
-  129,124,253,202,4,239,15,133,244,253,129,124,253,194,4,239,15,133,244,254,
-  139,44,202,131,195,4,59,44,194,255,15,141,244,255,255,15,140,244,255,255,
-  15,143,244,255,255,15,142,244,255,255,248,6,15,183,67,252,254,141,156,253,
-  131,233,248,9,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,
-  36,252,238,248,7,15,135,244,43,129,124,253,194,4,239,15,130,244,247,15,133,
-  244,43,255,252,242,15,42,4,194,252,233,244,248,255,221,4,202,219,4,194,252,
-  233,244,249,255,248,8,15,135,244,43,255,252,242,15,42,12,202,252,242,15,16,
-  4,194,131,195,4,102,15,46,193,255,15,134,244,9,255,15,135,244,9,255,15,130,
-  244,9,255,15,131,244,9,255,252,233,244,6,255,219,4,202,252,233,244,248,255,
-  129,124,253,202,4,239,15,131,244,43,129,124,253,194,4,239,15,131,244,43,255,
-  248,1,252,242,15,16,4,194,248,2,131,195,4,102,15,46,4,202,248,3,255,248,1,
-  221,4,202,248,2,221,4,194,248,3,131,195,4,255,223,252,233,221,216,255,218,
-  252,233,223,224,158,255,15,134,244,247,255,15,135,244,247,255,15,130,244,
-  247,255,15,131,244,247,255,15,183,67,252,254,141,156,253,131,233,248,1,139,
-  3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,255,139,
-  108,194,4,131,195,4,255,129,252,253,239,15,133,244,253,129,124,253,202,4,
-  239,15,133,244,254,139,44,194,59,44,202,255,15,133,244,255,255,15,132,244,
-  255,255,15,183,67,252,254,141,156,253,131,233,248,9,139,3,15,182,204,15,182,
-  232,131,195,4,193,232,16,65,252,255,36,252,238,248,7,15,135,244,251,129,124,
-  253,202,4,239,15,130,244,247,15,133,244,251,255,252,242,15,42,4,202,255,219,
-  4,202,255,252,233,244,248,248,8,15,135,244,251,255,252,242,15,42,4,194,102,
-  15,46,4,202,255,219,4,194,221,4,202,255,252,233,244,250,255,129,252,253,239,
-  15,131,244,251,129,124,253,202,4,239,15,131,244,251,255,248,1,252,242,15,
-  16,4,202,248,2,102,15,46,4,194,248,4,255,248,1,221,4,202,248,2,221,4,194,
-  248,4,255,15,138,244,248,15,133,244,248,255,15,138,244,248,15,132,244,247,
-  255,248,1,15,183,67,252,254,141,156,253,131,233,248,2,255,248,2,15,183,67,
-  252,254,141,156,253,131,233,248,1,255,252,233,244,9,255,248,5,255,129,252,
-  253,239,15,132,244,48,129,124,253,202,4,239,15,132,244,48,255,57,108,202,
-  4,15,133,244,2,129,252,253,239,15,131,244,1,139,12,202,139,4,194,57,193,15,
-  132,244,1,129,252,253,239,15,135,244,2,139,169,233,133,252,237,15,132,244,
-  2,252,246,133,233,235,15,133,244,2,255,49,252,237,255,189,1,0,0,0,255,252,
-  233,244,47,255,248,3,129,252,253,239,255,15,133,244,9,255,252,233,244,48,
-  255,72,252,247,208,139,108,202,4,131,195,4,129,252,253,239,15,133,244,249,
-  139,12,202,65,59,12,135,255,139,108,202,4,131,195,4,255,129,252,253,239,15,
-  133,244,253,65,129,124,253,199,4,239,15,133,244,254,65,139,44,199,59,44,202,
-  255,15,183,67,252,254,141,156,253,131,233,248,9,139,3,15,182,204,15,182,232,
-  131,195,4,193,232,16,65,252,255,36,252,238,248,7,15,135,244,249,65,129,124,
-  253,199,4,239,15,130,244,247,255,252,242,65,15,42,4,199,255,65,219,4,199,
-  255,252,233,244,248,248,8,255,252,242,15,42,4,202,102,65,15,46,4,199,255,
-  219,4,202,65,221,4,199,255,129,252,253,239,15,131,244,249,255,248,1,252,242,
-  65,15,16,4,199,248,2,102,15,46,4,202,248,4,255,248,1,65,221,4,199,248,2,221,
-  4,202,248,4,255,72,252,247,208,139,108,202,4,131,195,4,57,197,255,15,133,
-  244,249,15,183,67,252,254,141,156,253,131,233,248,2,139,3,15,182,204,15,182,
-  232,131,195,4,193,232,16,65,252,255,36,252,238,248,3,129,252,253,239,15,133,
-  244,2,252,233,244,48,255,15,132,244,248,129,252,253,239,15,132,244,48,15,
-  183,67,252,254,141,156,253,131,233,248,2,139,3,15,182,204,15,182,232,131,
-  195,4,193,232,16,65,252,255,36,252,238,255,139,108,194,4,131,195,4,129,252,
-  253,239,255,137,108,202,4,139,44,194,137,44,202,255,72,139,44,194,72,137,
-  44,202,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,
-  238,255,49,252,237,129,124,253,194,4,239,129,213,239,137,108,202,4,139,3,
-  15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,255,129,
-  124,253,194,4,239,15,133,244,251,139,44,194,252,247,221,15,128,244,250,199,
-  68,202,4,237,137,44,202,248,9,139,3,15,182,204,15,182,232,131,195,4,193,232,
-  16,65,252,255,36,252,238,248,4,199,68,202,4,0,0,224,65,199,4,202,0,0,0,0,
-  252,233,244,9,248,5,15,135,244,53,255,129,124,253,194,4,239,15,131,244,53,
-  255,252,242,15,16,4,194,72,184,237,237,102,72,15,110,200,15,87,193,252,242,
-  15,17,4,202,255,221,4,194,217,224,221,28,202,255,129,124,253,194,4,239,15,
-  133,244,248,139,4,194,255,139,128,233,248,1,199,68,202,4,237,137,4,202,255,
-  15,87,192,252,242,15,42,128,233,248,1,252,242,15,17,4,202,255,219,128,233,
-  248,1,221,28,202,255,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,
-  252,255,36,252,238,248,2,129,124,253,194,4,239,15,133,244,56,139,60,194,255,
-  139,175,233,131,252,253,0,15,133,244,255,248,3,255,248,57,137,213,232,251,
-  1,21,255,252,242,15,42,192,255,137,252,234,15,182,75,252,253,252,233,244,
-  1,255,248,9,252,246,133,233,235,15,133,244,3,252,233,244,56,255,15,182,252,
-  236,15,182,192,255,129,124,253,252,234,4,239,15,133,244,50,65,129,124,253,
-  199,4,239,15,133,244,50,139,44,252,234,65,3,44,199,15,128,244,49,255,129,
-  124,253,252,234,4,239,15,133,244,52,65,129,124,253,199,4,239,15,133,244,52,
-  65,139,4,199,3,4,252,234,15,128,244,51,255,129,124,253,252,234,4,239,15,133,
-  244,55,129,124,253,194,4,239,15,133,244,55,139,44,252,234,3,44,194,15,128,
-  244,54,255,199,68,202,4,237,255,129,124,253,252,234,4,239,15,131,244,50,255,
-  65,129,124,253,199,4,239,15,131,244,50,255,252,242,15,16,4,252,234,252,242,
-  65,15,88,4,199,255,221,4,252,234,65,220,4,199,255,129,124,253,252,234,4,239,
-  15,131,244,52,255,65,129,124,253,199,4,239,15,131,244,52,255,252,242,65,15,
-  16,4,199,252,242,15,88,4,252,234,255,65,221,4,199,220,4,252,234,255,129,124,
-  253,252,234,4,239,15,131,244,55,129,124,253,194,4,239,15,131,244,55,255,252,
-  242,15,16,4,252,234,252,242,15,88,4,194,255,221,4,252,234,220,4,194,255,129,
-  124,253,252,234,4,239,15,133,244,50,65,129,124,253,199,4,239,15,133,244,50,
-  139,44,252,234,65,43,44,199,15,128,244,49,255,129,124,253,252,234,4,239,15,
-  133,244,52,65,129,124,253,199,4,239,15,133,244,52,65,139,4,199,43,4,252,234,
-  15,128,244,51,255,129,124,253,252,234,4,239,15,133,244,55,129,124,253,194,
-  4,239,15,133,244,55,139,44,252,234,43,44,194,15,128,244,54,255,252,242,15,
-  16,4,252,234,252,242,65,15,92,4,199,255,221,4,252,234,65,220,36,199,255,252,
-  242,65,15,16,4,199,252,242,15,92,4,252,234,255,65,221,4,199,220,36,252,234,
-  255,252,242,15,16,4,252,234,252,242,15,92,4,194,255,221,4,252,234,220,36,
-  194,255,129,124,253,252,234,4,239,15,133,244,50,65,129,124,253,199,4,239,
-  15,133,244,50,139,44,252,234,65,15,175,44,199,15,128,244,49,255,129,124,253,
-  252,234,4,239,15,133,244,52,65,129,124,253,199,4,239,15,133,244,52,65,139,
-  4,199,15,175,4,252,234,15,128,244,51,255,129,124,253,252,234,4,239,15,133,
-  244,55,129,124,253,194,4,239,15,133,244,55,139,44,252,234,15,175,44,194,15,
-  128,244,54,255,252,242,15,16,4,252,234,252,242,65,15,89,4,199,255,221,4,252,
-  234,65,220,12,199,255,252,242,65,15,16,4,199,252,242,15,89,4,252,234,255,
-  65,221,4,199,220,12,252,234,255,252,242,15,16,4,252,234,252,242,15,89,4,194,
-  255,221,4,252,234,220,12,194,255,252,242,15,16,4,252,234,252,242,65,15,94,
-  4,199,255,221,4,252,234,65,220,52,199,255,252,242,65,15,16,4,199,252,242,
-  15,94,4,252,234,255,65,221,4,199,220,52,252,234,255,252,242,15,16,4,252,234,
-  252,242,15,94,4,194,255,221,4,252,234,220,52,194,255,252,242,15,16,4,252,
-  234,252,242,65,15,16,12,199,255,221,4,252,234,65,221,4,199,255,252,242,65,
-  15,16,4,199,252,242,15,16,12,252,234,255,65,221,4,199,221,4,252,234,255,252,
-  242,15,16,4,252,234,252,242,15,16,12,194,255,221,4,252,234,221,4,194,255,
-  248,166,232,244,156,255,252,233,244,166,255,232,244,116,255,15,182,252,236,
-  15,182,192,139,124,36,24,137,151,233,141,52,194,137,194,41,252,234,248,35,
-  137,252,253,137,92,36,28,232,251,1,27,139,149,233,133,192,15,133,244,44,15,
-  182,107,252,255,15,182,75,252,253,72,139,4,252,234,72,137,4,202,139,3,15,
-  182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,255,72,252,
-  247,208,65,139,4,135,199,68,202,4,237,137,4,202,139,3,15,182,204,15,182,232,
-  131,195,4,193,232,16,65,252,255,36,252,238,255,15,191,192,199,68,202,4,237,
-  137,4,202,255,15,191,192,252,242,15,42,192,252,242,15,17,4,202,255,223,67,
-  252,254,221,28,202,255,252,242,65,15,16,4,199,252,242,15,17,4,202,255,65,
-  221,4,199,221,28,202,255,72,252,247,208,137,68,202,4,139,3,15,182,204,15,
-  182,232,131,195,4,193,232,16,65,252,255,36,252,238,255,141,76,202,12,141,
-  68,194,4,189,237,137,105,252,248,248,1,137,41,131,193,8,57,193,15,134,244,
-  1,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,
-  255,139,106,252,248,139,172,253,133,233,139,173,233,72,139,69,0,72,137,4,
-  202,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,
-  255,139,106,252,248,139,172,253,141,233,128,189,233,0,139,173,233,139,12,
-  194,139,68,194,4,137,77,0,137,69,4,15,132,244,247,252,246,133,233,235,15,
-  133,244,248,248,1,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,
-  255,36,252,238,248,2,129,232,239,129,252,248,239,15,134,244,1,252,246,129,
-  233,235,15,132,244,1,137,252,238,137,213,65,141,190,233,255,232,251,1,28,
-  137,252,234,252,233,244,1,255,72,252,247,208,139,106,252,248,139,172,253,
-  141,233,65,139,12,135,139,133,233,137,8,199,64,4,237,252,246,133,233,235,
-  15,133,244,248,248,1,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,
-  252,255,36,252,238,248,2,252,246,129,233,235,15,132,244,1,128,189,233,0,15,
-  132,244,1,137,213,137,198,65,141,190,233,232,251,1,28,137,252,234,252,233,
-  244,1,255,139,106,252,248,255,252,242,65,15,16,4,199,255,139,172,253,141,
-  233,139,141,233,255,252,242,15,17,1,255,221,25,255,72,252,247,208,139,106,
-  252,248,139,172,253,141,233,139,141,233,137,65,4,139,3,15,182,204,15,182,
-  232,131,195,4,193,232,16,65,252,255,36,252,238,255,141,156,253,131,233,139,
-  108,36,24,131,189,233,0,15,132,244,247,137,149,233,141,52,202,137,252,239,
-  232,251,1,29,139,149,233,248,1,139,3,15,182,204,15,182,232,131,195,4,193,
-  232,16,65,252,255,36,252,238,255,72,252,247,208,139,108,36,24,137,149,233,
-  139,82,252,248,65,139,52,135,137,252,239,137,92,36,28,232,251,1,30,139,149,
-  233,15,182,75,252,253,137,4,202,199,68,202,4,237,139,3,15,182,204,15,182,
-  232,131,195,4,193,232,16,65,252,255,36,252,238,255,139,108,36,24,137,149,
-  233,65,139,142,233,65,59,142,233,137,92,36,28,15,131,244,251,248,1,137,194,
-  37,252,255,7,0,0,193,252,234,11,61,252,255,7,0,0,15,132,244,249,248,2,137,
-  252,239,137,198,232,251,1,31,139,149,233,15,182,75,252,253,137,4,202,199,
-  68,202,4,237,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,
-  36,252,238,248,3,184,1,8,0,0,252,233,244,2,248,5,137,252,239,232,251,1,32,
-  15,183,67,252,254,252,233,244,1,255,72,252,247,208,139,108,36,24,65,139,142,
-  233,137,92,36,28,65,59,142,233,137,149,233,15,131,244,249,248,2,65,139,52,
-  135,137,252,239,232,251,1,33,139,149,233,15,182,75,252,253,137,4,202,199,
-  68,202,4,237,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,
-  36,252,238,248,3,137,252,239,232,251,1,32,15,183,67,252,254,72,252,247,208,
-  252,233,244,2,255,72,252,247,208,139,106,252,248,139,173,233,65,139,4,135,
-  252,233,244,167,255,72,252,247,208,139,106,252,248,139,173,233,65,139,4,135,
-  252,233,244,168,255,15,182,252,236,15,182,192,129,124,253,252,234,4,239,15,
-  133,244,38,139,44,252,234,255,129,124,253,194,4,239,15,133,244,251,139,4,
-  194,255,129,124,253,194,4,239,15,131,244,251,255,252,242,15,16,4,194,252,
-  242,15,45,192,252,242,15,42,200,102,15,46,193,255,15,133,244,38,255,59,133,
-  233,15,131,244,38,193,224,3,3,133,233,129,120,253,4,239,15,132,244,248,72,
-  139,40,72,137,44,202,248,1,139,3,15,182,204,15,182,232,131,195,4,193,232,
-  16,65,252,255,36,252,238,248,2,131,189,233,0,15,132,244,249,139,141,233,252,
-  246,129,233,235,15,132,244,38,15,182,75,252,253,248,3,199,68,202,4,237,252,
-  233,244,1,248,5,255,129,124,253,194,4,239,15,133,244,38,139,4,194,252,233,
-  244,167,255,15,182,252,236,15,182,192,72,252,247,208,65,139,4,135,129,124,
-  253,252,234,4,239,15,133,244,36,139,44,252,234,248,167,139,141,233,35,136,
-  233,105,201,239,3,141,233,248,1,129,185,233,239,15,133,244,250,57,129,233,
-  15,133,244,250,129,121,253,4,239,15,132,244,251,15,182,67,252,253,72,139,
-  41,72,137,44,194,248,2,255,139,3,15,182,204,15,182,232,131,195,4,193,232,
-  16,65,252,255,36,252,238,248,3,15,182,67,252,253,199,68,194,4,237,252,233,
-  244,2,248,4,139,137,233,133,201,15,133,244,1,248,5,139,141,233,133,201,15,
-  132,244,3,252,246,129,233,235,15,133,244,3,252,233,244,36,255,15,182,252,
-  236,15,182,192,129,124,253,252,234,4,239,15,133,244,37,139,44,252,234,59,
-  133,233,15,131,244,37,193,224,3,3,133,233,129,120,253,4,239,15,132,244,248,
-  72,139,40,72,137,44,202,248,1,139,3,15,182,204,15,182,232,131,195,4,193,232,
-  16,65,252,255,36,252,238,248,2,131,189,233,0,15,132,244,249,139,141,233,252,
-  246,129,233,235,15,132,244,37,255,15,182,75,252,253,248,3,199,68,202,4,237,
-  252,233,244,1,255,15,182,252,236,15,182,192,129,124,253,252,234,4,239,15,
-  133,244,41,139,44,252,234,255,15,133,244,41,255,59,133,233,15,131,244,41,
-  193,224,3,3,133,233,129,120,253,4,239,15,132,244,249,248,1,252,246,133,233,
-  235,15,133,244,253,248,2,72,139,44,202,72,137,40,139,3,15,182,204,15,182,
-  232,131,195,4,193,232,16,65,252,255,36,252,238,248,3,131,189,233,0,15,132,
-  244,1,139,141,233,252,246,129,233,235,255,15,132,244,41,15,182,75,252,253,
-  252,233,244,1,248,5,129,124,253,194,4,239,15,133,244,41,139,4,194,252,233,
-  244,168,248,7,128,165,233,235,65,139,142,233,65,137,174,233,137,141,233,15,
-  182,75,252,253,252,233,244,2,255,15,182,252,236,15,182,192,72,252,247,208,
-  65,139,4,135,129,124,253,252,234,4,239,15,133,244,39,139,44,252,234,248,168,
-  139,141,233,35,136,233,105,201,239,198,133,233,0,3,141,233,248,1,129,185,
-  233,239,15,133,244,251,57,129,233,15,133,244,251,129,121,253,4,239,15,132,
-  244,250,248,2,255,252,246,133,233,235,15,133,244,253,248,3,15,182,67,252,
-  253,72,139,44,194,72,137,41,139,3,15,182,204,15,182,232,131,195,4,193,232,
-  16,65,252,255,36,252,238,248,4,131,189,233,0,15,132,244,2,137,12,36,139,141,
-  233,252,246,129,233,235,15,132,244,39,139,12,36,252,233,244,2,248,5,139,137,
-  233,133,201,15,133,244,1,255,139,141,233,133,201,15,132,244,252,252,246,129,
-  233,235,15,132,244,39,248,6,137,4,36,199,68,36,4,237,137,108,36,8,139,124,
-  36,24,137,151,233,72,141,20,36,137,252,238,137,252,253,137,92,36,28,232,251,
-  1,34,139,149,233,139,108,36,8,137,193,252,233,244,2,248,7,128,165,233,235,
-  65,139,134,233,65,137,174,233,137,133,233,252,233,244,3,255,15,182,252,236,
-  15,182,192,129,124,253,252,234,4,239,15,133,244,40,139,44,252,234,59,133,
-  233,15,131,244,40,193,224,3,3,133,233,129,120,253,4,239,15,132,244,249,248,
-  1,252,246,133,233,235,15,133,244,253,248,2,72,139,12,202,72,137,8,139,3,15,
-  182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,248,3,131,189,
-  233,0,15,132,244,1,255,139,141,233,252,246,129,233,235,15,132,244,40,15,182,
-  75,252,253,252,233,244,1,248,7,128,165,233,235,65,139,142,233,65,137,174,
-  233,137,141,233,15,182,75,252,253,252,233,244,2,255,68,137,60,36,69,139,60,
-  199,248,1,141,12,202,139,105,252,248,252,246,133,233,235,15,133,244,253,248,
-  2,139,68,36,4,131,232,1,15,132,244,250,68,1,252,248,59,133,233,15,135,244,
-  251,68,41,252,248,65,193,231,3,68,3,189,233,248,3,72,139,41,131,193,8,73,
-  137,47,65,131,199,8,131,232,1,15,133,244,3,248,4,68,139,60,36,139,3,15,182,
-  204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,248,5,139,124,36,
-  24,137,151,233,137,252,238,137,194,137,252,253,137,92,36,28,232,251,1,35,
-  139,149,233,15,182,75,252,253,252,233,244,1,248,7,255,128,165,233,235,65,
-  139,134,233,65,137,174,233,137,133,233,252,233,244,2,255,3,68,36,4,255,129,
-  124,253,202,4,239,139,44,202,15,133,244,58,141,84,202,8,137,90,252,252,139,
+  164,137,252,248,83,15,162,137,6,137,94,4,137,78,8,137,86,12,91,195,248,165,
+  255,204,248,166,255,83,65,87,65,86,72,131,252,236,40,68,141,181,233,139,157,
+  233,15,183,192,137,131,233,72,137,187,233,72,137,179,233,72,137,147,233,72,
+  137,139,233,252,242,15,17,131,233,252,242,15,17,139,233,252,242,15,17,147,
+  233,252,242,15,17,155,233,72,141,132,253,36,233,76,137,131,233,76,137,139,
+  233,252,242,15,17,163,233,252,242,15,17,171,233,252,242,15,17,179,233,252,
+  242,15,17,187,233,72,137,131,233,72,137,230,137,92,36,28,137,223,232,251,
+  1,27,65,199,134,233,237,255,139,144,233,139,128,233,41,208,139,106,252,248,
+  193,232,3,131,192,1,139,157,233,139,11,15,182,252,233,15,182,205,131,195,
+  4,65,252,255,36,252,238,255,248,32,255,139,76,36,24,65,139,158,233,72,137,
+  139,233,137,145,233,137,169,233,137,223,137,198,232,251,1,28,72,139,131,233,
+  252,242,15,16,131,233,252,233,244,16,255,248,167,255,85,72,137,229,83,72,
+  137,252,251,139,131,233,72,41,196,255,15,182,139,233,131,252,233,1,15,136,
+  244,248,248,1,72,139,132,253,203,233,72,137,132,253,204,233,131,252,233,1,
+  15,137,244,1,248,2,15,182,131,233,72,139,187,233,72,139,179,233,72,139,147,
+  233,72,139,139,233,76,139,131,233,76,139,139,233,133,192,15,132,244,251,15,
+  40,131,233,15,40,139,233,255,15,40,147,233,15,40,155,233,131,252,248,4,15,
+  134,244,251,15,40,163,233,15,40,171,233,15,40,179,233,15,40,187,233,248,5,
+  252,255,147,233,72,137,131,233,15,41,131,233,72,137,147,233,15,41,139,233,
+  255,72,139,93,252,248,201,195,255,129,124,253,202,4,239,15,133,244,253,129,
+  124,253,194,4,239,15,133,244,254,139,44,202,131,195,4,59,44,194,255,15,141,
+  244,255,255,15,140,244,255,255,15,143,244,255,255,15,142,244,255,255,248,
+  6,15,183,67,252,254,141,156,253,131,233,248,9,139,3,15,182,204,15,182,232,
+  131,195,4,193,232,16,65,252,255,36,252,238,248,7,15,135,244,44,129,124,253,
+  194,4,239,15,130,244,247,15,133,244,44,255,252,242,15,42,4,194,252,233,244,
+  248,255,221,4,202,219,4,194,252,233,244,249,255,248,8,15,135,244,44,255,252,
+  242,15,42,12,202,252,242,15,16,4,194,131,195,4,102,15,46,193,255,15,134,244,
+  9,255,15,135,244,9,255,15,130,244,9,255,15,131,244,9,255,252,233,244,6,255,
+  219,4,202,252,233,244,248,255,129,124,253,202,4,239,15,131,244,44,129,124,
+  253,194,4,239,15,131,244,44,255,248,1,252,242,15,16,4,194,248,2,131,195,4,
+  102,15,46,4,202,248,3,255,248,1,221,4,202,248,2,221,4,194,248,3,131,195,4,
+  255,223,252,233,221,216,255,218,252,233,223,224,158,255,15,135,244,247,255,
+  15,130,244,247,255,15,131,244,247,255,15,183,67,252,254,141,156,253,131,233,
+  248,1,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,
+  238,255,139,108,194,4,131,195,4,255,129,252,253,239,15,133,244,253,129,124,
+  253,202,4,239,15,133,244,254,139,44,194,59,44,202,255,15,133,244,255,255,
+  15,132,244,255,255,15,183,67,252,254,141,156,253,131,233,248,9,139,3,15,182,
+  204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,248,7,15,135,244,
+  251,129,124,253,202,4,239,15,130,244,247,15,133,244,251,255,252,242,15,42,
+  4,202,255,219,4,202,255,252,233,244,248,248,8,15,135,244,251,255,252,242,
+  15,42,4,194,102,15,46,4,202,255,219,4,194,221,4,202,255,252,233,244,250,255,
+  129,252,253,239,15,131,244,251,129,124,253,202,4,239,15,131,244,251,255,248,
+  1,252,242,15,16,4,202,248,2,102,15,46,4,194,248,4,255,248,1,221,4,202,248,
+  2,221,4,194,248,4,255,15,138,244,248,15,133,244,248,255,15,138,244,248,15,
+  132,244,247,255,248,1,15,183,67,252,254,141,156,253,131,233,248,2,255,248,
+  2,15,183,67,252,254,141,156,253,131,233,248,1,255,252,233,244,9,255,248,5,
+  255,129,252,253,239,15,132,244,49,129,124,253,202,4,239,15,132,244,49,255,
+  57,108,202,4,15,133,244,2,129,252,253,239,15,131,244,1,139,12,202,139,4,194,
+  57,193,15,132,244,1,129,252,253,239,15,135,244,2,129,252,253,239,15,130,244,
+  2,139,169,233,133,252,237,15,132,244,2,252,246,133,233,235,15,133,244,2,255,
+  49,252,237,255,189,1,0,0,0,255,252,233,244,48,255,248,3,129,252,253,239,255,
+  15,133,244,9,255,252,233,244,49,255,72,252,247,208,139,108,202,4,131,195,
+  4,129,252,253,239,15,133,244,249,139,12,202,65,59,12,135,255,139,108,202,
+  4,131,195,4,255,129,252,253,239,15,133,244,253,65,129,124,253,199,4,239,15,
+  133,244,254,65,139,44,199,59,44,202,255,15,183,67,252,254,141,156,253,131,
+  233,248,9,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,
+  252,238,248,7,15,135,244,249,65,129,124,253,199,4,239,15,130,244,247,255,
+  252,242,65,15,42,4,199,255,65,219,4,199,255,252,233,244,248,248,8,255,252,
+  242,15,42,4,202,102,65,15,46,4,199,255,219,4,202,65,221,4,199,255,129,252,
+  253,239,15,131,244,249,255,248,1,252,242,65,15,16,4,199,248,2,102,15,46,4,
+  202,248,4,255,248,1,65,221,4,199,248,2,221,4,202,248,4,255,72,252,247,208,
+  139,108,202,4,131,195,4,57,197,255,15,133,244,249,15,183,67,252,254,141,156,
+  253,131,233,248,2,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,
+  255,36,252,238,248,3,129,252,253,239,15,133,244,2,252,233,244,49,255,15,132,
+  244,248,129,252,253,239,15,132,244,49,15,183,67,252,254,141,156,253,131,233,
+  248,2,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,
+  238,255,139,108,194,4,131,195,4,129,252,253,239,255,137,108,202,4,139,44,
+  194,137,44,202,255,72,139,44,194,72,137,44,202,139,3,15,182,204,15,182,232,
+  131,195,4,193,232,16,65,252,255,36,252,238,255,49,252,237,129,124,253,194,
+  4,239,129,213,239,137,108,202,4,139,3,15,182,204,15,182,232,131,195,4,193,
+  232,16,65,252,255,36,252,238,255,129,124,253,194,4,239,15,133,244,251,139,
+  44,194,252,247,221,15,128,244,250,199,68,202,4,237,137,44,202,248,9,139,3,
+  15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,248,4,199,
+  68,202,4,0,0,224,65,199,4,202,0,0,0,0,252,233,244,9,248,5,15,135,244,54,255,
+  129,124,253,194,4,239,15,131,244,54,255,252,242,15,16,4,194,72,184,237,237,
+  102,72,15,110,200,15,87,193,252,242,15,17,4,202,255,221,4,194,217,224,221,
+  28,202,255,129,124,253,194,4,239,15,133,244,248,139,4,194,255,139,128,233,
+  248,1,199,68,202,4,237,137,4,202,255,15,87,192,252,242,15,42,128,233,248,
+  1,252,242,15,17,4,202,255,219,128,233,248,1,221,28,202,255,139,3,15,182,204,
+  15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,248,2,129,124,253,194,
+  4,239,15,133,244,57,139,60,194,255,139,175,233,131,252,253,0,15,133,244,255,
+  248,3,255,248,58,137,213,232,251,1,21,255,252,242,15,42,192,255,137,252,234,
+  15,182,75,252,253,252,233,244,1,255,248,9,252,246,133,233,235,15,133,244,
+  3,252,233,244,57,255,15,182,252,236,15,182,192,255,129,124,253,252,234,4,
+  239,15,133,244,51,65,129,124,253,199,4,239,15,133,244,51,139,44,252,234,65,
+  3,44,199,15,128,244,50,255,129,124,253,252,234,4,239,15,133,244,53,65,129,
+  124,253,199,4,239,15,133,244,53,65,139,4,199,3,4,252,234,15,128,244,52,255,
+  129,124,253,252,234,4,239,15,133,244,56,129,124,253,194,4,239,15,133,244,
+  56,139,44,252,234,3,44,194,15,128,244,55,255,199,68,202,4,237,255,129,124,
+  253,252,234,4,239,15,131,244,51,255,65,129,124,253,199,4,239,15,131,244,51,
+  255,252,242,15,16,4,252,234,252,242,65,15,88,4,199,255,221,4,252,234,65,220,
+  4,199,255,129,124,253,252,234,4,239,15,131,244,53,255,65,129,124,253,199,
+  4,239,15,131,244,53,255,252,242,65,15,16,4,199,252,242,15,88,4,252,234,255,
+  65,221,4,199,220,4,252,234,255,129,124,253,252,234,4,239,15,131,244,56,129,
+  124,253,194,4,239,15,131,244,56,255,252,242,15,16,4,252,234,252,242,15,88,
+  4,194,255,221,4,252,234,220,4,194,255,129,124,253,252,234,4,239,15,133,244,
+  51,65,129,124,253,199,4,239,15,133,244,51,139,44,252,234,65,43,44,199,15,
+  128,244,50,255,129,124,253,252,234,4,239,15,133,244,53,65,129,124,253,199,
+  4,239,15,133,244,53,65,139,4,199,43,4,252,234,15,128,244,52,255,129,124,253,
+  252,234,4,239,15,133,244,56,129,124,253,194,4,239,15,133,244,56,139,44,252,
+  234,43,44,194,15,128,244,55,255,252,242,15,16,4,252,234,252,242,65,15,92,
+  4,199,255,221,4,252,234,65,220,36,199,255,252,242,65,15,16,4,199,252,242,
+  15,92,4,252,234,255,65,221,4,199,220,36,252,234,255,252,242,15,16,4,252,234,
+  252,242,15,92,4,194,255,221,4,252,234,220,36,194,255,129,124,253,252,234,
+  4,239,15,133,244,51,65,129,124,253,199,4,239,15,133,244,51,139,44,252,234,
+  65,15,175,44,199,15,128,244,50,255,129,124,253,252,234,4,239,15,133,244,53,
+  65,129,124,253,199,4,239,15,133,244,53,65,139,4,199,15,175,4,252,234,15,128,
+  244,52,255,129,124,253,252,234,4,239,15,133,244,56,129,124,253,194,4,239,
+  15,133,244,56,139,44,252,234,15,175,44,194,15,128,244,55,255,252,242,15,16,
+  4,252,234,252,242,65,15,89,4,199,255,221,4,252,234,65,220,12,199,255,252,
+  242,65,15,16,4,199,252,242,15,89,4,252,234,255,65,221,4,199,220,12,252,234,
+  255,252,242,15,16,4,252,234,252,242,15,89,4,194,255,221,4,252,234,220,12,
+  194,255,252,242,15,16,4,252,234,252,242,65,15,94,4,199,255,221,4,252,234,
+  65,220,52,199,255,252,242,65,15,16,4,199,252,242,15,94,4,252,234,255,65,221,
+  4,199,220,52,252,234,255,252,242,15,16,4,252,234,252,242,15,94,4,194,255,
+  221,4,252,234,220,52,194,255,252,242,15,16,4,252,234,252,242,65,15,16,12,
+  199,255,221,4,252,234,65,221,4,199,255,252,242,65,15,16,4,199,252,242,15,
+  16,12,252,234,255,65,221,4,199,221,4,252,234,255,252,242,15,16,4,252,234,
+  252,242,15,16,12,194,255,221,4,252,234,221,4,194,255,248,168,232,244,157,
+  255,252,233,244,168,255,232,244,117,255,15,182,252,236,15,182,192,139,124,
+  36,24,137,151,233,141,52,194,137,194,41,252,234,248,36,137,252,253,137,92,
+  36,28,232,251,1,29,139,149,233,133,192,15,133,244,45,15,182,107,252,255,15,
+  182,75,252,253,72,139,4,252,234,72,137,4,202,139,3,15,182,204,15,182,232,
+  131,195,4,193,232,16,65,252,255,36,252,238,255,72,252,247,208,65,139,4,135,
+  199,68,202,4,237,137,4,202,139,3,15,182,204,15,182,232,131,195,4,193,232,
+  16,65,252,255,36,252,238,255,15,191,192,199,68,202,4,237,137,4,202,255,15,
+  191,192,252,242,15,42,192,252,242,15,17,4,202,255,223,67,252,254,221,28,202,
+  255,252,242,65,15,16,4,199,252,242,15,17,4,202,255,65,221,4,199,221,28,202,
+  255,72,252,247,208,137,68,202,4,139,3,15,182,204,15,182,232,131,195,4,193,
+  232,16,65,252,255,36,252,238,255,141,76,202,12,141,68,194,4,189,237,137,105,
+  252,248,248,1,137,41,131,193,8,57,193,15,134,244,1,139,3,15,182,204,15,182,
+  232,131,195,4,193,232,16,65,252,255,36,252,238,255,139,106,252,248,139,172,
+  253,133,233,139,173,233,72,139,69,0,72,137,4,202,139,3,15,182,204,15,182,
+  232,131,195,4,193,232,16,65,252,255,36,252,238,255,139,106,252,248,139,172,
+  253,141,233,128,189,233,0,139,173,233,139,12,194,139,68,194,4,137,77,0,137,
+  69,4,15,132,244,247,252,246,133,233,235,15,133,244,248,248,1,139,3,15,182,
+  204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,248,2,129,232,239,
+  129,252,248,239,15,134,244,1,252,246,129,233,235,15,132,244,1,137,252,238,
+  137,213,65,141,190,233,255,232,251,1,30,137,252,234,252,233,244,1,255,72,
+  252,247,208,139,106,252,248,139,172,253,141,233,65,139,12,135,139,133,233,
+  137,8,199,64,4,237,252,246,133,233,235,15,133,244,248,248,1,139,3,15,182,
+  204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,248,2,252,246,129,
+  233,235,15,132,244,1,128,189,233,0,15,132,244,1,137,213,137,198,65,141,190,
+  233,232,251,1,30,137,252,234,252,233,244,1,255,139,106,252,248,255,252,242,
+  65,15,16,4,199,255,139,172,253,141,233,139,141,233,255,252,242,15,17,1,255,
+  221,25,255,72,252,247,208,139,106,252,248,139,172,253,141,233,139,141,233,
+  137,65,4,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,
+  238,255,141,156,253,131,233,139,108,36,24,131,189,233,0,15,132,244,247,137,
+  149,233,141,52,202,137,252,239,232,251,1,31,139,149,233,248,1,139,3,15,182,
+  204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,255,72,252,247,
+  208,139,108,36,24,137,149,233,139,82,252,248,65,139,52,135,137,252,239,137,
+  92,36,28,232,251,1,32,139,149,233,15,182,75,252,253,137,4,202,199,68,202,
+  4,237,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,
+  238,255,139,108,36,24,137,149,233,65,139,142,233,65,59,142,233,137,92,36,
+  28,15,131,244,251,248,1,137,194,37,252,255,7,0,0,193,252,234,11,61,252,255,
+  7,0,0,15,132,244,249,248,2,137,252,239,137,198,232,251,1,33,139,149,233,15,
+  182,75,252,253,137,4,202,199,68,202,4,237,139,3,15,182,204,15,182,232,131,
+  195,4,193,232,16,65,252,255,36,252,238,248,3,184,1,8,0,0,252,233,244,2,248,
+  5,137,252,239,232,251,1,34,15,183,67,252,254,252,233,244,1,255,72,252,247,
+  208,139,108,36,24,65,139,142,233,137,92,36,28,65,59,142,233,137,149,233,15,
+  131,244,249,248,2,65,139,52,135,137,252,239,232,251,1,35,139,149,233,15,182,
+  75,252,253,137,4,202,199,68,202,4,237,139,3,15,182,204,15,182,232,131,195,
+  4,193,232,16,65,252,255,36,252,238,248,3,137,252,239,232,251,1,34,15,183,
+  67,252,254,72,252,247,208,252,233,244,2,255,72,252,247,208,139,106,252,248,
+  139,173,233,65,139,4,135,252,233,244,169,255,72,252,247,208,139,106,252,248,
+  139,173,233,65,139,4,135,252,233,244,170,255,15,182,252,236,15,182,192,129,
+  124,253,252,234,4,239,15,133,244,39,139,44,252,234,255,129,124,253,194,4,
+  239,15,133,244,251,139,4,194,255,129,124,253,194,4,239,15,131,244,251,255,
+  252,242,15,16,4,194,252,242,15,45,192,252,242,15,42,200,102,15,46,193,255,
+  15,133,244,39,255,59,133,233,15,131,244,39,193,224,3,3,133,233,129,120,253,
+  4,239,15,132,244,248,72,139,40,72,137,44,202,248,1,139,3,15,182,204,15,182,
+  232,131,195,4,193,232,16,65,252,255,36,252,238,248,2,131,189,233,0,15,132,
+  244,249,139,141,233,252,246,129,233,235,15,132,244,39,15,182,75,252,253,248,
+  3,199,68,202,4,237,252,233,244,1,248,5,255,129,124,253,194,4,239,15,133,244,
+  39,139,4,194,252,233,244,169,255,15,182,252,236,15,182,192,72,252,247,208,
+  65,139,4,135,129,124,253,252,234,4,239,15,133,244,37,139,44,252,234,248,169,
+  139,141,233,35,136,233,105,201,239,3,141,233,248,1,129,185,233,239,15,133,
+  244,250,57,129,233,15,133,244,250,129,121,253,4,239,15,132,244,251,15,182,
+  67,252,253,72,139,41,72,137,44,194,248,2,255,139,3,15,182,204,15,182,232,
+  131,195,4,193,232,16,65,252,255,36,252,238,248,3,15,182,67,252,253,199,68,
+  194,4,237,252,233,244,2,248,4,139,137,233,133,201,15,133,244,1,248,5,139,
+  141,233,133,201,15,132,244,3,252,246,129,233,235,15,133,244,3,252,233,244,
+  37,255,15,182,252,236,15,182,192,129,124,253,252,234,4,239,15,133,244,38,
+  139,44,252,234,59,133,233,15,131,244,38,193,224,3,3,133,233,129,120,253,4,
+  239,15,132,244,248,72,139,40,72,137,44,202,248,1,139,3,15,182,204,15,182,
+  232,131,195,4,193,232,16,65,252,255,36,252,238,248,2,131,189,233,0,15,132,
+  244,249,139,141,233,252,246,129,233,235,15,132,244,38,255,15,182,75,252,253,
+  248,3,199,68,202,4,237,252,233,244,1,255,15,182,252,236,15,182,192,129,124,
+  253,252,234,4,239,15,133,244,42,139,44,252,234,255,15,133,244,42,255,59,133,
+  233,15,131,244,42,193,224,3,3,133,233,129,120,253,4,239,15,132,244,249,248,
+  1,252,246,133,233,235,15,133,244,253,248,2,72,139,44,202,72,137,40,139,3,
+  15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,248,3,131,
+  189,233,0,15,132,244,1,139,141,233,252,246,129,233,235,255,15,132,244,42,
+  15,182,75,252,253,252,233,244,1,248,5,129,124,253,194,4,239,15,133,244,42,
+  139,4,194,252,233,244,170,248,7,128,165,233,235,65,139,142,233,65,137,174,
+  233,137,141,233,15,182,75,252,253,252,233,244,2,255,15,182,252,236,15,182,
+  192,72,252,247,208,65,139,4,135,129,124,253,252,234,4,239,15,133,244,40,139,
+  44,252,234,248,170,139,141,233,35,136,233,105,201,239,198,133,233,0,3,141,
+  233,248,1,129,185,233,239,15,133,244,251,57,129,233,15,133,244,251,129,121,
+  253,4,239,15,132,244,250,248,2,255,252,246,133,233,235,15,133,244,253,248,
+  3,15,182,67,252,253,72,139,44,194,72,137,41,139,3,15,182,204,15,182,232,131,
+  195,4,193,232,16,65,252,255,36,252,238,248,4,131,189,233,0,15,132,244,2,137,
+  12,36,139,141,233,252,246,129,233,235,15,132,244,40,139,12,36,252,233,244,
+  2,248,5,139,137,233,133,201,15,133,244,1,255,139,141,233,133,201,15,132,244,
+  252,252,246,129,233,235,15,132,244,40,248,6,137,4,36,199,68,36,4,237,137,
+  108,36,8,139,124,36,24,137,151,233,72,141,20,36,137,252,238,137,252,253,137,
+  92,36,28,232,251,1,36,139,149,233,139,108,36,8,137,193,252,233,244,2,248,
+  7,128,165,233,235,65,139,134,233,65,137,174,233,137,133,233,252,233,244,3,
+  255,15,182,252,236,15,182,192,129,124,253,252,234,4,239,15,133,244,41,139,
+  44,252,234,59,133,233,15,131,244,41,193,224,3,3,133,233,129,120,253,4,239,
+  15,132,244,249,248,1,252,246,133,233,235,15,133,244,253,248,2,72,139,12,202,
+  72,137,8,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,
+  238,248,3,131,189,233,0,15,132,244,1,255,139,141,233,252,246,129,233,235,
+  15,132,244,41,15,182,75,252,253,252,233,244,1,248,7,128,165,233,235,65,139,
+  142,233,65,137,174,233,137,141,233,15,182,75,252,253,252,233,244,2,255,68,
+  137,60,36,69,139,60,199,248,1,141,12,202,139,105,252,248,252,246,133,233,
+  235,15,133,244,253,248,2,139,68,36,4,131,232,1,15,132,244,250,68,1,252,248,
+  59,133,233,15,135,244,251,68,41,252,248,65,193,231,3,68,3,189,233,248,3,72,
+  139,41,131,193,8,73,137,47,65,131,199,8,131,232,1,15,133,244,3,248,4,68,139,
+  60,36,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,
+  238,248,5,139,124,36,24,137,151,233,137,252,238,137,194,137,252,253,137,92,
+  36,28,232,251,1,37,139,149,233,15,182,75,252,253,252,233,244,1,248,7,255,
+  128,165,233,235,65,139,134,233,65,137,174,233,137,133,233,252,233,244,2,255,
+  3,68,36,4,255,129,124,253,202,4,239,139,44,202,15,133,244,59,141,84,202,8,
+  137,90,252,252,139,157,233,139,11,15,182,252,233,15,182,205,131,195,4,65,
+  252,255,36,252,238,255,141,76,202,8,65,137,215,139,105,252,248,129,121,253,
+  252,252,239,15,133,244,29,248,60,139,90,252,252,252,247,195,237,15,133,244,
+  253,248,1,137,106,252,248,137,68,36,4,131,232,1,15,132,244,249,248,2,72,139,
+  41,131,193,8,73,137,47,65,131,199,8,131,232,1,15,133,244,2,139,106,252,248,
+  248,3,139,68,36,4,128,189,233,1,15,135,244,251,248,4,139,157,233,139,11,15,
+  182,252,233,15,182,205,131,195,4,65,252,255,36,252,238,248,5,255,252,247,
+  195,237,15,133,244,4,15,182,75,252,253,72,252,247,209,141,12,202,68,139,121,
+  252,248,69,139,191,233,69,139,191,233,252,233,244,4,248,7,129,252,235,239,
+  252,247,195,237,15,133,244,254,41,218,65,137,215,139,90,252,252,252,233,244,
+  1,248,8,129,195,239,252,233,244,1,255,141,76,202,8,72,139,105,232,72,139,
+  65,252,240,72,137,41,72,137,65,8,139,105,224,139,65,228,137,105,252,248,137,
+  65,252,252,129,252,248,239,184,237,15,133,244,29,137,202,137,90,252,252,139,
   157,233,139,11,15,182,252,233,15,182,205,131,195,4,65,252,255,36,252,238,
-  255,141,76,202,8,65,137,215,139,105,252,248,129,121,253,252,252,239,15,133,
-  244,29,248,59,139,90,252,252,252,247,195,237,15,133,244,253,248,1,137,106,
-  252,248,137,68,36,4,131,232,1,15,132,244,249,248,2,72,139,41,131,193,8,73,
-  137,47,65,131,199,8,131,232,1,15,133,244,2,139,106,252,248,248,3,139,68,36,
-  4,128,189,233,1,15,135,244,251,248,4,139,157,233,139,11,15,182,252,233,15,
-  182,205,131,195,4,65,252,255,36,252,238,248,5,255,252,247,195,237,15,133,
-  244,4,15,182,75,252,253,72,252,247,209,141,12,202,68,139,121,252,248,69,139,
-  191,233,69,139,191,233,252,233,244,4,248,7,129,252,235,239,252,247,195,237,
-  15,133,244,254,41,218,65,137,215,139,90,252,252,252,233,244,1,248,8,129,195,
-  239,252,233,244,1,255,141,76,202,8,72,139,105,232,72,139,65,252,240,72,137,
-  41,72,137,65,8,139,105,224,139,65,228,137,105,252,248,137,65,252,252,129,
-  252,248,239,184,237,15,133,244,29,137,202,137,90,252,252,139,157,233,139,
-  11,15,182,252,233,15,182,205,131,195,4,65,252,255,36,252,238,255,68,137,60,
-  36,68,137,116,36,4,139,108,202,252,240,139,68,202,252,248,68,139,181,233,
-  131,195,4,68,139,189,233,248,1,68,57,252,240,15,131,244,251,65,129,124,253,
-  199,4,239,15,132,244,250,255,219,68,202,252,248,255,73,139,44,199,72,137,
-  108,202,8,131,192,1,255,137,68,202,252,248,248,2,15,183,67,252,254,141,156,
-  253,131,233,248,3,68,139,116,36,4,68,139,60,36,139,3,15,182,204,15,182,232,
-  131,195,4,193,232,16,65,252,255,36,252,238,248,4,131,192,1,255,137,68,202,
-  252,248,255,252,233,244,1,248,5,68,41,252,240,248,6,59,133,233,15,135,244,
-  3,68,105,252,248,239,68,3,189,233,65,129,191,233,239,15,132,244,253,70,141,
-  116,48,1,73,139,175,233,73,139,135,233,72,137,44,202,72,137,68,202,8,68,137,
-  116,202,252,248,252,233,244,2,248,7,131,192,1,252,233,244,6,255,129,124,253,
-  202,252,236,239,15,133,244,251,139,108,202,232,129,124,253,202,252,244,239,
-  15,133,244,251,129,124,253,202,252,252,239,15,133,244,251,128,189,233,235,
-  15,133,244,251,141,156,253,131,233,199,68,202,252,248,0,0,0,0,248,1,139,3,
-  15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,248,5,198,
-  67,252,252,235,141,156,253,131,233,198,3,235,252,233,244,1,255,15,182,252,
-  236,15,182,192,68,137,60,36,68,141,188,253,194,233,141,12,202,68,43,122,252,
-  252,133,252,237,15,132,244,251,141,108,252,233,252,248,65,57,215,15,131,244,
-  248,248,1,73,139,71,252,248,65,131,199,8,72,137,1,131,193,8,57,252,233,15,
-  131,244,249,65,57,215,15,130,244,1,248,2,199,65,4,237,131,193,8,57,252,233,
-  15,130,244,2,248,3,68,139,60,36,139,3,15,182,204,15,182,232,131,195,4,193,
-  232,16,65,252,255,36,252,238,248,5,199,68,36,4,1,0,0,0,137,208,68,41,252,
-  248,15,134,244,3,137,197,193,252,237,3,131,197,1,137,108,36,4,139,108,36,
-  24,1,200,59,133,233,15,135,244,253,248,6,255,73,139,71,252,248,65,131,199,
-  8,72,137,1,131,193,8,65,57,215,15,130,244,6,252,233,244,3,248,7,137,149,233,
-  137,141,233,137,92,36,28,65,41,215,139,116,36,4,131,252,238,1,137,252,239,
-  232,251,1,0,139,149,233,139,141,233,65,1,215,252,233,244,6,255,193,225,3,
-  255,248,1,139,90,252,252,137,68,36,4,252,247,195,237,15,133,244,253,255,248,
-  13,65,137,215,131,232,1,15,132,244,249,248,2,73,139,44,15,73,137,111,252,
-  248,65,131,199,8,131,232,1,15,133,244,2,248,3,139,68,36,4,15,182,107,252,
-  255,248,5,57,197,15,135,244,252,255,72,139,44,10,72,137,106,252,248,255,248,
-  5,56,67,252,255,15,135,244,252,255,15,182,75,252,253,72,252,247,209,141,20,
-  202,68,139,122,252,248,69,139,191,233,69,139,191,233,139,3,15,182,204,15,
-  182,232,131,195,4,193,232,16,65,252,255,36,252,238,248,6,255,65,199,71,252,
-  252,237,65,131,199,8,255,199,68,194,252,244,237,255,131,192,1,252,233,244,
-  5,248,7,141,171,233,252,247,197,237,15,133,244,14,41,252,234,255,1,252,233,
-  255,137,221,209,252,237,129,229,239,102,65,131,172,253,46,233,1,15,132,244,
-  148,255,141,12,202,255,129,121,253,4,239,15,133,244,255,255,129,121,253,12,
-  239,15,133,244,60,129,121,253,20,239,15,133,244,60,139,41,131,121,16,0,15,
-  140,244,251,255,129,121,253,12,239,15,133,244,165,129,121,253,20,239,15,133,
-  244,165,255,139,105,16,133,252,237,15,136,244,251,3,41,15,128,244,247,137,
-  41,255,59,105,8,199,65,28,237,137,105,24,255,15,142,244,253,248,1,248,6,141,
-  156,253,131,233,255,141,156,253,131,233,15,183,67,252,254,15,142,245,248,
-  1,248,6,255,15,143,244,253,248,6,141,156,253,131,233,248,1,255,248,7,139,
-  3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,248,5,
-  255,3,41,15,128,244,1,137,41,255,15,141,244,7,255,141,156,253,131,233,15,
-  183,67,252,254,15,141,245,255,15,140,244,7,255,252,233,244,6,248,9,255,129,
-  121,253,4,239,255,15,131,244,60,129,121,253,12,239,15,131,244,60,255,129,
-  121,253,12,239,15,131,244,165,129,121,253,20,239,15,131,244,165,255,139,105,
-  20,255,129,252,253,239,15,131,244,60,255,252,242,15,16,1,252,242,15,16,73,
-  8,255,252,242,15,88,65,16,252,242,15,17,1,133,252,237,15,136,244,249,255,
-  15,140,244,249,255,102,15,46,200,248,1,252,242,15,17,65,24,255,221,65,8,221,
-  1,255,220,65,16,221,17,221,81,24,133,252,237,15,136,244,247,255,221,81,24,
-  15,140,244,247,255,217,201,248,1,255,15,183,67,252,254,255,15,131,244,7,255,
-  15,131,244,248,141,156,253,131,233,255,141,156,253,131,233,15,183,67,252,
-  254,15,131,245,255,15,130,244,7,255,15,130,244,248,141,156,253,131,233,255,
-  248,3,102,15,46,193,252,233,244,1,255,141,12,202,139,105,4,129,252,253,239,
-  15,132,244,247,255,137,105,252,252,139,41,137,105,252,248,252,233,245,255,
-  141,156,253,131,233,139,1,137,105,252,252,137,65,252,248,255,65,139,142,233,
-  139,4,129,72,139,128,233,139,108,36,24,65,137,150,233,65,137,174,233,76,137,
-  36,36,76,137,108,36,8,72,131,252,236,16,252,255,224,255,141,156,253,131,233,
-  139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,255,
-  137,221,209,252,237,129,229,239,102,65,131,172,253,46,233,1,15,132,244,150,
-  255,68,139,187,233,139,108,36,24,141,12,202,59,141,233,15,135,244,24,15,182,
-  139,233,57,200,15,134,244,249,248,2,255,15,183,67,252,254,252,233,245,255,
-  248,3,199,68,194,252,252,237,131,192,1,57,200,15,134,244,3,252,233,244,2,
-  255,141,44,197,237,141,4,194,68,139,122,252,248,137,104,252,252,68,137,120,
-  252,248,139,108,36,24,141,12,200,59,141,233,15,135,244,23,137,209,137,194,
-  15,182,171,233,133,252,237,15,132,244,248,248,1,131,193,8,57,209,15,131,244,
-  249,68,139,121,252,248,68,137,56,68,139,121,252,252,68,137,120,4,131,192,
-  8,199,65,252,252,237,131,252,237,1,15,133,244,1,248,2,255,68,139,187,233,
-  139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,255,
-  248,3,199,64,4,237,131,192,8,131,252,237,1,15,133,244,3,252,233,244,2,255,
-  139,106,252,248,76,139,189,233,139,108,36,24,141,68,194,252,248,137,149,233,
-  141,136,233,59,141,233,137,133,233,255,76,137,252,254,137,252,239,255,15,
-  135,244,22,65,199,134,233,237,255,65,252,255,215,255,65,252,255,150,233,255,
-  65,199,134,233,237,139,149,233,141,12,194,252,247,217,3,141,233,139,90,252,
-  252,252,233,244,12,255,254,0
+  255,68,137,60,36,68,137,116,36,4,139,108,202,252,240,139,68,202,252,248,68,
+  139,181,233,131,195,4,68,139,189,233,248,1,68,57,252,240,15,131,244,251,65,
+  129,124,253,199,4,239,15,132,244,250,255,219,68,202,252,248,255,73,139,44,
+  199,72,137,108,202,8,131,192,1,255,137,68,202,252,248,248,2,15,183,67,252,
+  254,141,156,253,131,233,248,3,68,139,116,36,4,68,139,60,36,139,3,15,182,204,
+  15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,248,4,131,192,1,255,
+  137,68,202,252,248,255,252,233,244,1,248,5,68,41,252,240,248,6,59,133,233,
+  15,135,244,3,68,105,252,248,239,68,3,189,233,65,129,191,233,239,15,132,244,
+  253,70,141,116,48,1,73,139,175,233,73,139,135,233,72,137,44,202,72,137,68,
+  202,8,68,137,116,202,252,248,252,233,244,2,248,7,131,192,1,252,233,244,6,
+  255,129,124,253,202,252,236,239,15,133,244,251,139,108,202,232,129,124,253,
+  202,252,244,239,15,133,244,251,129,124,253,202,252,252,239,15,133,244,251,
+  128,189,233,235,15,133,244,251,141,156,253,131,233,199,68,202,252,248,0,0,
+  0,0,248,1,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,
+  252,238,248,5,198,67,252,252,235,141,156,253,131,233,198,3,235,252,233,244,
+  1,255,15,182,252,236,15,182,192,68,137,60,36,68,141,188,253,194,233,141,12,
+  202,68,43,122,252,252,133,252,237,15,132,244,251,141,108,252,233,252,248,
+  65,57,215,15,131,244,248,248,1,73,139,71,252,248,65,131,199,8,72,137,1,131,
+  193,8,57,252,233,15,131,244,249,65,57,215,15,130,244,1,248,2,199,65,4,237,
+  131,193,8,57,252,233,15,130,244,2,248,3,68,139,60,36,139,3,15,182,204,15,
+  182,232,131,195,4,193,232,16,65,252,255,36,252,238,248,5,199,68,36,4,1,0,
+  0,0,137,208,68,41,252,248,15,134,244,3,137,197,193,252,237,3,131,197,1,137,
+  108,36,4,139,108,36,24,1,200,59,133,233,15,135,244,253,248,6,255,73,139,71,
+  252,248,65,131,199,8,72,137,1,131,193,8,65,57,215,15,130,244,6,252,233,244,
+  3,248,7,137,149,233,137,141,233,137,92,36,28,65,41,215,139,116,36,4,131,252,
+  238,1,137,252,239,232,251,1,0,139,149,233,139,141,233,65,1,215,252,233,244,
+  6,255,193,225,3,255,248,1,139,90,252,252,137,68,36,4,252,247,195,237,15,133,
+  244,253,255,248,13,65,137,215,131,232,1,15,132,244,249,248,2,73,139,44,15,
+  73,137,111,252,248,65,131,199,8,131,232,1,15,133,244,2,248,3,139,68,36,4,
+  15,182,107,252,255,248,5,57,197,15,135,244,252,255,72,139,44,10,72,137,106,
+  252,248,255,248,5,56,67,252,255,15,135,244,252,255,15,182,75,252,253,72,252,
+  247,209,141,20,202,68,139,122,252,248,69,139,191,233,69,139,191,233,139,3,
+  15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,252,238,248,6,255,
+  65,199,71,252,252,237,65,131,199,8,255,199,68,194,252,244,237,255,131,192,
+  1,252,233,244,5,248,7,141,171,233,252,247,197,237,15,133,244,14,41,252,234,
+  255,1,252,233,255,137,221,209,252,237,129,229,239,102,65,129,172,253,46,233,
+  238,15,130,244,149,255,141,12,202,255,129,121,253,4,239,15,133,244,255,255,
+  129,121,253,12,239,15,133,244,61,129,121,253,20,239,15,133,244,61,139,41,
+  131,121,16,0,15,140,244,251,255,129,121,253,12,239,15,133,244,165,129,121,
+  253,20,239,15,133,244,165,255,139,105,16,133,252,237,15,136,244,251,3,41,
+  15,128,244,247,137,41,255,59,105,8,199,65,28,237,137,105,24,255,15,142,244,
+  253,248,1,248,6,141,156,253,131,233,255,141,156,253,131,233,15,183,67,252,
+  254,15,142,245,248,1,248,6,255,15,143,244,253,248,6,141,156,253,131,233,248,
+  1,255,248,7,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,
+  252,238,248,5,255,3,41,15,128,244,1,137,41,255,15,141,244,7,255,141,156,253,
+  131,233,15,183,67,252,254,15,141,245,255,15,140,244,7,255,252,233,244,6,248,
+  9,255,129,121,253,4,239,255,15,131,244,61,129,121,253,12,239,15,131,244,61,
+  255,129,121,253,12,239,15,131,244,165,129,121,253,20,239,15,131,244,165,255,
+  139,105,20,255,129,252,253,239,15,131,244,61,255,252,242,15,16,1,252,242,
+  15,16,73,8,255,252,242,15,88,65,16,252,242,15,17,1,133,252,237,15,136,244,
+  249,255,15,140,244,249,255,102,15,46,200,248,1,252,242,15,17,65,24,255,221,
+  65,8,221,1,255,220,65,16,221,17,221,81,24,133,252,237,15,136,244,247,255,
+  221,81,24,15,140,244,247,255,217,201,248,1,255,15,183,67,252,254,255,15,131,
+  244,7,255,15,131,244,248,141,156,253,131,233,255,141,156,253,131,233,15,183,
+  67,252,254,15,131,245,255,15,130,244,7,255,15,130,244,248,141,156,253,131,
+  233,255,248,3,102,15,46,193,252,233,244,1,255,141,12,202,139,105,4,129,252,
+  253,239,15,132,244,247,255,137,105,252,252,139,41,137,105,252,248,252,233,
+  245,255,141,156,253,131,233,139,1,137,105,252,252,137,65,252,248,255,65,139,
+  142,233,139,4,129,72,139,128,233,139,108,36,24,65,137,150,233,65,137,174,
+  233,76,137,36,36,76,137,108,36,8,72,131,252,236,16,252,255,224,255,141,156,
+  253,131,233,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,36,
+  252,238,255,137,221,209,252,237,129,229,239,102,65,129,172,253,46,233,238,
+  15,130,244,151,255,68,139,187,233,139,108,36,24,141,12,202,59,141,233,15,
+  135,244,24,15,182,139,233,57,200,15,134,244,249,248,2,255,15,183,67,252,254,
+  252,233,245,255,248,3,199,68,194,252,252,237,131,192,1,57,200,15,134,244,
+  3,252,233,244,2,255,141,44,197,237,141,4,194,68,139,122,252,248,137,104,252,
+  252,68,137,120,252,248,139,108,36,24,141,12,200,59,141,233,15,135,244,23,
+  137,209,137,194,15,182,171,233,133,252,237,15,132,244,248,248,1,131,193,8,
+  57,209,15,131,244,249,68,139,121,252,248,68,137,56,68,139,121,252,252,68,
+  137,120,4,131,192,8,199,65,252,252,237,131,252,237,1,15,133,244,1,248,2,255,
+  68,139,187,233,139,3,15,182,204,15,182,232,131,195,4,193,232,16,65,252,255,
+  36,252,238,255,248,3,199,64,4,237,131,192,8,131,252,237,1,15,133,244,3,252,
+  233,244,2,255,139,106,252,248,76,139,189,233,139,108,36,24,141,68,194,252,
+  248,137,149,233,141,136,233,59,141,233,137,133,233,255,76,137,252,254,137,
+  252,239,255,15,135,244,22,65,199,134,233,237,255,65,252,255,215,255,65,252,
+  255,150,233,255,65,199,134,233,237,139,149,233,141,12,194,252,247,217,3,141,
+  233,139,90,252,252,252,233,244,12,255,254,0
 };
 
 enum {
@@ -818,6 +829,7 @@ enum {
   GLOB_vmeta_call,
   GLOB_vm_call_dispatch_f,
   GLOB_vm_cpcall,
+  GLOB_cont_ffi_callback,
   GLOB_vm_call_tail,
   GLOB_cont_cat,
   GLOB_cont_ra,
@@ -950,8 +962,9 @@ enum {
   GLOB_vm_foldfpm,
   GLOB_vm_foldarith,
   GLOB_vm_cpuid,
-  GLOB_vm_ffi_call,
   GLOB_assert_bad_for_arg_type,
+  GLOB_vm_ffi_callback,
+  GLOB_vm_ffi_call,
   GLOB_BC_MODVN_Z,
   GLOB_BC_TGETS_Z,
   GLOB_BC_TSETS_Z,
@@ -980,6 +993,7 @@ static const char *const globnames[] = {
   "vmeta_call",
   "vm_call_dispatch_f",
   "vm_cpcall",
+  "cont_ffi_callback",
   "vm_call_tail",
   "cont_cat",
   "cont_ra",
@@ -1112,8 +1126,9 @@ static const char *const globnames[] = {
   "vm_foldfpm",
   "vm_foldarith",
   "vm_cpuid",
-  "vm_ffi_call@4",
   "assert_bad_for_arg_type",
+  "vm_ffi_callback",
+  "vm_ffi_call@4",
   "BC_MODVN_Z",
   "BC_TGETS_Z",
   "BC_TSETS_Z",
@@ -1147,6 +1162,8 @@ static const char *const extnames[] = {
   "lj_trace_hot@8",
   "lj_dispatch_call@8",
   "lj_trace_exit@8",
+  "lj_ccallback_enter@8",
+  "lj_ccallback_leave@8",
   "lj_meta_cat",
   "lj_gc_barrieruv@8",
   "lj_func_closeuv@8",
@@ -1187,676 +1204,694 @@ static void build_subroutines(BuildCtx *ctx, int cmov, int sse)
   dasm_put(Dst, 385, Dt1(->top), Dt1(->base), Dt1(->top), Dt7(->pc), FRAME_CP, CFRAME_RESUME, Dt1(->glref), GG_G2DISP, Dt1(->cframe), Dt1(->status), DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->status), Dt1(->base), Dt1(->top), FRAME_TYPE);
   dasm_put(Dst, 548, FRAME_CP, FRAME_C, Dt1(->cframe), Dt1(->cframe), Dt1(->glref), GG_G2DISP, DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base));
   dasm_put(Dst, 648, Dt1(->top), LJ_TFUNC, Dt7(->pc), Dt1(->stack), Dt1(->top), Dt1(->cframe), Dt1(->cframe), FRAME_CP, LJ_TNIL);
-  dasm_put(Dst, 819, 0, Dt7(->pc), PC2PROTO(k), Dt1(->base), LJ_TSTR, BC_GGET, DISPATCH_GL(tmptv), LJ_TTAB);
-  dasm_put(Dst, 944);
+#if LJ_HASFFI
+  dasm_put(Dst, 813);
+#endif
+  dasm_put(Dst, 822, 0);
+#if LJ_HASFFI
+#endif
+  dasm_put(Dst, 831, Dt7(->pc), PC2PROTO(k));
+#if LJ_HASFFI
+  dasm_put(Dst, 848);
+#endif
+  dasm_put(Dst, 869, Dt1(->base), LJ_TSTR, BC_GGET, DISPATCH_GL(tmptv), LJ_TTAB);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 958, LJ_TISNUM);
+    dasm_put(Dst, 967, LJ_TISNUM);
   } else if (sse) {
-    dasm_put(Dst, 967);
+    dasm_put(Dst, 976);
   } else {
   }
-  dasm_put(Dst, 979, Dt1(->base), Dt1(->base), Dt1(->top), FRAME_CONT, 2+1, LJ_TSTR, BC_GSET);
-  dasm_put(Dst, 1125, DISPATCH_GL(tmptv), LJ_TTAB);
+  dasm_put(Dst, 988, Dt1(->base), Dt1(->base), Dt1(->top), FRAME_CONT, 2+1, LJ_TSTR, BC_GSET);
+  dasm_put(Dst, 1134, DISPATCH_GL(tmptv), LJ_TTAB);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 958, LJ_TISNUM);
+    dasm_put(Dst, 967, LJ_TISNUM);
   } else if (sse) {
-    dasm_put(Dst, 967);
+    dasm_put(Dst, 976);
   } else {
   }
-  dasm_put(Dst, 1149, Dt1(->base), Dt1(->base), Dt1(->top), FRAME_CONT, 3+1, Dt1(->base), Dt1(->base));
-  dasm_put(Dst, 1321, -BCBIAS_J*4, LJ_TISTRUECOND, LJ_TISTRUECOND, Dt1(->base));
-  dasm_put(Dst, 1420);
+  dasm_put(Dst, 1158, Dt1(->base), Dt1(->base), Dt1(->top), FRAME_CONT, 3+1, Dt1(->base), Dt1(->base));
+  dasm_put(Dst, 1330, -BCBIAS_J*4, LJ_TISTRUECOND, LJ_TISTRUECOND, Dt1(->base));
+  dasm_put(Dst, 1429);
 #if LJ_HASFFI
-  dasm_put(Dst, 1440, Dt1(->base));
+  dasm_put(Dst, 1449, Dt1(->base));
 #endif
-  dasm_put(Dst, 1471);
+  dasm_put(Dst, 1480);
 #if LJ_DUALNUM
-  dasm_put(Dst, 1474);
+  dasm_put(Dst, 1483);
 #endif
-  dasm_put(Dst, 1480);
+  dasm_put(Dst, 1489);
 #if LJ_DUALNUM
-  dasm_put(Dst, 952);
+  dasm_put(Dst, 961);
 #endif
-  dasm_put(Dst, 1493);
+  dasm_put(Dst, 1502);
 #if LJ_DUALNUM
-  dasm_put(Dst, 1474);
+  dasm_put(Dst, 1483);
 #endif
-  dasm_put(Dst, 1522, Dt1(->base), Dt1(->base), FRAME_CONT, 2+1, Dt1(->base), Dt1(->base));
+  dasm_put(Dst, 1531, Dt1(->base), Dt1(->base), FRAME_CONT, 2+1, Dt1(->base), Dt1(->base));
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-  dasm_put(Dst, 1624);
+  dasm_put(Dst, 1633);
 #else
-  dasm_put(Dst, 1643);
+  dasm_put(Dst, 1652);
 #endif
-  dasm_put(Dst, 1648, Dt1(->base), Dt1(->base), Dt7(->pc), Dt1(->base), Dt1(->base), GG_DISP2STATIC, 1+1, LJ_TISTRUECOND);
-  dasm_put(Dst, 1834, 1+1, ~LJ_TNUMX);
+  dasm_put(Dst, 1657, Dt1(->base), Dt1(->base), Dt7(->pc), Dt1(->base), Dt1(->base), GG_DISP2STATIC, 1+1, LJ_TISTRUECOND);
+  dasm_put(Dst, 1843, 1+1, ~LJ_TNUMX);
   if (cmov) {
-  dasm_put(Dst, 1903);
+  dasm_put(Dst, 1912);
   } else {
-  dasm_put(Dst, 1907);
+  dasm_put(Dst, 1916);
   }
-  dasm_put(Dst, 1916, ((char *)(&((GCfuncC *)0)->upvalue)), LJ_TSTR, ~LJ_TLIGHTUD, 1+1, LJ_TTAB, Dt6(->metatable), LJ_TNIL);
-  dasm_put(Dst, 1995, DISPATCH_GL(gcroot)+4*(GCROOT_MMNAME+MM_metatable), LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), DtB(->next));
-  dasm_put(Dst, 2053, LJ_TNIL, LJ_TUDATA, LJ_TNUMX, LJ_TISNUM, LJ_TLIGHTUD);
-  dasm_put(Dst, 2119, LJ_TNUMX, DISPATCH_GL(gcroot[GCROOT_BASEMT]), 2+1, LJ_TTAB, Dt6(->metatable), LJ_TTAB, Dt6(->metatable), LJ_TTAB);
-  dasm_put(Dst, 2190, Dt6(->marked), LJ_GC_BLACK, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist), 2+1, LJ_TTAB);
-  dasm_put(Dst, 2280, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 1925, ((char *)(&((GCfuncC *)0)->upvalue)), LJ_TSTR, ~LJ_TLIGHTUD, 1+1, LJ_TTAB, Dt6(->metatable), LJ_TNIL);
+  dasm_put(Dst, 2004, DISPATCH_GL(gcroot)+4*(GCROOT_MMNAME+MM_metatable), LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), DtB(->next));
+  dasm_put(Dst, 2062, LJ_TNIL, LJ_TUDATA, LJ_TNUMX, LJ_TISNUM, LJ_TLIGHTUD);
+  dasm_put(Dst, 2128, LJ_TNUMX, DISPATCH_GL(gcroot[GCROOT_BASEMT]), 2+1, LJ_TTAB, Dt6(->metatable), LJ_TTAB, Dt6(->metatable), LJ_TTAB);
+  dasm_put(Dst, 2199, Dt6(->marked), LJ_GC_BLACK, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist), 2+1, LJ_TTAB);
+  dasm_put(Dst, 2289, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 2294);
+    dasm_put(Dst, 2303);
   } else {
-    dasm_put(Dst, 2311);
+    dasm_put(Dst, 2320);
   }
   if (sse) {
-    dasm_put(Dst, 2316);
+    dasm_put(Dst, 2325);
   } else {
-    dasm_put(Dst, 2326);
+    dasm_put(Dst, 2335);
   }
-  dasm_put(Dst, 2333, 1+1, LJ_TSTR, LJ_TSTR, LJ_TISNUM, DISPATCH_GL(gcroot[GCROOT_BASEMT_NUM]), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
-  dasm_put(Dst, 2402, Dt1(->base));
+  dasm_put(Dst, 2342, 1+1, LJ_TSTR, LJ_TSTR, LJ_TISNUM, DISPATCH_GL(gcroot[GCROOT_BASEMT_NUM]), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
+  dasm_put(Dst, 2411, Dt1(->base));
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 2428);
+    dasm_put(Dst, 2437);
   } else {
-    dasm_put(Dst, 2433);
+    dasm_put(Dst, 2442);
   }
-  dasm_put(Dst, 2438, Dt1(->base), 1+1, LJ_TTAB, Dt1(->base), Dt1(->top), Dt1(->base), 1+2);
-  dasm_put(Dst, 2530, LJ_TNIL, LJ_TNIL, 1+1, LJ_TTAB);
+  dasm_put(Dst, 2447, Dt1(->base), 1+1, LJ_TTAB, Dt1(->base), Dt1(->top), Dt1(->base), 1+2);
+  dasm_put(Dst, 2539, LJ_TNIL, LJ_TNIL, 1+1, LJ_TTAB);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-  dasm_put(Dst, 2577, Dt6(->metatable));
+  dasm_put(Dst, 2586, Dt6(->metatable));
 #endif
-  dasm_put(Dst, 2586, Dt8(->upvalue[0]), LJ_TFUNC, LJ_TNIL, 1+3, 1+1, LJ_TTAB, LJ_TISNUM);
+  dasm_put(Dst, 2595, Dt8(->upvalue[0]), LJ_TFUNC, LJ_TNIL, 1+3, 1+1, LJ_TTAB, LJ_TISNUM);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 2572);
+    dasm_put(Dst, 2581);
   } else {
-    dasm_put(Dst, 2311);
+    dasm_put(Dst, 2320);
   }
-  dasm_put(Dst, 2641);
+  dasm_put(Dst, 2650);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 2646, LJ_TISNUM);
+    dasm_put(Dst, 2655, LJ_TISNUM);
   } else if (sse) {
-    dasm_put(Dst, 2662, (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
+    dasm_put(Dst, 2671, (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 2695, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->hmask), 1+0);
-  dasm_put(Dst, 2557, 1+1, LJ_TTAB);
+  dasm_put(Dst, 2704, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->hmask), 1+0);
+  dasm_put(Dst, 2566, 1+1, LJ_TTAB);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-  dasm_put(Dst, 2577, Dt6(->metatable));
+  dasm_put(Dst, 2586, Dt6(->metatable));
 #endif
-  dasm_put(Dst, 2772, Dt8(->upvalue[0]), LJ_TFUNC);
+  dasm_put(Dst, 2781, Dt8(->upvalue[0]), LJ_TFUNC);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 2793, LJ_TISNUM);
+    dasm_put(Dst, 2802, LJ_TISNUM);
   } else if (sse) {
-    dasm_put(Dst, 2805);
-  } else {
-    dasm_put(Dst, 2815);
-  }
-  dasm_put(Dst, 2822, 1+3, 1+1, 8+FRAME_PCALL, DISPATCH_GL(hookmask), HOOK_ACTIVE_SHIFT, 2+1, LJ_TFUNC);
-  dasm_put(Dst, 2887, LJ_TFUNC, 16+FRAME_PCALL, 1+1, LJ_TTHREAD, Dt1(->cframe), Dt1(->status), LUA_YIELD, Dt1(->top));
-  dasm_put(Dst, 2976, Dt1(->base), Dt1(->maxstack), Dt1(->top), Dt1(->base), Dt1(->top), DISPATCH_GL(vmstate), ~LJ_VMST_INTERP);
-  dasm_put(Dst, 3063, Dt1(->base), LUA_YIELD, Dt1(->base), Dt1(->top), Dt1(->top), Dt1(->maxstack), LJ_TTRUE, FRAME_TYPE);
-  dasm_put(Dst, 3178, LJ_TFALSE, Dt1(->top), Dt1(->top), 1+2, Dt1(->top), Dt1(->base), Dt8(->upvalue[0].gcr), Dt1(->cframe));
-  dasm_put(Dst, 3273, Dt1(->status), LUA_YIELD, Dt1(->top), Dt1(->base), Dt1(->maxstack), Dt1(->top), Dt1(->base), Dt1(->top));
-  dasm_put(Dst, 3339, DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base), LUA_YIELD, Dt1(->base), Dt1(->top), Dt1(->top), Dt1(->maxstack));
-  dasm_put(Dst, 3428, FRAME_TYPE, Dt1(->top), Dt1(->base), Dt1(->cframe), CFRAME_RESUME);
-  dasm_put(Dst, 3538, Dt1(->base), Dt1(->top), Dt1(->cframe), LUA_YIELD, Dt1(->status));
+    dasm_put(Dst, 2814);
+  } else {
+    dasm_put(Dst, 2824);
+  }
+  dasm_put(Dst, 2831, 1+3, 1+1, 8+FRAME_PCALL, DISPATCH_GL(hookmask), HOOK_ACTIVE_SHIFT, 2+1, LJ_TFUNC);
+  dasm_put(Dst, 2896, LJ_TFUNC, 16+FRAME_PCALL, 1+1, LJ_TTHREAD, Dt1(->cframe), Dt1(->status), LUA_YIELD, Dt1(->top));
+  dasm_put(Dst, 2985, Dt1(->base), Dt1(->maxstack), Dt1(->top), Dt1(->base), Dt1(->top), DISPATCH_GL(vmstate), ~LJ_VMST_INTERP);
+  dasm_put(Dst, 3072, Dt1(->base), LUA_YIELD, Dt1(->base), Dt1(->top), Dt1(->top), Dt1(->maxstack), LJ_TTRUE, FRAME_TYPE);
+  dasm_put(Dst, 3187, LJ_TFALSE, Dt1(->top), Dt1(->top), 1+2, Dt1(->top), Dt1(->base), Dt8(->upvalue[0].gcr), Dt1(->cframe));
+  dasm_put(Dst, 3282, Dt1(->status), LUA_YIELD, Dt1(->top), Dt1(->base), Dt1(->maxstack), Dt1(->top), Dt1(->base), Dt1(->top));
+  dasm_put(Dst, 3348, DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base), LUA_YIELD, Dt1(->base), Dt1(->top), Dt1(->top), Dt1(->maxstack));
+  dasm_put(Dst, 3437, FRAME_TYPE, Dt1(->top), Dt1(->base), Dt1(->cframe), CFRAME_RESUME);
+  dasm_put(Dst, 3547, Dt1(->base), Dt1(->top), Dt1(->cframe), LUA_YIELD, Dt1(->status));
   if (!LJ_DUALNUM) {
-    dasm_put(Dst, 3565);
+    dasm_put(Dst, 3574);
   }
   if (sse) {
-    dasm_put(Dst, 3568);
+    dasm_put(Dst, 3577);
   }
-  dasm_put(Dst, 3583, 1+1);
+  dasm_put(Dst, 3592, 1+1);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 3594, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 3603, LJ_TISNUM, LJ_TISNUM);
   } else {
-    dasm_put(Dst, 3674, LJ_TISNUM);
+    dasm_put(Dst, 3683, LJ_TISNUM);
   }
   if (sse) {
-    dasm_put(Dst, 3684, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32));
+    dasm_put(Dst, 3693, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32));
   } else {
-    dasm_put(Dst, 3715);
+    dasm_put(Dst, 3724);
   }
-  dasm_put(Dst, 3732, 1+1, FRAME_TYPE, LJ_TNIL);
+  dasm_put(Dst, 3741, 1+1, FRAME_TYPE, LJ_TNIL);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 3829, LJ_TISNUM);
+  dasm_put(Dst, 3838, LJ_TISNUM);
   } else {
-  dasm_put(Dst, 3674, LJ_TISNUM);
+  dasm_put(Dst, 3683, LJ_TISNUM);
   }
   if (sse) {
-  dasm_put(Dst, 3851);
-    if (LJ_DUALNUM) {
   dasm_put(Dst, 3860);
+    if (LJ_DUALNUM) {
+  dasm_put(Dst, 3869);
     }
-  dasm_put(Dst, 2321);
+  dasm_put(Dst, 2330);
   } else {
-  dasm_put(Dst, 3894);
+  dasm_put(Dst, 3903);
     if (LJ_DUALNUM) {
     } else {
-  dasm_put(Dst, 2328);
+  dasm_put(Dst, 2337);
     }
   }
-  dasm_put(Dst, 3900);
+  dasm_put(Dst, 3909);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 3829, LJ_TISNUM);
+  dasm_put(Dst, 3838, LJ_TISNUM);
   } else {
-  dasm_put(Dst, 3674, LJ_TISNUM);
+  dasm_put(Dst, 3683, LJ_TISNUM);
   }
   if (sse) {
-  dasm_put(Dst, 3903);
+  dasm_put(Dst, 3912);
     if (LJ_DUALNUM) {
-  dasm_put(Dst, 3860);
+  dasm_put(Dst, 3869);
     }
-  dasm_put(Dst, 2321);
+  dasm_put(Dst, 2330);
   } else {
-  dasm_put(Dst, 3912);
+  dasm_put(Dst, 3921);
     if (LJ_DUALNUM) {
     } else {
-  dasm_put(Dst, 2328);
+  dasm_put(Dst, 2337);
     }
   }
   if (sse) {
-    dasm_put(Dst, 3918, 1+1, LJ_TISNUM);
+    dasm_put(Dst, 3927, 1+1, LJ_TISNUM);
   } else {
-    dasm_put(Dst, 3947, 1+1, LJ_TISNUM);
+    dasm_put(Dst, 3956, 1+1, LJ_TISNUM);
   }
-  dasm_put(Dst, 3976, 1+1, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1);
-  dasm_put(Dst, 4045, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1);
-  dasm_put(Dst, 4102, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1);
-  dasm_put(Dst, 4165, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1, LJ_TISNUM);
-  dasm_put(Dst, 4255);
+  dasm_put(Dst, 3985, 1+1, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1);
+  dasm_put(Dst, 4054, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1);
+  dasm_put(Dst, 4111, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1);
+  dasm_put(Dst, 4174, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 4264);
   if (sse) {
-  dasm_put(Dst, 4267, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 4276, 1+1, LJ_TISNUM);
   } else {
   }
-  dasm_put(Dst, 4292);
+  dasm_put(Dst, 4301);
   if (sse) {
-  dasm_put(Dst, 4306, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 4315, 1+1, LJ_TISNUM);
   } else {
   }
-  dasm_put(Dst, 4331);
+  dasm_put(Dst, 4340);
   if (sse) {
-  dasm_put(Dst, 4345, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 4354, 1+1, LJ_TISNUM);
   } else {
   }
-  dasm_put(Dst, 4370);
+  dasm_put(Dst, 4379);
   if (sse) {
-    dasm_put(Dst, 4386, 1+1, LJ_TISNUM, Dt8(->upvalue[0]));
+    dasm_put(Dst, 4395, 1+1, LJ_TISNUM, Dt8(->upvalue[0]));
   } else {
-    dasm_put(Dst, 4425, 1+1, LJ_TISNUM, Dt8(->upvalue[0]));
+    dasm_put(Dst, 4434, 1+1, LJ_TISNUM, Dt8(->upvalue[0]));
   }
-  dasm_put(Dst, 4458, 2+1, LJ_TISNUM, LJ_TISNUM, 2+1, LJ_TISNUM, LJ_TISNUM);
-  dasm_put(Dst, 4523, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 4467, 2+1, LJ_TISNUM, LJ_TISNUM, 2+1, LJ_TISNUM, LJ_TISNUM);
+  dasm_put(Dst, 4532, 1+1, LJ_TISNUM);
   if (sse) {
-    dasm_put(Dst, 4622);
+    dasm_put(Dst, 4631);
   } else {
-    dasm_put(Dst, 4628);
+    dasm_put(Dst, 4637);
   }
-  dasm_put(Dst, 4635);
+  dasm_put(Dst, 4644);
   if (sse) {
-    dasm_put(Dst, 4660);
+    dasm_put(Dst, 4669);
   } else {
-    dasm_put(Dst, 4666);
+    dasm_put(Dst, 4675);
   }
-  dasm_put(Dst, 4669, 1+2);
+  dasm_put(Dst, 4678, 1+2);
   if (sse) {
-    dasm_put(Dst, 4678);
+    dasm_put(Dst, 4687);
   } else {
-    dasm_put(Dst, 4686);
+    dasm_put(Dst, 4695);
   }
-  dasm_put(Dst, 4694);
+  dasm_put(Dst, 4703);
   if (sse) {
-    dasm_put(Dst, 4697, (unsigned int)(U64x(43500000,00000000)), (unsigned int)((U64x(43500000,00000000))>>32));
+    dasm_put(Dst, 4706, (unsigned int)(U64x(43500000,00000000)), (unsigned int)((U64x(43500000,00000000))>>32));
   } else {
-    dasm_put(Dst, 4724);
+    dasm_put(Dst, 4733);
   }
-  dasm_put(Dst, 4741);
+  dasm_put(Dst, 4750);
   if (sse) {
-    dasm_put(Dst, 4757, 1+1, LJ_TISNUM);
+    dasm_put(Dst, 4766, 1+1, LJ_TISNUM);
   } else {
-    dasm_put(Dst, 4782, 1+1, LJ_TISNUM);
+    dasm_put(Dst, 4791, 1+1, LJ_TISNUM);
   }
-  dasm_put(Dst, 4804);
+  dasm_put(Dst, 4813);
   if (sse) {
-    dasm_put(Dst, 4826);
+    dasm_put(Dst, 4835);
   } else {
-    dasm_put(Dst, 4852);
+    dasm_put(Dst, 4861);
   }
-  dasm_put(Dst, 4869, 1+2);
+  dasm_put(Dst, 4878, 1+2);
   if (sse) {
-    dasm_put(Dst, 4909);
+    dasm_put(Dst, 4918);
   } else {
-    dasm_put(Dst, 4917);
+    dasm_put(Dst, 4926);
   }
-  dasm_put(Dst, 4927, 2+1, LJ_TISNUM, LJ_TISNUM);
+  dasm_put(Dst, 4936, 2+1, LJ_TISNUM, LJ_TISNUM);
   if (sse) {
-    dasm_put(Dst, 4979, 2+1, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 4988, 2+1, LJ_TISNUM, LJ_TISNUM);
   } else {
-    dasm_put(Dst, 5026, 2+1, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 5035, 2+1, LJ_TISNUM, LJ_TISNUM);
   }
-  dasm_put(Dst, 5067, LJ_TISNUM);
+  dasm_put(Dst, 5076, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 5080, LJ_TISNUM);
+  dasm_put(Dst, 5089, LJ_TISNUM);
   if (sse) {
-  dasm_put(Dst, 4622);
+  dasm_put(Dst, 4631);
   } else {
   }
-  dasm_put(Dst, 5130);
+  dasm_put(Dst, 5139);
   } else {
-  dasm_put(Dst, 2311);
+  dasm_put(Dst, 2320);
   }
   if (sse) {
-  dasm_put(Dst, 5141, LJ_TISNUM);
+  dasm_put(Dst, 5150, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 5162);
+  dasm_put(Dst, 5171);
   } else {
-  dasm_put(Dst, 2311);
+  dasm_put(Dst, 2320);
   }
-  dasm_put(Dst, 5183);
+  dasm_put(Dst, 5192);
   } else {
   }
-  dasm_put(Dst, 5208, LJ_TISNUM);
+  dasm_put(Dst, 5217, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 5221, LJ_TISNUM);
+  dasm_put(Dst, 5230, LJ_TISNUM);
   if (sse) {
-  dasm_put(Dst, 4622);
+  dasm_put(Dst, 4631);
   } else {
   }
-  dasm_put(Dst, 5130);
+  dasm_put(Dst, 5139);
   } else {
-  dasm_put(Dst, 2311);
+  dasm_put(Dst, 2320);
   }
   if (sse) {
-  dasm_put(Dst, 5141, LJ_TISNUM);
+  dasm_put(Dst, 5150, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 5162);
+  dasm_put(Dst, 5171);
   } else {
-  dasm_put(Dst, 2311);
+  dasm_put(Dst, 2320);
   }
-  dasm_put(Dst, 5271);
+  dasm_put(Dst, 5280);
   } else {
   }
   if (!sse) {
-    dasm_put(Dst, 5296);
+    dasm_put(Dst, 5305);
   }
-  dasm_put(Dst, 5305, 1+1, LJ_TSTR);
+  dasm_put(Dst, 5314, 1+1, LJ_TSTR);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 5327, Dt5(->len));
+    dasm_put(Dst, 5336, Dt5(->len));
   } else if (sse) {
-    dasm_put(Dst, 5335, Dt5(->len));
+    dasm_put(Dst, 5344, Dt5(->len));
   } else {
-    dasm_put(Dst, 5346, Dt5(->len));
+    dasm_put(Dst, 5355, Dt5(->len));
   }
-  dasm_put(Dst, 5354, 1+1, LJ_TSTR, Dt5(->len), Dt5([1]));
+  dasm_put(Dst, 5363, 1+1, LJ_TSTR, Dt5(->len), Dt5([1]));
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 5330);
+    dasm_put(Dst, 5339);
   } else if (sse) {
-    dasm_put(Dst, 5392);
+    dasm_put(Dst, 5401);
   } else {
-    dasm_put(Dst, 5402);
+    dasm_put(Dst, 5411);
   }
-  dasm_put(Dst, 5413, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), 1+1, LJ_TISNUM);
+  dasm_put(Dst, 5422, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 5446);
+    dasm_put(Dst, 5455);
   } else if (sse) {
-    dasm_put(Dst, 5469);
+    dasm_put(Dst, 5478);
   } else {
-    dasm_put(Dst, 5495);
+    dasm_put(Dst, 5504);
   }
-  dasm_put(Dst, 5519, Dt1(->base), Dt1(->base), LJ_TSTR, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), 1+2, LJ_TISNUM);
+  dasm_put(Dst, 5528, Dt1(->base), Dt1(->base), LJ_TSTR, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), 1+2, LJ_TISNUM);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 5628);
+    dasm_put(Dst, 5637);
   } else if (sse) {
-    dasm_put(Dst, 5640);
+    dasm_put(Dst, 5649);
   } else {
-    dasm_put(Dst, 5655);
+    dasm_put(Dst, 5664);
   }
-  dasm_put(Dst, 5667, LJ_TSTR, LJ_TISNUM);
+  dasm_put(Dst, 5676, LJ_TSTR, LJ_TISNUM);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 2572);
+    dasm_put(Dst, 2581);
   } else {
-    dasm_put(Dst, 2311);
+    dasm_put(Dst, 2320);
   }
-  dasm_put(Dst, 5684, Dt5(->len));
+  dasm_put(Dst, 5693, Dt5(->len));
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 5694);
+    dasm_put(Dst, 5703);
   } else if (sse) {
-    dasm_put(Dst, 5698);
+    dasm_put(Dst, 5707);
   } else {
   }
-  dasm_put(Dst, 5705, sizeof(GCstr)-1);
-  dasm_put(Dst, 5780, 2+1, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
-  dasm_put(Dst, 5841, LJ_TSTR, LJ_TISNUM);
+  dasm_put(Dst, 5714, sizeof(GCstr)-1);
+  dasm_put(Dst, 5789, 2+1, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
+  dasm_put(Dst, 5850, LJ_TSTR, LJ_TISNUM);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 5858);
+    dasm_put(Dst, 5867);
   } else if (sse) {
-    dasm_put(Dst, 5866);
+    dasm_put(Dst, 5875);
   } else {
-    dasm_put(Dst, 5877);
+    dasm_put(Dst, 5886);
   }
-  dasm_put(Dst, 5893, Dt5(->len), DISPATCH_GL(tmpbuf.sz), Dt5([1]), DISPATCH_GL(tmpbuf.buf), DISPATCH_GL(tmpbuf.buf), 1+1);
-  dasm_put(Dst, 5961, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf));
-  dasm_put(Dst, 6028, 1+1, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz));
-  dasm_put(Dst, 6101, sizeof(GCstr), DISPATCH_GL(tmpbuf.buf), 1+1);
-  dasm_put(Dst, 6186, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf));
-  dasm_put(Dst, 6260, 1+1, LJ_TTAB);
+  dasm_put(Dst, 5902, Dt5(->len), DISPATCH_GL(tmpbuf.sz), Dt5([1]), DISPATCH_GL(tmpbuf.buf), DISPATCH_GL(tmpbuf.buf), 1+1);
+  dasm_put(Dst, 5970, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf));
+  dasm_put(Dst, 6037, 1+1, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz));
+  dasm_put(Dst, 6110, sizeof(GCstr), DISPATCH_GL(tmpbuf.buf), 1+1);
+  dasm_put(Dst, 6195, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf));
+  dasm_put(Dst, 6269, 1+1, LJ_TTAB);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 6327);
+    dasm_put(Dst, 6336);
   } else if (sse) {
-    dasm_put(Dst, 6334);
+    dasm_put(Dst, 6343);
   } else {
   }
-  dasm_put(Dst, 6344, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 6353, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6360);
+  dasm_put(Dst, 6369);
   } else {
-  dasm_put(Dst, 2311);
+  dasm_put(Dst, 2320);
   }
   if (sse) {
-  dasm_put(Dst, 6377, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6386, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
   dasm_put(Dst, 106);
   if (LJ_DUALNUM || sse) {
     if (!sse) {
     }
-    dasm_put(Dst, 6401);
+    dasm_put(Dst, 6410);
   } else {
   }
-  dasm_put(Dst, 6406, 1+1);
+  dasm_put(Dst, 6415, 1+1);
   if (sse) {
-  dasm_put(Dst, 6417, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6426, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
-  dasm_put(Dst, 6427);
+  dasm_put(Dst, 6436);
   }
-  dasm_put(Dst, 2288, LJ_TISNUM);
+  dasm_put(Dst, 2297, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6435);
+  dasm_put(Dst, 6444);
   } else {
-  dasm_put(Dst, 2311);
+  dasm_put(Dst, 2320);
   }
   if (sse) {
-  dasm_put(Dst, 6452);
+  dasm_put(Dst, 6461);
   } else {
   }
-  dasm_put(Dst, 6467, LJ_TISNUM);
+  dasm_put(Dst, 6476, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6492);
+  dasm_put(Dst, 6501);
   } else {
-  dasm_put(Dst, 6512);
+  dasm_put(Dst, 6521);
   }
   if (sse) {
-  dasm_put(Dst, 6517);
+  dasm_put(Dst, 6526);
   } else {
   }
-  dasm_put(Dst, 6534, 1+1);
+  dasm_put(Dst, 6543, 1+1);
   if (sse) {
-  dasm_put(Dst, 6417, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6426, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
-  dasm_put(Dst, 6427);
+  dasm_put(Dst, 6436);
   }
-  dasm_put(Dst, 2288, LJ_TISNUM);
+  dasm_put(Dst, 2297, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6435);
+  dasm_put(Dst, 6444);
   } else {
-  dasm_put(Dst, 2311);
+  dasm_put(Dst, 2320);
   }
   if (sse) {
-  dasm_put(Dst, 6452);
+  dasm_put(Dst, 6461);
   } else {
   }
-  dasm_put(Dst, 6467, LJ_TISNUM);
+  dasm_put(Dst, 6476, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6552);
+  dasm_put(Dst, 6561);
   } else {
-  dasm_put(Dst, 6512);
+  dasm_put(Dst, 6521);
   }
   if (sse) {
-  dasm_put(Dst, 6572);
+  dasm_put(Dst, 6581);
   } else {
   }
-  dasm_put(Dst, 6589, 1+1);
+  dasm_put(Dst, 6598, 1+1);
   if (sse) {
-  dasm_put(Dst, 6417, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6426, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
-  dasm_put(Dst, 6427);
+  dasm_put(Dst, 6436);
   }
-  dasm_put(Dst, 2288, LJ_TISNUM);
+  dasm_put(Dst, 2297, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6435);
+  dasm_put(Dst, 6444);
   } else {
-  dasm_put(Dst, 2311);
+  dasm_put(Dst, 2320);
   }
   if (sse) {
-  dasm_put(Dst, 6452);
+  dasm_put(Dst, 6461);
   } else {
   }
-  dasm_put(Dst, 6467, LJ_TISNUM);
+  dasm_put(Dst, 6476, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6607);
+  dasm_put(Dst, 6616);
   } else {
-  dasm_put(Dst, 6512);
+  dasm_put(Dst, 6521);
   }
   if (sse) {
-  dasm_put(Dst, 6627);
+  dasm_put(Dst, 6636);
   } else {
   }
-  dasm_put(Dst, 6644, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 6653, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6435);
+  dasm_put(Dst, 6444);
   } else {
-  dasm_put(Dst, 2311);
+  dasm_put(Dst, 2320);
   }
   if (sse) {
-  dasm_put(Dst, 6377, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6386, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6667, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 6676, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6435);
+  dasm_put(Dst, 6444);
   } else {
-  dasm_put(Dst, 2311);
+  dasm_put(Dst, 2320);
   }
   if (sse) {
-  dasm_put(Dst, 6377, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6386, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6691);
+  dasm_put(Dst, 6700);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 6401);
+    dasm_put(Dst, 6410);
   } else if (sse) {
-    dasm_put(Dst, 6697);
+    dasm_put(Dst, 6706);
   } else {
   }
-  dasm_put(Dst, 6709);
+  dasm_put(Dst, 6718);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6720, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 6729, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6435);
+  dasm_put(Dst, 6444);
   } else {
-  dasm_put(Dst, 2311);
+  dasm_put(Dst, 2320);
   }
   if (sse) {
-  dasm_put(Dst, 6377, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6386, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6736, LJ_TISNUM);
+  dasm_put(Dst, 6745, LJ_TISNUM);
   } else if (sse) {
-  dasm_put(Dst, 6751, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6760, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6818);
+  dasm_put(Dst, 6827);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6825, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 6834, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6435);
+  dasm_put(Dst, 6444);
   } else {
-  dasm_put(Dst, 2311);
+  dasm_put(Dst, 2320);
   }
   if (sse) {
-  dasm_put(Dst, 6377, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6386, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6736, LJ_TISNUM);
+  dasm_put(Dst, 6745, LJ_TISNUM);
   } else if (sse) {
-  dasm_put(Dst, 6841, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6850, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6908);
+  dasm_put(Dst, 6917);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6916, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 6925, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6435);
+  dasm_put(Dst, 6444);
   } else {
-  dasm_put(Dst, 2311);
+  dasm_put(Dst, 2320);
   }
   if (sse) {
-  dasm_put(Dst, 6377, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6386, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6736, LJ_TISNUM);
+  dasm_put(Dst, 6745, LJ_TISNUM);
   } else if (sse) {
-  dasm_put(Dst, 6932, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6941, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6999);
+  dasm_put(Dst, 7008);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 7007, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 7016, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6435);
+  dasm_put(Dst, 6444);
   } else {
-  dasm_put(Dst, 2311);
+  dasm_put(Dst, 2320);
   }
   if (sse) {
-  dasm_put(Dst, 6377, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6386, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6736, LJ_TISNUM);
+  dasm_put(Dst, 6745, LJ_TISNUM);
   } else if (sse) {
-  dasm_put(Dst, 7023, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 7032, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 7090);
+  dasm_put(Dst, 7099);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 7097, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 7106, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6435);
+  dasm_put(Dst, 6444);
   } else {
-  dasm_put(Dst, 2311);
+  dasm_put(Dst, 2320);
   }
   if (sse) {
-  dasm_put(Dst, 6377, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6386, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6736, LJ_TISNUM);
+  dasm_put(Dst, 6745, LJ_TISNUM);
   } else if (sse) {
-  dasm_put(Dst, 7113, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 7122, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 7180, 1+2, 1+1, Dt1(->base), 8*LUA_MINSTACK, Dt1(->top), Dt1(->maxstack), Dt8(->f), Dt1(->base));
-  dasm_put(Dst, 7256, Dt1(->top), Dt7(->pc), FRAME_TYPE, LUA_MINSTACK, Dt1(->base), Dt1(->base));
-  dasm_put(Dst, 7383, Dt1(->top), Dt1(->base), Dt1(->top));
+  dasm_put(Dst, 7189, 1+2, 1+1, Dt1(->base), 8*LUA_MINSTACK, Dt1(->top), Dt1(->maxstack), Dt8(->f), Dt1(->base));
+  dasm_put(Dst, 7265, Dt1(->top), Dt7(->pc), FRAME_TYPE, LUA_MINSTACK, Dt1(->base), Dt1(->base));
+  dasm_put(Dst, 7392, Dt1(->top), Dt1(->base), Dt1(->top));
 #if LJ_HASJIT
-  dasm_put(Dst, 7422, DISPATCH_GL(hookmask), HOOK_VMEVENT, HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount));
+  dasm_put(Dst, 7431, DISPATCH_GL(hookmask), HOOK_VMEVENT, HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount));
 #endif
-  dasm_put(Dst, 7455, DISPATCH_GL(hookmask), HOOK_ACTIVE, DISPATCH_GL(hookmask), HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount), LUA_MASKLINE);
-  dasm_put(Dst, 7509, Dt1(->base), Dt1(->base), GG_DISP2STATIC);
+  dasm_put(Dst, 7464, DISPATCH_GL(hookmask), HOOK_ACTIVE, DISPATCH_GL(hookmask), HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount), LUA_MASKLINE);
+  dasm_put(Dst, 7518, Dt1(->base), Dt1(->base), GG_DISP2STATIC);
 #if LJ_HASJIT
-  dasm_put(Dst, 7576, Dt7(->pc), PC2PROTO(framesize), Dt1(->base), Dt1(->top), GG_DISP2J, DISPATCH_J(L));
+  dasm_put(Dst, 7585, Dt7(->pc), PC2PROTO(framesize), Dt1(->base), Dt1(->top), GG_DISP2J, DISPATCH_J(L));
 #endif
-  dasm_put(Dst, 7623);
+  dasm_put(Dst, 7632);
 #if LJ_HASJIT
-  dasm_put(Dst, 7450);
+  dasm_put(Dst, 7459);
 #endif
-  dasm_put(Dst, 7630);
+  dasm_put(Dst, 7639);
 #if LJ_HASJIT
-  dasm_put(Dst, 7633);
+  dasm_put(Dst, 7642);
 #endif
-  dasm_put(Dst, 7643, Dt1(->base), Dt1(->top));
+  dasm_put(Dst, 7652, Dt1(->base), Dt1(->top));
 #if LJ_HASJIT
-  dasm_put(Dst, 7676);
+  dasm_put(Dst, 7685);
 #endif
-  dasm_put(Dst, 7681, Dt1(->base), Dt1(->top));
+  dasm_put(Dst, 7690, Dt1(->base), Dt1(->top));
 #if LJ_HASJIT
-  dasm_put(Dst, 7712, DISPATCH_GL(vmstate), DISPATCH_GL(vmstate), ~LJ_VMST_EXIT, DISPATCH_J(exitno), DISPATCH_J(parent), 16*8, DISPATCH_GL(jit_L), DISPATCH_GL(jit_base), DISPATCH_J(L), DISPATCH_GL(jit_L), Dt1(->base), GG_DISP2J, Dt1(->cframe), CFRAME_RAWMASK, CFRAME_OFS_L, Dt1(->base), CFRAME_OFS_PC);
+  dasm_put(Dst, 7721, DISPATCH_GL(vmstate), DISPATCH_GL(vmstate), ~LJ_VMST_EXIT, DISPATCH_J(exitno), DISPATCH_J(parent), 16*8, DISPATCH_GL(jit_L), DISPATCH_GL(jit_base), DISPATCH_J(L), DISPATCH_GL(jit_L), Dt1(->base), GG_DISP2J, Dt1(->cframe), CFRAME_RAWMASK, CFRAME_OFS_L, Dt1(->base), CFRAME_OFS_PC);
 #endif
-  dasm_put(Dst, 7951);
+  dasm_put(Dst, 7960);
 #if LJ_HASJIT
-  dasm_put(Dst, 7954, Dt7(->pc), PC2PROTO(k), DISPATCH_GL(jit_L), DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, BC_FUNCF);
+  dasm_put(Dst, 7963, Dt7(->pc), PC2PROTO(k), DISPATCH_GL(jit_L), DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, BC_FUNCF);
 #endif
-  dasm_put(Dst, 8054);
+  dasm_put(Dst, 8063);
   if (!sse) {
-  dasm_put(Dst, 8057);
+  dasm_put(Dst, 8066);
   }
-  dasm_put(Dst, 8102, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(43300000,00000000)), (unsigned int)((U64x(43300000,00000000))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
+  dasm_put(Dst, 8111, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(43300000,00000000)), (unsigned int)((U64x(43300000,00000000))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
   if (!sse) {
-  dasm_put(Dst, 8188);
+  dasm_put(Dst, 8197);
   }
-  dasm_put(Dst, 8233, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(43300000,00000000)), (unsigned int)((U64x(43300000,00000000))>>32), (unsigned int)(U64x(bff00000,00000000)), (unsigned int)((U64x(bff00000,00000000))>>32));
+  dasm_put(Dst, 8242, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(43300000,00000000)), (unsigned int)((U64x(43300000,00000000))>>32), (unsigned int)(U64x(bff00000,00000000)), (unsigned int)((U64x(bff00000,00000000))>>32));
   if (!sse) {
-  dasm_put(Dst, 8319);
+  dasm_put(Dst, 8328);
   }
-  dasm_put(Dst, 8358, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(43300000,00000000)), (unsigned int)((U64x(43300000,00000000))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
+  dasm_put(Dst, 8367, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(43300000,00000000)), (unsigned int)((U64x(43300000,00000000))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
   if (sse) {
-    dasm_put(Dst, 8447, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(43300000,00000000)), (unsigned int)((U64x(43300000,00000000))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
+    dasm_put(Dst, 8456, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(43300000,00000000)), (unsigned int)((U64x(43300000,00000000))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
   } else {
-    dasm_put(Dst, 8561);
+    dasm_put(Dst, 8570);
   }
-  dasm_put(Dst, 8608);
+  dasm_put(Dst, 8617);
   if (!sse) {
   } else {
-    dasm_put(Dst, 8685);
+    dasm_put(Dst, 8694);
   }
-  dasm_put(Dst, 8688);
-  dasm_put(Dst, 8773, (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
-  dasm_put(Dst, 8876, (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32), (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32), (unsigned int)(U64x(7ff00000,00000000)), (unsigned int)((U64x(7ff00000,00000000))>>32));
-  dasm_put(Dst, 9038);
+  dasm_put(Dst, 8697);
+  dasm_put(Dst, 8782, (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
+  dasm_put(Dst, 8885, (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32), (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32), (unsigned int)(U64x(7ff00000,00000000)), (unsigned int)((U64x(7ff00000,00000000))>>32));
+  dasm_put(Dst, 9047);
 #if LJ_HASJIT
   if (sse) {
-    dasm_put(Dst, 9079);
-    dasm_put(Dst, 9149);
-    dasm_put(Dst, 9221);
+    dasm_put(Dst, 9088);
+    dasm_put(Dst, 9158);
+    dasm_put(Dst, 9230);
   } else {
-    dasm_put(Dst, 9273);
-    dasm_put(Dst, 9365);
+    dasm_put(Dst, 9282);
+    dasm_put(Dst, 9374);
   }
-  dasm_put(Dst, 9411);
+  dasm_put(Dst, 9420);
 #endif
-  dasm_put(Dst, 9415);
+  dasm_put(Dst, 9424);
   if (sse) {
-    dasm_put(Dst, 9418, (unsigned int)(U64x(80000000,00000000)), (unsigned int)((U64x(80000000,00000000))>>32));
-    dasm_put(Dst, 9503, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32));
+    dasm_put(Dst, 9427, (unsigned int)(U64x(80000000,00000000)), (unsigned int)((U64x(80000000,00000000))>>32));
+    dasm_put(Dst, 9512, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32));
   } else {
-    dasm_put(Dst, 9631);
-    dasm_put(Dst, 9714);
+    dasm_put(Dst, 9640);
+    dasm_put(Dst, 9723);
     if (cmov) {
-    dasm_put(Dst, 9769);
+    dasm_put(Dst, 9778);
     } else {
-    dasm_put(Dst, 9788);
+    dasm_put(Dst, 9797);
     }
-    dasm_put(Dst, 9411);
+    dasm_put(Dst, 9420);
   }
-  dasm_put(Dst, 9829);
+  dasm_put(Dst, 9838);
+#ifdef LUA_USE_ASSERT
+  dasm_put(Dst, 9422);
+#endif
+  dasm_put(Dst, 9862);
+#if LJ_HASFFI
+#define DtE(_V) (int)(ptrdiff_t)&(((CTState *)0)_V)
+  dasm_put(Dst, 9866, GG_G2DISP, Dt2(->ctype_state), DtE(->cb.slot), DtE(->cb.gpr[0]), DtE(->cb.gpr[1]), DtE(->cb.gpr[2]), DtE(->cb.gpr[3]), DtE(->cb.fpr[0]), DtE(->cb.fpr[1]), DtE(->cb.fpr[2]), DtE(->cb.fpr[3]), CFRAME_SIZE, DtE(->cb.gpr[4]), DtE(->cb.gpr[5]), DtE(->cb.fpr[4]), DtE(->cb.fpr[5]), DtE(->cb.fpr[6]), DtE(->cb.fpr[7]), DtE(->cb.stack), DISPATCH_GL(vmstate), ~LJ_VMST_INTERP);
+  dasm_put(Dst, 9990, Dt1(->base), Dt1(->top), Dt7(->pc));
+#endif
+  dasm_put(Dst, 10030);
 #if LJ_HASFFI
-#define DtE(_V) (int)(ptrdiff_t)&(((CCallState *)0)_V)
-  dasm_put(Dst, 9853, DtE(->spadj));
+  dasm_put(Dst, 10033, DISPATCH_GL(ctype_state), DtE(->L), Dt1(->base), Dt1(->top), DtE(->cb.gpr[0]), DtE(->cb.fpr[0]));
+#endif
+  dasm_put(Dst, 10074);
+#if LJ_HASFFI
+#define DtF(_V) (int)(ptrdiff_t)&(((CCallState *)0)_V)
+  dasm_put(Dst, 10077, DtF(->spadj));
 #if LJ_TARGET_WINDOWS
 #endif
-  dasm_put(Dst, 9869, DtE(->nsp), offsetof(CCallState, stack), CCALL_SPS_EXTRA*8, DtE(->nfpr), DtE(->gpr[0]), DtE(->gpr[1]), DtE(->gpr[2]), DtE(->gpr[3]), DtE(->gpr[4]), DtE(->gpr[5]), DtE(->fpr[0]), DtE(->fpr[1]));
-  dasm_put(Dst, 9948, DtE(->fpr[2]), DtE(->fpr[3]), DtE(->fpr[4]), DtE(->fpr[5]), DtE(->fpr[6]), DtE(->fpr[7]), DtE(->func), DtE(->gpr[0]), DtE(->fpr[0]), DtE(->gpr[1]), DtE(->fpr[1]));
+  dasm_put(Dst, 10093, DtF(->nsp), offsetof(CCallState, stack), CCALL_SPS_EXTRA*8, DtF(->nfpr), DtF(->gpr[0]), DtF(->gpr[1]), DtF(->gpr[2]), DtF(->gpr[3]), DtF(->gpr[4]), DtF(->gpr[5]), DtF(->fpr[0]), DtF(->fpr[1]));
+  dasm_put(Dst, 10172, DtF(->fpr[2]), DtF(->fpr[3]), DtF(->fpr[4]), DtF(->fpr[5]), DtF(->fpr[6]), DtF(->fpr[7]), DtF(->func), DtF(->gpr[0]), DtF(->fpr[0]), DtF(->gpr[1]), DtF(->fpr[1]));
 #if LJ_TARGET_WINDOWS
 #endif
-  dasm_put(Dst, 10003);
+  dasm_put(Dst, 10227);
 #endif
-  dasm_put(Dst, 10011);
-#ifdef LUA_USE_ASSERT
-  dasm_put(Dst, 9413);
-#endif
-  dasm_put(Dst, 9413);
 }
 
 /* Generate the code for a single instruction. */
 static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
 {
   int vk = 0;
-  dasm_put(Dst, 10014, defop);
+  dasm_put(Dst, 829, defop);
 
   switch (op) {
 
@@ -1867,302 +1902,302 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
 
   case BC_ISLT: case BC_ISGE: case BC_ISLE: case BC_ISGT:
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 10016, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 10235, LJ_TISNUM, LJ_TISNUM);
       switch (op) {
       case BC_ISLT:
-      dasm_put(Dst, 10046);
+      dasm_put(Dst, 10265);
       break;
       case BC_ISGE:
-      dasm_put(Dst, 10051);
+      dasm_put(Dst, 10270);
       break;
       case BC_ISLE:
-      dasm_put(Dst, 10056);
+      dasm_put(Dst, 10275);
       break;
       case BC_ISGT:
-      dasm_put(Dst, 10061);
+      dasm_put(Dst, 10280);
       break;
       default: break;  /* Shut up GCC. */
       }
-      dasm_put(Dst, 10066, -BCBIAS_J*4, LJ_TISNUM);
+      dasm_put(Dst, 10285, -BCBIAS_J*4, LJ_TISNUM);
       if (sse) {
-	dasm_put(Dst, 10121);
+	dasm_put(Dst, 10340);
       } else {
-	dasm_put(Dst, 10132);
+	dasm_put(Dst, 10351);
       }
-      dasm_put(Dst, 10143);
+      dasm_put(Dst, 10362);
       if (sse) {
-	dasm_put(Dst, 10150);
+	dasm_put(Dst, 10369);
 	switch (op) {
 	case BC_ISLT:
-	dasm_put(Dst, 10170);
+	dasm_put(Dst, 10389);
 	break;
 	case BC_ISGE:
-	dasm_put(Dst, 10175);
+	dasm_put(Dst, 10394);
 	break;
 	case BC_ISLE:
-	dasm_put(Dst, 10180);
+	dasm_put(Dst, 10399);
 	break;
 	case BC_ISGT:
-	dasm_put(Dst, 10185);
+	dasm_put(Dst, 10404);
 	break;
 	default: break;  /* Shut up GCC. */
 	}
-	dasm_put(Dst, 10190);
+	dasm_put(Dst, 10409);
       } else {
-	dasm_put(Dst, 10195);
+	dasm_put(Dst, 10414);
       }
     } else {
-      dasm_put(Dst, 10203, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 10422, LJ_TISNUM, LJ_TISNUM);
     }
     if (sse) {
-      dasm_put(Dst, 10224);
+      dasm_put(Dst, 10443);
     } else {
-      dasm_put(Dst, 10245);
+      dasm_put(Dst, 10464);
       if (cmov) {
-      dasm_put(Dst, 10261);
+      dasm_put(Dst, 10480);
       } else {
-      dasm_put(Dst, 10267);
+      dasm_put(Dst, 10486);
       }
     }
     if (LJ_DUALNUM) {
       switch (op) {
       case BC_ISLT:
-      dasm_put(Dst, 10170);
+      dasm_put(Dst, 10389);
       break;
       case BC_ISGE:
-      dasm_put(Dst, 10175);
+      dasm_put(Dst, 10394);
       break;
       case BC_ISLE:
-      dasm_put(Dst, 10180);
+      dasm_put(Dst, 10399);
       break;
       case BC_ISGT:
-      dasm_put(Dst, 10185);
+      dasm_put(Dst, 10404);
       break;
       default: break;  /* Shut up GCC. */
       }
-      dasm_put(Dst, 10190);
+      dasm_put(Dst, 10409);
     } else {
       switch (op) {
       case BC_ISLT:
-      dasm_put(Dst, 10274);
+      dasm_put(Dst, 817);
       break;
       case BC_ISGE:
-      dasm_put(Dst, 10279);
+      dasm_put(Dst, 10493);
       break;
       case BC_ISLE:
-      dasm_put(Dst, 10284);
+      dasm_put(Dst, 10498);
       break;
       case BC_ISGT:
-      dasm_put(Dst, 10289);
+      dasm_put(Dst, 10503);
       break;
       default: break;  /* Shut up GCC. */
       }
-      dasm_put(Dst, 10294, -BCBIAS_J*4);
+      dasm_put(Dst, 10508, -BCBIAS_J*4);
     }
     break;
 
   case BC_ISEQV: case BC_ISNEV:
     vk = op == BC_ISEQV;
-    dasm_put(Dst, 10327);
+    dasm_put(Dst, 10541);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 10335, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 10549, LJ_TISNUM, LJ_TISNUM);
       if (vk) {
-	dasm_put(Dst, 10360);
+	dasm_put(Dst, 10574);
       } else {
-	dasm_put(Dst, 10365);
+	dasm_put(Dst, 10579);
       }
-      dasm_put(Dst, 10370, -BCBIAS_J*4, LJ_TISNUM);
+      dasm_put(Dst, 10584, -BCBIAS_J*4, LJ_TISNUM);
       if (sse) {
-	dasm_put(Dst, 10423);
+	dasm_put(Dst, 10637);
       } else {
-	dasm_put(Dst, 10430);
+	dasm_put(Dst, 10644);
       }
-      dasm_put(Dst, 10434);
+      dasm_put(Dst, 10648);
       if (sse) {
-	dasm_put(Dst, 10445);
+	dasm_put(Dst, 10659);
       } else {
-	dasm_put(Dst, 10457);
+	dasm_put(Dst, 10671);
       }
-      dasm_put(Dst, 10464);
+      dasm_put(Dst, 10678);
     } else {
-      dasm_put(Dst, 10469, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 10683, LJ_TISNUM, LJ_TISNUM);
     }
     if (sse) {
-      dasm_put(Dst, 10488);
+      dasm_put(Dst, 10702);
     } else {
-      dasm_put(Dst, 10506);
+      dasm_put(Dst, 10720);
       if (cmov) {
-      dasm_put(Dst, 10261);
+      dasm_put(Dst, 10480);
       } else {
-      dasm_put(Dst, 10267);
+      dasm_put(Dst, 10486);
       }
     }
   iseqne_fp:
     if (vk) {
-      dasm_put(Dst, 10519);
+      dasm_put(Dst, 10733);
     } else {
-      dasm_put(Dst, 10528);
+      dasm_put(Dst, 10742);
     }
   iseqne_end:
     if (vk) {
-      dasm_put(Dst, 10537, -BCBIAS_J*4);
+      dasm_put(Dst, 10751, -BCBIAS_J*4);
       if (!LJ_HASFFI) {
-	dasm_put(Dst, 4675);
+	dasm_put(Dst, 4684);
       }
     } else {
       if (!LJ_HASFFI) {
-	dasm_put(Dst, 4675);
+	dasm_put(Dst, 4684);
       }
-      dasm_put(Dst, 10552, -BCBIAS_J*4);
+      dasm_put(Dst, 10766, -BCBIAS_J*4);
     }
     if (LJ_DUALNUM && (op == BC_ISEQV || op == BC_ISNEV ||
 		       op == BC_ISEQN || op == BC_ISNEN)) {
-      dasm_put(Dst, 10567);
+      dasm_put(Dst, 10781);
     } else {
-      dasm_put(Dst, 10306);
+      dasm_put(Dst, 10520);
     }
     if (op == BC_ISEQV || op == BC_ISNEV) {
-      dasm_put(Dst, 10572);
+      dasm_put(Dst, 10786);
       if (LJ_HASFFI) {
-	dasm_put(Dst, 10575, LJ_TCDATA, LJ_TCDATA);
+	dasm_put(Dst, 10789, LJ_TCDATA, LJ_TCDATA);
       }
-      dasm_put(Dst, 10594, LJ_TISPRI, LJ_TISTABUD, Dt6(->metatable), Dt6(->nomm), 1<<MM_eq);
+      dasm_put(Dst, 10808, LJ_TISPRI, LJ_TISTABUD, LJ_TUDATA, Dt6(->metatable), Dt6(->nomm), 1<<MM_eq);
       if (vk) {
-	dasm_put(Dst, 10650);
+	dasm_put(Dst, 10872);
       } else {
-	dasm_put(Dst, 10654);
+	dasm_put(Dst, 10876);
       }
-      dasm_put(Dst, 10660);
+      dasm_put(Dst, 10882);
     } else if (LJ_HASFFI) {
-      dasm_put(Dst, 10665, LJ_TCDATA);
+      dasm_put(Dst, 10887, LJ_TCDATA);
       if (LJ_DUALNUM && vk) {
-	dasm_put(Dst, 10672);
+	dasm_put(Dst, 10894);
       } else {
-	dasm_put(Dst, 10645);
+	dasm_put(Dst, 10867);
       }
-      dasm_put(Dst, 10677);
+      dasm_put(Dst, 10899);
     }
     break;
   case BC_ISEQS: case BC_ISNES:
     vk = op == BC_ISEQS;
-    dasm_put(Dst, 10682, LJ_TSTR);
+    dasm_put(Dst, 10904, LJ_TSTR);
   iseqne_test:
     if (vk) {
-      dasm_put(Dst, 10523);
+      dasm_put(Dst, 10737);
     } else {
-      dasm_put(Dst, 814);
+      dasm_put(Dst, 2980);
     }
     goto iseqne_end;
   case BC_ISEQN: case BC_ISNEN:
     vk = op == BC_ISEQN;
-    dasm_put(Dst, 10709);
+    dasm_put(Dst, 10931);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 10717, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 10939, LJ_TISNUM, LJ_TISNUM);
       if (vk) {
-	dasm_put(Dst, 10360);
+	dasm_put(Dst, 10574);
       } else {
-	dasm_put(Dst, 10365);
+	dasm_put(Dst, 10579);
       }
-      dasm_put(Dst, 10744, -BCBIAS_J*4, LJ_TISNUM);
+      dasm_put(Dst, 10966, -BCBIAS_J*4, LJ_TISNUM);
       if (sse) {
-	dasm_put(Dst, 10794);
+	dasm_put(Dst, 11016);
       } else {
-	dasm_put(Dst, 10802);
+	dasm_put(Dst, 11024);
       }
-      dasm_put(Dst, 10807);
+      dasm_put(Dst, 11029);
       if (sse) {
-	dasm_put(Dst, 10814);
+	dasm_put(Dst, 11036);
       } else {
-	dasm_put(Dst, 10827);
+	dasm_put(Dst, 11049);
       }
-      dasm_put(Dst, 10464);
+      dasm_put(Dst, 10678);
     } else {
-      dasm_put(Dst, 10835, LJ_TISNUM);
+      dasm_put(Dst, 11057, LJ_TISNUM);
     }
     if (sse) {
-      dasm_put(Dst, 10844);
+      dasm_put(Dst, 11066);
     } else {
-      dasm_put(Dst, 10863);
+      dasm_put(Dst, 11085);
       if (cmov) {
-      dasm_put(Dst, 10261);
+      dasm_put(Dst, 10480);
       } else {
-      dasm_put(Dst, 10267);
+      dasm_put(Dst, 10486);
       }
     }
     goto iseqne_fp;
   case BC_ISEQP: case BC_ISNEP:
     vk = op == BC_ISEQP;
-    dasm_put(Dst, 10877);
+    dasm_put(Dst, 11099);
     if (!LJ_HASFFI) goto iseqne_test;
     if (vk) {
-      dasm_put(Dst, 10891, -BCBIAS_J*4, LJ_TCDATA);
+      dasm_put(Dst, 11113, -BCBIAS_J*4, LJ_TCDATA);
     } else {
-      dasm_put(Dst, 10942, LJ_TCDATA, -BCBIAS_J*4);
+      dasm_put(Dst, 11164, LJ_TCDATA, -BCBIAS_J*4);
     }
     break;
 
   /* -- Unary test and copy ops ------------------------------------------- */
 
   case BC_ISTC: case BC_ISFC: case BC_IST: case BC_ISF:
-    dasm_put(Dst, 10987, LJ_TISTRUECOND);
+    dasm_put(Dst, 11209, LJ_TISTRUECOND);
     if (op == BC_IST || op == BC_ISTC) {
-      dasm_put(Dst, 10289);
+      dasm_put(Dst, 10503);
     } else {
-      dasm_put(Dst, 10284);
+      dasm_put(Dst, 10498);
     }
     if (op == BC_ISTC || op == BC_ISFC) {
-      dasm_put(Dst, 10999);
+      dasm_put(Dst, 11221);
     }
-    dasm_put(Dst, 10294, -BCBIAS_J*4);
+    dasm_put(Dst, 10508, -BCBIAS_J*4);
     break;
 
   /* -- Unary ops --------------------------------------------------------- */
 
   case BC_MOV:
-    dasm_put(Dst, 11010);
+    dasm_put(Dst, 11232);
     break;
   case BC_NOT:
-    dasm_put(Dst, 11039, LJ_TISTRUECOND, LJ_TTRUE);
+    dasm_put(Dst, 11261, LJ_TISTRUECOND, LJ_TTRUE);
     break;
   case BC_UNM:
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 11076, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 11298, LJ_TISNUM, LJ_TISNUM);
     } else {
-      dasm_put(Dst, 11154, LJ_TISNUM);
+      dasm_put(Dst, 11376, LJ_TISNUM);
     }
     if (sse) {
-      dasm_put(Dst, 11165, (unsigned int)(U64x(80000000,00000000)), (unsigned int)((U64x(80000000,00000000))>>32));
+      dasm_put(Dst, 11387, (unsigned int)(U64x(80000000,00000000)), (unsigned int)((U64x(80000000,00000000))>>32));
     } else {
-      dasm_put(Dst, 11190);
+      dasm_put(Dst, 11412);
     }
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 10567);
+      dasm_put(Dst, 10781);
     } else {
-      dasm_put(Dst, 10306);
+      dasm_put(Dst, 10520);
     }
     break;
   case BC_LEN:
-    dasm_put(Dst, 11199, LJ_TSTR);
+    dasm_put(Dst, 11421, LJ_TSTR);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 11213, Dt5(->len), LJ_TISNUM);
+      dasm_put(Dst, 11435, Dt5(->len), LJ_TISNUM);
     } else if (sse) {
-      dasm_put(Dst, 11227, Dt5(->len));
+      dasm_put(Dst, 11449, Dt5(->len));
     } else {
-      dasm_put(Dst, 11245, Dt5(->len));
+      dasm_put(Dst, 11467, Dt5(->len));
     }
-    dasm_put(Dst, 11254, LJ_TTAB);
+    dasm_put(Dst, 11476, LJ_TTAB);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-    dasm_put(Dst, 11290, Dt6(->metatable));
+    dasm_put(Dst, 11512, Dt6(->metatable));
 #endif
-    dasm_put(Dst, 11304);
+    dasm_put(Dst, 11526);
     if (LJ_DUALNUM) {
     } else if (sse) {
-      dasm_put(Dst, 11313);
+      dasm_put(Dst, 11535);
     } else {
     }
-    dasm_put(Dst, 11319);
+    dasm_put(Dst, 11541);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-    dasm_put(Dst, 11332, Dt6(->nomm), 1<<MM_len);
+    dasm_put(Dst, 11554, Dt6(->nomm), 1<<MM_len);
 #endif
     break;
 
@@ -2171,605 +2206,605 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
 
   case BC_ADDVN: case BC_ADDNV: case BC_ADDVV:
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11348);
+    dasm_put(Dst, 11570);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11356, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11578, LJ_TISNUM, LJ_TISNUM);
       break;
     case 1:
-    dasm_put(Dst, 11391, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11613, LJ_TISNUM, LJ_TISNUM);
       break;
     default:
-    dasm_put(Dst, 11426, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11648, LJ_TISNUM, LJ_TISNUM);
       break;
     }
-    dasm_put(Dst, 11459, LJ_TISNUM);
+    dasm_put(Dst, 11681, LJ_TISNUM);
     if (vk == 1) {
-    dasm_put(Dst, 11223);
+    dasm_put(Dst, 11445);
     } else {
-    dasm_put(Dst, 11006);
+    dasm_put(Dst, 11228);
     }
-    dasm_put(Dst, 10306);
+    dasm_put(Dst, 10520);
     } else {
-    dasm_put(Dst, 11348);
+    dasm_put(Dst, 11570);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11465, LJ_TISNUM);
+    dasm_put(Dst, 11687, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11477, LJ_TISNUM);
+    dasm_put(Dst, 11699, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11489);
+    dasm_put(Dst, 11711);
     } else {
-    dasm_put(Dst, 11504);
+    dasm_put(Dst, 11726);
     }
       break;
     case 1:
-    dasm_put(Dst, 11513, LJ_TISNUM);
+    dasm_put(Dst, 11735, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11525, LJ_TISNUM);
+    dasm_put(Dst, 11747, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11537);
+    dasm_put(Dst, 11759);
     } else {
-    dasm_put(Dst, 11552);
+    dasm_put(Dst, 11774);
     }
       break;
     default:
-    dasm_put(Dst, 11561, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11783, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 11583);
+    dasm_put(Dst, 11805);
     } else {
-    dasm_put(Dst, 11597);
+    dasm_put(Dst, 11819);
     }
       break;
     }
     if (sse) {
-    dasm_put(Dst, 11183);
+    dasm_put(Dst, 11405);
     } else {
-    dasm_put(Dst, 11195);
+    dasm_put(Dst, 11417);
     }
-    dasm_put(Dst, 10306);
+    dasm_put(Dst, 10520);
     }
     break;
   case BC_SUBVN: case BC_SUBNV: case BC_SUBVV:
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11348);
+    dasm_put(Dst, 11570);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11605, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11827, LJ_TISNUM, LJ_TISNUM);
       break;
     case 1:
-    dasm_put(Dst, 11640, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11862, LJ_TISNUM, LJ_TISNUM);
       break;
     default:
-    dasm_put(Dst, 11675, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11897, LJ_TISNUM, LJ_TISNUM);
       break;
     }
-    dasm_put(Dst, 11459, LJ_TISNUM);
+    dasm_put(Dst, 11681, LJ_TISNUM);
     if (vk == 1) {
-    dasm_put(Dst, 11223);
+    dasm_put(Dst, 11445);
     } else {
-    dasm_put(Dst, 11006);
+    dasm_put(Dst, 11228);
     }
-    dasm_put(Dst, 10306);
+    dasm_put(Dst, 10520);
     } else {
-    dasm_put(Dst, 11348);
+    dasm_put(Dst, 11570);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11465, LJ_TISNUM);
+    dasm_put(Dst, 11687, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11477, LJ_TISNUM);
+    dasm_put(Dst, 11699, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11708);
+    dasm_put(Dst, 11930);
     } else {
-    dasm_put(Dst, 11723);
+    dasm_put(Dst, 11945);
     }
       break;
     case 1:
-    dasm_put(Dst, 11513, LJ_TISNUM);
+    dasm_put(Dst, 11735, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11525, LJ_TISNUM);
+    dasm_put(Dst, 11747, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11732);
+    dasm_put(Dst, 11954);
     } else {
-    dasm_put(Dst, 11747);
+    dasm_put(Dst, 11969);
     }
       break;
     default:
-    dasm_put(Dst, 11561, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11783, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 11756);
+    dasm_put(Dst, 11978);
     } else {
-    dasm_put(Dst, 11770);
+    dasm_put(Dst, 11992);
     }
       break;
     }
     if (sse) {
-    dasm_put(Dst, 11183);
+    dasm_put(Dst, 11405);
     } else {
-    dasm_put(Dst, 11195);
+    dasm_put(Dst, 11417);
     }
-    dasm_put(Dst, 10306);
+    dasm_put(Dst, 10520);
     }
     break;
   case BC_MULVN: case BC_MULNV: case BC_MULVV:
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11348);
+    dasm_put(Dst, 11570);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11778, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 12000, LJ_TISNUM, LJ_TISNUM);
       break;
     case 1:
-    dasm_put(Dst, 11814, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 12036, LJ_TISNUM, LJ_TISNUM);
       break;
     default:
-    dasm_put(Dst, 11850, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 12072, LJ_TISNUM, LJ_TISNUM);
       break;
     }
-    dasm_put(Dst, 11459, LJ_TISNUM);
+    dasm_put(Dst, 11681, LJ_TISNUM);
     if (vk == 1) {
-    dasm_put(Dst, 11223);
+    dasm_put(Dst, 11445);
     } else {
-    dasm_put(Dst, 11006);
+    dasm_put(Dst, 11228);
     }
-    dasm_put(Dst, 10306);
+    dasm_put(Dst, 10520);
     } else {
-    dasm_put(Dst, 11348);
+    dasm_put(Dst, 11570);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11465, LJ_TISNUM);
+    dasm_put(Dst, 11687, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11477, LJ_TISNUM);
+    dasm_put(Dst, 11699, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11884);
+    dasm_put(Dst, 12106);
     } else {
-    dasm_put(Dst, 11899);
+    dasm_put(Dst, 12121);
     }
       break;
     case 1:
-    dasm_put(Dst, 11513, LJ_TISNUM);
+    dasm_put(Dst, 11735, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11525, LJ_TISNUM);
+    dasm_put(Dst, 11747, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11908);
+    dasm_put(Dst, 12130);
     } else {
-    dasm_put(Dst, 11923);
+    dasm_put(Dst, 12145);
     }
       break;
     default:
-    dasm_put(Dst, 11561, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11783, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 11932);
+    dasm_put(Dst, 12154);
     } else {
-    dasm_put(Dst, 11946);
+    dasm_put(Dst, 12168);
     }
       break;
     }
     if (sse) {
-    dasm_put(Dst, 11183);
+    dasm_put(Dst, 11405);
     } else {
-    dasm_put(Dst, 11195);
+    dasm_put(Dst, 11417);
     }
-    dasm_put(Dst, 10306);
+    dasm_put(Dst, 10520);
     }
     break;
   case BC_DIVVN: case BC_DIVNV: case BC_DIVVV:
-    dasm_put(Dst, 11348);
+    dasm_put(Dst, 11570);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11465, LJ_TISNUM);
+    dasm_put(Dst, 11687, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11477, LJ_TISNUM);
+    dasm_put(Dst, 11699, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11954);
+    dasm_put(Dst, 12176);
     } else {
-    dasm_put(Dst, 11969);
+    dasm_put(Dst, 12191);
     }
       break;
     case 1:
-    dasm_put(Dst, 11513, LJ_TISNUM);
+    dasm_put(Dst, 11735, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11525, LJ_TISNUM);
+    dasm_put(Dst, 11747, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11978);
+    dasm_put(Dst, 12200);
     } else {
-    dasm_put(Dst, 11993);
+    dasm_put(Dst, 12215);
     }
       break;
     default:
-    dasm_put(Dst, 11561, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11783, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 12002);
+    dasm_put(Dst, 12224);
     } else {
-    dasm_put(Dst, 12016);
+    dasm_put(Dst, 12238);
     }
       break;
     }
     if (sse) {
-    dasm_put(Dst, 11183);
+    dasm_put(Dst, 11405);
     } else {
-    dasm_put(Dst, 11195);
+    dasm_put(Dst, 11417);
     }
-    dasm_put(Dst, 10306);
+    dasm_put(Dst, 10520);
     break;
   case BC_MODVN:
-    dasm_put(Dst, 11348);
+    dasm_put(Dst, 11570);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11465, LJ_TISNUM);
+    dasm_put(Dst, 11687, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11477, LJ_TISNUM);
+    dasm_put(Dst, 11699, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 12024);
+    dasm_put(Dst, 12246);
     } else {
-    dasm_put(Dst, 12039);
+    dasm_put(Dst, 12261);
     }
       break;
     case 1:
-    dasm_put(Dst, 11513, LJ_TISNUM);
+    dasm_put(Dst, 11735, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11525, LJ_TISNUM);
+    dasm_put(Dst, 11747, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 12048);
+    dasm_put(Dst, 12270);
     } else {
-    dasm_put(Dst, 12063);
+    dasm_put(Dst, 12285);
     }
       break;
     default:
-    dasm_put(Dst, 11561, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11783, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 12072);
+    dasm_put(Dst, 12294);
     } else {
-    dasm_put(Dst, 12086);
+    dasm_put(Dst, 12308);
     }
       break;
     }
-    dasm_put(Dst, 12094);
+    dasm_put(Dst, 12316);
     if (sse) {
-    dasm_put(Dst, 11183);
+    dasm_put(Dst, 11405);
     } else {
-    dasm_put(Dst, 11195);
+    dasm_put(Dst, 11417);
     }
-    dasm_put(Dst, 10306);
+    dasm_put(Dst, 10520);
     break;
   case BC_MODNV: case BC_MODVV:
-    dasm_put(Dst, 11348);
+    dasm_put(Dst, 11570);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11465, LJ_TISNUM);
+    dasm_put(Dst, 11687, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11477, LJ_TISNUM);
+    dasm_put(Dst, 11699, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 12024);
+    dasm_put(Dst, 12246);
     } else {
-    dasm_put(Dst, 12039);
+    dasm_put(Dst, 12261);
     }
       break;
     case 1:
-    dasm_put(Dst, 11513, LJ_TISNUM);
+    dasm_put(Dst, 11735, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11525, LJ_TISNUM);
+    dasm_put(Dst, 11747, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 12048);
+    dasm_put(Dst, 12270);
     } else {
-    dasm_put(Dst, 12063);
+    dasm_put(Dst, 12285);
     }
       break;
     default:
-    dasm_put(Dst, 11561, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11783, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 12072);
+    dasm_put(Dst, 12294);
     } else {
-    dasm_put(Dst, 12086);
+    dasm_put(Dst, 12308);
     }
       break;
     }
-    dasm_put(Dst, 12100);
+    dasm_put(Dst, 12322);
     break;
   case BC_POW:
-    dasm_put(Dst, 11348);
+    dasm_put(Dst, 11570);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11465, LJ_TISNUM);
+    dasm_put(Dst, 11687, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11477, LJ_TISNUM);
+    dasm_put(Dst, 11699, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 12024);
+    dasm_put(Dst, 12246);
     } else {
-    dasm_put(Dst, 12039);
+    dasm_put(Dst, 12261);
     }
       break;
     case 1:
-    dasm_put(Dst, 11513, LJ_TISNUM);
+    dasm_put(Dst, 11735, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11525, LJ_TISNUM);
+    dasm_put(Dst, 11747, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 12048);
+    dasm_put(Dst, 12270);
     } else {
-    dasm_put(Dst, 12063);
+    dasm_put(Dst, 12285);
     }
       break;
     default:
-    dasm_put(Dst, 11561, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11783, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 12072);
+    dasm_put(Dst, 12294);
     } else {
-    dasm_put(Dst, 12086);
+    dasm_put(Dst, 12308);
     }
       break;
     }
-    dasm_put(Dst, 12105);
+    dasm_put(Dst, 12327);
     if (sse) {
-    dasm_put(Dst, 11183);
+    dasm_put(Dst, 11405);
     } else {
-    dasm_put(Dst, 11195);
+    dasm_put(Dst, 11417);
     }
-    dasm_put(Dst, 10306);
+    dasm_put(Dst, 10520);
     break;
 
   case BC_CAT:
-    dasm_put(Dst, 12109, Dt1(->base), Dt1(->base));
+    dasm_put(Dst, 12331, Dt1(->base), Dt1(->base));
     break;
 
   /* -- Constant ops ------------------------------------------------------ */
 
   case BC_KSTR:
-    dasm_put(Dst, 12193, LJ_TSTR);
+    dasm_put(Dst, 12415, LJ_TSTR);
     break;
   case BC_KCDATA:
 #if LJ_HASFFI
-    dasm_put(Dst, 12193, LJ_TCDATA);
+    dasm_put(Dst, 12415, LJ_TCDATA);
 #endif
     break;
   case BC_KSHORT:
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 12230, LJ_TISNUM);
+      dasm_put(Dst, 12452, LJ_TISNUM);
     } else if (sse) {
-      dasm_put(Dst, 12242);
+      dasm_put(Dst, 12464);
     } else {
-      dasm_put(Dst, 12257);
+      dasm_put(Dst, 12479);
     }
-    dasm_put(Dst, 10306);
+    dasm_put(Dst, 10520);
     break;
   case BC_KNUM:
     if (sse) {
-      dasm_put(Dst, 12265);
+      dasm_put(Dst, 12487);
     } else {
-      dasm_put(Dst, 12279);
+      dasm_put(Dst, 12501);
     }
-    dasm_put(Dst, 10306);
+    dasm_put(Dst, 10520);
     break;
   case BC_KPRI:
-    dasm_put(Dst, 12287);
+    dasm_put(Dst, 12509);
     break;
   case BC_KNIL:
-    dasm_put(Dst, 12316, LJ_TNIL);
+    dasm_put(Dst, 12538, LJ_TNIL);
     break;
 
   /* -- Upvalue and function ops ------------------------------------------ */
 
   case BC_UGET:
-    dasm_put(Dst, 12364, offsetof(GCfuncL, uvptr), DtA(->v));
+    dasm_put(Dst, 12586, offsetof(GCfuncL, uvptr), DtA(->v));
     break;
   case BC_USETV:
 #define TV2MARKOFS \
  ((int32_t)offsetof(GCupval, marked)-(int32_t)offsetof(GCupval, tv))
-    dasm_put(Dst, 12405, offsetof(GCfuncL, uvptr), DtA(->closed), DtA(->v), TV2MARKOFS, LJ_GC_BLACK, LJ_TISGCV, LJ_TISNUM - LJ_TISGCV, Dt4(->gch.marked), LJ_GC_WHITES, GG_DISP2G);
-    dasm_put(Dst, 12501);
+    dasm_put(Dst, 12627, offsetof(GCfuncL, uvptr), DtA(->closed), DtA(->v), TV2MARKOFS, LJ_GC_BLACK, LJ_TISGCV, LJ_TISNUM - LJ_TISGCV, Dt4(->gch.marked), LJ_GC_WHITES, GG_DISP2G);
+    dasm_put(Dst, 12723);
     break;
 #undef TV2MARKOFS
   case BC_USETS:
-    dasm_put(Dst, 12513, offsetof(GCfuncL, uvptr), DtA(->v), LJ_TSTR, DtA(->marked), LJ_GC_BLACK, Dt4(->gch.marked), LJ_GC_WHITES, DtA(->closed), GG_DISP2G);
+    dasm_put(Dst, 12735, offsetof(GCfuncL, uvptr), DtA(->v), LJ_TSTR, DtA(->marked), LJ_GC_BLACK, Dt4(->gch.marked), LJ_GC_WHITES, DtA(->closed), GG_DISP2G);
     break;
   case BC_USETN:
-    dasm_put(Dst, 12609);
+    dasm_put(Dst, 12831);
     if (sse) {
-      dasm_put(Dst, 12614);
+      dasm_put(Dst, 12836);
     } else {
-      dasm_put(Dst, 10830);
+      dasm_put(Dst, 11052);
     }
-    dasm_put(Dst, 12622, offsetof(GCfuncL, uvptr), DtA(->v));
+    dasm_put(Dst, 12844, offsetof(GCfuncL, uvptr), DtA(->v));
     if (sse) {
-      dasm_put(Dst, 12631);
+      dasm_put(Dst, 12853);
     } else {
-      dasm_put(Dst, 12637);
+      dasm_put(Dst, 12859);
     }
-    dasm_put(Dst, 10306);
+    dasm_put(Dst, 10520);
     break;
   case BC_USETP:
-    dasm_put(Dst, 12640, offsetof(GCfuncL, uvptr), DtA(->v));
+    dasm_put(Dst, 12862, offsetof(GCfuncL, uvptr), DtA(->v));
     break;
   case BC_UCLO:
-    dasm_put(Dst, 12680, -BCBIAS_J*4, Dt1(->openupval), Dt1(->base), Dt1(->base));
+    dasm_put(Dst, 12902, -BCBIAS_J*4, Dt1(->openupval), Dt1(->base), Dt1(->base));
     break;
 
   case BC_FNEW:
-    dasm_put(Dst, 12736, Dt1(->base), Dt1(->base), LJ_TFUNC);
+    dasm_put(Dst, 12958, Dt1(->base), Dt1(->base), LJ_TFUNC);
     break;
 
   /* -- Table ops --------------------------------------------------------- */
 
   case BC_TNEW:
-    dasm_put(Dst, 12803, Dt1(->base), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), LJ_TTAB);
+    dasm_put(Dst, 13025, Dt1(->base), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), LJ_TTAB);
     break;
   case BC_TDUP:
-    dasm_put(Dst, 12927, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), Dt1(->base), LJ_TTAB);
+    dasm_put(Dst, 13149, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), Dt1(->base), LJ_TTAB);
     break;
 
   case BC_GGET:
-    dasm_put(Dst, 13026, Dt7(->env));
+    dasm_put(Dst, 13248, Dt7(->env));
     break;
   case BC_GSET:
-    dasm_put(Dst, 13046, Dt7(->env));
+    dasm_put(Dst, 13268, Dt7(->env));
     break;
 
   case BC_TGETV:
-    dasm_put(Dst, 13066, LJ_TTAB);
+    dasm_put(Dst, 13288, LJ_TTAB);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 13089, LJ_TISNUM);
+      dasm_put(Dst, 13311, LJ_TISNUM);
     } else {
-      dasm_put(Dst, 13103, LJ_TISNUM);
+      dasm_put(Dst, 13325, LJ_TISNUM);
       if (sse) {
-	dasm_put(Dst, 13114);
+	dasm_put(Dst, 13336);
       } else {
       }
-      dasm_put(Dst, 13135);
+      dasm_put(Dst, 13357);
     }
-    dasm_put(Dst, 13140, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_index, LJ_TNIL);
-    dasm_put(Dst, 13232, LJ_TSTR);
+    dasm_put(Dst, 13362, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_index, LJ_TNIL);
+    dasm_put(Dst, 13454, LJ_TSTR);
     break;
   case BC_TGETS:
-    dasm_put(Dst, 13250, LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), LJ_TNIL);
-    dasm_put(Dst, 13335, LJ_TNIL, DtB(->next), Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
+    dasm_put(Dst, 13472, LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), LJ_TNIL);
+    dasm_put(Dst, 13557, LJ_TNIL, DtB(->next), Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
     break;
   case BC_TGETB:
-    dasm_put(Dst, 13407, LJ_TTAB, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
-    dasm_put(Dst, 13503, LJ_TNIL);
+    dasm_put(Dst, 13629, LJ_TTAB, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
+    dasm_put(Dst, 13725, LJ_TNIL);
     break;
 
   case BC_TSETV:
-    dasm_put(Dst, 13520, LJ_TTAB);
+    dasm_put(Dst, 13742, LJ_TTAB);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 13089, LJ_TISNUM);
+      dasm_put(Dst, 13311, LJ_TISNUM);
     } else {
-      dasm_put(Dst, 13103, LJ_TISNUM);
+      dasm_put(Dst, 13325, LJ_TISNUM);
       if (sse) {
-	dasm_put(Dst, 13114);
+	dasm_put(Dst, 13336);
       } else {
       }
-      dasm_put(Dst, 13543);
+      dasm_put(Dst, 13765);
     }
-    dasm_put(Dst, 13548, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex);
-    dasm_put(Dst, 13629, LJ_TSTR, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
+    dasm_put(Dst, 13770, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex);
+    dasm_put(Dst, 13851, LJ_TSTR, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
     break;
   case BC_TSETS:
-    dasm_put(Dst, 13688, LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->nomm), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), LJ_TNIL);
-    dasm_put(Dst, 13765, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, DtB(->next));
-    dasm_put(Dst, 13852, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, LJ_TSTR, Dt1(->base), Dt1(->base), Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
+    dasm_put(Dst, 13910, LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->nomm), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), LJ_TNIL);
+    dasm_put(Dst, 13987, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, DtB(->next));
+    dasm_put(Dst, 14074, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, LJ_TSTR, Dt1(->base), Dt1(->base), Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
     break;
   case BC_TSETB:
-    dasm_put(Dst, 13944, LJ_TTAB, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable));
-    dasm_put(Dst, 14039, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
+    dasm_put(Dst, 14166, LJ_TTAB, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable));
+    dasm_put(Dst, 14261, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
     break;
 
   case BC_TSETM:
-    dasm_put(Dst, 14087, Dt6(->marked), LJ_GC_BLACK, Dt6(->asize), Dt6(->array), Dt1(->base), Dt1(->base));
-    dasm_put(Dst, 14237, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
+    dasm_put(Dst, 14309, Dt6(->marked), LJ_GC_BLACK, Dt6(->asize), Dt6(->array), Dt1(->base), Dt1(->base));
+    dasm_put(Dst, 14459, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
     break;
 
   /* -- Calls and vararg handling ----------------------------------------- */
 
   case BC_CALL: case BC_CALLM:
-    dasm_put(Dst, 11352);
+    dasm_put(Dst, 11574);
     if (op == BC_CALLM) {
-      dasm_put(Dst, 14257);
+      dasm_put(Dst, 14479);
     }
-    dasm_put(Dst, 14262, LJ_TFUNC, Dt7(->pc));
+    dasm_put(Dst, 14484, LJ_TFUNC, Dt7(->pc));
     break;
 
   case BC_CALLMT:
-    dasm_put(Dst, 14257);
+    dasm_put(Dst, 14479);
     break;
   case BC_CALLT:
-    dasm_put(Dst, 14305, LJ_TFUNC, FRAME_TYPE, Dt7(->ffid), Dt7(->pc));
-    dasm_put(Dst, 14423, FRAME_TYPE, Dt7(->pc), PC2PROTO(k), FRAME_VARG, FRAME_TYPEP, FRAME_VARG);
+    dasm_put(Dst, 14527, LJ_TFUNC, FRAME_TYPE, Dt7(->ffid), Dt7(->pc));
+    dasm_put(Dst, 14645, FRAME_TYPE, Dt7(->pc), PC2PROTO(k), FRAME_VARG, FRAME_TYPEP, FRAME_VARG);
     break;
 
   case BC_ITERC:
-    dasm_put(Dst, 14497, LJ_TFUNC, 2+1, Dt7(->pc));
+    dasm_put(Dst, 14719, LJ_TFUNC, 2+1, Dt7(->pc));
     break;
 
   case BC_ITERN:
 #if LJ_HASJIT
 #endif
-    dasm_put(Dst, 14569, Dt6(->asize), Dt6(->array), LJ_TNIL);
+    dasm_put(Dst, 14791, Dt6(->asize), Dt6(->array), LJ_TNIL);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 11218, LJ_TISNUM);
+      dasm_put(Dst, 11440, LJ_TISNUM);
     } else if (sse) {
-      dasm_put(Dst, 11313);
+      dasm_put(Dst, 11535);
     } else {
-      dasm_put(Dst, 14621);
+      dasm_put(Dst, 14843);
     }
-    dasm_put(Dst, 14627);
+    dasm_put(Dst, 14849);
     if (LJ_DUALNUM) {
     } else if (sse) {
-      dasm_put(Dst, 11183);
+      dasm_put(Dst, 11405);
     } else {
-      dasm_put(Dst, 11195);
+      dasm_put(Dst, 11417);
     }
-    dasm_put(Dst, 14640, -BCBIAS_J*4);
+    dasm_put(Dst, 14862, -BCBIAS_J*4);
     if (!LJ_DUALNUM && !sse) {
-      dasm_put(Dst, 14694);
+      dasm_put(Dst, 14916);
     }
-    dasm_put(Dst, 14700, Dt6(->hmask), sizeof(Node), Dt6(->node), DtB(->val.it), LJ_TNIL, DtB(->key), DtB(->val));
+    dasm_put(Dst, 14922, Dt6(->hmask), sizeof(Node), Dt6(->node), DtB(->val.it), LJ_TNIL, DtB(->key), DtB(->val));
     break;
 
   case BC_ISNEXT:
-    dasm_put(Dst, 14779, LJ_TFUNC, LJ_TTAB, LJ_TNIL, Dt8(->ffid), FF_next_N, -BCBIAS_J*4, BC_JMP, -BCBIAS_J*4, BC_ITERC);
+    dasm_put(Dst, 15001, LJ_TFUNC, LJ_TTAB, LJ_TNIL, Dt8(->ffid), FF_next_N, -BCBIAS_J*4, BC_JMP, -BCBIAS_J*4, BC_ITERC);
     break;
 
   case BC_VARG:
-    dasm_put(Dst, 14880, (8+FRAME_VARG), LJ_TNIL, Dt1(->maxstack));
-    dasm_put(Dst, 15047, Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top));
+    dasm_put(Dst, 15102, (8+FRAME_VARG), LJ_TNIL, Dt1(->maxstack));
+    dasm_put(Dst, 15269, Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top));
     break;
 
   /* -- Returns ----------------------------------------------------------- */
 
   case BC_RETM:
-    dasm_put(Dst, 14257);
+    dasm_put(Dst, 14479);
     break;
 
   case BC_RET: case BC_RET0: case BC_RET1:
     if (op != BC_RET0) {
-      dasm_put(Dst, 15117);
+      dasm_put(Dst, 15339);
     }
-    dasm_put(Dst, 15121, FRAME_TYPE);
+    dasm_put(Dst, 15343, FRAME_TYPE);
     switch (op) {
     case BC_RET:
-      dasm_put(Dst, 15140);
+      dasm_put(Dst, 15362);
       break;
     case BC_RET1:
-      dasm_put(Dst, 15194);
+      dasm_put(Dst, 15416);
       /* fallthrough */
     case BC_RET0:
-      dasm_put(Dst, 15204);
+      dasm_put(Dst, 15426);
     default:
       break;
     }
-    dasm_put(Dst, 15215, Dt7(->pc), PC2PROTO(k));
+    dasm_put(Dst, 15437, Dt7(->pc), PC2PROTO(k));
     if (op == BC_RET) {
-      dasm_put(Dst, 15263, LJ_TNIL);
+      dasm_put(Dst, 15485, LJ_TNIL);
     } else {
-      dasm_put(Dst, 15274, LJ_TNIL);
+      dasm_put(Dst, 15496, LJ_TNIL);
     }
-    dasm_put(Dst, 15281, -FRAME_VARG, FRAME_TYPEP);
+    dasm_put(Dst, 15503, -FRAME_VARG, FRAME_TYPEP);
     if (op != BC_RET0) {
-      dasm_put(Dst, 15305);
+      dasm_put(Dst, 15527);
     }
-    dasm_put(Dst, 4752);
+    dasm_put(Dst, 4761);
     break;
 
   /* -- Loops and branches ------------------------------------------------ */
@@ -2777,7 +2812,7 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
 
   case BC_FORL:
 #if LJ_HASJIT
-    dasm_put(Dst, 15309, HOTCOUNT_PCMASK, GG_DISP2HOT);
+    dasm_put(Dst, 15531, HOTCOUNT_PCMASK, GG_DISP2HOT, HOTCOUNT_LOOP);
 #endif
     break;
 
@@ -2789,111 +2824,111 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
   case BC_FORI:
   case BC_IFORL:
     vk = (op == BC_IFORL || op == BC_JFORL);
-    dasm_put(Dst, 15330);
+    dasm_put(Dst, 15552);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 15334, LJ_TISNUM);
+      dasm_put(Dst, 15556, LJ_TISNUM);
       if (!vk) {
-	dasm_put(Dst, 15344, LJ_TISNUM, LJ_TISNUM);
+	dasm_put(Dst, 15566, LJ_TISNUM, LJ_TISNUM);
       } else {
 #ifdef LUA_USE_ASSERT
-	dasm_put(Dst, 15373, LJ_TISNUM, LJ_TISNUM);
+	dasm_put(Dst, 15595, LJ_TISNUM, LJ_TISNUM);
 #endif
-	dasm_put(Dst, 15392);
+	dasm_put(Dst, 15614);
       }
-      dasm_put(Dst, 15411, LJ_TISNUM);
+      dasm_put(Dst, 15633, LJ_TISNUM);
       if (op == BC_FORI) {
-	dasm_put(Dst, 15422, -BCBIAS_J*4);
+	dasm_put(Dst, 15644, -BCBIAS_J*4);
       } else if (op == BC_JFORI) {
-	dasm_put(Dst, 15436, -BCBIAS_J*4, BC_JLOOP);
+	dasm_put(Dst, 15658, -BCBIAS_J*4, BC_JLOOP);
       } else if (op == BC_IFORL) {
-	dasm_put(Dst, 15454, -BCBIAS_J*4);
+	dasm_put(Dst, 15676, -BCBIAS_J*4);
       } else {
-	dasm_put(Dst, 15446, BC_JLOOP);
+	dasm_put(Dst, 15668, BC_JLOOP);
       }
-      dasm_put(Dst, 15468);
+      dasm_put(Dst, 15690);
       if (vk) {
-	dasm_put(Dst, 15493);
+	dasm_put(Dst, 15715);
       }
-      dasm_put(Dst, 15411, LJ_TISNUM);
+      dasm_put(Dst, 15633, LJ_TISNUM);
       if (op == BC_FORI) {
-	dasm_put(Dst, 15502);
+	dasm_put(Dst, 15724);
       } else if (op == BC_JFORI) {
-	dasm_put(Dst, 15507, -BCBIAS_J*4, BC_JLOOP);
+	dasm_put(Dst, 15729, -BCBIAS_J*4, BC_JLOOP);
       } else if (op == BC_IFORL) {
-	dasm_put(Dst, 15521);
+	dasm_put(Dst, 15743);
       } else {
-	dasm_put(Dst, 15517, BC_JLOOP);
+	dasm_put(Dst, 15739, BC_JLOOP);
       }
-      dasm_put(Dst, 15526);
+      dasm_put(Dst, 15748);
     } else if (!vk) {
-      dasm_put(Dst, 15533, LJ_TISNUM);
+      dasm_put(Dst, 15755, LJ_TISNUM);
     }
     if (!vk) {
-      dasm_put(Dst, 15539, LJ_TISNUM);
+      dasm_put(Dst, 15761, LJ_TISNUM);
     } else {
 #ifdef LUA_USE_ASSERT
-      dasm_put(Dst, 15553, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 15775, LJ_TISNUM, LJ_TISNUM);
 #endif
     }
-    dasm_put(Dst, 15572);
+    dasm_put(Dst, 15794);
     if (!vk) {
-      dasm_put(Dst, 15576, LJ_TISNUM);
+      dasm_put(Dst, 15798, LJ_TISNUM);
     }
     if (sse) {
-      dasm_put(Dst, 15585);
+      dasm_put(Dst, 15807);
       if (vk) {
-	dasm_put(Dst, 15597);
+	dasm_put(Dst, 15819);
       } else {
-	dasm_put(Dst, 15616);
+	dasm_put(Dst, 15838);
       }
-      dasm_put(Dst, 15621);
+      dasm_put(Dst, 15843);
     } else {
-      dasm_put(Dst, 15634);
+      dasm_put(Dst, 15856);
       if (vk) {
-	dasm_put(Dst, 15640);
+	dasm_put(Dst, 15862);
       } else {
-	dasm_put(Dst, 15656);
+	dasm_put(Dst, 15878);
       }
-      dasm_put(Dst, 15664);
+      dasm_put(Dst, 15886);
       if (cmov) {
-      dasm_put(Dst, 10261);
+      dasm_put(Dst, 10480);
       } else {
-      dasm_put(Dst, 10267);
+      dasm_put(Dst, 10486);
       }
       if (!cmov) {
-	dasm_put(Dst, 15669);
+	dasm_put(Dst, 15891);
       }
     }
     if (op == BC_FORI) {
       if (LJ_DUALNUM) {
-	dasm_put(Dst, 15675);
+	dasm_put(Dst, 15897);
       } else {
-	dasm_put(Dst, 15680, -BCBIAS_J*4);
+	dasm_put(Dst, 15902, -BCBIAS_J*4);
       }
     } else if (op == BC_JFORI) {
-      dasm_put(Dst, 15690, -BCBIAS_J*4, BC_JLOOP);
+      dasm_put(Dst, 15912, -BCBIAS_J*4, BC_JLOOP);
     } else if (op == BC_IFORL) {
       if (LJ_DUALNUM) {
-	dasm_put(Dst, 15704);
+	dasm_put(Dst, 15926);
       } else {
-	dasm_put(Dst, 15709, -BCBIAS_J*4);
+	dasm_put(Dst, 15931, -BCBIAS_J*4);
       }
     } else {
-      dasm_put(Dst, 15700, BC_JLOOP);
+      dasm_put(Dst, 15922, BC_JLOOP);
     }
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 10190);
+      dasm_put(Dst, 10409);
     } else {
-      dasm_put(Dst, 10964);
+      dasm_put(Dst, 11186);
     }
     if (sse) {
-      dasm_put(Dst, 15719);
+      dasm_put(Dst, 15941);
     }
     break;
 
   case BC_ITERL:
 #if LJ_HASJIT
-    dasm_put(Dst, 15309, HOTCOUNT_PCMASK, GG_DISP2HOT);
+    dasm_put(Dst, 15531, HOTCOUNT_PCMASK, GG_DISP2HOT, HOTCOUNT_LOOP);
 #endif
     break;
 
@@ -2902,33 +2937,33 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
     break;
 #endif
   case BC_IITERL:
-    dasm_put(Dst, 15730, LJ_TNIL);
+    dasm_put(Dst, 15952, LJ_TNIL);
     if (op == BC_JITERL) {
-      dasm_put(Dst, 15745, BC_JLOOP);
+      dasm_put(Dst, 15967, BC_JLOOP);
     } else {
-      dasm_put(Dst, 15759, -BCBIAS_J*4);
+      dasm_put(Dst, 15981, -BCBIAS_J*4);
     }
-    dasm_put(Dst, 10304);
+    dasm_put(Dst, 10518);
     break;
 
   case BC_LOOP:
 #if LJ_HASJIT
-    dasm_put(Dst, 15309, HOTCOUNT_PCMASK, GG_DISP2HOT);
+    dasm_put(Dst, 15531, HOTCOUNT_PCMASK, GG_DISP2HOT, HOTCOUNT_LOOP);
 #endif
     break;
 
   case BC_ILOOP:
-    dasm_put(Dst, 10306);
+    dasm_put(Dst, 10520);
     break;
 
   case BC_JLOOP:
 #if LJ_HASJIT
-    dasm_put(Dst, 15775, DISPATCH_J(trace), DtD(->mcode), DISPATCH_GL(jit_base), DISPATCH_GL(jit_L));
+    dasm_put(Dst, 15997, DISPATCH_J(trace), DtD(->mcode), DISPATCH_GL(jit_base), DISPATCH_GL(jit_L));
 #endif
     break;
 
   case BC_JMP:
-    dasm_put(Dst, 15816, -BCBIAS_J*4);
+    dasm_put(Dst, 16038, -BCBIAS_J*4);
     break;
 
   /* -- Function headers -------------------------------------------------- */
@@ -2942,7 +2977,7 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
 
   case BC_FUNCF:
 #if LJ_HASJIT
-    dasm_put(Dst, 15842, HOTCOUNT_PCMASK, GG_DISP2HOT);
+    dasm_put(Dst, 16064, HOTCOUNT_PCMASK, GG_DISP2HOT, HOTCOUNT_CALL);
 #endif
   case BC_FUNCV:  /* NYI: compiled vararg functions. */
     break;
@@ -2952,47 +2987,47 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
     break;
 #endif
   case BC_IFUNCF:
-    dasm_put(Dst, 15863, -4+PC2PROTO(k), Dt1(->maxstack), -4+PC2PROTO(numparams));
+    dasm_put(Dst, 16085, -4+PC2PROTO(k), Dt1(->maxstack), -4+PC2PROTO(numparams));
     if (op == BC_JFUNCF) {
-      dasm_put(Dst, 15894, BC_JLOOP);
+      dasm_put(Dst, 16116, BC_JLOOP);
     } else {
-      dasm_put(Dst, 10306);
+      dasm_put(Dst, 10520);
     }
-    dasm_put(Dst, 15903, LJ_TNIL);
+    dasm_put(Dst, 16125, LJ_TNIL);
     break;
 
   case BC_JFUNCV:
 #if !LJ_HASJIT
     break;
 #endif
-    dasm_put(Dst, 9413);
+    dasm_put(Dst, 9422);
     break;  /* NYI: compiled vararg functions. */
 
   case BC_IFUNCV:
-    dasm_put(Dst, 15925, FRAME_VARG, Dt1(->maxstack), -4+PC2PROTO(numparams), LJ_TNIL);
+    dasm_put(Dst, 16147, FRAME_VARG, Dt1(->maxstack), -4+PC2PROTO(numparams), LJ_TNIL);
     if (op == BC_JFUNCV) {
-      dasm_put(Dst, 15894, BC_JLOOP);
+      dasm_put(Dst, 16116, BC_JLOOP);
     } else {
-      dasm_put(Dst, 16022, -4+PC2PROTO(k));
+      dasm_put(Dst, 16244, -4+PC2PROTO(k));
     }
-    dasm_put(Dst, 16047, LJ_TNIL);
+    dasm_put(Dst, 16269, LJ_TNIL);
     break;
 
   case BC_FUNCC:
   case BC_FUNCCW:
-    dasm_put(Dst, 16069, Dt8(->f), Dt1(->base), 8*LUA_MINSTACK, Dt1(->maxstack), Dt1(->top));
+    dasm_put(Dst, 16291, Dt8(->f), Dt1(->base), 8*LUA_MINSTACK, Dt1(->maxstack), Dt1(->top));
     if (op == BC_FUNCC) {
-      dasm_put(Dst, 2424);
+      dasm_put(Dst, 2433);
     } else {
-      dasm_put(Dst, 16099);
+      dasm_put(Dst, 16321);
     }
-    dasm_put(Dst, 16107, DISPATCH_GL(vmstate), ~LJ_VMST_C);
+    dasm_put(Dst, 16329, DISPATCH_GL(vmstate), ~LJ_VMST_C);
     if (op == BC_FUNCC) {
-      dasm_put(Dst, 16117);
+      dasm_put(Dst, 16339);
     } else {
-      dasm_put(Dst, 16122, DISPATCH_GL(wrapf));
+      dasm_put(Dst, 16344, DISPATCH_GL(wrapf));
     }
-    dasm_put(Dst, 16128, DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base), Dt1(->top));
+    dasm_put(Dst, 16350, DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base), Dt1(->top));
     break;
 
   /* ---------------------------------------------------------------------- */
@@ -3020,7 +3055,7 @@ static int build_backend(BuildCtx *ctx)
 
   build_subroutines(ctx, cmov, sse);
 
-  dasm_put(Dst, 16154);
+  dasm_put(Dst, 16376);
   for (op = 0; op < BC__MAX; op++)
     build_ins(ctx, (BCOp)op, op, cmov, sse);
 
@@ -3030,6 +3065,7 @@ static int build_backend(BuildCtx *ctx)
 /* Emit pseudo frame-info for all assembler functions. */
 static void emit_asm_debug(BuildCtx *ctx)
 {
+  int fcofs = (int)((uint8_t *)ctx->glob[GLOB_vm_ffi_call] - ctx->code);
 #if LJ_64
 #define SZPTR	"8"
 #define BSZPTR	"3"
@@ -3063,22 +3099,49 @@ static void emit_asm_debug(BuildCtx *ctx)
 	"\t.long .LEFDE0-.LASFDE0\n"
 	".LASFDE0:\n"
 	"\t.long .Lframe0\n"
-	"\t.long .Lbegin\n"
-	"\t.long %d\n"
-	"\t.byte 0xe\n\t.uleb128 %d\n"		/* def_cfa_offset */
 #if LJ_64
+	"\t.quad .Lbegin\n"
+	"\t.quad %d\n"
+	"\t.byte 0xe\n\t.uleb128 %d\n"		/* def_cfa_offset */
 	"\t.byte 0x86\n\t.uleb128 0x2\n"	/* offset rbp */
 	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset rbx */
 	"\t.byte 0x8f\n\t.uleb128 0x4\n"	/* offset r15 */
 	"\t.byte 0x8e\n\t.uleb128 0x5\n"	/* offset r14 */
 #else
+	"\t.long .Lbegin\n"
+	"\t.long %d\n"
+	"\t.byte 0xe\n\t.uleb128 %d\n"		/* def_cfa_offset */
 	"\t.byte 0x85\n\t.uleb128 0x2\n"	/* offset ebp */
 	"\t.byte 0x87\n\t.uleb128 0x3\n"	/* offset edi */
 	"\t.byte 0x86\n\t.uleb128 0x4\n"	/* offset esi */
 	"\t.byte 0x83\n\t.uleb128 0x5\n"	/* offset ebx */
 #endif
 	"\t.align " SZPTR "\n"
-	".LEFDE0:\n\n", (int)ctx->codesz, CFRAME_SIZE);
+	".LEFDE0:\n\n", fcofs, CFRAME_SIZE);
+#if LJ_HASFFI
+    fprintf(ctx->fp,
+	".LSFDE1:\n"
+	"\t.long .LEFDE1-.LASFDE1\n"
+	".LASFDE1:\n"
+	"\t.long .Lframe0\n"
+#if LJ_64
+	"\t.quad lj_vm_ffi_call\n"
+	"\t.quad %d\n"
+	"\t.byte 0xe\n\t.uleb128 16\n"		/* def_cfa_offset */
+	"\t.byte 0x86\n\t.uleb128 0x2\n"	/* offset rbp */
+	"\t.byte 0xd\n\t.uleb128 0x6\n"		/* def_cfa_register rbp */
+	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset rbx */
+#else
+	"\t.long lj_vm_ffi_call\n"
+	"\t.long %d\n"
+	"\t.byte 0xe\n\t.uleb128 8\n"		/* def_cfa_offset */
+	"\t.byte 0x85\n\t.uleb128 0x2\n"	/* offset ebp */
+	"\t.byte 0xd\n\t.uleb128 0x5\n"		/* def_cfa_register ebp */
+	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset ebx */
+#endif
+	"\t.align " SZPTR "\n"
+	".LEFDE1:\n\n", (int)ctx->codesz - fcofs);
+#endif
 #if (defined(__sun__) && defined(__svr4__)) || defined(__solaris_)
     fprintf(ctx->fp, "\t.section .eh_frame,\"aw\",@progbits\n");
 #else
@@ -3103,10 +3166,10 @@ static void emit_asm_debug(BuildCtx *ctx)
 	"\t.align " SZPTR "\n"
 	".LECIE1:\n\n");
     fprintf(ctx->fp,
-	".LSFDE1:\n"
-	"\t.long .LEFDE1-.LASFDE1\n"
-	".LASFDE1:\n"
-	"\t.long .LASFDE1-.Lframe1\n"
+	".LSFDE2:\n"
+	"\t.long .LEFDE2-.LASFDE2\n"
+	".LASFDE2:\n"
+	"\t.long .LASFDE2-.Lframe1\n"
 	"\t.long .Lbegin-.\n"
 	"\t.long %d\n"
 	"\t.uleb128 0\n"			/* augmentation length */
@@ -3123,7 +3186,46 @@ static void emit_asm_debug(BuildCtx *ctx)
 	"\t.byte 0x83\n\t.uleb128 0x5\n"	/* offset ebx */
 #endif
 	"\t.align " SZPTR "\n"
-	".LEFDE1:\n\n", (int)ctx->codesz, CFRAME_SIZE);
+	".LEFDE2:\n\n", fcofs, CFRAME_SIZE);
+#if LJ_HASFFI
+    fprintf(ctx->fp,
+	".Lframe2:\n"
+	"\t.long .LECIE2-.LSCIE2\n"
+	".LSCIE2:\n"
+	"\t.long 0\n"
+	"\t.byte 0x1\n"
+	"\t.string \"zR\"\n"
+	"\t.uleb128 0x1\n"
+	"\t.sleb128 -" SZPTR "\n"
+	"\t.byte " REG_RA "\n"
+	"\t.uleb128 1\n"			/* augmentation length */
+	"\t.byte 0x1b\n"			/* pcrel|sdata4 */
+	"\t.byte 0xc\n\t.uleb128 " REG_SP "\n\t.uleb128 " SZPTR "\n"
+	"\t.byte 0x80+" REG_RA "\n\t.uleb128 0x1\n"
+	"\t.align " SZPTR "\n"
+	".LECIE2:\n\n");
+    fprintf(ctx->fp,
+	".LSFDE3:\n"
+	"\t.long .LEFDE3-.LASFDE3\n"
+	".LASFDE3:\n"
+	"\t.long .LASFDE3-.Lframe2\n"
+	"\t.long lj_vm_ffi_call-.\n"
+	"\t.long %d\n"
+	"\t.uleb128 0\n"			/* augmentation length */
+#if LJ_64
+	"\t.byte 0xe\n\t.uleb128 16\n"		/* def_cfa_offset */
+	"\t.byte 0x86\n\t.uleb128 0x2\n"	/* offset rbp */
+	"\t.byte 0xd\n\t.uleb128 0x6\n"		/* def_cfa_register rbp */
+	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset rbx */
+#else
+	"\t.byte 0xe\n\t.uleb128 8\n"		/* def_cfa_offset */
+	"\t.byte 0x85\n\t.uleb128 0x2\n"	/* offset ebp */
+	"\t.byte 0xd\n\t.uleb128 0x5\n"		/* def_cfa_register ebp */
+	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset ebx */
+#endif
+	"\t.align " SZPTR "\n"
+	".LEFDE3:\n\n", (int)ctx->codesz - fcofs);
+#endif
     break;
   case BUILD_coffasm:
     fprintf(ctx->fp, "\t.section .eh_frame,\"dr\"\n");
@@ -3174,6 +3276,9 @@ static void emit_asm_debug(BuildCtx *ctx)
   ** Or a linker. Or a plastic case. But I digress.
   */
   case BUILD_machasm: {
+#if LJ_HASFFI
+    int fcsize = 0;
+#endif
     int i;
     fprintf(ctx->fp, "\t.section __TEXT,__eh_frame,coalesced,no_toc+strip_static_syms+live_support\n");
     fprintf(ctx->fp,
@@ -3205,6 +3310,9 @@ static void emit_asm_debug(BuildCtx *ctx)
       const char *name = ctx->sym[i].name;
       int32_t size = ctx->sym[i+1].ofs - ctx->sym[i].ofs;
       if (size == 0) continue;
+#if LJ_HASFFI
+      if (!strcmp(name, "_lj_vm_ffi_call")) { fcsize = size; continue; }
+#endif
       fprintf(ctx->fp,
 	  "%s.eh:\n"
 	  "LSFDE%d:\n"
@@ -3214,23 +3322,72 @@ static void emit_asm_debug(BuildCtx *ctx)
 	  "\t.long LASFDE%d-EH_frame1\n"
 	  "\t.long %s-.\n"
 	  "\t.long %d\n"
-	  "\t.byte 0\n"			/* augmentation length */
+	  "\t.byte 0\n"				/* augmentation length */
 	  "\t.byte 0xe\n\t.byte %d\n"		/* def_cfa_offset */
 #if LJ_64
-	  "\t.byte 0x86\n\t.byte 0x2\n"	/* offset rbp */
-	  "\t.byte 0x83\n\t.byte 0x3\n"	/* offset rbx */
-	  "\t.byte 0x8f\n\t.byte 0x4\n"	/* offset r15 */
-	  "\t.byte 0x8e\n\t.byte 0x5\n"	/* offset r14 */
+	  "\t.byte 0x86\n\t.byte 0x2\n"		/* offset rbp */
+	  "\t.byte 0x83\n\t.byte 0x3\n"		/* offset rbx */
+	  "\t.byte 0x8f\n\t.byte 0x4\n"		/* offset r15 */
+	  "\t.byte 0x8e\n\t.byte 0x5\n"		/* offset r14 */
 #else
-	  "\t.byte 0x84\n\t.byte 0x2\n"	/* offset ebp (4 for MACH-O)*/
-	  "\t.byte 0x87\n\t.byte 0x3\n"	/* offset edi */
-	  "\t.byte 0x86\n\t.byte 0x4\n"	/* offset esi */
-	  "\t.byte 0x83\n\t.byte 0x5\n"	/* offset ebx */
+	  "\t.byte 0x84\n\t.byte 0x2\n"		/* offset ebp (4 for MACH-O)*/
+	  "\t.byte 0x87\n\t.byte 0x3\n"		/* offset edi */
+	  "\t.byte 0x86\n\t.byte 0x4\n"		/* offset esi */
+	  "\t.byte 0x83\n\t.byte 0x5\n"		/* offset ebx */
 #endif
 	  "\t.align " BSZPTR "\n"
 	  "LEFDE%d:\n\n",
 	  name, i, i, i, i, i, i, i, name, size, CFRAME_SIZE, i);
     }
+#if LJ_HASFFI
+    if (fcsize) {
+      fprintf(ctx->fp,
+	  "EH_frame2:\n"
+	  "\t.set L$set$y,LECIEY-LSCIEY\n"
+	  "\t.long L$set$y\n"
+	  "LSCIEY:\n"
+	  "\t.long 0\n"
+	  "\t.byte 0x1\n"
+	  "\t.ascii \"zR\\0\"\n"
+	  "\t.byte 0x1\n"
+	  "\t.byte 128-" SZPTR "\n"
+	  "\t.byte " REG_RA "\n"
+	  "\t.byte 1\n"				/* augmentation length */
+#if LJ_64
+	  "\t.byte 0x1b\n"			/* pcrel|sdata4 */
+	  "\t.byte 0xc\n\t.byte " REG_SP "\n\t.byte " SZPTR "\n"
+#else
+	  "\t.byte 0x1b\n"			/* pcrel|sdata4 */
+	  "\t.byte 0xc\n\t.byte 0x5\n\t.byte 0x4\n"  /* esp=5 on 32 bit MACH. */
+#endif
+	  "\t.byte 0x80+" REG_RA "\n\t.byte 0x1\n"
+	  "\t.align " BSZPTR "\n"
+	  "LECIEY:\n\n");
+      fprintf(ctx->fp,
+	  "_lj_vm_ffi_call.eh:\n"
+	  "LSFDEY:\n"
+	  "\t.set L$set$yy,LEFDEY-LASFDEY\n"
+	  "\t.long L$set$yy\n"
+	  "LASFDEY:\n"
+	  "\t.long LASFDEY-EH_frame2\n"
+	  "\t.long _lj_vm_ffi_call-.\n"
+	  "\t.long %d\n"
+	  "\t.byte 0\n"				/* augmentation length */
+#if LJ_64
+	  "\t.byte 0xe\n\t.byte 16\n"		/* def_cfa_offset */
+	  "\t.byte 0x86\n\t.byte 0x2\n"		/* offset rbp */
+	  "\t.byte 0xd\n\t.uleb128 0x6\n"	/* def_cfa_register rbp */
+	  "\t.byte 0x83\n\t.byte 0x3\n"		/* offset rbx */
+#else
+	  "\t.byte 0xe\n\t.byte 8\n"		/* def_cfa_offset */
+	  "\t.byte 0x84\n\t.byte 0x2\n"		/* offset ebp (4 for MACH-O)*/
+	  "\t.byte 0xd\n\t.uleb128 0x4\n"	/* def_cfa_register ebp */
+	  "\t.byte 0x83\n\t.byte 0x3\n"		/* offset ebx */
+#endif
+	  "\t.align " BSZPTR "\n"
+	  "LEFDEY:\n\n", fcsize);
+    }
+#endif
 #if LJ_64
     fprintf(ctx->fp, "\t.subsections_via_symbols\n");
 #else
diff --git a/third_party/luajit/src/buildvm_x64win.h b/third_party/luajit/src/buildvm_x64win.h
index bb8132841bf70fd4605fe90679cca763c0de7849..533d5b006a788a11a42ffc0a509c924fe901b3c2 100644
--- a/third_party/luajit/src/buildvm_x64win.h
+++ b/third_party/luajit/src/buildvm_x64win.h
@@ -12,7 +12,7 @@
 #define DASM_SECTION_CODE_OP	0
 #define DASM_SECTION_CODE_SUB	1
 #define DASM_MAXSECTION		2
-static const unsigned char build_actionlist[16011] = {
+static const unsigned char build_actionlist[16196] = {
   254,1,248,10,252,247,198,237,15,132,244,11,131,230,252,248,41,252,242,72,
   141,76,49,252,248,139,114,252,252,199,68,10,4,237,248,12,131,192,1,137,68,
   36,84,252,247,198,237,15,132,244,13,248,14,129,252,246,239,252,247,198,237,
@@ -50,656 +50,665 @@ static const unsigned char build_actionlist[16011] = {
   124,36,88,72,139,189,233,72,137,124,36,104,72,137,165,233,65,252,255,209,
   133,192,15,132,244,15,137,193,190,237,252,233,244,2,248,11,1,209,131,230,
   252,248,137,213,41,252,242,199,68,193,252,252,237,137,200,139,117,252,244,
-  72,99,77,252,240,133,201,15,132,244,247,255,72,141,61,245,72,1,252,249,139,
-  122,252,248,139,191,233,139,191,233,252,255,225,248,1,41,213,193,252,237,
-  3,141,69,252,255,252,233,244,32,248,33,15,182,78,252,255,131,252,237,16,141,
-  12,202,41,252,233,15,132,244,34,252,247,217,193,252,233,3,65,137,200,139,
-  76,36,96,137,145,233,72,139,0,72,137,69,0,137,252,234,252,233,244,35,248,
-  36,137,68,36,80,199,68,36,84,237,72,141,68,36,80,128,126,252,252,235,15,133,
-  244,247,141,139,233,137,41,199,65,4,237,255,137,205,252,233,244,248,248,37,
-  15,182,70,252,254,255,199,68,36,84,237,137,68,36,80,255,252,242,15,42,192,
-  252,242,15,17,68,36,80,255,72,141,68,36,80,252,233,244,247,248,38,15,182,
-  70,252,254,141,4,194,248,1,15,182,110,252,255,141,44,252,234,248,2,139,76,
-  36,96,137,145,233,137,252,234,73,137,192,137,205,137,116,36,100,232,251,1,
-  1,139,149,233,133,192,15,132,244,249,248,34,15,182,78,252,253,72,139,40,72,
-  137,44,202,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,252,
-  235,248,3,139,141,233,137,113,252,244,141,177,233,41,214,139,105,252,248,
-  184,237,252,233,244,30,248,39,137,68,36,80,199,68,36,84,237,72,141,68,36,
-  80,128,126,252,252,235,15,133,244,247,255,141,139,233,137,41,199,65,4,237,
-  137,205,252,233,244,248,248,40,15,182,70,252,254,255,72,141,68,36,80,252,
-  233,244,247,248,41,15,182,70,252,254,141,4,194,248,1,15,182,110,252,255,141,
-  44,252,234,248,2,139,76,36,96,137,145,233,137,252,234,73,137,192,137,205,
-  137,116,36,100,232,251,1,2,139,149,233,133,192,15,132,244,249,15,182,78,252,
-  253,72,139,44,202,72,137,40,248,42,139,6,15,182,204,15,182,232,131,198,4,
-  193,232,16,252,255,36,252,235,248,3,139,141,233,137,113,252,244,15,182,70,
-  252,253,72,139,44,194,72,137,105,16,141,177,233,41,214,139,105,252,248,184,
-  237,252,233,244,30,248,43,139,108,36,96,137,149,233,68,141,4,194,141,20,202,
-  137,252,233,68,15,182,78,252,252,137,116,36,100,232,251,1,3,248,3,139,149,
-  233,255,131,252,248,1,15,135,244,44,248,4,141,118,4,15,130,244,252,248,5,
-  15,183,70,252,254,141,180,253,134,233,248,6,139,6,15,182,204,15,182,232,131,
-  198,4,193,232,16,252,255,36,252,235,248,45,131,198,4,129,120,253,4,239,15,
-  130,244,5,252,233,244,6,248,46,129,120,253,4,239,252,233,244,4,248,47,131,
-  252,238,4,65,137,192,65,137,252,233,139,108,36,96,137,149,233,255,137,202,
-  137,252,233,137,116,36,100,232,251,1,4,252,233,244,3,248,48,255,131,252,238,
-  4,139,108,36,96,137,149,233,137,252,233,139,86,252,252,137,116,36,100,232,
-  251,1,5,252,233,244,3,255,248,49,255,15,182,110,252,255,255,248,50,141,4,
-  199,252,233,244,247,248,51,255,248,52,141,4,199,141,44,252,234,149,252,233,
-  244,248,248,53,141,4,194,137,197,252,233,244,248,248,54,255,248,55,141,4,
-  194,248,1,141,44,252,234,248,2,141,12,202,65,137,232,65,137,193,15,182,70,
-  252,252,137,68,36,32,139,108,36,96,137,149,233,137,202,137,252,233,137,116,
-  36,100,232,251,1,6,139,149,233,133,192,15,132,244,42,248,44,137,193,41,208,
-  137,113,252,244,141,176,233,184,237,252,233,244,28,248,56,139,108,36,96,137,
-  149,233,141,20,194,137,252,233,137,116,36,100,232,251,1,7,139,149,233,255,
-  133,192,15,133,244,44,15,183,70,252,254,139,12,194,252,233,244,57,255,252,
-  233,244,44,255,248,58,141,76,202,8,248,29,137,76,36,84,137,68,36,80,131,252,
-  233,8,139,108,36,96,137,149,233,137,202,68,141,4,193,137,252,233,137,116,
-  36,100,232,251,1,8,139,149,233,139,76,36,84,139,68,36,80,139,105,252,248,
-  131,192,1,57,215,15,132,244,59,137,202,137,114,252,252,139,181,233,139,14,
-  15,182,252,233,15,182,205,131,198,4,252,255,36,252,235,248,60,139,108,36,
-  96,137,149,233,137,202,137,252,233,137,116,36,100,232,251,1,9,139,149,233,
-  139,70,252,252,15,182,204,15,182,232,193,232,16,252,255,164,253,252,235,233,
-  248,61,129,252,248,239,15,130,244,62,139,106,4,129,252,253,239,15,131,244,
-  62,139,114,252,252,137,68,36,84,137,106,252,252,139,42,137,106,252,248,131,
-  232,2,15,132,244,248,255,137,209,248,1,131,193,8,72,139,41,72,137,105,252,
-  248,131,232,1,15,133,244,1,248,2,139,68,36,84,252,233,244,63,248,64,129,252,
-  248,239,15,130,244,62,139,106,4,137,252,233,193,252,249,15,131,252,249,252,
-  254,15,132,244,249,184,237,252,247,213,57,232,255,15,71,197,255,15,134,244,
-  247,137,232,248,1,255,248,2,139,106,252,248,139,132,253,197,233,139,114,252,
-  252,199,66,252,252,237,137,66,252,248,252,233,244,65,248,3,184,237,252,233,
-  244,2,248,66,129,252,248,239,15,130,244,62,139,106,4,139,114,252,252,129,
-  252,253,239,15,133,244,252,248,1,139,42,139,173,233,248,2,133,252,237,199,
-  66,252,252,237,255,15,132,244,65,139,131,233,199,66,252,252,237,137,106,252,
-  248,139,141,233,35,136,233,105,201,239,3,141,233,248,3,129,185,233,239,15,
-  133,244,250,57,129,233,15,132,244,251,248,4,139,137,233,133,201,15,133,244,
-  3,255,252,233,244,65,248,5,139,105,4,129,252,253,239,15,132,244,65,139,1,
-  137,106,252,252,137,66,252,248,252,233,244,65,248,6,129,252,253,239,15,132,
-  244,1,129,252,253,239,15,135,244,254,129,252,253,239,15,134,244,253,189,237,
-  252,233,244,254,248,7,255,189,237,248,8,252,247,213,139,172,253,171,233,252,
-  233,244,2,248,67,129,252,248,239,15,130,244,62,129,122,253,4,239,15,133,244,
-  62,139,42,131,189,233,0,15,133,244,62,129,122,253,12,239,15,133,244,62,139,
-  66,8,137,133,233,139,114,252,252,199,66,252,252,237,255,137,106,252,248,252,
-  246,133,233,235,15,132,244,247,128,165,233,235,139,131,233,137,171,233,137,
-  133,233,248,1,252,233,244,65,248,68,129,252,248,239,15,130,244,62,129,122,
-  253,4,239,15,133,244,62,137,213,68,141,66,8,139,18,139,76,36,96,232,251,1,
-  10,137,252,234,72,139,40,139,114,252,252,72,137,106,252,248,252,233,244,65,
-  248,69,255,129,252,248,239,15,133,244,62,129,122,253,4,239,255,15,133,244,
-  247,139,42,252,233,244,70,248,1,15,135,244,62,255,15,131,244,62,255,252,242,
-  15,16,2,252,233,244,71,255,221,2,252,233,244,72,255,248,73,129,252,248,239,
-  15,130,244,62,139,114,252,252,129,122,253,4,239,15,133,244,249,139,2,248,
-  2,199,66,252,252,237,137,66,252,248,252,233,244,65,248,3,129,122,253,4,239,
-  15,135,244,62,131,187,233,0,15,133,244,62,139,171,233,59,171,233,255,15,130,
-  244,247,232,244,74,248,1,139,108,36,96,137,149,233,137,116,36,100,137,252,
-  233,255,232,251,1,11,255,232,251,1,12,255,139,149,233,252,233,244,2,248,75,
-  129,252,248,239,15,130,244,62,15,132,244,248,248,1,129,122,253,4,239,15,133,
-  244,62,139,108,36,96,137,149,233,137,149,233,139,114,252,252,68,141,66,8,
-  139,18,137,252,233,137,116,36,100,232,251,1,13,139,149,233,133,192,15,132,
-  244,249,72,139,106,8,72,139,66,16,72,137,106,252,248,72,137,2,248,76,184,
-  237,255,252,233,244,77,248,2,199,66,12,237,252,233,244,1,248,3,199,66,252,
-  252,237,252,233,244,65,248,78,129,252,248,239,15,130,244,62,139,42,129,122,
-  253,4,239,15,133,244,62,255,131,189,233,0,15,133,244,62,255,139,106,252,248,
-  139,133,233,139,114,252,252,199,66,252,252,237,137,66,252,248,199,66,12,237,
-  184,237,252,233,244,77,248,79,129,252,248,239,15,130,244,62,129,122,253,4,
-  239,15,133,244,62,129,122,253,12,239,255,139,114,252,252,255,139,66,8,131,
-  192,1,199,66,252,252,237,137,66,252,248,255,252,242,15,16,66,8,72,189,237,
-  237,102,72,15,110,205,252,242,15,88,193,252,242,15,45,192,252,242,15,17,66,
-  252,248,255,139,42,59,133,233,15,131,244,248,193,224,3,3,133,233,248,1,129,
-  120,253,4,239,15,132,244,80,72,139,40,72,137,42,252,233,244,76,248,2,131,
-  189,233,0,15,132,244,80,137,252,233,137,213,137,194,232,251,1,14,137,252,
-  234,133,192,15,133,244,1,248,80,184,237,252,233,244,77,248,81,255,139,106,
-  252,248,139,133,233,139,114,252,252,199,66,252,252,237,137,66,252,248,255,
-  199,66,12,237,199,66,8,0,0,0,0,255,15,87,192,252,242,15,17,66,8,255,217,252,
-  238,221,90,8,255,184,237,252,233,244,77,248,82,129,252,248,239,15,130,244,
-  62,141,74,8,131,232,1,190,237,248,1,15,182,171,233,193,252,237,235,131,229,
-  1,1,252,238,252,233,244,28,248,83,129,252,248,239,15,130,244,62,129,122,253,
-  12,239,15,133,244,62,255,139,106,4,137,106,12,199,66,4,237,139,42,139,114,
-  8,137,106,8,137,50,141,74,16,131,232,2,190,237,252,233,244,1,248,84,129,252,
-  248,239,15,130,244,62,139,42,139,114,252,252,137,116,36,100,137,108,36,80,
-  129,122,253,4,239,15,133,244,62,72,131,189,233,0,15,133,244,62,128,189,233,
-  235,15,135,244,62,139,141,233,15,132,244,247,255,59,141,233,15,132,244,62,
-  248,1,141,116,193,252,240,59,181,233,15,135,244,62,137,181,233,139,108,36,
-  96,137,149,233,131,194,8,137,149,233,141,108,194,232,72,41,252,245,57,206,
-  15,132,244,249,248,2,72,139,4,46,72,137,70,252,248,131,252,238,8,57,206,15,
-  133,244,2,248,3,137,202,139,76,36,80,232,244,25,199,131,233,237,255,139,108,
-  36,96,139,116,36,80,139,149,233,129,252,248,239,15,135,244,254,248,4,139,
-  142,233,139,190,233,137,142,233,137,252,254,41,206,15,132,244,252,141,4,50,
-  193,252,238,3,59,133,233,15,135,244,255,137,213,72,41,205,248,5,72,139,1,
-  72,137,4,41,131,193,8,57,252,249,15,133,244,5,248,6,141,70,2,199,66,252,252,
-  237,248,7,139,116,36,100,137,68,36,84,72,199,193,252,248,252,255,252,255,
-  252,255,252,247,198,237,255,15,132,244,13,252,233,244,14,248,8,199,66,252,
-  252,237,139,142,233,131,252,233,8,137,142,233,72,139,1,72,137,2,184,237,252,
-  233,244,7,248,9,139,76,36,80,137,185,233,137,252,242,137,252,233,232,251,
-  1,0,139,116,36,80,139,149,233,252,233,244,4,248,85,139,106,252,248,139,173,
-  233,139,114,252,252,137,116,36,100,137,108,36,80,72,131,189,233,0,15,133,
-  244,62,255,128,189,233,235,15,135,244,62,139,141,233,15,132,244,247,59,141,
-  233,15,132,244,62,248,1,141,116,193,252,248,59,181,233,15,135,244,62,137,
-  181,233,139,108,36,96,137,149,233,137,149,233,141,108,194,252,240,72,41,252,
-  245,57,206,15,132,244,249,248,2,255,72,139,4,46,72,137,70,252,248,131,252,
-  238,8,57,206,15,133,244,2,248,3,137,202,139,76,36,80,232,244,25,199,131,233,
-  237,139,108,36,96,139,116,36,80,139,149,233,129,252,248,239,15,135,244,254,
-  248,4,139,142,233,139,190,233,137,142,233,137,252,254,41,206,15,132,244,252,
-  141,4,50,193,252,238,3,59,133,233,15,135,244,255,255,137,213,72,41,205,248,
-  5,72,139,1,72,137,4,41,131,193,8,57,252,249,15,133,244,5,248,6,141,70,1,248,
-  7,139,116,36,100,137,68,36,84,49,201,252,247,198,237,15,132,244,13,252,233,
-  244,14,248,8,137,252,242,137,252,233,232,251,1,15,248,9,139,76,36,80,137,
-  185,233,137,252,242,137,252,233,232,251,1,0,139,116,36,80,139,149,233,252,
-  233,244,4,248,86,139,108,36,96,72,252,247,133,233,237,15,132,244,62,255,137,
-  149,233,141,68,194,252,248,137,133,233,49,192,72,137,133,233,176,235,136,
-  133,233,252,233,244,16,255,248,70,255,248,72,139,114,252,252,221,90,252,248,
-  252,233,244,65,255,248,87,129,252,248,239,15,130,244,62,255,129,122,253,4,
-  239,15,133,244,248,139,42,131,252,253,0,15,137,244,70,252,247,221,15,136,
-  244,247,248,88,248,70,139,114,252,252,199,66,252,252,237,137,106,252,248,
-  252,233,244,65,248,1,139,114,252,252,199,66,252,252,0,0,224,65,199,66,252,
-  248,0,0,0,0,252,233,244,65,248,2,15,135,244,62,255,129,122,253,4,239,15,131,
-  244,62,255,252,242,15,16,2,72,184,237,237,102,72,15,110,200,15,84,193,248,
-  71,139,114,252,252,252,242,15,17,66,252,248,255,221,2,217,225,248,71,248,
-  72,139,114,252,252,221,90,252,248,255,248,65,184,237,248,77,137,68,36,84,
-  248,63,252,247,198,237,15,133,244,253,248,5,56,70,252,255,15,135,244,252,
-  15,182,78,252,253,72,252,247,209,141,20,202,139,6,15,182,204,15,182,232,131,
-  198,4,193,232,16,252,255,36,252,235,248,6,199,68,194,252,244,237,131,192,
-  1,252,233,244,5,248,7,72,199,193,252,248,252,255,252,255,252,255,252,233,
-  244,14,248,89,255,129,122,253,4,239,15,133,244,247,139,42,252,233,244,70,
-  248,1,15,135,244,62,255,252,242,15,16,2,232,244,90,255,252,242,15,45,232,
-  129,252,253,0,0,0,128,15,133,244,70,252,242,15,42,205,102,15,46,193,15,138,
-  244,71,15,132,244,70,255,221,2,232,244,90,255,248,91,255,252,242,15,16,2,
-  232,244,92,255,221,2,232,244,92,255,248,93,129,252,248,239,15,130,244,62,
-  129,122,253,4,239,15,131,244,62,252,242,15,81,2,252,233,244,71,255,248,93,
-  129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,221,2,217,252,
-  250,252,233,244,72,255,248,94,129,252,248,239,15,130,244,62,129,122,253,4,
-  239,15,131,244,62,217,252,237,221,2,217,252,241,252,233,244,72,248,95,129,
-  252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,217,252,236,221,
-  2,217,252,241,252,233,244,72,248,96,129,252,248,239,255,15,130,244,62,129,
-  122,253,4,239,15,131,244,62,221,2,232,244,97,252,233,244,72,248,98,129,252,
-  248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,221,2,217,252,254,252,
-  233,244,72,248,99,129,252,248,239,255,15,130,244,62,129,122,253,4,239,15,
-  131,244,62,221,2,217,252,255,252,233,244,72,248,100,129,252,248,239,15,130,
-  244,62,129,122,253,4,239,15,131,244,62,221,2,217,252,242,221,216,252,233,
-  244,72,248,101,129,252,248,239,15,130,244,62,255,129,122,253,4,239,15,131,
-  244,62,221,2,217,192,216,200,217,232,222,225,217,252,250,217,252,243,252,
-  233,244,72,248,102,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,
-  244,62,221,2,217,192,216,200,217,232,222,225,217,252,250,217,201,217,252,
-  243,252,233,244,72,248,103,129,252,248,239,15,130,244,62,129,122,253,4,239,
-  15,131,244,62,255,221,2,217,232,217,252,243,252,233,244,72,255,248,104,129,
-  252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,252,242,15,16,2,
-  255,137,213,232,251,1,16,137,252,234,252,233,244,71,255,248,105,129,252,248,
-  239,15,130,244,62,129,122,253,4,239,15,131,244,62,252,242,15,16,2,255,137,
-  213,232,251,1,17,137,252,234,252,233,244,71,255,248,106,129,252,248,239,15,
-  130,244,62,129,122,253,4,239,15,131,244,62,252,242,15,16,2,255,137,213,232,
-  251,1,18,137,252,234,252,233,244,71,248,107,255,248,108,129,252,248,239,15,
-  130,244,62,129,122,253,4,239,15,131,244,62,252,242,15,16,2,139,106,252,248,
-  252,242,15,89,133,233,252,233,244,71,255,248,108,129,252,248,239,15,130,244,
-  62,129,122,253,4,239,15,131,244,62,221,2,139,106,252,248,220,141,233,252,
-  233,244,72,255,248,109,129,252,248,239,15,130,244,62,129,122,253,4,239,15,
-  131,244,62,129,122,253,12,239,15,131,244,62,221,2,221,66,8,217,252,243,252,
-  233,244,72,248,110,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,
-  244,62,129,122,253,12,239,255,15,131,244,62,221,66,8,221,2,217,252,253,221,
-  217,252,233,244,72,248,111,129,252,248,239,15,130,244,62,139,106,4,129,252,
-  253,239,15,131,244,62,139,114,252,252,139,2,137,106,252,252,137,66,252,248,
-  209,229,129,252,253,0,0,224,252,255,15,131,244,249,9,232,15,132,244,249,184,
-  252,254,3,0,0,129,252,253,0,0,32,0,15,130,244,250,248,1,193,252,237,21,41,
-  197,255,252,242,15,42,197,255,137,108,36,80,219,68,36,80,255,139,106,252,
-  252,129,229,252,255,252,255,15,128,129,205,0,0,224,63,137,106,252,252,248,
-  2,255,252,242,15,17,2,255,221,26,255,184,237,252,233,244,77,248,3,255,15,
-  87,192,252,233,244,2,255,217,252,238,252,233,244,2,255,248,4,255,252,242,
-  15,16,2,72,189,237,237,102,72,15,110,205,252,242,15,89,193,252,242,15,17,
-  66,252,248,255,221,2,199,68,36,80,0,0,128,90,216,76,36,80,221,90,252,248,
-  255,139,106,252,252,184,52,4,0,0,209,229,252,233,244,1,255,248,112,129,252,
-  248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,252,242,15,16,2,255,
-  248,112,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,221,
-  2,255,139,106,4,139,114,252,252,209,229,129,252,253,0,0,224,252,255,15,132,
-  244,250,255,15,40,224,232,244,113,252,242,15,92,224,248,1,252,242,15,17,66,
-  252,248,252,242,15,17,34,255,217,192,232,244,113,220,252,233,248,1,221,90,
-  252,248,221,26,255,139,66,252,252,139,106,4,49,232,15,136,244,249,248,2,184,
-  237,252,233,244,77,248,3,129,252,245,0,0,0,128,137,106,4,252,233,244,2,248,
-  4,255,15,87,228,252,233,244,1,255,217,252,238,217,201,252,233,244,1,255,248,
-  114,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,129,122,
-  253,12,239,15,131,244,62,221,66,8,221,2,248,1,217,252,248,223,224,158,15,
-  138,244,1,221,217,252,233,244,72,255,248,115,129,252,248,239,15,130,244,62,
-  129,122,253,4,239,15,131,244,62,129,122,253,12,239,15,131,244,62,252,242,
-  15,16,2,252,242,15,16,74,8,232,244,116,252,233,244,71,255,248,115,129,252,
-  248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,129,122,253,12,239,
-  15,131,244,62,221,2,221,66,8,232,244,116,252,233,244,72,255,248,117,185,2,
-  0,0,0,129,122,253,4,239,255,15,133,244,250,139,42,248,1,57,193,15,131,244,
-  70,129,124,253,202,252,252,239,15,133,244,249,59,108,202,252,248,15,79,108,
-  202,252,248,131,193,1,252,233,244,1,248,3,15,135,244,62,255,252,233,244,252,
-  248,4,15,135,244,62,255,252,242,15,16,2,248,5,57,193,15,131,244,71,129,124,
-  253,202,252,252,239,255,15,130,244,252,15,135,244,62,252,242,15,42,76,202,
-  252,248,252,233,244,253,255,248,6,252,242,15,16,76,202,252,248,248,7,252,
-  242,15,93,193,131,193,1,252,233,244,5,255,248,118,185,2,0,0,0,129,122,253,
-  4,239,255,15,133,244,250,139,42,248,1,57,193,15,131,244,70,129,124,253,202,
-  252,252,239,15,133,244,249,59,108,202,252,248,15,76,108,202,252,248,131,193,
-  1,252,233,244,1,248,3,15,135,244,62,255,248,6,252,242,15,16,76,202,252,248,
-  248,7,252,242,15,95,193,131,193,1,252,233,244,5,255,248,9,221,216,252,233,
-  244,62,255,248,119,129,252,248,239,15,130,244,62,129,122,253,4,239,15,133,
-  244,62,139,42,255,139,173,233,252,233,244,70,255,252,242,15,42,133,233,252,
-  233,244,71,255,219,133,233,252,233,244,72,255,248,120,129,252,248,239,15,
-  133,244,62,129,122,253,4,239,15,133,244,62,139,42,139,114,252,252,131,189,
-  233,1,15,130,244,80,15,182,173,233,255,252,242,15,42,197,252,233,244,71,255,
-  137,108,36,80,219,68,36,80,252,233,244,72,255,248,121,139,171,233,59,171,
-  233,15,130,244,247,232,244,74,248,1,129,252,248,239,15,133,244,62,129,122,
-  253,4,239,255,15,133,244,62,139,42,129,252,253,252,255,0,0,0,15,135,244,62,
-  137,108,36,84,255,15,131,244,62,252,242,15,44,42,129,252,253,252,255,0,0,
-  0,15,135,244,62,137,108,36,84,255,15,131,244,62,221,2,219,92,36,84,129,124,
-  36,84,252,255,0,0,0,15,135,244,62,255,199,68,36,32,1,0,0,0,72,141,68,36,84,
-  248,122,139,108,36,96,137,149,233,68,139,68,36,32,72,137,194,137,252,233,
-  137,116,36,100,232,251,1,19,139,149,233,139,114,252,252,199,66,252,252,237,
-  137,66,252,248,252,233,244,65,248,123,139,171,233,59,171,233,15,130,244,247,
-  232,244,74,248,1,199,68,36,84,252,255,252,255,252,255,252,255,129,252,248,
-  239,15,130,244,62,15,134,244,247,129,122,253,20,239,255,15,133,244,62,139,
-  106,16,137,108,36,84,255,15,131,244,62,252,242,15,44,106,16,137,108,36,84,
-  255,15,131,244,62,221,66,16,219,92,36,84,255,248,1,129,122,253,4,239,15,133,
-  244,62,129,122,253,12,239,255,139,42,137,108,36,32,139,173,233,255,139,74,
-  8,255,252,242,15,44,74,8,255,139,68,36,84,57,197,15,130,244,251,248,2,133,
-  201,15,142,244,253,248,3,139,108,36,32,41,200,15,140,244,124,141,172,253,
-  13,233,131,192,1,248,4,137,68,36,32,137,232,252,233,244,122,248,5,15,140,
-  244,252,141,68,40,1,252,233,244,2,248,6,137,232,252,233,244,2,248,7,255,15,
-  132,244,254,1,252,233,131,193,1,15,143,244,3,248,8,185,1,0,0,0,252,233,244,
-  3,248,124,49,192,252,233,244,4,248,125,129,252,248,239,15,130,244,62,139,
-  171,233,59,171,233,15,130,244,247,232,244,74,248,1,255,129,122,253,4,239,
-  15,133,244,62,129,122,253,12,239,139,42,255,15,133,244,62,139,66,8,255,15,
-  131,244,62,252,242,15,44,66,8,255,15,131,244,62,221,66,8,219,92,36,84,139,
-  68,36,84,255,133,192,15,142,244,124,131,189,233,1,15,130,244,124,15,133,244,
-  126,57,131,233,15,130,244,126,15,182,141,233,139,171,233,137,68,36,32,248,
-  1,136,77,0,131,197,1,131,232,1,15,133,244,1,139,131,233,252,233,244,122,248,
-  127,129,252,248,239,255,15,130,244,62,139,171,233,59,171,233,15,130,244,247,
-  232,244,74,248,1,129,122,253,4,239,15,133,244,62,139,42,139,133,233,133,192,
-  15,132,244,124,57,131,233,15,130,244,128,129,197,239,137,116,36,84,137,68,
-  36,32,139,179,233,248,1,255,15,182,77,0,131,197,1,131,232,1,136,12,6,15,133,
-  244,1,137,252,240,139,116,36,84,252,233,244,122,248,129,129,252,248,239,15,
-  130,244,62,139,171,233,59,171,233,15,130,244,247,232,244,74,248,1,129,122,
-  253,4,239,15,133,244,62,139,42,139,133,233,57,131,233,255,15,130,244,128,
+  72,99,77,252,240,255,131,252,249,1,15,134,244,247,255,72,141,61,245,72,1,
+  252,249,255,139,122,252,248,139,191,233,139,191,233,252,255,225,255,248,1,
+  15,132,244,32,41,213,193,252,237,3,141,69,252,255,252,233,244,33,255,248,
+  34,15,182,78,252,255,131,252,237,16,141,12,202,41,252,233,15,132,244,35,252,
+  247,217,193,252,233,3,65,137,200,139,76,36,96,137,145,233,72,139,0,72,137,
+  69,0,137,252,234,252,233,244,36,248,37,137,68,36,80,199,68,36,84,237,72,141,
+  68,36,80,128,126,252,252,235,15,133,244,247,141,139,233,137,41,199,65,4,237,
+  137,205,252,233,244,248,248,38,15,182,70,252,254,255,199,68,36,84,237,137,
+  68,36,80,255,252,242,15,42,192,252,242,15,17,68,36,80,255,72,141,68,36,80,
+  252,233,244,247,248,39,15,182,70,252,254,141,4,194,248,1,15,182,110,252,255,
+  141,44,252,234,248,2,139,76,36,96,137,145,233,137,252,234,73,137,192,137,
+  205,137,116,36,100,232,251,1,1,139,149,233,133,192,15,132,244,249,248,35,
+  15,182,78,252,253,72,139,40,72,137,44,202,139,6,15,182,204,15,182,232,131,
+  198,4,193,232,16,252,255,36,252,235,248,3,139,141,233,137,113,252,244,141,
+  177,233,41,214,139,105,252,248,184,237,252,233,244,30,248,40,137,68,36,80,
+  199,68,36,84,237,72,141,68,36,80,128,126,252,252,235,15,133,244,247,255,141,
+  139,233,137,41,199,65,4,237,137,205,252,233,244,248,248,41,15,182,70,252,
+  254,255,72,141,68,36,80,252,233,244,247,248,42,15,182,70,252,254,141,4,194,
+  248,1,15,182,110,252,255,141,44,252,234,248,2,139,76,36,96,137,145,233,137,
+  252,234,73,137,192,137,205,137,116,36,100,232,251,1,2,139,149,233,133,192,
+  15,132,244,249,15,182,78,252,253,72,139,44,202,72,137,40,248,43,139,6,15,
+  182,204,15,182,232,131,198,4,193,232,16,252,255,36,252,235,248,3,139,141,
+  233,137,113,252,244,15,182,70,252,253,72,139,44,194,72,137,105,16,141,177,
+  233,41,214,139,105,252,248,184,237,252,233,244,30,248,44,139,108,36,96,137,
+  149,233,68,141,4,194,141,20,202,137,252,233,68,15,182,78,252,252,137,116,
+  36,100,232,251,1,3,248,3,139,149,233,255,131,252,248,1,15,135,244,45,248,
+  4,141,118,4,15,130,244,252,248,5,15,183,70,252,254,141,180,253,134,233,248,
+  6,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,252,235,248,
+  46,131,198,4,129,120,253,4,239,15,130,244,5,252,233,244,6,248,47,129,120,
+  253,4,239,252,233,244,4,248,48,131,252,238,4,65,137,192,65,137,252,233,139,
+  108,36,96,137,149,233,255,137,202,137,252,233,137,116,36,100,232,251,1,4,
+  252,233,244,3,248,49,255,131,252,238,4,139,108,36,96,137,149,233,137,252,
+  233,139,86,252,252,137,116,36,100,232,251,1,5,252,233,244,3,255,248,50,255,
+  15,182,110,252,255,255,248,51,141,4,199,252,233,244,247,248,52,255,248,53,
+  141,4,199,141,44,252,234,149,252,233,244,248,248,54,141,4,194,137,197,252,
+  233,244,248,248,55,255,248,56,141,4,194,248,1,141,44,252,234,248,2,141,12,
+  202,65,137,232,65,137,193,15,182,70,252,252,137,68,36,32,139,108,36,96,137,
+  149,233,137,202,137,252,233,137,116,36,100,232,251,1,6,139,149,233,133,192,
+  15,132,244,43,248,45,137,193,41,208,137,113,252,244,141,176,233,184,237,252,
+  233,244,28,248,57,139,108,36,96,137,149,233,141,20,194,137,252,233,137,116,
+  36,100,232,251,1,7,139,149,233,255,133,192,15,133,244,45,15,183,70,252,254,
+  139,12,194,252,233,244,58,255,252,233,244,45,255,248,59,141,76,202,8,248,
+  29,137,76,36,84,137,68,36,80,131,252,233,8,139,108,36,96,137,149,233,137,
+  202,68,141,4,193,137,252,233,137,116,36,100,232,251,1,8,139,149,233,139,76,
+  36,84,139,68,36,80,139,105,252,248,131,192,1,57,215,15,132,244,60,137,202,
+  137,114,252,252,139,181,233,139,14,15,182,252,233,15,182,205,131,198,4,252,
+  255,36,252,235,248,61,139,108,36,96,137,149,233,137,202,137,252,233,137,116,
+  36,100,232,251,1,9,139,149,233,139,70,252,252,15,182,204,15,182,232,193,232,
+  16,252,255,164,253,252,235,233,248,62,129,252,248,239,15,130,244,63,139,106,
+  4,129,252,253,239,15,131,244,63,139,114,252,252,137,68,36,84,137,106,252,
+  252,139,42,137,106,252,248,131,232,2,15,132,244,248,255,137,209,248,1,131,
+  193,8,72,139,41,72,137,105,252,248,131,232,1,15,133,244,1,248,2,139,68,36,
+  84,252,233,244,64,248,65,129,252,248,239,15,130,244,63,139,106,4,137,252,
+  233,193,252,249,15,131,252,249,252,254,15,132,244,249,184,237,252,247,213,
+  57,232,255,15,71,197,255,15,134,244,247,137,232,248,1,255,248,2,139,106,252,
+  248,139,132,253,197,233,139,114,252,252,199,66,252,252,237,137,66,252,248,
+  252,233,244,66,248,3,184,237,252,233,244,2,248,67,129,252,248,239,15,130,
+  244,63,139,106,4,139,114,252,252,129,252,253,239,15,133,244,252,248,1,139,
+  42,139,173,233,248,2,133,252,237,199,66,252,252,237,255,15,132,244,66,139,
+  131,233,199,66,252,252,237,137,106,252,248,139,141,233,35,136,233,105,201,
+  239,3,141,233,248,3,129,185,233,239,15,133,244,250,57,129,233,15,132,244,
+  251,248,4,139,137,233,133,201,15,133,244,3,255,252,233,244,66,248,5,139,105,
+  4,129,252,253,239,15,132,244,66,139,1,137,106,252,252,137,66,252,248,252,
+  233,244,66,248,6,129,252,253,239,15,132,244,1,129,252,253,239,15,135,244,
+  254,129,252,253,239,15,134,244,253,189,237,252,233,244,254,248,7,255,189,
+  237,248,8,252,247,213,139,172,253,171,233,252,233,244,2,248,68,129,252,248,
+  239,15,130,244,63,129,122,253,4,239,15,133,244,63,139,42,131,189,233,0,15,
+  133,244,63,129,122,253,12,239,15,133,244,63,139,66,8,137,133,233,139,114,
+  252,252,199,66,252,252,237,255,137,106,252,248,252,246,133,233,235,15,132,
+  244,247,128,165,233,235,139,131,233,137,171,233,137,133,233,248,1,252,233,
+  244,66,248,69,129,252,248,239,15,130,244,63,129,122,253,4,239,15,133,244,
+  63,137,213,68,141,66,8,139,18,139,76,36,96,232,251,1,10,137,252,234,72,139,
+  40,139,114,252,252,72,137,106,252,248,252,233,244,66,248,70,255,129,252,248,
+  239,15,133,244,63,129,122,253,4,239,255,15,133,244,247,139,42,252,233,244,
+  71,248,1,15,135,244,63,255,15,131,244,63,255,252,242,15,16,2,252,233,244,
+  72,255,221,2,252,233,244,73,255,248,74,129,252,248,239,15,130,244,63,139,
+  114,252,252,129,122,253,4,239,15,133,244,249,139,2,248,2,199,66,252,252,237,
+  137,66,252,248,252,233,244,66,248,3,129,122,253,4,239,15,135,244,63,131,187,
+  233,0,15,133,244,63,139,171,233,59,171,233,255,15,130,244,247,232,244,75,
+  248,1,139,108,36,96,137,149,233,137,116,36,100,137,252,233,255,232,251,1,
+  11,255,232,251,1,12,255,139,149,233,252,233,244,2,248,76,129,252,248,239,
+  15,130,244,63,15,132,244,248,248,1,129,122,253,4,239,15,133,244,63,139,108,
+  36,96,137,149,233,137,149,233,139,114,252,252,68,141,66,8,139,18,137,252,
+  233,137,116,36,100,232,251,1,13,139,149,233,133,192,15,132,244,249,72,139,
+  106,8,72,139,66,16,72,137,106,252,248,72,137,2,248,77,184,237,255,252,233,
+  244,78,248,2,199,66,12,237,252,233,244,1,248,3,199,66,252,252,237,252,233,
+  244,66,248,79,129,252,248,239,15,130,244,63,139,42,129,122,253,4,239,15,133,
+  244,63,255,131,189,233,0,15,133,244,63,255,139,106,252,248,139,133,233,139,
+  114,252,252,199,66,252,252,237,137,66,252,248,199,66,12,237,184,237,252,233,
+  244,78,248,80,129,252,248,239,15,130,244,63,129,122,253,4,239,15,133,244,
+  63,129,122,253,12,239,255,139,114,252,252,255,139,66,8,131,192,1,199,66,252,
+  252,237,137,66,252,248,255,252,242,15,16,66,8,72,189,237,237,102,72,15,110,
+  205,252,242,15,88,193,252,242,15,45,192,252,242,15,17,66,252,248,255,139,
+  42,59,133,233,15,131,244,248,193,224,3,3,133,233,248,1,129,120,253,4,239,
+  15,132,244,81,72,139,40,72,137,42,252,233,244,77,248,2,131,189,233,0,15,132,
+  244,81,137,252,233,137,213,137,194,232,251,1,14,137,252,234,133,192,15,133,
+  244,1,248,81,184,237,252,233,244,78,248,82,255,139,106,252,248,139,133,233,
+  139,114,252,252,199,66,252,252,237,137,66,252,248,255,199,66,12,237,199,66,
+  8,0,0,0,0,255,15,87,192,252,242,15,17,66,8,255,217,252,238,221,90,8,255,184,
+  237,252,233,244,78,248,83,129,252,248,239,15,130,244,63,141,74,8,131,232,
+  1,190,237,248,1,15,182,171,233,193,252,237,235,131,229,1,1,252,238,252,233,
+  244,28,248,84,129,252,248,239,15,130,244,63,129,122,253,12,239,15,133,244,
+  63,255,139,106,4,137,106,12,199,66,4,237,139,42,139,114,8,137,106,8,137,50,
+  141,74,16,131,232,2,190,237,252,233,244,1,248,85,129,252,248,239,15,130,244,
+  63,139,42,139,114,252,252,137,116,36,100,137,108,36,80,129,122,253,4,239,
+  15,133,244,63,72,131,189,233,0,15,133,244,63,128,189,233,235,15,135,244,63,
+  139,141,233,15,132,244,247,255,59,141,233,15,132,244,63,248,1,141,116,193,
+  252,240,59,181,233,15,135,244,63,137,181,233,139,108,36,96,137,149,233,131,
+  194,8,137,149,233,141,108,194,232,72,41,252,245,57,206,15,132,244,249,248,
+  2,72,139,4,46,72,137,70,252,248,131,252,238,8,57,206,15,133,244,2,248,3,137,
+  202,139,76,36,80,232,244,25,199,131,233,237,255,139,108,36,96,139,116,36,
+  80,139,149,233,129,252,248,239,15,135,244,254,248,4,139,142,233,139,190,233,
+  137,142,233,137,252,254,41,206,15,132,244,252,141,4,50,193,252,238,3,59,133,
+  233,15,135,244,255,137,213,72,41,205,248,5,72,139,1,72,137,4,41,131,193,8,
+  57,252,249,15,133,244,5,248,6,141,70,2,199,66,252,252,237,248,7,139,116,36,
+  100,137,68,36,84,72,199,193,252,248,252,255,252,255,252,255,252,247,198,237,
+  255,15,132,244,13,252,233,244,14,248,8,199,66,252,252,237,139,142,233,131,
+  252,233,8,137,142,233,72,139,1,72,137,2,184,237,252,233,244,7,248,9,139,76,
+  36,80,137,185,233,137,252,242,137,252,233,232,251,1,0,139,116,36,80,139,149,
+  233,252,233,244,4,248,86,139,106,252,248,139,173,233,139,114,252,252,137,
+  116,36,100,137,108,36,80,72,131,189,233,0,15,133,244,63,255,128,189,233,235,
+  15,135,244,63,139,141,233,15,132,244,247,59,141,233,15,132,244,63,248,1,141,
+  116,193,252,248,59,181,233,15,135,244,63,137,181,233,139,108,36,96,137,149,
+  233,137,149,233,141,108,194,252,240,72,41,252,245,57,206,15,132,244,249,248,
+  2,255,72,139,4,46,72,137,70,252,248,131,252,238,8,57,206,15,133,244,2,248,
+  3,137,202,139,76,36,80,232,244,25,199,131,233,237,139,108,36,96,139,116,36,
+  80,139,149,233,129,252,248,239,15,135,244,254,248,4,139,142,233,139,190,233,
+  137,142,233,137,252,254,41,206,15,132,244,252,141,4,50,193,252,238,3,59,133,
+  233,15,135,244,255,255,137,213,72,41,205,248,5,72,139,1,72,137,4,41,131,193,
+  8,57,252,249,15,133,244,5,248,6,141,70,1,248,7,139,116,36,100,137,68,36,84,
+  49,201,252,247,198,237,15,132,244,13,252,233,244,14,248,8,137,252,242,137,
+  252,233,232,251,1,15,248,9,139,76,36,80,137,185,233,137,252,242,137,252,233,
+  232,251,1,0,139,116,36,80,139,149,233,252,233,244,4,248,87,139,108,36,96,
+  72,252,247,133,233,237,15,132,244,63,255,137,149,233,141,68,194,252,248,137,
+  133,233,49,192,72,137,133,233,176,235,136,133,233,252,233,244,16,255,248,
+  71,255,248,73,139,114,252,252,221,90,252,248,252,233,244,66,255,248,88,129,
+  252,248,239,15,130,244,63,255,129,122,253,4,239,15,133,244,248,139,42,131,
+  252,253,0,15,137,244,71,252,247,221,15,136,244,247,248,89,248,71,139,114,
+  252,252,199,66,252,252,237,137,106,252,248,252,233,244,66,248,1,139,114,252,
+  252,199,66,252,252,0,0,224,65,199,66,252,248,0,0,0,0,252,233,244,66,248,2,
+  15,135,244,63,255,129,122,253,4,239,15,131,244,63,255,252,242,15,16,2,72,
+  184,237,237,102,72,15,110,200,15,84,193,248,72,139,114,252,252,252,242,15,
+  17,66,252,248,255,221,2,217,225,248,72,248,73,139,114,252,252,221,90,252,
+  248,255,248,66,184,237,248,78,137,68,36,84,248,64,252,247,198,237,15,133,
+  244,253,248,5,56,70,252,255,15,135,244,252,15,182,78,252,253,72,252,247,209,
+  141,20,202,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,252,
+  235,248,6,199,68,194,252,244,237,131,192,1,252,233,244,5,248,7,72,199,193,
+  252,248,252,255,252,255,252,255,252,233,244,14,248,90,255,129,122,253,4,239,
+  15,133,244,247,139,42,252,233,244,71,248,1,15,135,244,63,255,252,242,15,16,
+  2,232,244,91,255,252,242,15,45,232,129,252,253,0,0,0,128,15,133,244,71,252,
+  242,15,42,205,102,15,46,193,15,138,244,72,15,132,244,71,255,221,2,232,244,
+  91,255,248,92,255,252,242,15,16,2,232,244,93,255,221,2,232,244,93,255,248,
+  94,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,252,242,
+  15,81,2,252,233,244,72,255,248,94,129,252,248,239,15,130,244,63,129,122,253,
+  4,239,15,131,244,63,221,2,217,252,250,252,233,244,73,255,248,95,129,252,248,
+  239,15,130,244,63,129,122,253,4,239,15,131,244,63,217,252,237,221,2,217,252,
+  241,252,233,244,73,248,96,129,252,248,239,15,130,244,63,129,122,253,4,239,
+  15,131,244,63,217,252,236,221,2,217,252,241,252,233,244,73,248,97,129,252,
+  248,239,255,15,130,244,63,129,122,253,4,239,15,131,244,63,221,2,232,244,98,
+  252,233,244,73,248,99,129,252,248,239,15,130,244,63,129,122,253,4,239,15,
+  131,244,63,221,2,217,252,254,252,233,244,73,248,100,129,252,248,239,255,15,
+  130,244,63,129,122,253,4,239,15,131,244,63,221,2,217,252,255,252,233,244,
+  73,248,101,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,
+  221,2,217,252,242,221,216,252,233,244,73,248,102,129,252,248,239,15,130,244,
+  63,255,129,122,253,4,239,15,131,244,63,221,2,217,192,216,200,217,232,222,
+  225,217,252,250,217,252,243,252,233,244,73,248,103,129,252,248,239,15,130,
+  244,63,129,122,253,4,239,15,131,244,63,221,2,217,192,216,200,217,232,222,
+  225,217,252,250,217,201,217,252,243,252,233,244,73,248,104,129,252,248,239,
+  15,130,244,63,129,122,253,4,239,15,131,244,63,255,221,2,217,232,217,252,243,
+  252,233,244,73,255,248,105,129,252,248,239,15,130,244,63,129,122,253,4,239,
+  15,131,244,63,252,242,15,16,2,255,137,213,232,251,1,16,137,252,234,252,233,
+  244,72,255,248,106,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,
+  244,63,252,242,15,16,2,255,137,213,232,251,1,17,137,252,234,252,233,244,72,
+  255,248,107,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,
+  252,242,15,16,2,255,137,213,232,251,1,18,137,252,234,252,233,244,72,248,108,
+  255,248,109,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,
+  252,242,15,16,2,139,106,252,248,252,242,15,89,133,233,252,233,244,72,255,
+  248,109,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,221,
+  2,139,106,252,248,220,141,233,252,233,244,73,255,248,110,129,252,248,239,
+  15,130,244,63,129,122,253,4,239,15,131,244,63,129,122,253,12,239,15,131,244,
+  63,221,2,221,66,8,217,252,243,252,233,244,73,248,111,129,252,248,239,15,130,
+  244,63,129,122,253,4,239,15,131,244,63,129,122,253,12,239,255,15,131,244,
+  63,221,66,8,221,2,217,252,253,221,217,252,233,244,73,248,112,129,252,248,
+  239,15,130,244,63,139,106,4,129,252,253,239,15,131,244,63,139,114,252,252,
+  139,2,137,106,252,252,137,66,252,248,209,229,129,252,253,0,0,224,252,255,
+  15,131,244,249,9,232,15,132,244,249,184,252,254,3,0,0,129,252,253,0,0,32,
+  0,15,130,244,250,248,1,193,252,237,21,41,197,255,252,242,15,42,197,255,137,
+  108,36,80,219,68,36,80,255,139,106,252,252,129,229,252,255,252,255,15,128,
+  129,205,0,0,224,63,137,106,252,252,248,2,255,252,242,15,17,2,255,221,26,255,
+  184,237,252,233,244,78,248,3,255,15,87,192,252,233,244,2,255,217,252,238,
+  252,233,244,2,255,248,4,255,252,242,15,16,2,72,189,237,237,102,72,15,110,
+  205,252,242,15,89,193,252,242,15,17,66,252,248,255,221,2,199,68,36,80,0,0,
+  128,90,216,76,36,80,221,90,252,248,255,139,106,252,252,184,52,4,0,0,209,229,
+  252,233,244,1,255,248,113,129,252,248,239,15,130,244,63,129,122,253,4,239,
+  15,131,244,63,252,242,15,16,2,255,248,113,129,252,248,239,15,130,244,63,129,
+  122,253,4,239,15,131,244,63,221,2,255,139,106,4,139,114,252,252,209,229,129,
+  252,253,0,0,224,252,255,15,132,244,250,255,15,40,224,232,244,114,252,242,
+  15,92,224,248,1,252,242,15,17,66,252,248,252,242,15,17,34,255,217,192,232,
+  244,114,220,252,233,248,1,221,90,252,248,221,26,255,139,66,252,252,139,106,
+  4,49,232,15,136,244,249,248,2,184,237,252,233,244,78,248,3,129,252,245,0,
+  0,0,128,137,106,4,252,233,244,2,248,4,255,15,87,228,252,233,244,1,255,217,
+  252,238,217,201,252,233,244,1,255,248,115,129,252,248,239,15,130,244,63,129,
+  122,253,4,239,15,131,244,63,129,122,253,12,239,15,131,244,63,221,66,8,221,
+  2,248,1,217,252,248,223,224,158,15,138,244,1,221,217,252,233,244,73,255,248,
+  116,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,129,122,
+  253,12,239,15,131,244,63,252,242,15,16,2,252,242,15,16,74,8,232,244,117,252,
+  233,244,72,255,248,116,129,252,248,239,15,130,244,63,129,122,253,4,239,15,
+  131,244,63,129,122,253,12,239,15,131,244,63,221,2,221,66,8,232,244,117,252,
+  233,244,73,255,248,118,185,2,0,0,0,129,122,253,4,239,255,15,133,244,250,139,
+  42,248,1,57,193,15,131,244,71,129,124,253,202,252,252,239,15,133,244,249,
+  59,108,202,252,248,15,79,108,202,252,248,131,193,1,252,233,244,1,248,3,15,
+  135,244,63,255,252,233,244,252,248,4,15,135,244,63,255,252,242,15,16,2,248,
+  5,57,193,15,131,244,72,129,124,253,202,252,252,239,255,15,130,244,252,15,
+  135,244,63,252,242,15,42,76,202,252,248,252,233,244,253,255,248,6,252,242,
+  15,16,76,202,252,248,248,7,252,242,15,93,193,131,193,1,252,233,244,5,255,
+  248,119,185,2,0,0,0,129,122,253,4,239,255,15,133,244,250,139,42,248,1,57,
+  193,15,131,244,71,129,124,253,202,252,252,239,15,133,244,249,59,108,202,252,
+  248,15,76,108,202,252,248,131,193,1,252,233,244,1,248,3,15,135,244,63,255,
+  248,6,252,242,15,16,76,202,252,248,248,7,252,242,15,95,193,131,193,1,252,
+  233,244,5,255,248,9,221,216,252,233,244,63,255,248,120,129,252,248,239,15,
+  130,244,63,129,122,253,4,239,15,133,244,63,139,42,255,139,173,233,252,233,
+  244,71,255,252,242,15,42,133,233,252,233,244,72,255,219,133,233,252,233,244,
+  73,255,248,121,129,252,248,239,15,133,244,63,129,122,253,4,239,15,133,244,
+  63,139,42,139,114,252,252,131,189,233,1,15,130,244,81,15,182,173,233,255,
+  252,242,15,42,197,252,233,244,72,255,137,108,36,80,219,68,36,80,252,233,244,
+  73,255,248,122,139,171,233,59,171,233,15,130,244,247,232,244,75,248,1,129,
+  252,248,239,15,133,244,63,129,122,253,4,239,255,15,133,244,63,139,42,129,
+  252,253,252,255,0,0,0,15,135,244,63,137,108,36,84,255,15,131,244,63,252,242,
+  15,44,42,129,252,253,252,255,0,0,0,15,135,244,63,137,108,36,84,255,15,131,
+  244,63,221,2,219,92,36,84,129,124,36,84,252,255,0,0,0,15,135,244,63,255,199,
+  68,36,32,1,0,0,0,72,141,68,36,84,248,123,139,108,36,96,137,149,233,68,139,
+  68,36,32,72,137,194,137,252,233,137,116,36,100,232,251,1,19,139,149,233,139,
+  114,252,252,199,66,252,252,237,137,66,252,248,252,233,244,66,248,124,139,
+  171,233,59,171,233,15,130,244,247,232,244,75,248,1,199,68,36,84,252,255,252,
+  255,252,255,252,255,129,252,248,239,15,130,244,63,15,134,244,247,129,122,
+  253,20,239,255,15,133,244,63,139,106,16,137,108,36,84,255,15,131,244,63,252,
+  242,15,44,106,16,137,108,36,84,255,15,131,244,63,221,66,16,219,92,36,84,255,
+  248,1,129,122,253,4,239,15,133,244,63,129,122,253,12,239,255,139,42,137,108,
+  36,32,139,173,233,255,139,74,8,255,252,242,15,44,74,8,255,139,68,36,84,57,
+  197,15,130,244,251,248,2,133,201,15,142,244,253,248,3,139,108,36,32,41,200,
+  15,140,244,125,141,172,253,13,233,131,192,1,248,4,137,68,36,32,137,232,252,
+  233,244,123,248,5,15,140,244,252,141,68,40,1,252,233,244,2,248,6,137,232,
+  252,233,244,2,248,7,255,15,132,244,254,1,252,233,131,193,1,15,143,244,3,248,
+  8,185,1,0,0,0,252,233,244,3,248,125,49,192,252,233,244,4,248,126,129,252,
+  248,239,15,130,244,63,139,171,233,59,171,233,15,130,244,247,232,244,75,248,
+  1,255,129,122,253,4,239,15,133,244,63,129,122,253,12,239,139,42,255,15,133,
+  244,63,139,66,8,255,15,131,244,63,252,242,15,44,66,8,255,15,131,244,63,221,
+  66,8,219,92,36,84,139,68,36,84,255,133,192,15,142,244,125,131,189,233,1,15,
+  130,244,125,15,133,244,127,57,131,233,15,130,244,127,15,182,141,233,139,171,
+  233,137,68,36,32,248,1,136,77,0,131,197,1,131,232,1,15,133,244,1,139,131,
+  233,252,233,244,123,248,128,129,252,248,239,255,15,130,244,63,139,171,233,
+  59,171,233,15,130,244,247,232,244,75,248,1,129,122,253,4,239,15,133,244,63,
+  139,42,139,133,233,133,192,15,132,244,125,57,131,233,15,130,244,129,129,197,
+  239,137,116,36,84,137,68,36,32,139,179,233,248,1,255,15,182,77,0,131,197,
+  1,131,232,1,136,12,6,15,133,244,1,137,252,240,139,116,36,84,252,233,244,123,
+  248,130,129,252,248,239,15,130,244,63,139,171,233,59,171,233,15,130,244,247,
+  232,244,75,248,1,129,122,253,4,239,15,133,244,63,139,42,139,133,233,57,131,
+  233,255,15,130,244,129,129,197,239,137,116,36,84,137,68,36,32,139,179,233,
+  252,233,244,249,248,1,15,182,76,5,0,131,252,249,65,15,130,244,248,131,252,
+  249,90,15,135,244,248,131,252,241,32,248,2,136,12,6,248,3,131,232,1,15,137,
+  244,1,137,252,240,139,116,36,84,252,233,244,123,248,131,129,252,248,239,15,
+  130,244,63,255,139,171,233,59,171,233,15,130,244,247,232,244,75,248,1,129,
+  122,253,4,239,15,133,244,63,139,42,139,133,233,57,131,233,15,130,244,129,
   129,197,239,137,116,36,84,137,68,36,32,139,179,233,252,233,244,249,248,1,
-  15,182,76,5,0,131,252,249,65,15,130,244,248,131,252,249,90,15,135,244,248,
-  131,252,241,32,248,2,136,12,6,248,3,131,232,1,15,137,244,1,137,252,240,139,
-  116,36,84,252,233,244,122,248,130,129,252,248,239,15,130,244,62,255,139,171,
-  233,59,171,233,15,130,244,247,232,244,74,248,1,129,122,253,4,239,15,133,244,
-  62,139,42,139,133,233,57,131,233,15,130,244,128,129,197,239,137,116,36,84,
-  137,68,36,32,139,179,233,252,233,244,249,248,1,15,182,76,5,0,131,252,249,
-  97,15,130,244,248,255,131,252,249,122,15,135,244,248,131,252,241,32,248,2,
-  136,12,6,248,3,131,232,1,15,137,244,1,137,252,240,139,116,36,84,252,233,244,
-  122,248,131,129,252,248,239,15,130,244,62,129,122,253,4,239,15,133,244,62,
-  137,213,139,10,232,251,1,20,137,252,234,255,137,197,252,233,244,70,255,252,
-  242,15,42,192,252,233,244,71,255,248,132,129,252,248,239,15,130,244,62,129,
-  122,253,4,239,255,15,133,244,247,139,42,252,233,244,88,248,1,15,135,244,62,
-  255,252,242,15,16,2,72,189,237,237,102,72,15,110,205,252,242,15,88,193,102,
-  15,126,197,255,252,233,244,88,255,248,133,129,252,248,239,15,130,244,62,255,
-  72,189,237,237,102,72,15,110,205,255,199,68,36,80,0,0,192,89,255,15,133,244,
-  247,139,42,252,233,244,248,248,1,15,135,244,62,255,252,242,15,16,2,252,242,
-  15,88,193,102,15,126,197,255,248,2,137,68,36,84,141,68,194,252,240,248,1,
-  57,208,15,134,244,88,129,120,253,4,239,255,15,133,244,248,35,40,131,232,8,
-  252,233,244,1,248,2,15,135,244,134,255,15,131,244,134,255,252,242,15,16,0,
-  252,242,15,88,193,102,15,126,193,33,205,255,131,232,8,252,233,244,1,248,135,
-  129,252,248,239,15,130,244,62,255,15,133,244,248,11,40,131,232,8,252,233,
-  244,1,248,2,15,135,244,134,255,252,242,15,16,0,252,242,15,88,193,102,15,126,
-  193,9,205,255,131,232,8,252,233,244,1,248,136,129,252,248,239,15,130,244,
-  62,255,15,133,244,248,51,40,131,232,8,252,233,244,1,248,2,15,135,244,134,
-  255,252,242,15,16,0,252,242,15,88,193,102,15,126,193,49,205,255,131,232,8,
-  252,233,244,1,248,137,129,252,248,239,15,130,244,62,129,122,253,4,239,255,
-  248,2,15,205,252,233,244,88,248,138,129,252,248,239,15,130,244,62,129,122,
-  253,4,239,255,248,2,252,247,213,255,248,88,252,242,15,42,197,252,233,244,
-  71,255,248,134,139,68,36,84,252,233,244,62,255,248,139,129,252,248,239,15,
-  130,244,62,129,122,253,4,239,255,248,2,129,122,253,12,239,15,133,244,62,139,
-  74,8,255,248,139,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,
-  62,129,122,253,12,239,15,131,244,62,252,242,15,16,2,252,242,15,16,74,8,72,
-  189,237,237,102,72,15,110,213,252,242,15,88,194,252,242,15,88,202,102,15,
-  126,197,102,15,126,201,255,211,229,252,233,244,88,255,248,140,129,252,248,
-  239,15,130,244,62,129,122,253,4,239,255,248,140,129,252,248,239,15,130,244,
-  62,129,122,253,4,239,15,131,244,62,129,122,253,12,239,15,131,244,62,252,242,
-  15,16,2,252,242,15,16,74,8,72,189,237,237,102,72,15,110,213,252,242,15,88,
-  194,252,242,15,88,202,102,15,126,197,102,15,126,201,255,211,252,237,252,233,
-  244,88,255,248,141,129,252,248,239,15,130,244,62,129,122,253,4,239,255,248,
-  141,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,129,122,
-  253,12,239,15,131,244,62,252,242,15,16,2,252,242,15,16,74,8,72,189,237,237,
-  102,72,15,110,213,252,242,15,88,194,252,242,15,88,202,102,15,126,197,102,
-  15,126,201,255,211,252,253,252,233,244,88,255,248,142,129,252,248,239,15,
-  130,244,62,129,122,253,4,239,255,248,142,129,252,248,239,15,130,244,62,129,
-  122,253,4,239,15,131,244,62,129,122,253,12,239,15,131,244,62,252,242,15,16,
+  15,182,76,5,0,131,252,249,97,15,130,244,248,255,131,252,249,122,15,135,244,
+  248,131,252,241,32,248,2,136,12,6,248,3,131,232,1,15,137,244,1,137,252,240,
+  139,116,36,84,252,233,244,123,248,132,129,252,248,239,15,130,244,63,129,122,
+  253,4,239,15,133,244,63,137,213,139,10,232,251,1,20,137,252,234,255,137,197,
+  252,233,244,71,255,252,242,15,42,192,252,233,244,72,255,248,133,129,252,248,
+  239,15,130,244,63,129,122,253,4,239,255,15,133,244,247,139,42,252,233,244,
+  89,248,1,15,135,244,63,255,252,242,15,16,2,72,189,237,237,102,72,15,110,205,
+  252,242,15,88,193,102,15,126,197,255,252,233,244,89,255,248,134,129,252,248,
+  239,15,130,244,63,255,72,189,237,237,102,72,15,110,205,255,199,68,36,80,0,
+  0,192,89,255,15,133,244,247,139,42,252,233,244,248,248,1,15,135,244,63,255,
+  252,242,15,16,2,252,242,15,88,193,102,15,126,197,255,248,2,137,68,36,84,141,
+  68,194,252,240,248,1,57,208,15,134,244,89,129,120,253,4,239,255,15,133,244,
+  248,35,40,131,232,8,252,233,244,1,248,2,15,135,244,135,255,15,131,244,135,
+  255,252,242,15,16,0,252,242,15,88,193,102,15,126,193,33,205,255,131,232,8,
+  252,233,244,1,248,136,129,252,248,239,15,130,244,63,255,15,133,244,248,11,
+  40,131,232,8,252,233,244,1,248,2,15,135,244,135,255,252,242,15,16,0,252,242,
+  15,88,193,102,15,126,193,9,205,255,131,232,8,252,233,244,1,248,137,129,252,
+  248,239,15,130,244,63,255,15,133,244,248,51,40,131,232,8,252,233,244,1,248,
+  2,15,135,244,135,255,252,242,15,16,0,252,242,15,88,193,102,15,126,193,49,
+  205,255,131,232,8,252,233,244,1,248,138,129,252,248,239,15,130,244,63,129,
+  122,253,4,239,255,248,2,15,205,252,233,244,89,248,139,129,252,248,239,15,
+  130,244,63,129,122,253,4,239,255,248,2,252,247,213,255,248,89,252,242,15,
+  42,197,252,233,244,72,255,248,135,139,68,36,84,252,233,244,63,255,248,140,
+  129,252,248,239,15,130,244,63,129,122,253,4,239,255,248,2,129,122,253,12,
+  239,15,133,244,63,139,74,8,255,248,140,129,252,248,239,15,130,244,63,129,
+  122,253,4,239,15,131,244,63,129,122,253,12,239,15,131,244,63,252,242,15,16,
   2,252,242,15,16,74,8,72,189,237,237,102,72,15,110,213,252,242,15,88,194,252,
-  242,15,88,202,102,15,126,197,102,15,126,201,255,211,197,252,233,244,88,255,
-  248,143,129,252,248,239,15,130,244,62,129,122,253,4,239,255,248,143,129,252,
-  248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,129,122,253,12,239,
-  15,131,244,62,252,242,15,16,2,252,242,15,16,74,8,72,189,237,237,102,72,15,
+  242,15,88,202,102,15,126,197,102,15,126,201,255,211,229,252,233,244,89,255,
+  248,141,129,252,248,239,15,130,244,63,129,122,253,4,239,255,248,141,129,252,
+  248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,129,122,253,12,239,
+  15,131,244,63,252,242,15,16,2,252,242,15,16,74,8,72,189,237,237,102,72,15,
   110,213,252,242,15,88,194,252,242,15,88,202,102,15,126,197,102,15,126,201,
-  255,211,205,252,233,244,88,248,126,184,237,252,233,244,62,248,128,184,237,
-  248,62,139,108,36,96,139,114,252,252,137,116,36,100,137,149,233,141,68,194,
-  252,248,141,136,233,137,133,233,139,66,252,248,59,141,233,15,135,244,251,
-  137,252,233,252,255,144,233,139,149,233,133,192,15,143,244,77,248,1,255,139,
-  141,233,41,209,193,252,233,3,133,192,141,65,1,139,106,252,248,15,133,244,
-  32,139,181,233,139,14,15,182,252,233,15,182,205,131,198,4,252,255,36,252,
-  235,248,32,137,209,252,247,198,237,15,133,244,249,15,182,110,252,253,72,252,
-  247,213,141,20,252,234,252,233,244,28,248,3,137,252,245,131,229,252,248,41,
-  252,234,252,233,244,28,248,5,186,237,137,252,233,232,251,1,0,139,149,233,
-  49,192,252,233,244,1,248,74,93,72,137,108,36,32,139,108,36,96,137,116,36,
-  100,137,149,233,255,141,68,194,252,248,137,252,233,137,133,233,232,251,1,
-  21,139,149,233,139,133,233,41,208,193,232,3,131,192,1,72,139,108,36,32,85,
-  195,248,144,255,15,182,131,233,168,235,15,133,244,251,168,235,15,133,244,
-  247,168,235,15,132,244,247,252,255,139,233,252,233,244,247,255,248,145,15,
-  182,131,233,168,235,15,133,244,251,252,233,244,247,248,146,15,182,131,233,
-  168,235,15,133,244,251,168,235,15,132,244,251,252,255,139,233,15,132,244,
-  247,168,235,15,132,244,251,248,1,255,139,108,36,96,137,149,233,137,252,242,
-  137,252,233,232,251,1,22,248,3,139,149,233,248,4,15,182,78,252,253,248,5,
-  15,182,110,252,252,15,183,70,252,254,252,255,164,253,252,235,233,248,147,
-  131,198,4,139,77,232,137,76,36,84,252,233,244,4,248,148,255,139,106,252,248,
-  139,173,233,15,182,133,233,141,4,194,139,108,36,96,137,149,233,137,133,233,
-  137,252,242,141,139,233,72,137,171,233,137,116,36,100,232,251,1,23,252,233,
-  244,3,255,248,149,137,116,36,100,255,248,150,255,137,116,36,100,131,206,1,
-  248,1,255,141,68,194,252,248,139,108,36,96,137,149,233,137,133,233,137,252,
-  242,137,252,233,232,251,1,24,199,68,36,100,0,0,0,0,255,131,230,252,254,255,
-  139,149,233,72,137,193,139,133,233,41,208,72,137,205,15,182,78,252,253,193,
-  232,3,131,192,1,252,255,229,248,151,255,65,85,65,84,65,83,65,82,65,81,65,
-  80,87,86,85,72,141,108,36,88,85,83,82,81,80,15,182,69,252,248,138,101,252,
-  240,76,137,125,252,248,76,137,117,252,240,139,93,0,139,139,233,199,131,233,
-  237,137,131,233,137,139,233,72,129,252,236,239,72,131,197,128,252,242,68,
-  15,17,125,252,248,252,242,68,15,17,117,252,240,252,242,68,15,17,109,232,252,
-  242,68,15,17,101,224,252,242,68,15,17,93,216,252,242,68,15,17,85,208,252,
-  242,68,15,17,77,200,252,242,68,15,17,69,192,252,242,15,17,125,184,252,242,
-  15,17,117,176,252,242,15,17,109,168,252,242,15,17,101,160,252,242,15,17,93,
-  152,252,242,15,17,85,144,252,242,15,17,77,136,252,242,15,17,69,128,139,171,
-  233,139,147,233,72,137,171,233,199,131,233,0,0,0,0,137,149,233,72,141,148,
-  253,36,233,141,139,233,232,251,1,25,72,139,141,233,72,129,225,239,137,169,
-  233,139,149,233,139,177,233,252,233,244,247,255,248,152,255,72,141,140,253,
-  36,233,248,1,102,68,15,111,185,233,102,68,15,111,177,233,102,68,15,111,169,
-  233,102,68,15,111,161,233,102,68,15,111,153,233,102,68,15,111,145,233,102,
-  68,15,111,137,233,102,68,15,111,129,233,102,15,111,185,233,72,137,204,102,
-  15,111,49,76,139,124,36,16,76,139,116,36,24,76,139,108,36,32,76,139,100,36,
-  80,133,192,15,136,244,249,137,68,36,84,139,122,252,248,139,191,233,139,191,
-  233,199,131,233,0,0,0,0,199,131,233,237,139,6,15,182,204,15,182,232,131,198,
-  4,193,232,16,129,252,253,239,15,130,244,248,255,139,68,36,84,248,2,252,255,
-  36,252,235,248,3,252,247,216,137,252,233,137,194,232,251,1,26,255,248,90,
-  255,217,124,36,4,137,68,36,8,102,184,0,4,102,11,68,36,4,102,37,252,255,252,
-  247,102,137,68,36,6,217,108,36,6,217,252,252,217,108,36,4,139,68,36,8,195,
-  255,248,153,72,184,237,237,102,72,15,110,208,72,184,237,237,102,72,15,110,
-  216,15,40,200,102,15,84,202,102,15,46,217,15,134,244,247,102,15,85,208,252,
-  242,15,88,203,252,242,15,92,203,102,15,86,202,72,184,237,237,102,72,15,110,
-  208,252,242,15,194,193,1,102,15,84,194,252,242,15,92,200,15,40,193,248,1,
-  195,248,92,255,217,124,36,4,137,68,36,8,102,184,0,8,102,11,68,36,4,102,37,
-  252,255,252,251,102,137,68,36,6,217,108,36,6,217,252,252,217,108,36,4,139,
-  68,36,8,195,255,248,154,72,184,237,237,102,72,15,110,208,72,184,237,237,102,
-  72,15,110,216,15,40,200,102,15,84,202,102,15,46,217,15,134,244,247,102,15,
-  85,208,252,242,15,88,203,252,242,15,92,203,102,15,86,202,72,184,237,237,102,
-  72,15,110,208,252,242,15,194,193,6,102,15,84,194,252,242,15,92,200,15,40,
-  193,248,1,195,248,113,255,217,124,36,4,137,68,36,8,102,184,0,12,102,11,68,
-  36,4,102,137,68,36,6,217,108,36,6,217,252,252,217,108,36,4,139,68,36,8,195,
-  255,248,155,72,184,237,237,102,72,15,110,208,72,184,237,237,102,72,15,110,
-  216,15,40,200,102,15,84,202,102,15,46,217,15,134,244,247,102,15,85,208,15,
-  40,193,252,242,15,88,203,252,242,15,92,203,72,184,237,237,102,72,15,110,216,
-  252,242,15,194,193,1,102,15,84,195,252,242,15,92,200,102,15,86,202,15,40,
-  193,248,1,195,248,156,255,15,40,232,252,242,15,94,193,72,184,237,237,102,
-  72,15,110,208,72,184,237,237,102,72,15,110,216,15,40,224,102,15,84,226,102,
-  15,46,220,15,134,244,247,102,15,85,208,252,242,15,88,227,252,242,15,92,227,
-  102,15,86,226,72,184,237,237,102,72,15,110,208,252,242,15,194,196,1,102,15,
-  84,194,252,242,15,92,224,15,40,197,252,242,15,89,204,252,242,15,92,193,195,
-  248,1,252,242,15,89,200,15,40,197,252,242,15,92,193,195,255,217,193,216,252,
-  241,217,124,36,4,102,184,0,4,102,11,68,36,4,102,37,252,255,252,247,102,137,
-  68,36,6,217,108,36,6,217,252,252,217,108,36,4,222,201,222,252,233,195,255,
-  248,97,217,252,234,222,201,248,157,217,84,36,8,129,124,36,8,0,0,128,127,15,
-  132,244,247,129,124,36,8,0,0,128,252,255,15,132,244,248,248,158,217,192,217,
-  252,252,220,252,233,217,201,217,252,240,217,232,222,193,217,252,253,221,217,
-  248,1,195,248,2,221,216,217,252,238,195,255,248,116,255,248,159,252,242,15,
-  45,193,252,242,15,42,208,102,15,46,202,15,133,244,254,15,138,244,255,248,
-  160,131,252,248,1,15,142,244,252,248,1,169,1,0,0,0,15,133,244,248,252,242,
-  15,89,192,209,232,252,233,244,1,248,2,209,232,15,132,244,251,15,40,200,248,
-  3,252,242,15,89,192,209,232,15,132,244,250,15,131,244,3,255,252,242,15,89,
-  200,252,233,244,3,248,4,252,242,15,89,193,248,5,195,248,6,15,132,244,5,15,
-  130,244,253,252,247,216,232,244,1,72,184,237,237,102,72,15,110,200,252,242,
-  15,94,200,15,40,193,195,248,7,72,184,237,237,102,72,15,110,192,195,248,8,
-  102,72,15,126,200,72,209,224,72,193,192,12,72,61,252,254,15,0,0,15,132,244,
-  248,102,72,15,126,192,72,209,224,15,132,244,250,255,72,193,192,12,72,61,252,
-  254,15,0,0,15,132,244,251,252,242,15,17,76,36,16,252,242,15,17,68,36,8,221,
-  68,36,16,221,68,36,8,217,252,241,217,192,217,252,252,220,252,233,217,201,
-  217,252,240,217,232,222,193,217,252,253,221,217,221,92,36,8,252,242,15,16,
-  68,36,8,195,248,9,72,184,237,237,102,72,15,110,208,102,15,46,194,15,132,244,
-  247,15,40,193,248,1,195,248,2,72,184,237,237,102,72,15,110,208,102,15,84,
-  194,72,184,237,237,102,72,15,110,208,102,15,46,194,15,132,244,1,102,15,80,
-  193,15,87,192,136,196,15,146,208,48,224,15,133,244,1,248,3,72,184,237,237,
-  255,102,72,15,110,192,195,248,4,102,15,80,193,133,192,15,133,244,3,15,87,
-  192,195,248,5,102,15,80,193,133,192,15,132,244,3,15,87,192,195,248,161,255,
-  131,252,250,1,15,130,244,90,15,132,244,92,131,252,250,3,15,130,244,113,15,
-  135,244,248,252,242,15,81,192,195,248,2,252,242,15,17,68,36,8,221,68,36,8,
-  131,252,250,5,15,135,244,248,88,15,132,244,247,232,244,97,80,252,233,244,
-  253,248,1,232,244,157,255,80,252,233,244,253,248,2,131,252,250,7,15,132,244,
-  247,15,135,244,248,217,252,237,217,201,217,252,241,252,233,244,253,248,1,
-  217,232,217,201,217,252,241,252,233,244,253,248,2,131,252,250,9,15,132,244,
-  247,15,135,244,248,217,252,236,217,201,217,252,241,252,233,244,253,248,1,
-  255,217,252,254,252,233,244,253,248,2,131,252,250,11,15,132,244,247,15,135,
-  244,255,217,252,255,252,233,244,253,248,1,217,252,242,221,216,248,7,221,92,
-  36,8,252,242,15,16,68,36,8,195,255,139,84,36,12,221,68,36,4,131,252,250,1,
-  15,130,244,90,15,132,244,92,131,252,250,3,15,130,244,113,15,135,244,248,217,
-  252,250,195,248,2,131,252,250,5,15,130,244,97,15,132,244,157,131,252,250,
-  7,15,132,244,247,15,135,244,248,217,252,237,217,201,217,252,241,195,248,1,
-  217,232,217,201,217,252,241,195,248,2,131,252,250,9,15,132,244,247,255,15,
-  135,244,248,217,252,236,217,201,217,252,241,195,248,1,217,252,254,195,248,
-  2,131,252,250,11,15,132,244,247,15,135,244,255,217,252,255,195,248,1,217,
-  252,242,221,216,195,255,248,9,204,255,248,162,255,65,131,252,248,1,15,132,
-  244,247,15,135,244,248,252,242,15,88,193,195,248,1,252,242,15,92,193,195,
-  248,2,65,131,252,248,3,15,132,244,247,15,135,244,248,252,242,15,89,193,195,
-  248,1,252,242,15,94,193,195,248,2,65,131,252,248,5,15,130,244,156,15,132,
-  244,116,65,131,252,248,7,15,132,244,247,15,135,244,248,72,184,237,237,255,
-  102,72,15,110,200,15,87,193,195,248,1,72,184,237,237,102,72,15,110,200,15,
-  84,193,195,248,2,65,131,252,248,9,15,135,244,248,252,242,15,17,68,36,8,252,
-  242,15,17,76,36,16,221,68,36,8,221,68,36,16,15,132,244,247,217,252,243,248,
-  7,221,92,36,8,252,242,15,16,68,36,8,195,248,1,217,201,217,252,253,221,217,
-  252,233,244,7,248,2,65,131,252,248,11,15,132,244,247,15,135,244,255,252,242,
-  15,93,193,195,248,1,252,242,15,95,193,195,248,9,204,255,139,68,36,20,221,
-  68,36,4,221,68,36,12,131,252,248,1,15,132,244,247,15,135,244,248,222,193,
-  195,248,1,222,252,233,195,248,2,131,252,248,3,15,132,244,247,15,135,244,248,
-  222,201,195,248,1,222,252,249,195,248,2,131,252,248,5,15,130,244,156,15,132,
-  244,116,131,252,248,7,15,132,244,247,15,135,244,248,255,221,216,217,224,195,
-  248,1,221,216,217,225,195,248,2,131,252,248,9,15,132,244,247,15,135,244,248,
-  217,252,243,195,248,1,217,201,217,252,253,221,217,195,248,2,131,252,248,11,
-  15,132,244,247,15,135,244,255,255,219,252,233,219,209,221,217,195,248,1,219,
-  252,233,218,209,221,217,195,255,221,225,223,224,252,246,196,1,15,132,244,
-  248,217,201,248,2,221,216,195,248,1,221,225,223,224,252,246,196,1,15,133,
-  244,248,217,201,248,2,221,216,195,255,248,163,137,200,86,72,137,214,83,15,
-  162,137,6,137,94,4,137,78,8,137,86,12,91,94,195,248,164,255,85,72,137,229,
-  83,72,137,203,139,131,233,72,41,196,255,15,182,139,233,131,252,233,1,15,136,
-  244,248,248,1,72,139,132,253,203,233,72,137,132,253,204,233,131,252,233,1,
-  15,137,244,1,248,2,15,182,131,233,72,139,139,233,72,139,147,233,76,139,131,
-  233,76,139,139,233,133,192,15,132,244,251,15,40,131,233,15,40,139,233,15,
-  40,147,233,15,40,155,233,248,5,255,252,255,147,233,72,137,131,233,15,41,131,
-  233,255,72,139,93,252,248,201,195,255,248,165,255,249,255,129,124,253,202,
-  4,239,15,133,244,253,129,124,253,194,4,239,15,133,244,254,139,44,202,131,
-  198,4,59,44,194,255,15,141,244,255,255,15,140,244,255,255,15,143,244,255,
-  255,15,142,244,255,255,248,6,15,183,70,252,254,141,180,253,134,233,248,9,
+  255,211,252,237,252,233,244,89,255,248,142,129,252,248,239,15,130,244,63,
+  129,122,253,4,239,255,248,142,129,252,248,239,15,130,244,63,129,122,253,4,
+  239,15,131,244,63,129,122,253,12,239,15,131,244,63,252,242,15,16,2,252,242,
+  15,16,74,8,72,189,237,237,102,72,15,110,213,252,242,15,88,194,252,242,15,
+  88,202,102,15,126,197,102,15,126,201,255,211,252,253,252,233,244,89,255,248,
+  143,129,252,248,239,15,130,244,63,129,122,253,4,239,255,248,143,129,252,248,
+  239,15,130,244,63,129,122,253,4,239,15,131,244,63,129,122,253,12,239,15,131,
+  244,63,252,242,15,16,2,252,242,15,16,74,8,72,189,237,237,102,72,15,110,213,
+  252,242,15,88,194,252,242,15,88,202,102,15,126,197,102,15,126,201,255,211,
+  197,252,233,244,89,255,248,144,129,252,248,239,15,130,244,63,129,122,253,
+  4,239,255,248,144,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,
+  244,63,129,122,253,12,239,15,131,244,63,252,242,15,16,2,252,242,15,16,74,
+  8,72,189,237,237,102,72,15,110,213,252,242,15,88,194,252,242,15,88,202,102,
+  15,126,197,102,15,126,201,255,211,205,252,233,244,89,248,127,184,237,252,
+  233,244,63,248,129,184,237,248,63,139,108,36,96,139,114,252,252,137,116,36,
+  100,137,149,233,141,68,194,252,248,141,136,233,137,133,233,139,66,252,248,
+  59,141,233,15,135,244,251,137,252,233,252,255,144,233,139,149,233,133,192,
+  15,143,244,78,248,1,255,139,141,233,41,209,193,252,233,3,133,192,141,65,1,
+  139,106,252,248,15,133,244,33,139,181,233,139,14,15,182,252,233,15,182,205,
+  131,198,4,252,255,36,252,235,248,33,137,209,252,247,198,237,15,133,244,249,
+  15,182,110,252,253,72,252,247,213,141,20,252,234,252,233,244,28,248,3,137,
+  252,245,131,229,252,248,41,252,234,252,233,244,28,248,5,186,237,137,252,233,
+  232,251,1,0,139,149,233,49,192,252,233,244,1,248,75,93,72,137,108,36,32,139,
+  108,36,96,137,116,36,100,137,149,233,255,141,68,194,252,248,137,252,233,137,
+  133,233,232,251,1,21,139,149,233,139,133,233,41,208,193,232,3,131,192,1,72,
+  139,108,36,32,85,195,248,145,255,15,182,131,233,168,235,15,133,244,251,168,
+  235,15,133,244,247,168,235,15,132,244,247,252,255,139,233,252,233,244,247,
+  255,248,146,15,182,131,233,168,235,15,133,244,251,252,233,244,247,248,147,
+  15,182,131,233,168,235,15,133,244,251,168,235,15,132,244,251,252,255,139,
+  233,15,132,244,247,168,235,15,132,244,251,248,1,255,139,108,36,96,137,149,
+  233,137,252,242,137,252,233,232,251,1,22,248,3,139,149,233,248,4,15,182,78,
+  252,253,248,5,15,182,110,252,252,15,183,70,252,254,252,255,164,253,252,235,
+  233,248,148,131,198,4,139,77,232,137,76,36,84,252,233,244,4,248,149,255,139,
+  106,252,248,139,173,233,15,182,133,233,141,4,194,139,108,36,96,137,149,233,
+  137,133,233,137,252,242,141,139,233,72,137,171,233,137,116,36,100,232,251,
+  1,23,252,233,244,3,255,248,150,137,116,36,100,255,248,151,255,137,116,36,
+  100,131,206,1,248,1,255,141,68,194,252,248,139,108,36,96,137,149,233,137,
+  133,233,137,252,242,137,252,233,232,251,1,24,199,68,36,100,0,0,0,0,255,131,
+  230,252,254,255,139,149,233,72,137,193,139,133,233,41,208,72,137,205,15,182,
+  78,252,253,193,232,3,131,192,1,252,255,229,248,152,255,65,85,65,84,65,83,
+  65,82,65,81,65,80,87,86,85,72,141,108,36,88,85,83,82,81,80,15,182,69,252,
+  248,138,101,252,240,76,137,125,252,248,76,137,117,252,240,139,93,0,139,139,
+  233,199,131,233,237,137,131,233,137,139,233,72,129,252,236,239,72,131,197,
+  128,252,242,68,15,17,125,252,248,252,242,68,15,17,117,252,240,252,242,68,
+  15,17,109,232,252,242,68,15,17,101,224,252,242,68,15,17,93,216,252,242,68,
+  15,17,85,208,252,242,68,15,17,77,200,252,242,68,15,17,69,192,252,242,15,17,
+  125,184,252,242,15,17,117,176,252,242,15,17,109,168,252,242,15,17,101,160,
+  252,242,15,17,93,152,252,242,15,17,85,144,252,242,15,17,77,136,252,242,15,
+  17,69,128,139,171,233,139,147,233,72,137,171,233,199,131,233,0,0,0,0,137,
+  149,233,72,141,148,253,36,233,141,139,233,232,251,1,25,72,139,141,233,72,
+  129,225,239,137,169,233,139,149,233,139,177,233,252,233,244,247,255,248,153,
+  255,72,141,140,253,36,233,248,1,102,68,15,111,185,233,102,68,15,111,177,233,
+  102,68,15,111,169,233,102,68,15,111,161,233,102,68,15,111,153,233,102,68,
+  15,111,145,233,102,68,15,111,137,233,102,68,15,111,129,233,102,15,111,185,
+  233,72,137,204,102,15,111,49,76,139,124,36,16,76,139,116,36,24,76,139,108,
+  36,32,76,139,100,36,80,133,192,15,136,244,249,137,68,36,84,139,122,252,248,
+  139,191,233,139,191,233,199,131,233,0,0,0,0,199,131,233,237,139,6,15,182,
+  204,15,182,232,131,198,4,193,232,16,129,252,253,239,15,130,244,248,255,139,
+  68,36,84,248,2,252,255,36,252,235,248,3,252,247,216,137,252,233,137,194,232,
+  251,1,26,255,248,91,255,217,124,36,4,137,68,36,8,102,184,0,4,102,11,68,36,
+  4,102,37,252,255,252,247,102,137,68,36,6,217,108,36,6,217,252,252,217,108,
+  36,4,139,68,36,8,195,255,248,154,72,184,237,237,102,72,15,110,208,72,184,
+  237,237,102,72,15,110,216,15,40,200,102,15,84,202,102,15,46,217,15,134,244,
+  247,102,15,85,208,252,242,15,88,203,252,242,15,92,203,102,15,86,202,72,184,
+  237,237,102,72,15,110,208,252,242,15,194,193,1,102,15,84,194,252,242,15,92,
+  200,15,40,193,248,1,195,248,93,255,217,124,36,4,137,68,36,8,102,184,0,8,102,
+  11,68,36,4,102,37,252,255,252,251,102,137,68,36,6,217,108,36,6,217,252,252,
+  217,108,36,4,139,68,36,8,195,255,248,155,72,184,237,237,102,72,15,110,208,
+  72,184,237,237,102,72,15,110,216,15,40,200,102,15,84,202,102,15,46,217,15,
+  134,244,247,102,15,85,208,252,242,15,88,203,252,242,15,92,203,102,15,86,202,
+  72,184,237,237,102,72,15,110,208,252,242,15,194,193,6,102,15,84,194,252,242,
+  15,92,200,15,40,193,248,1,195,248,114,255,217,124,36,4,137,68,36,8,102,184,
+  0,12,102,11,68,36,4,102,137,68,36,6,217,108,36,6,217,252,252,217,108,36,4,
+  139,68,36,8,195,255,248,156,72,184,237,237,102,72,15,110,208,72,184,237,237,
+  102,72,15,110,216,15,40,200,102,15,84,202,102,15,46,217,15,134,244,247,102,
+  15,85,208,15,40,193,252,242,15,88,203,252,242,15,92,203,72,184,237,237,102,
+  72,15,110,216,252,242,15,194,193,1,102,15,84,195,252,242,15,92,200,102,15,
+  86,202,15,40,193,248,1,195,248,157,255,15,40,232,252,242,15,94,193,72,184,
+  237,237,102,72,15,110,208,72,184,237,237,102,72,15,110,216,15,40,224,102,
+  15,84,226,102,15,46,220,15,134,244,247,102,15,85,208,252,242,15,88,227,252,
+  242,15,92,227,102,15,86,226,72,184,237,237,102,72,15,110,208,252,242,15,194,
+  196,1,102,15,84,194,252,242,15,92,224,15,40,197,252,242,15,89,204,252,242,
+  15,92,193,195,248,1,252,242,15,89,200,15,40,197,252,242,15,92,193,195,255,
+  217,193,216,252,241,217,124,36,4,102,184,0,4,102,11,68,36,4,102,37,252,255,
+  252,247,102,137,68,36,6,217,108,36,6,217,252,252,217,108,36,4,222,201,222,
+  252,233,195,255,248,98,217,252,234,222,201,248,158,217,84,36,8,129,124,36,
+  8,0,0,128,127,15,132,244,247,129,124,36,8,0,0,128,252,255,15,132,244,248,
+  248,159,217,192,217,252,252,220,252,233,217,201,217,252,240,217,232,222,193,
+  217,252,253,221,217,248,1,195,248,2,221,216,217,252,238,195,255,248,117,255,
+  248,160,252,242,15,45,193,252,242,15,42,208,102,15,46,202,15,133,244,254,
+  15,138,244,255,248,161,131,252,248,1,15,142,244,252,248,1,169,1,0,0,0,15,
+  133,244,248,252,242,15,89,192,209,232,252,233,244,1,248,2,209,232,15,132,
+  244,251,15,40,200,248,3,252,242,15,89,192,209,232,15,132,244,250,15,131,244,
+  3,255,252,242,15,89,200,252,233,244,3,248,4,252,242,15,89,193,248,5,195,248,
+  6,15,132,244,5,15,130,244,253,252,247,216,232,244,1,72,184,237,237,102,72,
+  15,110,200,252,242,15,94,200,15,40,193,195,248,7,72,184,237,237,102,72,15,
+  110,192,195,248,8,102,72,15,126,200,72,209,224,72,193,192,12,72,61,252,254,
+  15,0,0,15,132,244,248,102,72,15,126,192,72,209,224,15,132,244,250,255,72,
+  193,192,12,72,61,252,254,15,0,0,15,132,244,251,252,242,15,17,76,36,16,252,
+  242,15,17,68,36,8,221,68,36,16,221,68,36,8,217,252,241,217,192,217,252,252,
+  220,252,233,217,201,217,252,240,217,232,222,193,217,252,253,221,217,221,92,
+  36,8,252,242,15,16,68,36,8,195,248,9,72,184,237,237,102,72,15,110,208,102,
+  15,46,194,15,132,244,247,15,40,193,248,1,195,248,2,72,184,237,237,102,72,
+  15,110,208,102,15,84,194,72,184,237,237,102,72,15,110,208,102,15,46,194,15,
+  132,244,1,102,15,80,193,15,87,192,136,196,15,146,208,48,224,15,133,244,1,
+  248,3,72,184,237,237,255,102,72,15,110,192,195,248,4,102,15,80,193,133,192,
+  15,133,244,3,15,87,192,195,248,5,102,15,80,193,133,192,15,132,244,3,15,87,
+  192,195,248,162,255,131,252,250,1,15,130,244,91,15,132,244,93,131,252,250,
+  3,15,130,244,114,15,135,244,248,252,242,15,81,192,195,248,2,252,242,15,17,
+  68,36,8,221,68,36,8,131,252,250,5,15,135,244,248,88,15,132,244,247,232,244,
+  98,80,252,233,244,253,248,1,232,244,158,255,80,252,233,244,253,248,2,131,
+  252,250,7,15,132,244,247,15,135,244,248,217,252,237,217,201,217,252,241,252,
+  233,244,253,248,1,217,232,217,201,217,252,241,252,233,244,253,248,2,131,252,
+  250,9,15,132,244,247,15,135,244,248,217,252,236,217,201,217,252,241,252,233,
+  244,253,248,1,255,217,252,254,252,233,244,253,248,2,131,252,250,11,15,132,
+  244,247,15,135,244,255,217,252,255,252,233,244,253,248,1,217,252,242,221,
+  216,248,7,221,92,36,8,252,242,15,16,68,36,8,195,255,139,84,36,12,221,68,36,
+  4,131,252,250,1,15,130,244,91,15,132,244,93,131,252,250,3,15,130,244,114,
+  15,135,244,248,217,252,250,195,248,2,131,252,250,5,15,130,244,98,15,132,244,
+  158,131,252,250,7,15,132,244,247,15,135,244,248,217,252,237,217,201,217,252,
+  241,195,248,1,217,232,217,201,217,252,241,195,248,2,131,252,250,9,15,132,
+  244,247,255,15,135,244,248,217,252,236,217,201,217,252,241,195,248,1,217,
+  252,254,195,248,2,131,252,250,11,15,132,244,247,15,135,244,255,217,252,255,
+  195,248,1,217,252,242,221,216,195,255,248,9,204,255,248,163,255,65,131,252,
+  248,1,15,132,244,247,15,135,244,248,252,242,15,88,193,195,248,1,252,242,15,
+  92,193,195,248,2,65,131,252,248,3,15,132,244,247,15,135,244,248,252,242,15,
+  89,193,195,248,1,252,242,15,94,193,195,248,2,65,131,252,248,5,15,130,244,
+  157,15,132,244,117,65,131,252,248,7,15,132,244,247,15,135,244,248,72,184,
+  237,237,255,102,72,15,110,200,15,87,193,195,248,1,72,184,237,237,102,72,15,
+  110,200,15,84,193,195,248,2,65,131,252,248,9,15,135,244,248,252,242,15,17,
+  68,36,8,252,242,15,17,76,36,16,221,68,36,8,221,68,36,16,15,132,244,247,217,
+  252,243,248,7,221,92,36,8,252,242,15,16,68,36,8,195,248,1,217,201,217,252,
+  253,221,217,252,233,244,7,248,2,65,131,252,248,11,15,132,244,247,15,135,244,
+  255,252,242,15,93,193,195,248,1,252,242,15,95,193,195,248,9,204,255,139,68,
+  36,20,221,68,36,4,221,68,36,12,131,252,248,1,15,132,244,247,15,135,244,248,
+  222,193,195,248,1,222,252,233,195,248,2,131,252,248,3,15,132,244,247,15,135,
+  244,248,222,201,195,248,1,222,252,249,195,248,2,131,252,248,5,15,130,244,
+  157,15,132,244,117,131,252,248,7,15,132,244,247,15,135,244,248,255,221,216,
+  217,224,195,248,1,221,216,217,225,195,248,2,131,252,248,9,15,132,244,247,
+  15,135,244,248,217,252,243,195,248,1,217,201,217,252,253,221,217,195,248,
+  2,131,252,248,11,15,132,244,247,15,135,244,255,255,219,252,233,219,209,221,
+  217,195,248,1,219,252,233,218,209,221,217,195,255,221,225,223,224,252,246,
+  196,1,15,132,244,248,217,201,248,2,221,216,195,248,1,221,225,223,224,252,
+  246,196,1,15,133,244,248,217,201,248,2,221,216,195,255,248,164,137,200,86,
+  72,137,214,83,15,162,137,6,137,94,4,137,78,8,137,86,12,91,94,195,248,165,
+  255,204,248,166,255,87,86,83,72,131,252,236,40,141,157,233,139,181,233,15,
+  183,192,137,134,233,72,137,142,233,72,137,150,233,76,137,134,233,76,137,142,
+  233,252,242,15,17,134,233,252,242,15,17,142,233,252,242,15,17,150,233,252,
+  242,15,17,158,233,72,141,132,253,36,233,72,137,134,233,72,137,226,137,116,
+  36,100,137,252,241,232,251,1,27,199,131,233,237,139,144,233,139,128,233,41,
+  208,139,106,252,248,193,232,3,131,192,1,139,181,233,139,14,15,182,252,233,
+  15,182,205,131,198,4,252,255,36,252,235,255,248,32,255,139,76,36,96,139,179,
+  233,72,137,142,233,137,145,233,137,169,233,137,252,241,137,194,232,251,1,
+  28,72,139,134,233,252,242,15,16,134,233,252,233,244,16,255,248,167,255,85,
+  72,137,229,83,72,137,203,139,131,233,72,41,196,255,15,182,139,233,131,252,
+  233,1,15,136,244,248,248,1,72,139,132,253,203,233,72,137,132,253,204,233,
+  131,252,233,1,15,137,244,1,248,2,15,182,131,233,72,139,139,233,72,139,147,
+  233,76,139,131,233,76,139,139,233,133,192,15,132,244,251,15,40,131,233,15,
+  40,139,233,15,40,147,233,15,40,155,233,248,5,255,252,255,147,233,72,137,131,
+  233,15,41,131,233,255,72,139,93,252,248,201,195,255,129,124,253,202,4,239,
+  15,133,244,253,129,124,253,194,4,239,15,133,244,254,139,44,202,131,198,4,
+  59,44,194,255,15,141,244,255,255,15,140,244,255,255,15,143,244,255,255,15,
+  142,244,255,255,248,6,15,183,70,252,254,141,180,253,134,233,248,9,139,6,15,
+  182,204,15,182,232,131,198,4,193,232,16,252,255,36,252,235,248,7,15,135,244,
+  44,129,124,253,194,4,239,15,130,244,247,15,133,244,44,255,252,242,15,42,4,
+  194,252,233,244,248,255,221,4,202,219,4,194,252,233,244,249,255,248,8,15,
+  135,244,44,255,252,242,15,42,12,202,252,242,15,16,4,194,131,198,4,102,15,
+  46,193,255,15,134,244,9,255,15,135,244,9,255,15,130,244,9,255,15,131,244,
+  9,255,252,233,244,6,255,219,4,202,252,233,244,248,255,129,124,253,202,4,239,
+  15,131,244,44,129,124,253,194,4,239,15,131,244,44,255,248,1,252,242,15,16,
+  4,194,248,2,131,198,4,102,15,46,4,202,248,3,255,248,1,221,4,202,248,2,221,
+  4,194,248,3,131,198,4,255,223,252,233,221,216,255,218,252,233,223,224,158,
+  255,15,135,244,247,255,15,130,244,247,255,15,131,244,247,255,15,183,70,252,
+  254,141,180,253,134,233,248,1,139,6,15,182,204,15,182,232,131,198,4,193,232,
+  16,252,255,36,252,235,255,139,108,194,4,131,198,4,255,129,252,253,239,15,
+  133,244,253,129,124,253,202,4,239,15,133,244,254,139,44,194,59,44,202,255,
+  15,133,244,255,255,15,132,244,255,255,15,183,70,252,254,141,180,253,134,233,
+  248,9,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,252,235,
+  248,7,15,135,244,251,129,124,253,202,4,239,15,130,244,247,15,133,244,251,
+  255,252,242,15,42,4,202,255,219,4,202,255,252,233,244,248,248,8,15,135,244,
+  251,255,252,242,15,42,4,194,102,15,46,4,202,255,219,4,194,221,4,202,255,252,
+  233,244,250,255,129,252,253,239,15,131,244,251,129,124,253,202,4,239,15,131,
+  244,251,255,248,1,252,242,15,16,4,202,248,2,102,15,46,4,194,248,4,255,248,
+  1,221,4,202,248,2,221,4,194,248,4,255,15,138,244,248,15,133,244,248,255,15,
+  138,244,248,15,132,244,247,255,248,1,15,183,70,252,254,141,180,253,134,233,
+  248,2,255,248,2,15,183,70,252,254,141,180,253,134,233,248,1,255,252,233,244,
+  9,255,129,252,253,239,15,132,244,49,129,124,253,202,4,239,15,132,244,49,255,
+  57,108,202,4,15,133,244,2,129,252,253,239,15,131,244,1,139,12,202,139,4,194,
+  57,193,15,132,244,1,129,252,253,239,15,135,244,2,129,252,253,239,15,130,244,
+  2,139,169,233,133,252,237,15,132,244,2,252,246,133,233,235,15,133,244,2,255,
+  49,252,237,255,189,1,0,0,0,255,252,233,244,48,255,248,3,129,252,253,239,255,
+  15,133,244,9,255,252,233,244,49,255,72,252,247,208,139,108,202,4,131,198,
+  4,129,252,253,239,15,133,244,249,139,12,202,59,12,135,255,139,108,202,4,131,
+  198,4,255,129,252,253,239,15,133,244,253,129,124,253,199,4,239,15,133,244,
+  254,139,44,199,59,44,202,255,15,183,70,252,254,141,180,253,134,233,248,9,
   139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,252,235,248,7,
-  15,135,244,43,129,124,253,194,4,239,15,130,244,247,15,133,244,43,255,252,
-  242,15,42,4,194,252,233,244,248,255,221,4,202,219,4,194,252,233,244,249,255,
-  248,8,15,135,244,43,255,252,242,15,42,12,202,252,242,15,16,4,194,131,198,
-  4,102,15,46,193,255,15,134,244,9,255,15,135,244,9,255,15,130,244,9,255,15,
-  131,244,9,255,252,233,244,6,255,219,4,202,252,233,244,248,255,129,124,253,
-  202,4,239,15,131,244,43,129,124,253,194,4,239,15,131,244,43,255,248,1,252,
-  242,15,16,4,194,248,2,131,198,4,102,15,46,4,202,248,3,255,248,1,221,4,202,
-  248,2,221,4,194,248,3,131,198,4,255,223,252,233,221,216,255,218,252,233,223,
-  224,158,255,15,134,244,247,255,15,135,244,247,255,15,130,244,247,255,15,131,
-  244,247,255,15,183,70,252,254,141,180,253,134,233,248,1,139,6,15,182,204,
-  15,182,232,131,198,4,193,232,16,252,255,36,252,235,255,139,108,194,4,131,
-  198,4,255,129,252,253,239,15,133,244,253,129,124,253,202,4,239,15,133,244,
-  254,139,44,194,59,44,202,255,15,133,244,255,255,15,132,244,255,255,15,183,
-  70,252,254,141,180,253,134,233,248,9,139,6,15,182,204,15,182,232,131,198,
-  4,193,232,16,252,255,36,252,235,248,7,15,135,244,251,129,124,253,202,4,239,
-  15,130,244,247,15,133,244,251,255,252,242,15,42,4,202,255,219,4,202,255,252,
-  233,244,248,248,8,15,135,244,251,255,252,242,15,42,4,194,102,15,46,4,202,
-  255,219,4,194,221,4,202,255,252,233,244,250,255,129,252,253,239,15,131,244,
-  251,129,124,253,202,4,239,15,131,244,251,255,248,1,252,242,15,16,4,202,248,
-  2,102,15,46,4,194,248,4,255,248,1,221,4,202,248,2,221,4,194,248,4,255,15,
-  138,244,248,15,133,244,248,255,15,138,244,248,15,132,244,247,255,248,1,15,
-  183,70,252,254,141,180,253,134,233,248,2,255,248,2,15,183,70,252,254,141,
-  180,253,134,233,248,1,255,252,233,244,9,255,129,252,253,239,15,132,244,48,
-  129,124,253,202,4,239,15,132,244,48,255,57,108,202,4,15,133,244,2,129,252,
-  253,239,15,131,244,1,139,12,202,139,4,194,57,193,15,132,244,1,129,252,253,
-  239,15,135,244,2,139,169,233,133,252,237,15,132,244,2,252,246,133,233,235,
-  15,133,244,2,255,49,252,237,255,189,1,0,0,0,255,252,233,244,47,255,248,3,
-  129,252,253,239,255,15,133,244,9,255,252,233,244,48,255,72,252,247,208,139,
-  108,202,4,131,198,4,129,252,253,239,15,133,244,249,139,12,202,59,12,135,255,
-  139,108,202,4,131,198,4,255,129,252,253,239,15,133,244,253,129,124,253,199,
-  4,239,15,133,244,254,139,44,199,59,44,202,255,15,183,70,252,254,141,180,253,
-  134,233,248,9,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,
-  252,235,248,7,15,135,244,249,129,124,253,199,4,239,15,130,244,247,255,252,
-  242,15,42,4,199,255,219,4,199,255,252,233,244,248,248,8,255,252,242,15,42,
-  4,202,102,15,46,4,199,255,219,4,202,221,4,199,255,129,252,253,239,15,131,
-  244,249,255,248,1,252,242,15,16,4,199,248,2,102,15,46,4,202,248,4,255,248,
-  1,221,4,199,248,2,221,4,202,248,4,255,72,252,247,208,139,108,202,4,131,198,
-  4,57,197,255,15,133,244,249,15,183,70,252,254,141,180,253,134,233,248,2,139,
-  6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,252,235,248,3,129,
-  252,253,239,15,133,244,2,252,233,244,48,255,15,132,244,248,129,252,253,239,
-  15,132,244,48,15,183,70,252,254,141,180,253,134,233,248,2,139,6,15,182,204,
-  15,182,232,131,198,4,193,232,16,252,255,36,252,235,255,139,108,194,4,131,
-  198,4,129,252,253,239,255,137,108,202,4,139,44,194,137,44,202,255,72,139,
-  44,194,72,137,44,202,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,
-  255,36,252,235,255,49,252,237,129,124,253,194,4,239,129,213,239,137,108,202,
-  4,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,252,235,255,
-  129,124,253,194,4,239,15,133,244,251,139,44,194,252,247,221,15,128,244,250,
-  199,68,202,4,237,137,44,202,248,9,139,6,15,182,204,15,182,232,131,198,4,193,
-  232,16,252,255,36,252,235,248,4,199,68,202,4,0,0,224,65,199,4,202,0,0,0,0,
-  252,233,244,9,248,5,15,135,244,53,255,129,124,253,194,4,239,15,131,244,53,
-  255,252,242,15,16,4,194,72,184,237,237,102,72,15,110,200,15,87,193,252,242,
-  15,17,4,202,255,221,4,194,217,224,221,28,202,255,129,124,253,194,4,239,15,
-  133,244,248,139,4,194,255,139,128,233,248,1,199,68,202,4,237,137,4,202,255,
-  15,87,192,252,242,15,42,128,233,248,1,252,242,15,17,4,202,255,219,128,233,
-  248,1,221,28,202,255,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,
-  255,36,252,235,248,2,129,124,253,194,4,239,15,133,244,56,139,12,194,255,139,
-  169,233,131,252,253,0,15,133,244,255,248,3,255,248,57,137,213,232,251,1,20,
-  255,252,242,15,42,192,255,137,252,234,15,182,78,252,253,252,233,244,1,255,
-  248,9,252,246,133,233,235,15,133,244,3,252,233,244,56,255,15,182,252,236,
-  15,182,192,255,129,124,253,252,234,4,239,15,133,244,50,129,124,253,199,4,
-  239,15,133,244,50,139,44,252,234,3,44,199,15,128,244,49,255,129,124,253,252,
-  234,4,239,15,133,244,52,129,124,253,199,4,239,15,133,244,52,139,4,199,3,4,
-  252,234,15,128,244,51,255,129,124,253,252,234,4,239,15,133,244,55,129,124,
-  253,194,4,239,15,133,244,55,139,44,252,234,3,44,194,15,128,244,54,255,199,
-  68,202,4,237,255,129,124,253,252,234,4,239,15,131,244,50,255,129,124,253,
-  199,4,239,15,131,244,50,255,252,242,15,16,4,252,234,252,242,15,88,4,199,255,
-  221,4,252,234,220,4,199,255,129,124,253,252,234,4,239,15,131,244,52,255,129,
-  124,253,199,4,239,15,131,244,52,255,252,242,15,16,4,199,252,242,15,88,4,252,
-  234,255,221,4,199,220,4,252,234,255,129,124,253,252,234,4,239,15,131,244,
-  55,129,124,253,194,4,239,15,131,244,55,255,252,242,15,16,4,252,234,252,242,
-  15,88,4,194,255,221,4,252,234,220,4,194,255,129,124,253,252,234,4,239,15,
-  133,244,50,129,124,253,199,4,239,15,133,244,50,139,44,252,234,43,44,199,15,
-  128,244,49,255,129,124,253,252,234,4,239,15,133,244,52,129,124,253,199,4,
-  239,15,133,244,52,139,4,199,43,4,252,234,15,128,244,51,255,129,124,253,252,
-  234,4,239,15,133,244,55,129,124,253,194,4,239,15,133,244,55,139,44,252,234,
-  43,44,194,15,128,244,54,255,252,242,15,16,4,252,234,252,242,15,92,4,199,255,
-  221,4,252,234,220,36,199,255,252,242,15,16,4,199,252,242,15,92,4,252,234,
-  255,221,4,199,220,36,252,234,255,252,242,15,16,4,252,234,252,242,15,92,4,
-  194,255,221,4,252,234,220,36,194,255,129,124,253,252,234,4,239,15,133,244,
-  50,129,124,253,199,4,239,15,133,244,50,139,44,252,234,15,175,44,199,15,128,
-  244,49,255,129,124,253,252,234,4,239,15,133,244,52,129,124,253,199,4,239,
-  15,133,244,52,139,4,199,15,175,4,252,234,15,128,244,51,255,129,124,253,252,
-  234,4,239,15,133,244,55,129,124,253,194,4,239,15,133,244,55,139,44,252,234,
-  15,175,44,194,15,128,244,54,255,252,242,15,16,4,252,234,252,242,15,89,4,199,
-  255,221,4,252,234,220,12,199,255,252,242,15,16,4,199,252,242,15,89,4,252,
-  234,255,221,4,199,220,12,252,234,255,252,242,15,16,4,252,234,252,242,15,89,
-  4,194,255,221,4,252,234,220,12,194,255,252,242,15,16,4,252,234,252,242,15,
-  94,4,199,255,221,4,252,234,220,52,199,255,252,242,15,16,4,199,252,242,15,
-  94,4,252,234,255,221,4,199,220,52,252,234,255,252,242,15,16,4,252,234,252,
-  242,15,94,4,194,255,221,4,252,234,220,52,194,255,252,242,15,16,4,252,234,
-  252,242,15,16,12,199,255,221,4,252,234,221,4,199,255,252,242,15,16,4,199,
-  252,242,15,16,12,252,234,255,221,4,199,221,4,252,234,255,252,242,15,16,4,
-  252,234,252,242,15,16,12,194,255,221,4,252,234,221,4,194,255,248,166,232,
-  244,156,255,252,233,244,166,255,232,244,116,255,15,182,252,236,15,182,192,
-  139,76,36,96,137,145,233,141,20,194,65,137,192,65,41,232,248,35,137,205,137,
-  116,36,100,232,251,1,27,139,149,233,133,192,15,133,244,44,15,182,110,252,
-  255,15,182,78,252,253,72,139,4,252,234,72,137,4,202,139,6,15,182,204,15,182,
-  232,131,198,4,193,232,16,252,255,36,252,235,255,72,252,247,208,139,4,135,
-  199,68,202,4,237,137,4,202,139,6,15,182,204,15,182,232,131,198,4,193,232,
-  16,252,255,36,252,235,255,15,191,192,199,68,202,4,237,137,4,202,255,15,191,
-  192,252,242,15,42,192,252,242,15,17,4,202,255,223,70,252,254,221,28,202,255,
-  252,242,15,16,4,199,252,242,15,17,4,202,255,221,4,199,221,28,202,255,72,252,
-  247,208,137,68,202,4,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,
-  255,36,252,235,255,141,76,202,12,141,68,194,4,189,237,137,105,252,248,248,
-  1,137,41,131,193,8,57,193,15,134,244,1,139,6,15,182,204,15,182,232,131,198,
-  4,193,232,16,252,255,36,252,235,255,139,106,252,248,139,172,253,133,233,139,
-  173,233,72,139,69,0,72,137,4,202,139,6,15,182,204,15,182,232,131,198,4,193,
-  232,16,252,255,36,252,235,255,139,106,252,248,139,172,253,141,233,128,189,
-  233,0,139,173,233,139,12,194,139,68,194,4,137,77,0,137,69,4,15,132,244,247,
-  252,246,133,233,235,15,133,244,248,248,1,139,6,15,182,204,15,182,232,131,
-  198,4,193,232,16,252,255,36,252,235,248,2,129,232,239,129,252,248,239,15,
-  134,244,1,252,246,129,233,235,15,132,244,1,135,213,141,139,233,255,232,251,
-  1,28,137,252,234,252,233,244,1,255,72,252,247,208,139,106,252,248,139,172,
-  253,141,233,139,12,135,139,133,233,137,8,199,64,4,237,252,246,133,233,235,
-  15,133,244,248,248,1,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,
-  255,36,252,235,248,2,252,246,129,233,235,15,132,244,1,128,189,233,0,15,132,
-  244,1,137,213,137,194,141,139,233,232,251,1,28,137,252,234,252,233,244,1,
-  255,139,106,252,248,255,252,242,15,16,4,199,255,139,172,253,141,233,139,141,
-  233,255,252,242,15,17,1,255,221,25,255,72,252,247,208,139,106,252,248,139,
-  172,253,141,233,139,141,233,137,65,4,139,6,15,182,204,15,182,232,131,198,
-  4,193,232,16,252,255,36,252,235,255,141,180,253,134,233,139,108,36,96,131,
-  189,233,0,15,132,244,247,137,149,233,141,20,202,137,252,233,232,251,1,29,
-  139,149,233,248,1,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,
-  36,252,235,255,72,252,247,208,139,108,36,96,137,149,233,68,139,66,252,248,
-  139,20,135,137,252,233,137,116,36,100,232,251,1,30,139,149,233,15,182,78,
-  252,253,137,4,202,199,68,202,4,237,139,6,15,182,204,15,182,232,131,198,4,
-  193,232,16,252,255,36,252,235,255,139,108,36,96,137,149,233,139,139,233,59,
-  139,233,137,116,36,100,15,131,244,251,248,1,65,137,192,37,252,255,7,0,0,65,
-  193,232,11,61,252,255,7,0,0,15,132,244,249,248,2,137,252,233,137,194,232,
-  251,1,31,139,149,233,15,182,78,252,253,137,4,202,199,68,202,4,237,139,6,15,
-  182,204,15,182,232,131,198,4,193,232,16,252,255,36,252,235,248,3,184,1,8,
-  0,0,252,233,244,2,248,5,137,252,233,232,251,1,32,15,183,70,252,254,252,233,
-  244,1,255,72,252,247,208,139,108,36,96,139,139,233,137,116,36,100,59,139,
-  233,137,149,233,15,131,244,249,248,2,139,20,135,137,252,233,232,251,1,33,
+  15,135,244,249,129,124,253,199,4,239,15,130,244,247,255,252,242,15,42,4,199,
+  255,219,4,199,255,252,233,244,248,248,8,255,252,242,15,42,4,202,102,15,46,
+  4,199,255,219,4,202,221,4,199,255,129,252,253,239,15,131,244,249,255,248,
+  1,252,242,15,16,4,199,248,2,102,15,46,4,202,248,4,255,248,1,221,4,199,248,
+  2,221,4,202,248,4,255,72,252,247,208,139,108,202,4,131,198,4,57,197,255,15,
+  133,244,249,15,183,70,252,254,141,180,253,134,233,248,2,139,6,15,182,204,
+  15,182,232,131,198,4,193,232,16,252,255,36,252,235,248,3,129,252,253,239,
+  15,133,244,2,252,233,244,49,255,15,132,244,248,129,252,253,239,15,132,244,
+  49,15,183,70,252,254,141,180,253,134,233,248,2,139,6,15,182,204,15,182,232,
+  131,198,4,193,232,16,252,255,36,252,235,255,139,108,194,4,131,198,4,129,252,
+  253,239,255,137,108,202,4,139,44,194,137,44,202,255,72,139,44,194,72,137,
+  44,202,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,252,235,
+  255,49,252,237,129,124,253,194,4,239,129,213,239,137,108,202,4,139,6,15,182,
+  204,15,182,232,131,198,4,193,232,16,252,255,36,252,235,255,129,124,253,194,
+  4,239,15,133,244,251,139,44,194,252,247,221,15,128,244,250,199,68,202,4,237,
+  137,44,202,248,9,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,
+  36,252,235,248,4,199,68,202,4,0,0,224,65,199,4,202,0,0,0,0,252,233,244,9,
+  248,5,15,135,244,54,255,129,124,253,194,4,239,15,131,244,54,255,252,242,15,
+  16,4,194,72,184,237,237,102,72,15,110,200,15,87,193,252,242,15,17,4,202,255,
+  221,4,194,217,224,221,28,202,255,129,124,253,194,4,239,15,133,244,248,139,
+  4,194,255,139,128,233,248,1,199,68,202,4,237,137,4,202,255,15,87,192,252,
+  242,15,42,128,233,248,1,252,242,15,17,4,202,255,219,128,233,248,1,221,28,
+  202,255,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,252,235,
+  248,2,129,124,253,194,4,239,15,133,244,57,139,12,194,255,139,169,233,131,
+  252,253,0,15,133,244,255,248,3,255,248,58,137,213,232,251,1,20,255,252,242,
+  15,42,192,255,137,252,234,15,182,78,252,253,252,233,244,1,255,248,9,252,246,
+  133,233,235,15,133,244,3,252,233,244,57,255,15,182,252,236,15,182,192,255,
+  129,124,253,252,234,4,239,15,133,244,51,129,124,253,199,4,239,15,133,244,
+  51,139,44,252,234,3,44,199,15,128,244,50,255,129,124,253,252,234,4,239,15,
+  133,244,53,129,124,253,199,4,239,15,133,244,53,139,4,199,3,4,252,234,15,128,
+  244,52,255,129,124,253,252,234,4,239,15,133,244,56,129,124,253,194,4,239,
+  15,133,244,56,139,44,252,234,3,44,194,15,128,244,55,255,199,68,202,4,237,
+  255,129,124,253,252,234,4,239,15,131,244,51,255,129,124,253,199,4,239,15,
+  131,244,51,255,252,242,15,16,4,252,234,252,242,15,88,4,199,255,221,4,252,
+  234,220,4,199,255,129,124,253,252,234,4,239,15,131,244,53,255,129,124,253,
+  199,4,239,15,131,244,53,255,252,242,15,16,4,199,252,242,15,88,4,252,234,255,
+  221,4,199,220,4,252,234,255,129,124,253,252,234,4,239,15,131,244,56,129,124,
+  253,194,4,239,15,131,244,56,255,252,242,15,16,4,252,234,252,242,15,88,4,194,
+  255,221,4,252,234,220,4,194,255,129,124,253,252,234,4,239,15,133,244,51,129,
+  124,253,199,4,239,15,133,244,51,139,44,252,234,43,44,199,15,128,244,50,255,
+  129,124,253,252,234,4,239,15,133,244,53,129,124,253,199,4,239,15,133,244,
+  53,139,4,199,43,4,252,234,15,128,244,52,255,129,124,253,252,234,4,239,15,
+  133,244,56,129,124,253,194,4,239,15,133,244,56,139,44,252,234,43,44,194,15,
+  128,244,55,255,252,242,15,16,4,252,234,252,242,15,92,4,199,255,221,4,252,
+  234,220,36,199,255,252,242,15,16,4,199,252,242,15,92,4,252,234,255,221,4,
+  199,220,36,252,234,255,252,242,15,16,4,252,234,252,242,15,92,4,194,255,221,
+  4,252,234,220,36,194,255,129,124,253,252,234,4,239,15,133,244,51,129,124,
+  253,199,4,239,15,133,244,51,139,44,252,234,15,175,44,199,15,128,244,50,255,
+  129,124,253,252,234,4,239,15,133,244,53,129,124,253,199,4,239,15,133,244,
+  53,139,4,199,15,175,4,252,234,15,128,244,52,255,129,124,253,252,234,4,239,
+  15,133,244,56,129,124,253,194,4,239,15,133,244,56,139,44,252,234,15,175,44,
+  194,15,128,244,55,255,252,242,15,16,4,252,234,252,242,15,89,4,199,255,221,
+  4,252,234,220,12,199,255,252,242,15,16,4,199,252,242,15,89,4,252,234,255,
+  221,4,199,220,12,252,234,255,252,242,15,16,4,252,234,252,242,15,89,4,194,
+  255,221,4,252,234,220,12,194,255,252,242,15,16,4,252,234,252,242,15,94,4,
+  199,255,221,4,252,234,220,52,199,255,252,242,15,16,4,199,252,242,15,94,4,
+  252,234,255,221,4,199,220,52,252,234,255,252,242,15,16,4,252,234,252,242,
+  15,94,4,194,255,221,4,252,234,220,52,194,255,252,242,15,16,4,252,234,252,
+  242,15,16,12,199,255,221,4,252,234,221,4,199,255,252,242,15,16,4,199,252,
+  242,15,16,12,252,234,255,221,4,199,221,4,252,234,255,252,242,15,16,4,252,
+  234,252,242,15,16,12,194,255,221,4,252,234,221,4,194,255,248,168,232,244,
+  157,255,252,233,244,168,255,232,244,117,255,15,182,252,236,15,182,192,139,
+  76,36,96,137,145,233,141,20,194,65,137,192,65,41,232,248,36,137,205,137,116,
+  36,100,232,251,1,29,139,149,233,133,192,15,133,244,45,15,182,110,252,255,
+  15,182,78,252,253,72,139,4,252,234,72,137,4,202,139,6,15,182,204,15,182,232,
+  131,198,4,193,232,16,252,255,36,252,235,255,72,252,247,208,139,4,135,199,
+  68,202,4,237,137,4,202,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,
+  255,36,252,235,255,15,191,192,199,68,202,4,237,137,4,202,255,15,191,192,252,
+  242,15,42,192,252,242,15,17,4,202,255,223,70,252,254,221,28,202,255,252,242,
+  15,16,4,199,252,242,15,17,4,202,255,221,4,199,221,28,202,255,72,252,247,208,
+  137,68,202,4,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,
+  252,235,255,141,76,202,12,141,68,194,4,189,237,137,105,252,248,248,1,137,
+  41,131,193,8,57,193,15,134,244,1,139,6,15,182,204,15,182,232,131,198,4,193,
+  232,16,252,255,36,252,235,255,139,106,252,248,139,172,253,133,233,139,173,
+  233,72,139,69,0,72,137,4,202,139,6,15,182,204,15,182,232,131,198,4,193,232,
+  16,252,255,36,252,235,255,139,106,252,248,139,172,253,141,233,128,189,233,
+  0,139,173,233,139,12,194,139,68,194,4,137,77,0,137,69,4,15,132,244,247,252,
+  246,133,233,235,15,133,244,248,248,1,139,6,15,182,204,15,182,232,131,198,
+  4,193,232,16,252,255,36,252,235,248,2,129,232,239,129,252,248,239,15,134,
+  244,1,252,246,129,233,235,15,132,244,1,135,213,141,139,233,255,232,251,1,
+  30,137,252,234,252,233,244,1,255,72,252,247,208,139,106,252,248,139,172,253,
+  141,233,139,12,135,139,133,233,137,8,199,64,4,237,252,246,133,233,235,15,
+  133,244,248,248,1,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,
+  36,252,235,248,2,252,246,129,233,235,15,132,244,1,128,189,233,0,15,132,244,
+  1,137,213,137,194,141,139,233,232,251,1,30,137,252,234,252,233,244,1,255,
+  139,106,252,248,255,252,242,15,16,4,199,255,139,172,253,141,233,139,141,233,
+  255,252,242,15,17,1,255,221,25,255,72,252,247,208,139,106,252,248,139,172,
+  253,141,233,139,141,233,137,65,4,139,6,15,182,204,15,182,232,131,198,4,193,
+  232,16,252,255,36,252,235,255,141,180,253,134,233,139,108,36,96,131,189,233,
+  0,15,132,244,247,137,149,233,141,20,202,137,252,233,232,251,1,31,139,149,
+  233,248,1,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,252,
+  235,255,72,252,247,208,139,108,36,96,137,149,233,68,139,66,252,248,139,20,
+  135,137,252,233,137,116,36,100,232,251,1,32,139,149,233,15,182,78,252,253,
+  137,4,202,199,68,202,4,237,139,6,15,182,204,15,182,232,131,198,4,193,232,
+  16,252,255,36,252,235,255,139,108,36,96,137,149,233,139,139,233,59,139,233,
+  137,116,36,100,15,131,244,251,248,1,65,137,192,37,252,255,7,0,0,65,193,232,
+  11,61,252,255,7,0,0,15,132,244,249,248,2,137,252,233,137,194,232,251,1,33,
   139,149,233,15,182,78,252,253,137,4,202,199,68,202,4,237,139,6,15,182,204,
-  15,182,232,131,198,4,193,232,16,252,255,36,252,235,248,3,137,252,233,232,
-  251,1,32,15,183,70,252,254,72,252,247,208,252,233,244,2,255,72,252,247,208,
-  139,106,252,248,139,173,233,139,4,135,252,233,244,167,255,72,252,247,208,
-  139,106,252,248,139,173,233,139,4,135,252,233,244,168,255,15,182,252,236,
-  15,182,192,129,124,253,252,234,4,239,15,133,244,38,139,44,252,234,255,129,
-  124,253,194,4,239,15,133,244,251,139,4,194,255,129,124,253,194,4,239,15,131,
-  244,251,255,252,242,15,16,4,194,252,242,15,45,192,252,242,15,42,200,102,15,
-  46,193,255,15,133,244,38,255,59,133,233,15,131,244,38,193,224,3,3,133,233,
-  129,120,253,4,239,15,132,244,248,72,139,40,72,137,44,202,248,1,139,6,15,182,
-  204,15,182,232,131,198,4,193,232,16,252,255,36,252,235,248,2,131,189,233,
-  0,15,132,244,249,139,141,233,252,246,129,233,235,15,132,244,38,15,182,78,
-  252,253,248,3,199,68,202,4,237,252,233,244,1,248,5,255,129,124,253,194,4,
-  239,15,133,244,38,139,4,194,252,233,244,167,255,15,182,252,236,15,182,192,
-  72,252,247,208,139,4,135,129,124,253,252,234,4,239,15,133,244,36,139,44,252,
-  234,248,167,139,141,233,35,136,233,105,201,239,3,141,233,248,1,129,185,233,
-  239,15,133,244,250,57,129,233,15,133,244,250,129,121,253,4,239,15,132,244,
-  251,15,182,70,252,253,72,139,41,72,137,44,194,248,2,255,139,6,15,182,204,
-  15,182,232,131,198,4,193,232,16,252,255,36,252,235,248,3,15,182,70,252,253,
-  199,68,194,4,237,252,233,244,2,248,4,139,137,233,133,201,15,133,244,1,248,
-  5,139,141,233,133,201,15,132,244,3,252,246,129,233,235,15,133,244,3,252,233,
-  244,36,255,15,182,252,236,15,182,192,129,124,253,252,234,4,239,15,133,244,
-  37,139,44,252,234,59,133,233,15,131,244,37,193,224,3,3,133,233,129,120,253,
+  15,182,232,131,198,4,193,232,16,252,255,36,252,235,248,3,184,1,8,0,0,252,
+  233,244,2,248,5,137,252,233,232,251,1,34,15,183,70,252,254,252,233,244,1,
+  255,72,252,247,208,139,108,36,96,139,139,233,137,116,36,100,59,139,233,137,
+  149,233,15,131,244,249,248,2,139,20,135,137,252,233,232,251,1,35,139,149,
+  233,15,182,78,252,253,137,4,202,199,68,202,4,237,139,6,15,182,204,15,182,
+  232,131,198,4,193,232,16,252,255,36,252,235,248,3,137,252,233,232,251,1,34,
+  15,183,70,252,254,72,252,247,208,252,233,244,2,255,72,252,247,208,139,106,
+  252,248,139,173,233,139,4,135,252,233,244,169,255,72,252,247,208,139,106,
+  252,248,139,173,233,139,4,135,252,233,244,170,255,15,182,252,236,15,182,192,
+  129,124,253,252,234,4,239,15,133,244,39,139,44,252,234,255,129,124,253,194,
+  4,239,15,133,244,251,139,4,194,255,129,124,253,194,4,239,15,131,244,251,255,
+  252,242,15,16,4,194,252,242,15,45,192,252,242,15,42,200,102,15,46,193,255,
+  15,133,244,39,255,59,133,233,15,131,244,39,193,224,3,3,133,233,129,120,253,
   4,239,15,132,244,248,72,139,40,72,137,44,202,248,1,139,6,15,182,204,15,182,
   232,131,198,4,193,232,16,252,255,36,252,235,248,2,131,189,233,0,15,132,244,
-  249,139,141,233,252,246,129,233,235,15,132,244,37,255,15,182,78,252,253,248,
-  3,199,68,202,4,237,252,233,244,1,255,15,182,252,236,15,182,192,129,124,253,
-  252,234,4,239,15,133,244,41,139,44,252,234,255,15,133,244,41,255,59,133,233,
-  15,131,244,41,193,224,3,3,133,233,129,120,253,4,239,15,132,244,249,248,1,
+  249,139,141,233,252,246,129,233,235,15,132,244,39,15,182,78,252,253,248,3,
+  199,68,202,4,237,252,233,244,1,248,5,255,129,124,253,194,4,239,15,133,244,
+  39,139,4,194,252,233,244,169,255,15,182,252,236,15,182,192,72,252,247,208,
+  139,4,135,129,124,253,252,234,4,239,15,133,244,37,139,44,252,234,248,169,
+  139,141,233,35,136,233,105,201,239,3,141,233,248,1,129,185,233,239,15,133,
+  244,250,57,129,233,15,133,244,250,129,121,253,4,239,15,132,244,251,15,182,
+  70,252,253,72,139,41,72,137,44,194,248,2,255,139,6,15,182,204,15,182,232,
+  131,198,4,193,232,16,252,255,36,252,235,248,3,15,182,70,252,253,199,68,194,
+  4,237,252,233,244,2,248,4,139,137,233,133,201,15,133,244,1,248,5,139,141,
+  233,133,201,15,132,244,3,252,246,129,233,235,15,133,244,3,252,233,244,37,
+  255,15,182,252,236,15,182,192,129,124,253,252,234,4,239,15,133,244,38,139,
+  44,252,234,59,133,233,15,131,244,38,193,224,3,3,133,233,129,120,253,4,239,
+  15,132,244,248,72,139,40,72,137,44,202,248,1,139,6,15,182,204,15,182,232,
+  131,198,4,193,232,16,252,255,36,252,235,248,2,131,189,233,0,15,132,244,249,
+  139,141,233,252,246,129,233,235,15,132,244,38,255,15,182,78,252,253,248,3,
+  199,68,202,4,237,252,233,244,1,255,15,182,252,236,15,182,192,129,124,253,
+  252,234,4,239,15,133,244,42,139,44,252,234,255,15,133,244,42,255,59,133,233,
+  15,131,244,42,193,224,3,3,133,233,129,120,253,4,239,15,132,244,249,248,1,
   252,246,133,233,235,15,133,244,253,248,2,72,139,44,202,72,137,40,139,6,15,
   182,204,15,182,232,131,198,4,193,232,16,252,255,36,252,235,248,3,131,189,
-  233,0,15,132,244,1,139,141,233,252,246,129,233,235,255,15,132,244,41,15,182,
-  78,252,253,252,233,244,1,248,5,129,124,253,194,4,239,15,133,244,41,139,4,
-  194,252,233,244,168,248,7,128,165,233,235,139,139,233,137,171,233,137,141,
+  233,0,15,132,244,1,139,141,233,252,246,129,233,235,255,15,132,244,42,15,182,
+  78,252,253,252,233,244,1,248,5,129,124,253,194,4,239,15,133,244,42,139,4,
+  194,252,233,244,170,248,7,128,165,233,235,139,139,233,137,171,233,137,141,
   233,15,182,78,252,253,252,233,244,2,255,15,182,252,236,15,182,192,72,252,
-  247,208,139,4,135,129,124,253,252,234,4,239,15,133,244,39,139,44,252,234,
-  248,168,139,141,233,35,136,233,105,201,239,198,133,233,0,3,141,233,248,1,
+  247,208,139,4,135,129,124,253,252,234,4,239,15,133,244,40,139,44,252,234,
+  248,170,139,141,233,35,136,233,105,201,239,198,133,233,0,3,141,233,248,1,
   129,185,233,239,15,133,244,251,57,129,233,15,133,244,251,129,121,253,4,239,
   15,132,244,250,248,2,255,252,246,133,233,235,15,133,244,253,248,3,15,182,
   70,252,253,72,139,44,194,72,137,41,139,6,15,182,204,15,182,232,131,198,4,
   193,232,16,252,255,36,252,235,248,4,131,189,233,0,15,132,244,2,137,76,36,
-  80,139,141,233,252,246,129,233,235,15,132,244,39,139,76,36,80,252,233,244,
+  80,139,141,233,252,246,129,233,235,15,132,244,40,139,76,36,80,252,233,244,
   2,248,5,139,137,233,133,201,15,133,244,1,255,139,141,233,133,201,15,132,244,
-  252,252,246,129,233,235,15,132,244,39,248,6,137,68,36,80,199,68,36,84,237,
+  252,252,246,129,233,235,15,132,244,40,248,6,137,68,36,80,199,68,36,84,237,
   137,108,36,32,139,76,36,96,137,145,233,76,141,68,36,80,137,252,234,137,205,
-  137,116,36,100,232,251,1,34,139,149,233,139,108,36,32,137,193,252,233,244,
+  137,116,36,100,232,251,1,36,139,149,233,139,108,36,32,137,193,252,233,244,
   2,248,7,128,165,233,235,139,131,233,137,171,233,137,133,233,252,233,244,3,
-  255,15,182,252,236,15,182,192,129,124,253,252,234,4,239,15,133,244,40,139,
-  44,252,234,59,133,233,15,131,244,40,193,224,3,3,133,233,129,120,253,4,239,
+  255,15,182,252,236,15,182,192,129,124,253,252,234,4,239,15,133,244,41,139,
+  44,252,234,59,133,233,15,131,244,41,193,224,3,3,133,233,129,120,253,4,239,
   15,132,244,249,248,1,252,246,133,233,235,15,133,244,253,248,2,72,139,12,202,
   72,137,8,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,252,
   235,248,3,131,189,233,0,15,132,244,1,255,139,141,233,252,246,129,233,235,
-  15,132,244,40,15,182,78,252,253,252,233,244,1,248,7,128,165,233,235,139,139,
+  15,132,244,41,15,182,78,252,253,252,233,244,1,248,7,128,165,233,235,139,139,
   233,137,171,233,137,141,233,15,182,78,252,253,252,233,244,2,255,137,124,36,
   80,139,60,199,248,1,141,12,202,139,105,252,248,252,246,133,233,235,15,133,
   244,253,248,2,139,68,36,84,131,232,1,15,132,244,250,1,252,248,59,133,233,
   15,135,244,251,41,252,248,193,231,3,3,189,233,248,3,72,139,41,131,193,8,72,
   137,47,131,199,8,131,232,1,15,133,244,3,248,4,139,124,36,80,139,6,15,182,
   204,15,182,232,131,198,4,193,232,16,252,255,36,252,235,248,5,139,76,36,96,
-  137,145,233,137,252,234,65,137,192,137,205,137,116,36,100,232,251,1,35,139,
+  137,145,233,137,252,234,65,137,192,137,205,137,116,36,100,232,251,1,37,139,
   149,233,15,182,78,252,253,252,233,244,1,248,7,255,128,165,233,235,139,131,
   233,137,171,233,137,133,233,252,233,244,2,255,3,68,36,84,255,129,124,253,
-  202,4,239,139,44,202,15,133,244,58,141,84,202,8,137,114,252,252,139,181,233,
+  202,4,239,139,44,202,15,133,244,59,141,84,202,8,137,114,252,252,139,181,233,
   139,14,15,182,252,233,15,182,205,131,198,4,252,255,36,252,235,255,141,76,
-  202,8,137,215,139,105,252,248,129,121,253,252,252,239,15,133,244,29,248,59,
+  202,8,137,215,139,105,252,248,129,121,253,252,252,239,15,133,244,29,248,60,
   139,114,252,252,252,247,198,237,15,133,244,253,248,1,137,106,252,248,137,
   68,36,84,131,232,1,15,132,244,249,248,2,72,139,41,131,193,8,72,137,47,131,
   199,8,131,232,1,15,133,244,2,139,106,252,248,248,3,139,68,36,84,128,189,233,
@@ -746,9 +755,9 @@ static const unsigned char build_actionlist[16011] = {
   36,252,235,248,6,255,199,71,252,252,237,131,199,8,255,199,68,194,252,244,
   237,255,131,192,1,252,233,244,5,248,7,141,174,233,252,247,197,237,15,133,
   244,14,41,252,234,255,1,252,233,255,137,252,245,209,252,237,129,229,239,102,
-  131,172,253,43,233,1,15,132,244,148,255,141,12,202,255,129,121,253,4,239,
-  15,133,244,255,255,129,121,253,12,239,15,133,244,60,129,121,253,20,239,15,
-  133,244,60,139,41,131,121,16,0,15,140,244,251,255,129,121,253,12,239,15,133,
+  129,172,253,43,233,238,15,130,244,149,255,141,12,202,255,129,121,253,4,239,
+  15,133,244,255,255,129,121,253,12,239,15,133,244,61,129,121,253,20,239,15,
+  133,244,61,139,41,131,121,16,0,15,140,244,251,255,129,121,253,12,239,15,133,
   244,165,129,121,253,20,239,15,133,244,165,255,139,105,16,133,252,237,15,136,
   244,251,3,41,15,128,244,247,137,41,255,59,105,8,199,65,28,237,137,105,24,
   255,15,142,244,253,248,1,248,6,141,180,253,134,233,255,141,180,253,134,233,
@@ -756,9 +765,9 @@ static const unsigned char build_actionlist[16011] = {
   253,134,233,248,1,255,248,7,139,6,15,182,204,15,182,232,131,198,4,193,232,
   16,252,255,36,252,235,248,5,255,3,41,15,128,244,1,137,41,255,15,141,244,7,
   255,141,180,253,134,233,15,183,70,252,254,15,141,245,255,15,140,244,7,255,
-  252,233,244,6,248,9,255,129,121,253,4,239,255,15,131,244,60,129,121,253,12,
-  239,15,131,244,60,255,129,121,253,12,239,15,131,244,165,129,121,253,20,239,
-  15,131,244,165,255,139,105,20,255,129,252,253,239,15,131,244,60,255,252,242,
+  252,233,244,6,248,9,255,129,121,253,4,239,255,15,131,244,61,129,121,253,12,
+  239,15,131,244,61,255,129,121,253,12,239,15,131,244,165,129,121,253,20,239,
+  15,131,244,165,255,139,105,20,255,129,252,253,239,15,131,244,61,255,252,242,
   15,16,1,252,242,15,16,73,8,255,252,242,15,88,65,16,252,242,15,17,1,133,252,
   237,15,136,244,249,255,15,140,244,249,255,102,15,46,200,248,1,252,242,15,
   17,65,24,255,221,65,8,221,1,255,220,65,16,221,17,221,81,24,133,252,237,15,
@@ -775,21 +784,21 @@ static const unsigned char build_actionlist[16011] = {
   15,127,153,233,102,68,15,127,161,233,102,68,15,127,169,233,102,68,15,127,
   177,233,102,68,15,127,185,233,252,255,224,255,141,180,253,134,233,139,6,15,
   182,204,15,182,232,131,198,4,193,232,16,252,255,36,252,235,255,137,252,245,
-  209,252,237,129,229,239,102,131,172,253,43,233,1,15,132,244,150,255,139,190,
-  233,139,108,36,96,141,12,202,59,141,233,15,135,244,24,15,182,142,233,57,200,
-  15,134,244,249,248,2,255,15,183,70,252,254,252,233,245,255,248,3,199,68,194,
-  252,252,237,131,192,1,57,200,15,134,244,3,252,233,244,2,255,141,44,197,237,
-  141,4,194,139,122,252,248,137,104,252,252,137,120,252,248,139,108,36,96,141,
-  12,200,59,141,233,15,135,244,23,137,209,137,194,15,182,174,233,133,252,237,
-  15,132,244,248,248,1,131,193,8,57,209,15,131,244,249,139,121,252,248,137,
-  56,139,121,252,252,137,120,4,131,192,8,199,65,252,252,237,131,252,237,1,15,
-  133,244,1,248,2,255,139,190,233,139,6,15,182,204,15,182,232,131,198,4,193,
-  232,16,252,255,36,252,235,255,248,3,199,64,4,237,131,192,8,131,252,237,1,
-  15,133,244,3,252,233,244,2,255,139,106,252,248,72,139,189,233,139,108,36,
-  96,141,68,194,252,248,137,149,233,141,136,233,59,141,233,137,133,233,255,
-  72,137,252,250,137,252,233,255,15,135,244,22,199,131,233,237,255,252,255,
-  215,255,252,255,147,233,255,199,131,233,237,139,149,233,141,12,194,252,247,
-  217,3,141,233,139,114,252,252,252,233,244,12,255,254,0
+  209,252,237,129,229,239,102,129,172,253,43,233,238,15,130,244,151,255,139,
+  190,233,139,108,36,96,141,12,202,59,141,233,15,135,244,24,15,182,142,233,
+  57,200,15,134,244,249,248,2,255,15,183,70,252,254,252,233,245,255,248,3,199,
+  68,194,252,252,237,131,192,1,57,200,15,134,244,3,252,233,244,2,255,141,44,
+  197,237,141,4,194,139,122,252,248,137,104,252,252,137,120,252,248,139,108,
+  36,96,141,12,200,59,141,233,15,135,244,23,137,209,137,194,15,182,174,233,
+  133,252,237,15,132,244,248,248,1,131,193,8,57,209,15,131,244,249,139,121,
+  252,248,137,56,139,121,252,252,137,120,4,131,192,8,199,65,252,252,237,131,
+  252,237,1,15,133,244,1,248,2,255,139,190,233,139,6,15,182,204,15,182,232,
+  131,198,4,193,232,16,252,255,36,252,235,255,248,3,199,64,4,237,131,192,8,
+  131,252,237,1,15,133,244,3,252,233,244,2,255,139,106,252,248,72,139,189,233,
+  139,108,36,96,141,68,194,252,248,137,149,233,141,136,233,59,141,233,137,133,
+  233,255,72,137,252,250,137,252,233,255,15,135,244,22,199,131,233,237,255,
+  252,255,215,255,252,255,147,233,255,199,131,233,237,139,149,233,141,12,194,
+  252,247,217,3,141,233,139,114,252,252,252,233,244,12,255,254,0
 };
 
 enum {
@@ -815,6 +824,7 @@ enum {
   GLOB_vmeta_call,
   GLOB_vm_call_dispatch_f,
   GLOB_vm_cpcall,
+  GLOB_cont_ffi_callback,
   GLOB_vm_call_tail,
   GLOB_cont_cat,
   GLOB_cont_ra,
@@ -947,8 +957,9 @@ enum {
   GLOB_vm_foldfpm,
   GLOB_vm_foldarith,
   GLOB_vm_cpuid,
-  GLOB_vm_ffi_call,
   GLOB_assert_bad_for_arg_type,
+  GLOB_vm_ffi_callback,
+  GLOB_vm_ffi_call,
   GLOB_BC_MODVN_Z,
   GLOB_BC_TGETS_Z,
   GLOB_BC_TSETS_Z,
@@ -977,6 +988,7 @@ static const char *const globnames[] = {
   "vmeta_call",
   "vm_call_dispatch_f",
   "vm_cpcall",
+  "cont_ffi_callback",
   "vm_call_tail",
   "cont_cat",
   "cont_ra",
@@ -1109,8 +1121,9 @@ static const char *const globnames[] = {
   "vm_foldfpm",
   "vm_foldarith",
   "vm_cpuid",
-  "vm_ffi_call@4",
   "assert_bad_for_arg_type",
+  "vm_ffi_callback",
+  "vm_ffi_call@4",
   "BC_MODVN_Z",
   "BC_TGETS_Z",
   "BC_TSETS_Z",
@@ -1144,6 +1157,8 @@ static const char *const extnames[] = {
   "lj_dispatch_call@8",
   "lj_trace_exit@8",
   "lj_err_throw@8",
+  "lj_ccallback_enter@8",
+  "lj_ccallback_leave@8",
   "lj_meta_cat",
   "lj_gc_barrieruv@8",
   "lj_func_closeuv@8",
@@ -1184,677 +1199,694 @@ static void build_subroutines(BuildCtx *ctx, int cmov, int sse)
   dasm_put(Dst, 356, Dt1(->top), Dt1(->base), Dt1(->top), Dt7(->pc), FRAME_CP, CFRAME_RESUME, Dt1(->glref), GG_G2DISP, Dt1(->cframe), Dt1(->status), DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->status), Dt1(->base), Dt1(->top), FRAME_TYPE);
   dasm_put(Dst, 511, FRAME_CP, FRAME_C, Dt1(->cframe), Dt1(->cframe), Dt1(->glref), GG_G2DISP, DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base));
   dasm_put(Dst, 604, Dt1(->top), LJ_TFUNC, Dt7(->pc), Dt1(->stack), Dt1(->top), Dt1(->cframe), Dt1(->cframe), FRAME_CP, LJ_TNIL);
-  dasm_put(Dst, 770, 0, Dt7(->pc), PC2PROTO(k), Dt1(->base), LJ_TSTR, BC_GGET, DISPATCH_GL(tmptv), LJ_TTAB);
-  dasm_put(Dst, 894);
+#if LJ_HASFFI
+  dasm_put(Dst, 764);
+#endif
+  dasm_put(Dst, 773, 0);
+#if LJ_HASFFI
+#endif
+  dasm_put(Dst, 782, Dt7(->pc), PC2PROTO(k));
+#if LJ_HASFFI
+  dasm_put(Dst, 796);
+#endif
+  dasm_put(Dst, 817, Dt1(->base), LJ_TSTR, BC_GGET, DISPATCH_GL(tmptv), LJ_TTAB);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 908, LJ_TISNUM);
+    dasm_put(Dst, 917, LJ_TISNUM);
   } else if (sse) {
-    dasm_put(Dst, 918);
+    dasm_put(Dst, 927);
   } else {
   }
-  dasm_put(Dst, 931, Dt1(->base), Dt1(->base), Dt1(->top), FRAME_CONT, 2+1, LJ_TSTR, BC_GSET);
-  dasm_put(Dst, 1078, DISPATCH_GL(tmptv), LJ_TTAB);
+  dasm_put(Dst, 940, Dt1(->base), Dt1(->base), Dt1(->top), FRAME_CONT, 2+1, LJ_TSTR, BC_GSET);
+  dasm_put(Dst, 1087, DISPATCH_GL(tmptv), LJ_TTAB);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 908, LJ_TISNUM);
+    dasm_put(Dst, 917, LJ_TISNUM);
   } else if (sse) {
-    dasm_put(Dst, 918);
+    dasm_put(Dst, 927);
   } else {
   }
-  dasm_put(Dst, 1101, Dt1(->base), Dt1(->base), Dt1(->top), FRAME_CONT, 3+1, Dt1(->base), Dt1(->base));
-  dasm_put(Dst, 1274, -BCBIAS_J*4, LJ_TISTRUECOND, LJ_TISTRUECOND, Dt1(->base));
-  dasm_put(Dst, 1374);
+  dasm_put(Dst, 1110, Dt1(->base), Dt1(->base), Dt1(->top), FRAME_CONT, 3+1, Dt1(->base), Dt1(->base));
+  dasm_put(Dst, 1283, -BCBIAS_J*4, LJ_TISTRUECOND, LJ_TISTRUECOND, Dt1(->base));
+  dasm_put(Dst, 1383);
 #if LJ_HASFFI
-  dasm_put(Dst, 1394, Dt1(->base));
+  dasm_put(Dst, 1403, Dt1(->base));
 #endif
-  dasm_put(Dst, 1425);
+  dasm_put(Dst, 1434);
 #if LJ_DUALNUM
-  dasm_put(Dst, 1428);
+  dasm_put(Dst, 1437);
 #endif
-  dasm_put(Dst, 1434);
+  dasm_put(Dst, 1443);
 #if LJ_DUALNUM
-  dasm_put(Dst, 902);
+  dasm_put(Dst, 911);
 #endif
-  dasm_put(Dst, 1446);
+  dasm_put(Dst, 1455);
 #if LJ_DUALNUM
-  dasm_put(Dst, 1428);
+  dasm_put(Dst, 1437);
 #endif
-  dasm_put(Dst, 1474, Dt1(->base), Dt1(->base), FRAME_CONT, 2+1, Dt1(->base), Dt1(->base));
+  dasm_put(Dst, 1483, Dt1(->base), Dt1(->base), FRAME_CONT, 2+1, Dt1(->base), Dt1(->base));
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-  dasm_put(Dst, 1580);
+  dasm_put(Dst, 1589);
 #else
-  dasm_put(Dst, 1599);
+  dasm_put(Dst, 1608);
 #endif
-  dasm_put(Dst, 1604, Dt1(->base), Dt1(->base), Dt7(->pc), Dt1(->base), Dt1(->base), GG_DISP2STATIC, 1+1, LJ_TISTRUECOND);
-  dasm_put(Dst, 1790, 1+1, ~LJ_TNUMX);
+  dasm_put(Dst, 1613, Dt1(->base), Dt1(->base), Dt7(->pc), Dt1(->base), Dt1(->base), GG_DISP2STATIC, 1+1, LJ_TISTRUECOND);
+  dasm_put(Dst, 1799, 1+1, ~LJ_TNUMX);
   if (cmov) {
-  dasm_put(Dst, 1859);
+  dasm_put(Dst, 1868);
   } else {
-  dasm_put(Dst, 1863);
+  dasm_put(Dst, 1872);
   }
-  dasm_put(Dst, 1872, ((char *)(&((GCfuncC *)0)->upvalue)), LJ_TSTR, ~LJ_TLIGHTUD, 1+1, LJ_TTAB, Dt6(->metatable), LJ_TNIL);
-  dasm_put(Dst, 1951, DISPATCH_GL(gcroot)+4*(GCROOT_MMNAME+MM_metatable), LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), DtB(->next));
-  dasm_put(Dst, 2008, LJ_TNIL, LJ_TUDATA, LJ_TNUMX, LJ_TISNUM, LJ_TLIGHTUD);
-  dasm_put(Dst, 2074, LJ_TNUMX, DISPATCH_GL(gcroot[GCROOT_BASEMT]), 2+1, LJ_TTAB, Dt6(->metatable), LJ_TTAB, Dt6(->metatable), LJ_TTAB);
-  dasm_put(Dst, 2144, Dt6(->marked), LJ_GC_BLACK, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist), 2+1, LJ_TTAB);
-  dasm_put(Dst, 2233, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 1881, ((char *)(&((GCfuncC *)0)->upvalue)), LJ_TSTR, ~LJ_TLIGHTUD, 1+1, LJ_TTAB, Dt6(->metatable), LJ_TNIL);
+  dasm_put(Dst, 1960, DISPATCH_GL(gcroot)+4*(GCROOT_MMNAME+MM_metatable), LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), DtB(->next));
+  dasm_put(Dst, 2017, LJ_TNIL, LJ_TUDATA, LJ_TNUMX, LJ_TISNUM, LJ_TLIGHTUD);
+  dasm_put(Dst, 2083, LJ_TNUMX, DISPATCH_GL(gcroot[GCROOT_BASEMT]), 2+1, LJ_TTAB, Dt6(->metatable), LJ_TTAB, Dt6(->metatable), LJ_TTAB);
+  dasm_put(Dst, 2153, Dt6(->marked), LJ_GC_BLACK, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist), 2+1, LJ_TTAB);
+  dasm_put(Dst, 2242, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 2247);
+    dasm_put(Dst, 2256);
   } else {
-    dasm_put(Dst, 2264);
+    dasm_put(Dst, 2273);
   }
   if (sse) {
-    dasm_put(Dst, 2269);
+    dasm_put(Dst, 2278);
   } else {
-    dasm_put(Dst, 2279);
+    dasm_put(Dst, 2288);
   }
-  dasm_put(Dst, 2286, 1+1, LJ_TSTR, LJ_TSTR, LJ_TISNUM, DISPATCH_GL(gcroot[GCROOT_BASEMT_NUM]), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
-  dasm_put(Dst, 2352, Dt1(->base));
+  dasm_put(Dst, 2295, 1+1, LJ_TSTR, LJ_TSTR, LJ_TISNUM, DISPATCH_GL(gcroot[GCROOT_BASEMT_NUM]), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
+  dasm_put(Dst, 2361, Dt1(->base));
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 2376);
+    dasm_put(Dst, 2385);
   } else {
-    dasm_put(Dst, 2381);
+    dasm_put(Dst, 2390);
   }
-  dasm_put(Dst, 2386, Dt1(->base), 1+1, LJ_TTAB, Dt1(->base), Dt1(->top), Dt1(->base), 1+2);
-  dasm_put(Dst, 2479, LJ_TNIL, LJ_TNIL, 1+1, LJ_TTAB);
+  dasm_put(Dst, 2395, Dt1(->base), 1+1, LJ_TTAB, Dt1(->base), Dt1(->top), Dt1(->base), 1+2);
+  dasm_put(Dst, 2488, LJ_TNIL, LJ_TNIL, 1+1, LJ_TTAB);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-  dasm_put(Dst, 2526, Dt6(->metatable));
+  dasm_put(Dst, 2535, Dt6(->metatable));
 #endif
-  dasm_put(Dst, 2535, Dt8(->upvalue[0]), LJ_TFUNC, LJ_TNIL, 1+3, 1+1, LJ_TTAB, LJ_TISNUM);
+  dasm_put(Dst, 2544, Dt8(->upvalue[0]), LJ_TFUNC, LJ_TNIL, 1+3, 1+1, LJ_TTAB, LJ_TISNUM);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 2521);
+    dasm_put(Dst, 2530);
   } else {
-    dasm_put(Dst, 2264);
+    dasm_put(Dst, 2273);
   }
-  dasm_put(Dst, 2590);
+  dasm_put(Dst, 2599);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 2595, LJ_TISNUM);
+    dasm_put(Dst, 2604, LJ_TISNUM);
   } else if (sse) {
-    dasm_put(Dst, 2611, (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
+    dasm_put(Dst, 2620, (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 2644, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->hmask), 1+0);
-  dasm_put(Dst, 2506, 1+1, LJ_TTAB);
+  dasm_put(Dst, 2653, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->hmask), 1+0);
+  dasm_put(Dst, 2515, 1+1, LJ_TTAB);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-  dasm_put(Dst, 2526, Dt6(->metatable));
+  dasm_put(Dst, 2535, Dt6(->metatable));
 #endif
-  dasm_put(Dst, 2721, Dt8(->upvalue[0]), LJ_TFUNC);
+  dasm_put(Dst, 2730, Dt8(->upvalue[0]), LJ_TFUNC);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 2742, LJ_TISNUM);
+    dasm_put(Dst, 2751, LJ_TISNUM);
   } else if (sse) {
-    dasm_put(Dst, 2754);
-  } else {
-    dasm_put(Dst, 2764);
-  }
-  dasm_put(Dst, 2771, 1+3, 1+1, 8+FRAME_PCALL, DISPATCH_GL(hookmask), HOOK_ACTIVE_SHIFT, 2+1, LJ_TFUNC);
-  dasm_put(Dst, 2835, LJ_TFUNC, 16+FRAME_PCALL, 1+1, LJ_TTHREAD, Dt1(->cframe), Dt1(->status), LUA_YIELD, Dt1(->top));
-  dasm_put(Dst, 2925, Dt1(->base), Dt1(->maxstack), Dt1(->top), Dt1(->base), Dt1(->top), DISPATCH_GL(vmstate), ~LJ_VMST_INTERP);
-  dasm_put(Dst, 3013, Dt1(->base), LUA_YIELD, Dt1(->base), Dt1(->top), Dt1(->top), Dt1(->maxstack), LJ_TTRUE, FRAME_TYPE);
-  dasm_put(Dst, 3126, LJ_TFALSE, Dt1(->top), Dt1(->top), 1+2, Dt1(->top), Dt1(->base), Dt8(->upvalue[0].gcr), Dt1(->cframe));
-  dasm_put(Dst, 3224, Dt1(->status), LUA_YIELD, Dt1(->top), Dt1(->base), Dt1(->maxstack), Dt1(->top), Dt1(->base), Dt1(->top));
-  dasm_put(Dst, 3291, DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base), LUA_YIELD, Dt1(->base), Dt1(->top), Dt1(->top), Dt1(->maxstack));
-  dasm_put(Dst, 3379, FRAME_TYPE, Dt1(->top), Dt1(->base), Dt1(->cframe), CFRAME_RESUME);
-  dasm_put(Dst, 3491, Dt1(->base), Dt1(->top), Dt1(->cframe), LUA_YIELD, Dt1(->status));
+    dasm_put(Dst, 2763);
+  } else {
+    dasm_put(Dst, 2773);
+  }
+  dasm_put(Dst, 2780, 1+3, 1+1, 8+FRAME_PCALL, DISPATCH_GL(hookmask), HOOK_ACTIVE_SHIFT, 2+1, LJ_TFUNC);
+  dasm_put(Dst, 2844, LJ_TFUNC, 16+FRAME_PCALL, 1+1, LJ_TTHREAD, Dt1(->cframe), Dt1(->status), LUA_YIELD, Dt1(->top));
+  dasm_put(Dst, 2934, Dt1(->base), Dt1(->maxstack), Dt1(->top), Dt1(->base), Dt1(->top), DISPATCH_GL(vmstate), ~LJ_VMST_INTERP);
+  dasm_put(Dst, 3022, Dt1(->base), LUA_YIELD, Dt1(->base), Dt1(->top), Dt1(->top), Dt1(->maxstack), LJ_TTRUE, FRAME_TYPE);
+  dasm_put(Dst, 3135, LJ_TFALSE, Dt1(->top), Dt1(->top), 1+2, Dt1(->top), Dt1(->base), Dt8(->upvalue[0].gcr), Dt1(->cframe));
+  dasm_put(Dst, 3233, Dt1(->status), LUA_YIELD, Dt1(->top), Dt1(->base), Dt1(->maxstack), Dt1(->top), Dt1(->base), Dt1(->top));
+  dasm_put(Dst, 3300, DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base), LUA_YIELD, Dt1(->base), Dt1(->top), Dt1(->top), Dt1(->maxstack));
+  dasm_put(Dst, 3388, FRAME_TYPE, Dt1(->top), Dt1(->base), Dt1(->cframe), CFRAME_RESUME);
+  dasm_put(Dst, 3500, Dt1(->base), Dt1(->top), Dt1(->cframe), LUA_YIELD, Dt1(->status));
   if (!LJ_DUALNUM) {
-    dasm_put(Dst, 3518);
+    dasm_put(Dst, 3527);
   }
   if (sse) {
-    dasm_put(Dst, 3521);
+    dasm_put(Dst, 3530);
   }
-  dasm_put(Dst, 3536, 1+1);
+  dasm_put(Dst, 3545, 1+1);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 3547, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 3556, LJ_TISNUM, LJ_TISNUM);
   } else {
-    dasm_put(Dst, 3627, LJ_TISNUM);
+    dasm_put(Dst, 3636, LJ_TISNUM);
   }
   if (sse) {
-    dasm_put(Dst, 3637, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32));
+    dasm_put(Dst, 3646, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32));
   } else {
-    dasm_put(Dst, 3668);
+    dasm_put(Dst, 3677);
   }
-  dasm_put(Dst, 3685, 1+1, FRAME_TYPE, LJ_TNIL);
+  dasm_put(Dst, 3694, 1+1, FRAME_TYPE, LJ_TNIL);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 3781, LJ_TISNUM);
+  dasm_put(Dst, 3790, LJ_TISNUM);
   } else {
-  dasm_put(Dst, 3627, LJ_TISNUM);
+  dasm_put(Dst, 3636, LJ_TISNUM);
   }
   if (sse) {
-  dasm_put(Dst, 3803);
-    if (LJ_DUALNUM) {
   dasm_put(Dst, 3812);
+    if (LJ_DUALNUM) {
+  dasm_put(Dst, 3821);
     }
-  dasm_put(Dst, 2274);
+  dasm_put(Dst, 2283);
   } else {
-  dasm_put(Dst, 3846);
+  dasm_put(Dst, 3855);
     if (LJ_DUALNUM) {
     } else {
-  dasm_put(Dst, 2281);
+  dasm_put(Dst, 2290);
     }
   }
-  dasm_put(Dst, 3852);
+  dasm_put(Dst, 3861);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 3781, LJ_TISNUM);
+  dasm_put(Dst, 3790, LJ_TISNUM);
   } else {
-  dasm_put(Dst, 3627, LJ_TISNUM);
+  dasm_put(Dst, 3636, LJ_TISNUM);
   }
   if (sse) {
-  dasm_put(Dst, 3855);
+  dasm_put(Dst, 3864);
     if (LJ_DUALNUM) {
-  dasm_put(Dst, 3812);
+  dasm_put(Dst, 3821);
     }
-  dasm_put(Dst, 2274);
+  dasm_put(Dst, 2283);
   } else {
-  dasm_put(Dst, 3864);
+  dasm_put(Dst, 3873);
     if (LJ_DUALNUM) {
     } else {
-  dasm_put(Dst, 2281);
+  dasm_put(Dst, 2290);
     }
   }
   if (sse) {
-    dasm_put(Dst, 3870, 1+1, LJ_TISNUM);
+    dasm_put(Dst, 3879, 1+1, LJ_TISNUM);
   } else {
-    dasm_put(Dst, 3899, 1+1, LJ_TISNUM);
+    dasm_put(Dst, 3908, 1+1, LJ_TISNUM);
   }
-  dasm_put(Dst, 3928, 1+1, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1);
-  dasm_put(Dst, 3997, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1);
-  dasm_put(Dst, 4054, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1);
-  dasm_put(Dst, 4117, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1, LJ_TISNUM);
-  dasm_put(Dst, 4207);
+  dasm_put(Dst, 3937, 1+1, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1);
+  dasm_put(Dst, 4006, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1);
+  dasm_put(Dst, 4063, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1);
+  dasm_put(Dst, 4126, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 4216);
   if (sse) {
-  dasm_put(Dst, 4219, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 4228, 1+1, LJ_TISNUM);
   } else {
   }
-  dasm_put(Dst, 4244);
+  dasm_put(Dst, 4253);
   if (sse) {
-  dasm_put(Dst, 4258, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 4267, 1+1, LJ_TISNUM);
   } else {
   }
-  dasm_put(Dst, 4283);
+  dasm_put(Dst, 4292);
   if (sse) {
-  dasm_put(Dst, 4297, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 4306, 1+1, LJ_TISNUM);
   } else {
   }
-  dasm_put(Dst, 4322);
+  dasm_put(Dst, 4331);
   if (sse) {
-    dasm_put(Dst, 4338, 1+1, LJ_TISNUM, Dt8(->upvalue[0]));
+    dasm_put(Dst, 4347, 1+1, LJ_TISNUM, Dt8(->upvalue[0]));
   } else {
-    dasm_put(Dst, 4377, 1+1, LJ_TISNUM, Dt8(->upvalue[0]));
+    dasm_put(Dst, 4386, 1+1, LJ_TISNUM, Dt8(->upvalue[0]));
   }
-  dasm_put(Dst, 4410, 2+1, LJ_TISNUM, LJ_TISNUM, 2+1, LJ_TISNUM, LJ_TISNUM);
-  dasm_put(Dst, 4475, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 4419, 2+1, LJ_TISNUM, LJ_TISNUM, 2+1, LJ_TISNUM, LJ_TISNUM);
+  dasm_put(Dst, 4484, 1+1, LJ_TISNUM);
   if (sse) {
-    dasm_put(Dst, 4574);
+    dasm_put(Dst, 4583);
   } else {
-    dasm_put(Dst, 4580);
+    dasm_put(Dst, 4589);
   }
-  dasm_put(Dst, 4589);
+  dasm_put(Dst, 4598);
   if (sse) {
-    dasm_put(Dst, 4614);
+    dasm_put(Dst, 4623);
   } else {
-    dasm_put(Dst, 4620);
+    dasm_put(Dst, 4629);
   }
-  dasm_put(Dst, 4623, 1+2);
+  dasm_put(Dst, 4632, 1+2);
   if (sse) {
-    dasm_put(Dst, 4632);
+    dasm_put(Dst, 4641);
   } else {
-    dasm_put(Dst, 4640);
+    dasm_put(Dst, 4649);
   }
-  dasm_put(Dst, 4648);
+  dasm_put(Dst, 4657);
   if (sse) {
-    dasm_put(Dst, 4651, (unsigned int)(U64x(43500000,00000000)), (unsigned int)((U64x(43500000,00000000))>>32));
+    dasm_put(Dst, 4660, (unsigned int)(U64x(43500000,00000000)), (unsigned int)((U64x(43500000,00000000))>>32));
   } else {
-    dasm_put(Dst, 4678);
+    dasm_put(Dst, 4687);
   }
-  dasm_put(Dst, 4697);
+  dasm_put(Dst, 4706);
   if (sse) {
-    dasm_put(Dst, 4713, 1+1, LJ_TISNUM);
+    dasm_put(Dst, 4722, 1+1, LJ_TISNUM);
   } else {
-    dasm_put(Dst, 4738, 1+1, LJ_TISNUM);
+    dasm_put(Dst, 4747, 1+1, LJ_TISNUM);
   }
-  dasm_put(Dst, 4760);
+  dasm_put(Dst, 4769);
   if (sse) {
-    dasm_put(Dst, 4782);
+    dasm_put(Dst, 4791);
   } else {
-    dasm_put(Dst, 4808);
+    dasm_put(Dst, 4817);
   }
-  dasm_put(Dst, 4825, 1+2);
+  dasm_put(Dst, 4834, 1+2);
   if (sse) {
-    dasm_put(Dst, 4865);
+    dasm_put(Dst, 4874);
   } else {
-    dasm_put(Dst, 4873);
+    dasm_put(Dst, 4882);
   }
-  dasm_put(Dst, 4883, 2+1, LJ_TISNUM, LJ_TISNUM);
+  dasm_put(Dst, 4892, 2+1, LJ_TISNUM, LJ_TISNUM);
   if (sse) {
-    dasm_put(Dst, 4935, 2+1, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 4944, 2+1, LJ_TISNUM, LJ_TISNUM);
   } else {
-    dasm_put(Dst, 4982, 2+1, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 4991, 2+1, LJ_TISNUM, LJ_TISNUM);
   }
-  dasm_put(Dst, 5023, LJ_TISNUM);
+  dasm_put(Dst, 5032, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 5036, LJ_TISNUM);
+  dasm_put(Dst, 5045, LJ_TISNUM);
   if (sse) {
-  dasm_put(Dst, 4574);
+  dasm_put(Dst, 4583);
   } else {
   }
-  dasm_put(Dst, 5086);
+  dasm_put(Dst, 5095);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 5097, LJ_TISNUM);
+  dasm_put(Dst, 5106, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 5118);
+  dasm_put(Dst, 5127);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
-  dasm_put(Dst, 5139);
+  dasm_put(Dst, 5148);
   } else {
   }
-  dasm_put(Dst, 5164, LJ_TISNUM);
+  dasm_put(Dst, 5173, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 5177, LJ_TISNUM);
+  dasm_put(Dst, 5186, LJ_TISNUM);
   if (sse) {
-  dasm_put(Dst, 4574);
+  dasm_put(Dst, 4583);
   } else {
   }
-  dasm_put(Dst, 5086);
+  dasm_put(Dst, 5095);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 5097, LJ_TISNUM);
+  dasm_put(Dst, 5106, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 5118);
+  dasm_put(Dst, 5127);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
-  dasm_put(Dst, 5227);
+  dasm_put(Dst, 5236);
   } else {
   }
   if (!sse) {
-    dasm_put(Dst, 5252);
+    dasm_put(Dst, 5261);
   }
-  dasm_put(Dst, 5261, 1+1, LJ_TSTR);
+  dasm_put(Dst, 5270, 1+1, LJ_TSTR);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 5283, Dt5(->len));
+    dasm_put(Dst, 5292, Dt5(->len));
   } else if (sse) {
-    dasm_put(Dst, 5291, Dt5(->len));
+    dasm_put(Dst, 5300, Dt5(->len));
   } else {
-    dasm_put(Dst, 5302, Dt5(->len));
+    dasm_put(Dst, 5311, Dt5(->len));
   }
-  dasm_put(Dst, 5310, 1+1, LJ_TSTR, Dt5(->len), Dt5([1]));
+  dasm_put(Dst, 5319, 1+1, LJ_TSTR, Dt5(->len), Dt5([1]));
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 5286);
+    dasm_put(Dst, 5295);
   } else if (sse) {
-    dasm_put(Dst, 5348);
+    dasm_put(Dst, 5357);
   } else {
-    dasm_put(Dst, 5358);
+    dasm_put(Dst, 5367);
   }
-  dasm_put(Dst, 5371, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), 1+1, LJ_TISNUM);
+  dasm_put(Dst, 5380, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 5402);
+    dasm_put(Dst, 5411);
   } else if (sse) {
-    dasm_put(Dst, 5425);
+    dasm_put(Dst, 5434);
   } else {
-    dasm_put(Dst, 5451);
+    dasm_put(Dst, 5460);
   }
-  dasm_put(Dst, 5475, Dt1(->base), Dt1(->base), LJ_TSTR, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), 1+2, LJ_TISNUM);
+  dasm_put(Dst, 5484, Dt1(->base), Dt1(->base), LJ_TSTR, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), 1+2, LJ_TISNUM);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 5583);
+    dasm_put(Dst, 5592);
   } else if (sse) {
-    dasm_put(Dst, 5595);
+    dasm_put(Dst, 5604);
   } else {
-    dasm_put(Dst, 5610);
+    dasm_put(Dst, 5619);
   }
-  dasm_put(Dst, 5622, LJ_TSTR, LJ_TISNUM);
+  dasm_put(Dst, 5631, LJ_TSTR, LJ_TISNUM);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 2521);
+    dasm_put(Dst, 2530);
   } else {
-    dasm_put(Dst, 2264);
+    dasm_put(Dst, 2273);
   }
-  dasm_put(Dst, 5639, Dt5(->len));
+  dasm_put(Dst, 5648, Dt5(->len));
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 5649);
+    dasm_put(Dst, 5658);
   } else if (sse) {
-    dasm_put(Dst, 5653);
+    dasm_put(Dst, 5662);
   } else {
   }
-  dasm_put(Dst, 5660, sizeof(GCstr)-1);
-  dasm_put(Dst, 5735, 2+1, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
-  dasm_put(Dst, 5794, LJ_TSTR, LJ_TISNUM);
+  dasm_put(Dst, 5669, sizeof(GCstr)-1);
+  dasm_put(Dst, 5744, 2+1, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
+  dasm_put(Dst, 5803, LJ_TSTR, LJ_TISNUM);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 5811);
+    dasm_put(Dst, 5820);
   } else if (sse) {
-    dasm_put(Dst, 5819);
+    dasm_put(Dst, 5828);
   } else {
-    dasm_put(Dst, 5830);
+    dasm_put(Dst, 5839);
   }
-  dasm_put(Dst, 5846, Dt5(->len), DISPATCH_GL(tmpbuf.sz), Dt5([1]), DISPATCH_GL(tmpbuf.buf), DISPATCH_GL(tmpbuf.buf), 1+1);
-  dasm_put(Dst, 5911, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf));
-  dasm_put(Dst, 5974, 1+1, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz));
-  dasm_put(Dst, 6045, sizeof(GCstr), DISPATCH_GL(tmpbuf.buf), 1+1);
-  dasm_put(Dst, 6130, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf));
-  dasm_put(Dst, 6200, 1+1, LJ_TTAB);
+  dasm_put(Dst, 5855, Dt5(->len), DISPATCH_GL(tmpbuf.sz), Dt5([1]), DISPATCH_GL(tmpbuf.buf), DISPATCH_GL(tmpbuf.buf), 1+1);
+  dasm_put(Dst, 5920, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf));
+  dasm_put(Dst, 5983, 1+1, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz));
+  dasm_put(Dst, 6054, sizeof(GCstr), DISPATCH_GL(tmpbuf.buf), 1+1);
+  dasm_put(Dst, 6139, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf));
+  dasm_put(Dst, 6209, 1+1, LJ_TTAB);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 6268);
+    dasm_put(Dst, 6277);
   } else if (sse) {
-    dasm_put(Dst, 6275);
+    dasm_put(Dst, 6284);
   } else {
   }
-  dasm_put(Dst, 6285, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 6294, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6301);
+  dasm_put(Dst, 6310);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6318, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6327, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
   dasm_put(Dst, 106);
   if (LJ_DUALNUM || sse) {
     if (!sse) {
     }
-    dasm_put(Dst, 6342);
+    dasm_put(Dst, 6351);
   } else {
   }
-  dasm_put(Dst, 6347, 1+1);
+  dasm_put(Dst, 6356, 1+1);
   if (sse) {
-  dasm_put(Dst, 6358, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6367, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
-  dasm_put(Dst, 6368);
+  dasm_put(Dst, 6377);
   }
-  dasm_put(Dst, 2241, LJ_TISNUM);
+  dasm_put(Dst, 2250, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6377);
+  dasm_put(Dst, 6386);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6394);
+  dasm_put(Dst, 6403);
   } else {
   }
-  dasm_put(Dst, 6409, LJ_TISNUM);
+  dasm_put(Dst, 6418, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6434);
+  dasm_put(Dst, 6443);
   } else {
-  dasm_put(Dst, 6454);
+  dasm_put(Dst, 6463);
   }
   if (sse) {
-  dasm_put(Dst, 6459);
+  dasm_put(Dst, 6468);
   } else {
   }
-  dasm_put(Dst, 6476, 1+1);
+  dasm_put(Dst, 6485, 1+1);
   if (sse) {
-  dasm_put(Dst, 6358, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6367, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
-  dasm_put(Dst, 6368);
+  dasm_put(Dst, 6377);
   }
-  dasm_put(Dst, 2241, LJ_TISNUM);
+  dasm_put(Dst, 2250, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6377);
+  dasm_put(Dst, 6386);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6394);
+  dasm_put(Dst, 6403);
   } else {
   }
-  dasm_put(Dst, 6409, LJ_TISNUM);
+  dasm_put(Dst, 6418, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6494);
+  dasm_put(Dst, 6503);
   } else {
-  dasm_put(Dst, 6454);
+  dasm_put(Dst, 6463);
   }
   if (sse) {
-  dasm_put(Dst, 6514);
+  dasm_put(Dst, 6523);
   } else {
   }
-  dasm_put(Dst, 6531, 1+1);
+  dasm_put(Dst, 6540, 1+1);
   if (sse) {
-  dasm_put(Dst, 6358, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6367, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
-  dasm_put(Dst, 6368);
+  dasm_put(Dst, 6377);
   }
-  dasm_put(Dst, 2241, LJ_TISNUM);
+  dasm_put(Dst, 2250, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6377);
+  dasm_put(Dst, 6386);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6394);
+  dasm_put(Dst, 6403);
   } else {
   }
-  dasm_put(Dst, 6409, LJ_TISNUM);
+  dasm_put(Dst, 6418, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6549);
+  dasm_put(Dst, 6558);
   } else {
-  dasm_put(Dst, 6454);
+  dasm_put(Dst, 6463);
   }
   if (sse) {
-  dasm_put(Dst, 6569);
+  dasm_put(Dst, 6578);
   } else {
   }
-  dasm_put(Dst, 6586, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 6595, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6377);
+  dasm_put(Dst, 6386);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6318, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6327, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6609, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 6618, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6377);
+  dasm_put(Dst, 6386);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6318, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6327, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6633);
+  dasm_put(Dst, 6642);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 6342);
+    dasm_put(Dst, 6351);
   } else if (sse) {
-    dasm_put(Dst, 6639);
+    dasm_put(Dst, 6648);
   } else {
   }
-  dasm_put(Dst, 6651);
+  dasm_put(Dst, 6660);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6662, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 6671, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6377);
+  dasm_put(Dst, 6386);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6318, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6327, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6678, LJ_TISNUM);
+  dasm_put(Dst, 6687, LJ_TISNUM);
   } else if (sse) {
-  dasm_put(Dst, 6693, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6702, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6760);
+  dasm_put(Dst, 6769);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6767, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 6776, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6377);
+  dasm_put(Dst, 6386);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6318, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6327, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6678, LJ_TISNUM);
+  dasm_put(Dst, 6687, LJ_TISNUM);
   } else if (sse) {
-  dasm_put(Dst, 6783, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6792, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6850);
+  dasm_put(Dst, 6859);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6858, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 6867, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6377);
+  dasm_put(Dst, 6386);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6318, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6327, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6678, LJ_TISNUM);
+  dasm_put(Dst, 6687, LJ_TISNUM);
   } else if (sse) {
-  dasm_put(Dst, 6874, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6883, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6941);
+  dasm_put(Dst, 6950);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6949, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 6958, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6377);
+  dasm_put(Dst, 6386);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6318, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6327, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6678, LJ_TISNUM);
+  dasm_put(Dst, 6687, LJ_TISNUM);
   } else if (sse) {
-  dasm_put(Dst, 6965, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6974, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 7032);
+  dasm_put(Dst, 7041);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 7039, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 7048, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6377);
+  dasm_put(Dst, 6386);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6318, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 6327, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 6678, LJ_TISNUM);
+  dasm_put(Dst, 6687, LJ_TISNUM);
   } else if (sse) {
-  dasm_put(Dst, 7055, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
+  dasm_put(Dst, 7064, 2+1, LJ_TISNUM, LJ_TISNUM, (unsigned int)(U64x(43380000,00000000)), (unsigned int)((U64x(43380000,00000000))>>32));
   } else {
   }
-  dasm_put(Dst, 7122, 1+2, 1+1, Dt1(->base), 8*LUA_MINSTACK, Dt1(->top), Dt1(->maxstack), Dt8(->f), Dt1(->base));
-  dasm_put(Dst, 7198, Dt1(->top), Dt7(->pc), FRAME_TYPE, LUA_MINSTACK, Dt1(->base), Dt1(->base));
-  dasm_put(Dst, 7325, Dt1(->top), Dt1(->base), Dt1(->top));
+  dasm_put(Dst, 7131, 1+2, 1+1, Dt1(->base), 8*LUA_MINSTACK, Dt1(->top), Dt1(->maxstack), Dt8(->f), Dt1(->base));
+  dasm_put(Dst, 7207, Dt1(->top), Dt7(->pc), FRAME_TYPE, LUA_MINSTACK, Dt1(->base), Dt1(->base));
+  dasm_put(Dst, 7334, Dt1(->top), Dt1(->base), Dt1(->top));
 #if LJ_HASJIT
-  dasm_put(Dst, 7364, DISPATCH_GL(hookmask), HOOK_VMEVENT, HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount));
+  dasm_put(Dst, 7373, DISPATCH_GL(hookmask), HOOK_VMEVENT, HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount));
 #endif
-  dasm_put(Dst, 7395, DISPATCH_GL(hookmask), HOOK_ACTIVE, DISPATCH_GL(hookmask), HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount), LUA_MASKLINE);
-  dasm_put(Dst, 7446, Dt1(->base), Dt1(->base), GG_DISP2STATIC);
+  dasm_put(Dst, 7404, DISPATCH_GL(hookmask), HOOK_ACTIVE, DISPATCH_GL(hookmask), HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount), LUA_MASKLINE);
+  dasm_put(Dst, 7455, Dt1(->base), Dt1(->base), GG_DISP2STATIC);
 #if LJ_HASJIT
-  dasm_put(Dst, 7513, Dt7(->pc), PC2PROTO(framesize), Dt1(->base), Dt1(->top), GG_DISP2J, DISPATCH_J(L));
+  dasm_put(Dst, 7522, Dt7(->pc), PC2PROTO(framesize), Dt1(->base), Dt1(->top), GG_DISP2J, DISPATCH_J(L));
 #endif
-  dasm_put(Dst, 7560);
+  dasm_put(Dst, 7569);
 #if LJ_HASJIT
-  dasm_put(Dst, 7390);
+  dasm_put(Dst, 7399);
 #endif
-  dasm_put(Dst, 7567);
+  dasm_put(Dst, 7576);
 #if LJ_HASJIT
-  dasm_put(Dst, 7570);
+  dasm_put(Dst, 7579);
 #endif
-  dasm_put(Dst, 7580, Dt1(->base), Dt1(->top));
+  dasm_put(Dst, 7589, Dt1(->base), Dt1(->top));
 #if LJ_HASJIT
-  dasm_put(Dst, 7614);
+  dasm_put(Dst, 7623);
 #endif
-  dasm_put(Dst, 7619, Dt1(->base), Dt1(->top));
+  dasm_put(Dst, 7628, Dt1(->base), Dt1(->top));
 #if LJ_HASJIT
-  dasm_put(Dst, 7650, DISPATCH_GL(vmstate), DISPATCH_GL(vmstate), ~LJ_VMST_EXIT, DISPATCH_J(exitno), DISPATCH_J(parent), 16*8+4*8, DISPATCH_GL(jit_L), DISPATCH_GL(jit_base), DISPATCH_J(L), DISPATCH_GL(jit_L), Dt1(->base), 4*8, GG_DISP2J, Dt1(->cframe), CFRAME_RAWMASK, CFRAME_OFS_L, Dt1(->base), CFRAME_OFS_PC);
+  dasm_put(Dst, 7659, DISPATCH_GL(vmstate), DISPATCH_GL(vmstate), ~LJ_VMST_EXIT, DISPATCH_J(exitno), DISPATCH_J(parent), 16*8+4*8, DISPATCH_GL(jit_L), DISPATCH_GL(jit_base), DISPATCH_J(L), DISPATCH_GL(jit_L), Dt1(->base), 4*8, GG_DISP2J, Dt1(->cframe), CFRAME_RAWMASK, CFRAME_OFS_L, Dt1(->base), CFRAME_OFS_PC);
 #endif
-  dasm_put(Dst, 7880);
+  dasm_put(Dst, 7889);
 #if LJ_HASJIT
-  dasm_put(Dst, 7883, 9*16+4*8, -9*16, -8*16, -7*16, -6*16, -5*16, -4*16, -3*16, -2*16, -1*16, Dt7(->pc), PC2PROTO(k), DISPATCH_GL(jit_L), DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, BC_FUNCF);
-  dasm_put(Dst, 8025);
+  dasm_put(Dst, 7892, 9*16+4*8, -9*16, -8*16, -7*16, -6*16, -5*16, -4*16, -3*16, -2*16, -1*16, Dt7(->pc), PC2PROTO(k), DISPATCH_GL(jit_L), DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, BC_FUNCF);
+  dasm_put(Dst, 8034);
 #endif
-  dasm_put(Dst, 8051);
+  dasm_put(Dst, 8060);
   if (!sse) {
-  dasm_put(Dst, 8054);
+  dasm_put(Dst, 8063);
   }
-  dasm_put(Dst, 8099, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(43300000,00000000)), (unsigned int)((U64x(43300000,00000000))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
+  dasm_put(Dst, 8108, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(43300000,00000000)), (unsigned int)((U64x(43300000,00000000))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
   if (!sse) {
-  dasm_put(Dst, 8185);
+  dasm_put(Dst, 8194);
   }
-  dasm_put(Dst, 8230, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(43300000,00000000)), (unsigned int)((U64x(43300000,00000000))>>32), (unsigned int)(U64x(bff00000,00000000)), (unsigned int)((U64x(bff00000,00000000))>>32));
+  dasm_put(Dst, 8239, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(43300000,00000000)), (unsigned int)((U64x(43300000,00000000))>>32), (unsigned int)(U64x(bff00000,00000000)), (unsigned int)((U64x(bff00000,00000000))>>32));
   if (!sse) {
-  dasm_put(Dst, 8316);
+  dasm_put(Dst, 8325);
   }
-  dasm_put(Dst, 8355, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(43300000,00000000)), (unsigned int)((U64x(43300000,00000000))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
+  dasm_put(Dst, 8364, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(43300000,00000000)), (unsigned int)((U64x(43300000,00000000))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
   if (sse) {
-    dasm_put(Dst, 8444, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(43300000,00000000)), (unsigned int)((U64x(43300000,00000000))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
+    dasm_put(Dst, 8453, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(43300000,00000000)), (unsigned int)((U64x(43300000,00000000))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
   } else {
-    dasm_put(Dst, 8558);
+    dasm_put(Dst, 8567);
   }
-  dasm_put(Dst, 8605);
+  dasm_put(Dst, 8614);
   if (!sse) {
   } else {
-    dasm_put(Dst, 8679);
+    dasm_put(Dst, 8688);
   }
-  dasm_put(Dst, 8682);
-  dasm_put(Dst, 8767, (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
-  dasm_put(Dst, 8870, (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32), (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32), (unsigned int)(U64x(7ff00000,00000000)), (unsigned int)((U64x(7ff00000,00000000))>>32));
-  dasm_put(Dst, 9026);
+  dasm_put(Dst, 8691);
+  dasm_put(Dst, 8776, (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32));
+  dasm_put(Dst, 8879, (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32), (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32), (unsigned int)(U64x(3ff00000,00000000)), (unsigned int)((U64x(3ff00000,00000000))>>32), (unsigned int)(U64x(7ff00000,00000000)), (unsigned int)((U64x(7ff00000,00000000))>>32));
+  dasm_put(Dst, 9035);
 #if LJ_HASJIT
   if (sse) {
-    dasm_put(Dst, 9067);
-    dasm_put(Dst, 9137);
-    dasm_put(Dst, 9210);
+    dasm_put(Dst, 9076);
+    dasm_put(Dst, 9146);
+    dasm_put(Dst, 9219);
   } else {
-    dasm_put(Dst, 9260);
-    dasm_put(Dst, 9352);
+    dasm_put(Dst, 9269);
+    dasm_put(Dst, 9361);
   }
-  dasm_put(Dst, 9398);
+  dasm_put(Dst, 9407);
 #endif
-  dasm_put(Dst, 9402);
+  dasm_put(Dst, 9411);
   if (sse) {
-    dasm_put(Dst, 9405, (unsigned int)(U64x(80000000,00000000)), (unsigned int)((U64x(80000000,00000000))>>32));
-    dasm_put(Dst, 9494, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32));
+    dasm_put(Dst, 9414, (unsigned int)(U64x(80000000,00000000)), (unsigned int)((U64x(80000000,00000000))>>32));
+    dasm_put(Dst, 9503, (unsigned int)(U64x(7fffffff,ffffffff)), (unsigned int)((U64x(7fffffff,ffffffff))>>32));
   } else {
-    dasm_put(Dst, 9618);
-    dasm_put(Dst, 9701);
+    dasm_put(Dst, 9627);
+    dasm_put(Dst, 9710);
     if (cmov) {
-    dasm_put(Dst, 9756);
+    dasm_put(Dst, 9765);
     } else {
-    dasm_put(Dst, 9775);
+    dasm_put(Dst, 9784);
     }
-    dasm_put(Dst, 9398);
+    dasm_put(Dst, 9407);
   }
-  dasm_put(Dst, 9816);
+  dasm_put(Dst, 9825);
+#ifdef LUA_USE_ASSERT
+  dasm_put(Dst, 9409);
+#endif
+  dasm_put(Dst, 9853);
 #if LJ_HASFFI
-#define DtE(_V) (int)(ptrdiff_t)&(((CCallState *)0)_V)
-  dasm_put(Dst, 9844, DtE(->spadj));
-#if LJ_TARGET_WINDOWS
+#define DtE(_V) (int)(ptrdiff_t)&(((CTState *)0)_V)
+  dasm_put(Dst, 9857, GG_G2DISP, Dt2(->ctype_state), DtE(->cb.slot), DtE(->cb.gpr[0]), DtE(->cb.gpr[1]), DtE(->cb.gpr[2]), DtE(->cb.gpr[3]), DtE(->cb.fpr[0]), DtE(->cb.fpr[1]), DtE(->cb.fpr[2]), DtE(->cb.fpr[3]), CFRAME_SIZE+4*8, DtE(->cb.stack), DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base), Dt1(->top), Dt7(->pc));
+#endif
+  dasm_put(Dst, 9984);
+#if LJ_HASFFI
+  dasm_put(Dst, 9987, DISPATCH_GL(ctype_state), DtE(->L), Dt1(->base), Dt1(->top), DtE(->cb.gpr[0]), DtE(->cb.fpr[0]));
 #endif
-  dasm_put(Dst, 9859, DtE(->nsp), offsetof(CCallState, stack), CCALL_SPS_EXTRA*8, DtE(->nfpr), DtE(->gpr[0]), DtE(->gpr[1]), DtE(->gpr[2]), DtE(->gpr[3]), DtE(->fpr[0]), DtE(->fpr[1]), DtE(->fpr[2]), DtE(->fpr[3]));
-  dasm_put(Dst, 9940, DtE(->func), DtE(->gpr[0]), DtE(->fpr[0]));
+  dasm_put(Dst, 10028);
+#if LJ_HASFFI
+#define DtF(_V) (int)(ptrdiff_t)&(((CCallState *)0)_V)
+  dasm_put(Dst, 10031, DtF(->spadj));
 #if LJ_TARGET_WINDOWS
 #endif
-  dasm_put(Dst, 9953);
+  dasm_put(Dst, 10046, DtF(->nsp), offsetof(CCallState, stack), CCALL_SPS_EXTRA*8, DtF(->nfpr), DtF(->gpr[0]), DtF(->gpr[1]), DtF(->gpr[2]), DtF(->gpr[3]), DtF(->fpr[0]), DtF(->fpr[1]), DtF(->fpr[2]), DtF(->fpr[3]));
+  dasm_put(Dst, 10127, DtF(->func), DtF(->gpr[0]), DtF(->fpr[0]));
+#if LJ_TARGET_WINDOWS
 #endif
-  dasm_put(Dst, 9961);
-#ifdef LUA_USE_ASSERT
-  dasm_put(Dst, 9400);
+  dasm_put(Dst, 10140);
 #endif
-  dasm_put(Dst, 9400);
 }
 
 /* Generate the code for a single instruction. */
 static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
 {
   int vk = 0;
-  dasm_put(Dst, 9964, defop);
+  dasm_put(Dst, 780, defop);
 
   switch (op) {
 
@@ -1865,302 +1897,302 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
 
   case BC_ISLT: case BC_ISGE: case BC_ISLE: case BC_ISGT:
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 9966, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 10148, LJ_TISNUM, LJ_TISNUM);
       switch (op) {
       case BC_ISLT:
-      dasm_put(Dst, 9996);
+      dasm_put(Dst, 10178);
       break;
       case BC_ISGE:
-      dasm_put(Dst, 10001);
+      dasm_put(Dst, 10183);
       break;
       case BC_ISLE:
-      dasm_put(Dst, 10006);
+      dasm_put(Dst, 10188);
       break;
       case BC_ISGT:
-      dasm_put(Dst, 10011);
+      dasm_put(Dst, 10193);
       break;
       default: break;  /* Shut up GCC. */
       }
-      dasm_put(Dst, 10016, -BCBIAS_J*4, LJ_TISNUM);
+      dasm_put(Dst, 10198, -BCBIAS_J*4, LJ_TISNUM);
       if (sse) {
-	dasm_put(Dst, 10070);
+	dasm_put(Dst, 10252);
       } else {
-	dasm_put(Dst, 10081);
+	dasm_put(Dst, 10263);
       }
-      dasm_put(Dst, 10092);
+      dasm_put(Dst, 10274);
       if (sse) {
-	dasm_put(Dst, 10099);
+	dasm_put(Dst, 10281);
 	switch (op) {
 	case BC_ISLT:
-	dasm_put(Dst, 10119);
+	dasm_put(Dst, 10301);
 	break;
 	case BC_ISGE:
-	dasm_put(Dst, 10124);
+	dasm_put(Dst, 10306);
 	break;
 	case BC_ISLE:
-	dasm_put(Dst, 10129);
+	dasm_put(Dst, 10311);
 	break;
 	case BC_ISGT:
-	dasm_put(Dst, 10134);
+	dasm_put(Dst, 10316);
 	break;
 	default: break;  /* Shut up GCC. */
 	}
-	dasm_put(Dst, 10139);
+	dasm_put(Dst, 10321);
       } else {
-	dasm_put(Dst, 10144);
+	dasm_put(Dst, 10326);
       }
     } else {
-      dasm_put(Dst, 10152, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 10334, LJ_TISNUM, LJ_TISNUM);
     }
     if (sse) {
-      dasm_put(Dst, 10173);
+      dasm_put(Dst, 10355);
     } else {
-      dasm_put(Dst, 10194);
+      dasm_put(Dst, 10376);
       if (cmov) {
-      dasm_put(Dst, 10210);
+      dasm_put(Dst, 10392);
       } else {
-      dasm_put(Dst, 10216);
+      dasm_put(Dst, 10398);
       }
     }
     if (LJ_DUALNUM) {
       switch (op) {
       case BC_ISLT:
-      dasm_put(Dst, 10119);
+      dasm_put(Dst, 10301);
       break;
       case BC_ISGE:
-      dasm_put(Dst, 10124);
+      dasm_put(Dst, 10306);
       break;
       case BC_ISLE:
-      dasm_put(Dst, 10129);
+      dasm_put(Dst, 10311);
       break;
       case BC_ISGT:
-      dasm_put(Dst, 10134);
+      dasm_put(Dst, 10316);
       break;
       default: break;  /* Shut up GCC. */
       }
-      dasm_put(Dst, 10139);
+      dasm_put(Dst, 10321);
     } else {
       switch (op) {
       case BC_ISLT:
-      dasm_put(Dst, 10223);
+      dasm_put(Dst, 768);
       break;
       case BC_ISGE:
-      dasm_put(Dst, 10228);
+      dasm_put(Dst, 10405);
       break;
       case BC_ISLE:
-      dasm_put(Dst, 10233);
+      dasm_put(Dst, 10410);
       break;
       case BC_ISGT:
-      dasm_put(Dst, 10238);
+      dasm_put(Dst, 10415);
       break;
       default: break;  /* Shut up GCC. */
       }
-      dasm_put(Dst, 10243, -BCBIAS_J*4);
+      dasm_put(Dst, 10420, -BCBIAS_J*4);
     }
     break;
 
   case BC_ISEQV: case BC_ISNEV:
     vk = op == BC_ISEQV;
-    dasm_put(Dst, 10275);
+    dasm_put(Dst, 10452);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 10283, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 10460, LJ_TISNUM, LJ_TISNUM);
       if (vk) {
-	dasm_put(Dst, 10308);
+	dasm_put(Dst, 10485);
       } else {
-	dasm_put(Dst, 10313);
+	dasm_put(Dst, 10490);
       }
-      dasm_put(Dst, 10318, -BCBIAS_J*4, LJ_TISNUM);
+      dasm_put(Dst, 10495, -BCBIAS_J*4, LJ_TISNUM);
       if (sse) {
-	dasm_put(Dst, 10370);
+	dasm_put(Dst, 10547);
       } else {
-	dasm_put(Dst, 10377);
+	dasm_put(Dst, 10554);
       }
-      dasm_put(Dst, 10381);
+      dasm_put(Dst, 10558);
       if (sse) {
-	dasm_put(Dst, 10392);
+	dasm_put(Dst, 10569);
       } else {
-	dasm_put(Dst, 10404);
+	dasm_put(Dst, 10581);
       }
-      dasm_put(Dst, 10411);
+      dasm_put(Dst, 10588);
     } else {
-      dasm_put(Dst, 10416, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 10593, LJ_TISNUM, LJ_TISNUM);
     }
     if (sse) {
-      dasm_put(Dst, 10435);
+      dasm_put(Dst, 10612);
     } else {
-      dasm_put(Dst, 10453);
+      dasm_put(Dst, 10630);
       if (cmov) {
-      dasm_put(Dst, 10210);
+      dasm_put(Dst, 10392);
       } else {
-      dasm_put(Dst, 10216);
+      dasm_put(Dst, 10398);
       }
     }
   iseqne_fp:
     if (vk) {
-      dasm_put(Dst, 10466);
+      dasm_put(Dst, 10643);
     } else {
-      dasm_put(Dst, 10475);
+      dasm_put(Dst, 10652);
     }
   iseqne_end:
     if (vk) {
-      dasm_put(Dst, 10484, -BCBIAS_J*4);
+      dasm_put(Dst, 10661, -BCBIAS_J*4);
       if (!LJ_HASFFI) {
-	dasm_put(Dst, 4629);
+	dasm_put(Dst, 4638);
       }
     } else {
       if (!LJ_HASFFI) {
-	dasm_put(Dst, 4629);
+	dasm_put(Dst, 4638);
       }
-      dasm_put(Dst, 10499, -BCBIAS_J*4);
+      dasm_put(Dst, 10676, -BCBIAS_J*4);
     }
     if (LJ_DUALNUM && (op == BC_ISEQV || op == BC_ISNEV ||
 		       op == BC_ISEQN || op == BC_ISNEN)) {
-      dasm_put(Dst, 10514);
+      dasm_put(Dst, 10691);
     } else {
-      dasm_put(Dst, 10255);
+      dasm_put(Dst, 10432);
     }
     if (op == BC_ISEQV || op == BC_ISNEV) {
-      dasm_put(Dst, 9937);
+      dasm_put(Dst, 10124);
       if (LJ_HASFFI) {
-	dasm_put(Dst, 10519, LJ_TCDATA, LJ_TCDATA);
+	dasm_put(Dst, 10696, LJ_TCDATA, LJ_TCDATA);
       }
-      dasm_put(Dst, 10538, LJ_TISPRI, LJ_TISTABUD, Dt6(->metatable), Dt6(->nomm), 1<<MM_eq);
+      dasm_put(Dst, 10715, LJ_TISPRI, LJ_TISTABUD, LJ_TUDATA, Dt6(->metatable), Dt6(->nomm), 1<<MM_eq);
       if (vk) {
-	dasm_put(Dst, 10594);
+	dasm_put(Dst, 10779);
       } else {
-	dasm_put(Dst, 10598);
+	dasm_put(Dst, 10783);
       }
-      dasm_put(Dst, 10604);
+      dasm_put(Dst, 10789);
     } else if (LJ_HASFFI) {
-      dasm_put(Dst, 10609, LJ_TCDATA);
+      dasm_put(Dst, 10794, LJ_TCDATA);
       if (LJ_DUALNUM && vk) {
-	dasm_put(Dst, 10616);
+	dasm_put(Dst, 10801);
       } else {
-	dasm_put(Dst, 10589);
+	dasm_put(Dst, 10774);
       }
-      dasm_put(Dst, 10621);
+      dasm_put(Dst, 10806);
     }
     break;
   case BC_ISEQS: case BC_ISNES:
     vk = op == BC_ISEQS;
-    dasm_put(Dst, 10626, LJ_TSTR);
+    dasm_put(Dst, 10811, LJ_TSTR);
   iseqne_test:
     if (vk) {
-      dasm_put(Dst, 10470);
+      dasm_put(Dst, 10647);
     } else {
-      dasm_put(Dst, 765);
+      dasm_put(Dst, 2929);
     }
     goto iseqne_end;
   case BC_ISEQN: case BC_ISNEN:
     vk = op == BC_ISEQN;
-    dasm_put(Dst, 10652);
+    dasm_put(Dst, 10837);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 10660, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 10845, LJ_TISNUM, LJ_TISNUM);
       if (vk) {
-	dasm_put(Dst, 10308);
+	dasm_put(Dst, 10485);
       } else {
-	dasm_put(Dst, 10313);
+	dasm_put(Dst, 10490);
       }
-      dasm_put(Dst, 10685, -BCBIAS_J*4, LJ_TISNUM);
+      dasm_put(Dst, 10870, -BCBIAS_J*4, LJ_TISNUM);
       if (sse) {
-	dasm_put(Dst, 10733);
+	dasm_put(Dst, 10918);
       } else {
-	dasm_put(Dst, 10740);
+	dasm_put(Dst, 10925);
       }
-      dasm_put(Dst, 10744);
+      dasm_put(Dst, 10929);
       if (sse) {
-	dasm_put(Dst, 10751);
+	dasm_put(Dst, 10936);
       } else {
-	dasm_put(Dst, 10763);
+	dasm_put(Dst, 10948);
       }
-      dasm_put(Dst, 10411);
+      dasm_put(Dst, 10588);
     } else {
-      dasm_put(Dst, 10770, LJ_TISNUM);
+      dasm_put(Dst, 10955, LJ_TISNUM);
     }
     if (sse) {
-      dasm_put(Dst, 10779);
+      dasm_put(Dst, 10964);
     } else {
-      dasm_put(Dst, 10797);
+      dasm_put(Dst, 10982);
       if (cmov) {
-      dasm_put(Dst, 10210);
+      dasm_put(Dst, 10392);
       } else {
-      dasm_put(Dst, 10216);
+      dasm_put(Dst, 10398);
       }
     }
     goto iseqne_fp;
   case BC_ISEQP: case BC_ISNEP:
     vk = op == BC_ISEQP;
-    dasm_put(Dst, 10810);
+    dasm_put(Dst, 10995);
     if (!LJ_HASFFI) goto iseqne_test;
     if (vk) {
-      dasm_put(Dst, 10824, -BCBIAS_J*4, LJ_TCDATA);
+      dasm_put(Dst, 11009, -BCBIAS_J*4, LJ_TCDATA);
     } else {
-      dasm_put(Dst, 10874, LJ_TCDATA, -BCBIAS_J*4);
+      dasm_put(Dst, 11059, LJ_TCDATA, -BCBIAS_J*4);
     }
     break;
 
   /* -- Unary test and copy ops ------------------------------------------- */
 
   case BC_ISTC: case BC_ISFC: case BC_IST: case BC_ISF:
-    dasm_put(Dst, 10918, LJ_TISTRUECOND);
+    dasm_put(Dst, 11103, LJ_TISTRUECOND);
     if (op == BC_IST || op == BC_ISTC) {
-      dasm_put(Dst, 10238);
+      dasm_put(Dst, 10415);
     } else {
-      dasm_put(Dst, 10233);
+      dasm_put(Dst, 10410);
     }
     if (op == BC_ISTC || op == BC_ISFC) {
-      dasm_put(Dst, 10930);
+      dasm_put(Dst, 11115);
     }
-    dasm_put(Dst, 10243, -BCBIAS_J*4);
+    dasm_put(Dst, 10420, -BCBIAS_J*4);
     break;
 
   /* -- Unary ops --------------------------------------------------------- */
 
   case BC_MOV:
-    dasm_put(Dst, 10941);
+    dasm_put(Dst, 11126);
     break;
   case BC_NOT:
-    dasm_put(Dst, 10969, LJ_TISTRUECOND, LJ_TTRUE);
+    dasm_put(Dst, 11154, LJ_TISTRUECOND, LJ_TTRUE);
     break;
   case BC_UNM:
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 11005, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 11190, LJ_TISNUM, LJ_TISNUM);
     } else {
-      dasm_put(Dst, 11082, LJ_TISNUM);
+      dasm_put(Dst, 11267, LJ_TISNUM);
     }
     if (sse) {
-      dasm_put(Dst, 11093, (unsigned int)(U64x(80000000,00000000)), (unsigned int)((U64x(80000000,00000000))>>32));
+      dasm_put(Dst, 11278, (unsigned int)(U64x(80000000,00000000)), (unsigned int)((U64x(80000000,00000000))>>32));
     } else {
-      dasm_put(Dst, 11118);
+      dasm_put(Dst, 11303);
     }
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 10514);
+      dasm_put(Dst, 10691);
     } else {
-      dasm_put(Dst, 10255);
+      dasm_put(Dst, 10432);
     }
     break;
   case BC_LEN:
-    dasm_put(Dst, 11127, LJ_TSTR);
+    dasm_put(Dst, 11312, LJ_TSTR);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 11141, Dt5(->len), LJ_TISNUM);
+      dasm_put(Dst, 11326, Dt5(->len), LJ_TISNUM);
     } else if (sse) {
-      dasm_put(Dst, 11155, Dt5(->len));
+      dasm_put(Dst, 11340, Dt5(->len));
     } else {
-      dasm_put(Dst, 11173, Dt5(->len));
+      dasm_put(Dst, 11358, Dt5(->len));
     }
-    dasm_put(Dst, 11182, LJ_TTAB);
+    dasm_put(Dst, 11367, LJ_TTAB);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-    dasm_put(Dst, 11217, Dt6(->metatable));
+    dasm_put(Dst, 11402, Dt6(->metatable));
 #endif
-    dasm_put(Dst, 11231);
+    dasm_put(Dst, 11416);
     if (LJ_DUALNUM) {
     } else if (sse) {
-      dasm_put(Dst, 11240);
+      dasm_put(Dst, 11425);
     } else {
     }
-    dasm_put(Dst, 11246);
+    dasm_put(Dst, 11431);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-    dasm_put(Dst, 11259, Dt6(->nomm), 1<<MM_len);
+    dasm_put(Dst, 11444, Dt6(->nomm), 1<<MM_len);
 #endif
     break;
 
@@ -2169,605 +2201,605 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
 
   case BC_ADDVN: case BC_ADDNV: case BC_ADDVV:
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11275);
+    dasm_put(Dst, 11460);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11283, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11468, LJ_TISNUM, LJ_TISNUM);
       break;
     case 1:
-    dasm_put(Dst, 11316, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11501, LJ_TISNUM, LJ_TISNUM);
       break;
     default:
-    dasm_put(Dst, 11349, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11534, LJ_TISNUM, LJ_TISNUM);
       break;
     }
-    dasm_put(Dst, 11382, LJ_TISNUM);
+    dasm_put(Dst, 11567, LJ_TISNUM);
     if (vk == 1) {
-    dasm_put(Dst, 11151);
+    dasm_put(Dst, 11336);
     } else {
-    dasm_put(Dst, 10937);
+    dasm_put(Dst, 11122);
     }
-    dasm_put(Dst, 10255);
+    dasm_put(Dst, 10432);
     } else {
-    dasm_put(Dst, 11275);
+    dasm_put(Dst, 11460);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11388, LJ_TISNUM);
+    dasm_put(Dst, 11573, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11400, LJ_TISNUM);
+    dasm_put(Dst, 11585, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11411);
+    dasm_put(Dst, 11596);
     } else {
-    dasm_put(Dst, 11425);
+    dasm_put(Dst, 11610);
     }
       break;
     case 1:
-    dasm_put(Dst, 11433, LJ_TISNUM);
+    dasm_put(Dst, 11618, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11445, LJ_TISNUM);
+    dasm_put(Dst, 11630, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11456);
+    dasm_put(Dst, 11641);
     } else {
-    dasm_put(Dst, 11470);
+    dasm_put(Dst, 11655);
     }
       break;
     default:
-    dasm_put(Dst, 11478, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11663, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 11500);
+    dasm_put(Dst, 11685);
     } else {
-    dasm_put(Dst, 11514);
+    dasm_put(Dst, 11699);
     }
       break;
     }
     if (sse) {
-    dasm_put(Dst, 11111);
+    dasm_put(Dst, 11296);
     } else {
-    dasm_put(Dst, 11123);
+    dasm_put(Dst, 11308);
     }
-    dasm_put(Dst, 10255);
+    dasm_put(Dst, 10432);
     }
     break;
   case BC_SUBVN: case BC_SUBNV: case BC_SUBVV:
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11275);
+    dasm_put(Dst, 11460);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11522, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11707, LJ_TISNUM, LJ_TISNUM);
       break;
     case 1:
-    dasm_put(Dst, 11555, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11740, LJ_TISNUM, LJ_TISNUM);
       break;
     default:
-    dasm_put(Dst, 11588, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11773, LJ_TISNUM, LJ_TISNUM);
       break;
     }
-    dasm_put(Dst, 11382, LJ_TISNUM);
+    dasm_put(Dst, 11567, LJ_TISNUM);
     if (vk == 1) {
-    dasm_put(Dst, 11151);
+    dasm_put(Dst, 11336);
     } else {
-    dasm_put(Dst, 10937);
+    dasm_put(Dst, 11122);
     }
-    dasm_put(Dst, 10255);
+    dasm_put(Dst, 10432);
     } else {
-    dasm_put(Dst, 11275);
+    dasm_put(Dst, 11460);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11388, LJ_TISNUM);
+    dasm_put(Dst, 11573, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11400, LJ_TISNUM);
+    dasm_put(Dst, 11585, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11621);
+    dasm_put(Dst, 11806);
     } else {
-    dasm_put(Dst, 11635);
+    dasm_put(Dst, 11820);
     }
       break;
     case 1:
-    dasm_put(Dst, 11433, LJ_TISNUM);
+    dasm_put(Dst, 11618, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11445, LJ_TISNUM);
+    dasm_put(Dst, 11630, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11643);
+    dasm_put(Dst, 11828);
     } else {
-    dasm_put(Dst, 11657);
+    dasm_put(Dst, 11842);
     }
       break;
     default:
-    dasm_put(Dst, 11478, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11663, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 11665);
+    dasm_put(Dst, 11850);
     } else {
-    dasm_put(Dst, 11679);
+    dasm_put(Dst, 11864);
     }
       break;
     }
     if (sse) {
-    dasm_put(Dst, 11111);
+    dasm_put(Dst, 11296);
     } else {
-    dasm_put(Dst, 11123);
+    dasm_put(Dst, 11308);
     }
-    dasm_put(Dst, 10255);
+    dasm_put(Dst, 10432);
     }
     break;
   case BC_MULVN: case BC_MULNV: case BC_MULVV:
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11275);
+    dasm_put(Dst, 11460);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11687, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11872, LJ_TISNUM, LJ_TISNUM);
       break;
     case 1:
-    dasm_put(Dst, 11721, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11906, LJ_TISNUM, LJ_TISNUM);
       break;
     default:
-    dasm_put(Dst, 11755, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11940, LJ_TISNUM, LJ_TISNUM);
       break;
     }
-    dasm_put(Dst, 11382, LJ_TISNUM);
+    dasm_put(Dst, 11567, LJ_TISNUM);
     if (vk == 1) {
-    dasm_put(Dst, 11151);
+    dasm_put(Dst, 11336);
     } else {
-    dasm_put(Dst, 10937);
+    dasm_put(Dst, 11122);
     }
-    dasm_put(Dst, 10255);
+    dasm_put(Dst, 10432);
     } else {
-    dasm_put(Dst, 11275);
+    dasm_put(Dst, 11460);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11388, LJ_TISNUM);
+    dasm_put(Dst, 11573, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11400, LJ_TISNUM);
+    dasm_put(Dst, 11585, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11789);
+    dasm_put(Dst, 11974);
     } else {
-    dasm_put(Dst, 11803);
+    dasm_put(Dst, 11988);
     }
       break;
     case 1:
-    dasm_put(Dst, 11433, LJ_TISNUM);
+    dasm_put(Dst, 11618, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11445, LJ_TISNUM);
+    dasm_put(Dst, 11630, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11811);
+    dasm_put(Dst, 11996);
     } else {
-    dasm_put(Dst, 11825);
+    dasm_put(Dst, 12010);
     }
       break;
     default:
-    dasm_put(Dst, 11478, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11663, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 11833);
+    dasm_put(Dst, 12018);
     } else {
-    dasm_put(Dst, 11847);
+    dasm_put(Dst, 12032);
     }
       break;
     }
     if (sse) {
-    dasm_put(Dst, 11111);
+    dasm_put(Dst, 11296);
     } else {
-    dasm_put(Dst, 11123);
+    dasm_put(Dst, 11308);
     }
-    dasm_put(Dst, 10255);
+    dasm_put(Dst, 10432);
     }
     break;
   case BC_DIVVN: case BC_DIVNV: case BC_DIVVV:
-    dasm_put(Dst, 11275);
+    dasm_put(Dst, 11460);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11388, LJ_TISNUM);
+    dasm_put(Dst, 11573, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11400, LJ_TISNUM);
+    dasm_put(Dst, 11585, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11855);
+    dasm_put(Dst, 12040);
     } else {
-    dasm_put(Dst, 11869);
+    dasm_put(Dst, 12054);
     }
       break;
     case 1:
-    dasm_put(Dst, 11433, LJ_TISNUM);
+    dasm_put(Dst, 11618, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11445, LJ_TISNUM);
+    dasm_put(Dst, 11630, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11877);
+    dasm_put(Dst, 12062);
     } else {
-    dasm_put(Dst, 11891);
+    dasm_put(Dst, 12076);
     }
       break;
     default:
-    dasm_put(Dst, 11478, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11663, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 11899);
+    dasm_put(Dst, 12084);
     } else {
-    dasm_put(Dst, 11913);
+    dasm_put(Dst, 12098);
     }
       break;
     }
     if (sse) {
-    dasm_put(Dst, 11111);
+    dasm_put(Dst, 11296);
     } else {
-    dasm_put(Dst, 11123);
+    dasm_put(Dst, 11308);
     }
-    dasm_put(Dst, 10255);
+    dasm_put(Dst, 10432);
     break;
   case BC_MODVN:
-    dasm_put(Dst, 11275);
+    dasm_put(Dst, 11460);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11388, LJ_TISNUM);
+    dasm_put(Dst, 11573, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11400, LJ_TISNUM);
+    dasm_put(Dst, 11585, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11921);
+    dasm_put(Dst, 12106);
     } else {
-    dasm_put(Dst, 11935);
+    dasm_put(Dst, 12120);
     }
       break;
     case 1:
-    dasm_put(Dst, 11433, LJ_TISNUM);
+    dasm_put(Dst, 11618, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11445, LJ_TISNUM);
+    dasm_put(Dst, 11630, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11943);
+    dasm_put(Dst, 12128);
     } else {
-    dasm_put(Dst, 11957);
+    dasm_put(Dst, 12142);
     }
       break;
     default:
-    dasm_put(Dst, 11478, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11663, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 11965);
+    dasm_put(Dst, 12150);
     } else {
-    dasm_put(Dst, 11979);
+    dasm_put(Dst, 12164);
     }
       break;
     }
-    dasm_put(Dst, 11987);
+    dasm_put(Dst, 12172);
     if (sse) {
-    dasm_put(Dst, 11111);
+    dasm_put(Dst, 11296);
     } else {
-    dasm_put(Dst, 11123);
+    dasm_put(Dst, 11308);
     }
-    dasm_put(Dst, 10255);
+    dasm_put(Dst, 10432);
     break;
   case BC_MODNV: case BC_MODVV:
-    dasm_put(Dst, 11275);
+    dasm_put(Dst, 11460);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11388, LJ_TISNUM);
+    dasm_put(Dst, 11573, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11400, LJ_TISNUM);
+    dasm_put(Dst, 11585, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11921);
+    dasm_put(Dst, 12106);
     } else {
-    dasm_put(Dst, 11935);
+    dasm_put(Dst, 12120);
     }
       break;
     case 1:
-    dasm_put(Dst, 11433, LJ_TISNUM);
+    dasm_put(Dst, 11618, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11445, LJ_TISNUM);
+    dasm_put(Dst, 11630, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11943);
+    dasm_put(Dst, 12128);
     } else {
-    dasm_put(Dst, 11957);
+    dasm_put(Dst, 12142);
     }
       break;
     default:
-    dasm_put(Dst, 11478, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11663, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 11965);
+    dasm_put(Dst, 12150);
     } else {
-    dasm_put(Dst, 11979);
+    dasm_put(Dst, 12164);
     }
       break;
     }
-    dasm_put(Dst, 11993);
+    dasm_put(Dst, 12178);
     break;
   case BC_POW:
-    dasm_put(Dst, 11275);
+    dasm_put(Dst, 11460);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 11388, LJ_TISNUM);
+    dasm_put(Dst, 11573, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11400, LJ_TISNUM);
+    dasm_put(Dst, 11585, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11921);
+    dasm_put(Dst, 12106);
     } else {
-    dasm_put(Dst, 11935);
+    dasm_put(Dst, 12120);
     }
       break;
     case 1:
-    dasm_put(Dst, 11433, LJ_TISNUM);
+    dasm_put(Dst, 11618, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 11445, LJ_TISNUM);
+    dasm_put(Dst, 11630, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 11943);
+    dasm_put(Dst, 12128);
     } else {
-    dasm_put(Dst, 11957);
+    dasm_put(Dst, 12142);
     }
       break;
     default:
-    dasm_put(Dst, 11478, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 11663, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 11965);
+    dasm_put(Dst, 12150);
     } else {
-    dasm_put(Dst, 11979);
+    dasm_put(Dst, 12164);
     }
       break;
     }
-    dasm_put(Dst, 11998);
+    dasm_put(Dst, 12183);
     if (sse) {
-    dasm_put(Dst, 11111);
+    dasm_put(Dst, 11296);
     } else {
-    dasm_put(Dst, 11123);
+    dasm_put(Dst, 11308);
     }
-    dasm_put(Dst, 10255);
+    dasm_put(Dst, 10432);
     break;
 
   case BC_CAT:
-    dasm_put(Dst, 12002, Dt1(->base), Dt1(->base));
+    dasm_put(Dst, 12187, Dt1(->base), Dt1(->base));
     break;
 
   /* -- Constant ops ------------------------------------------------------ */
 
   case BC_KSTR:
-    dasm_put(Dst, 12085, LJ_TSTR);
+    dasm_put(Dst, 12270, LJ_TSTR);
     break;
   case BC_KCDATA:
 #if LJ_HASFFI
-    dasm_put(Dst, 12085, LJ_TCDATA);
+    dasm_put(Dst, 12270, LJ_TCDATA);
 #endif
     break;
   case BC_KSHORT:
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 12120, LJ_TISNUM);
+      dasm_put(Dst, 12305, LJ_TISNUM);
     } else if (sse) {
-      dasm_put(Dst, 12132);
+      dasm_put(Dst, 12317);
     } else {
-      dasm_put(Dst, 12147);
+      dasm_put(Dst, 12332);
     }
-    dasm_put(Dst, 10255);
+    dasm_put(Dst, 10432);
     break;
   case BC_KNUM:
     if (sse) {
-      dasm_put(Dst, 12155);
+      dasm_put(Dst, 12340);
     } else {
-      dasm_put(Dst, 12168);
+      dasm_put(Dst, 12353);
     }
-    dasm_put(Dst, 10255);
+    dasm_put(Dst, 10432);
     break;
   case BC_KPRI:
-    dasm_put(Dst, 12175);
+    dasm_put(Dst, 12360);
     break;
   case BC_KNIL:
-    dasm_put(Dst, 12203, LJ_TNIL);
+    dasm_put(Dst, 12388, LJ_TNIL);
     break;
 
   /* -- Upvalue and function ops ------------------------------------------ */
 
   case BC_UGET:
-    dasm_put(Dst, 12250, offsetof(GCfuncL, uvptr), DtA(->v));
+    dasm_put(Dst, 12435, offsetof(GCfuncL, uvptr), DtA(->v));
     break;
   case BC_USETV:
 #define TV2MARKOFS \
  ((int32_t)offsetof(GCupval, marked)-(int32_t)offsetof(GCupval, tv))
-    dasm_put(Dst, 12290, offsetof(GCfuncL, uvptr), DtA(->closed), DtA(->v), TV2MARKOFS, LJ_GC_BLACK, LJ_TISGCV, LJ_TISNUM - LJ_TISGCV, Dt4(->gch.marked), LJ_GC_WHITES, GG_DISP2G);
-    dasm_put(Dst, 12381);
+    dasm_put(Dst, 12475, offsetof(GCfuncL, uvptr), DtA(->closed), DtA(->v), TV2MARKOFS, LJ_GC_BLACK, LJ_TISGCV, LJ_TISNUM - LJ_TISGCV, Dt4(->gch.marked), LJ_GC_WHITES, GG_DISP2G);
+    dasm_put(Dst, 12566);
     break;
 #undef TV2MARKOFS
   case BC_USETS:
-    dasm_put(Dst, 12393, offsetof(GCfuncL, uvptr), DtA(->v), LJ_TSTR, DtA(->marked), LJ_GC_BLACK, Dt4(->gch.marked), LJ_GC_WHITES, DtA(->closed), GG_DISP2G);
+    dasm_put(Dst, 12578, offsetof(GCfuncL, uvptr), DtA(->v), LJ_TSTR, DtA(->marked), LJ_GC_BLACK, Dt4(->gch.marked), LJ_GC_WHITES, DtA(->closed), GG_DISP2G);
     break;
   case BC_USETN:
-    dasm_put(Dst, 12486);
+    dasm_put(Dst, 12671);
     if (sse) {
-      dasm_put(Dst, 12491);
+      dasm_put(Dst, 12676);
     } else {
-      dasm_put(Dst, 10766);
+      dasm_put(Dst, 10951);
     }
-    dasm_put(Dst, 12498, offsetof(GCfuncL, uvptr), DtA(->v));
+    dasm_put(Dst, 12683, offsetof(GCfuncL, uvptr), DtA(->v));
     if (sse) {
-      dasm_put(Dst, 12507);
+      dasm_put(Dst, 12692);
     } else {
-      dasm_put(Dst, 12513);
+      dasm_put(Dst, 12698);
     }
-    dasm_put(Dst, 10255);
+    dasm_put(Dst, 10432);
     break;
   case BC_USETP:
-    dasm_put(Dst, 12516, offsetof(GCfuncL, uvptr), DtA(->v));
+    dasm_put(Dst, 12701, offsetof(GCfuncL, uvptr), DtA(->v));
     break;
   case BC_UCLO:
-    dasm_put(Dst, 12555, -BCBIAS_J*4, Dt1(->openupval), Dt1(->base), Dt1(->base));
+    dasm_put(Dst, 12740, -BCBIAS_J*4, Dt1(->openupval), Dt1(->base), Dt1(->base));
     break;
 
   case BC_FNEW:
-    dasm_put(Dst, 12610, Dt1(->base), Dt1(->base), LJ_TFUNC);
+    dasm_put(Dst, 12795, Dt1(->base), Dt1(->base), LJ_TFUNC);
     break;
 
   /* -- Table ops --------------------------------------------------------- */
 
   case BC_TNEW:
-    dasm_put(Dst, 12676, Dt1(->base), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), LJ_TTAB);
+    dasm_put(Dst, 12861, Dt1(->base), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), LJ_TTAB);
     break;
   case BC_TDUP:
-    dasm_put(Dst, 12798, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), Dt1(->base), LJ_TTAB);
+    dasm_put(Dst, 12983, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), Dt1(->base), LJ_TTAB);
     break;
 
   case BC_GGET:
-    dasm_put(Dst, 12893, Dt7(->env));
+    dasm_put(Dst, 13078, Dt7(->env));
     break;
   case BC_GSET:
-    dasm_put(Dst, 12912, Dt7(->env));
+    dasm_put(Dst, 13097, Dt7(->env));
     break;
 
   case BC_TGETV:
-    dasm_put(Dst, 12931, LJ_TTAB);
+    dasm_put(Dst, 13116, LJ_TTAB);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 12954, LJ_TISNUM);
+      dasm_put(Dst, 13139, LJ_TISNUM);
     } else {
-      dasm_put(Dst, 12968, LJ_TISNUM);
+      dasm_put(Dst, 13153, LJ_TISNUM);
       if (sse) {
-	dasm_put(Dst, 12979);
+	dasm_put(Dst, 13164);
       } else {
       }
-      dasm_put(Dst, 13000);
+      dasm_put(Dst, 13185);
     }
-    dasm_put(Dst, 13005, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_index, LJ_TNIL);
-    dasm_put(Dst, 13096, LJ_TSTR);
+    dasm_put(Dst, 13190, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_index, LJ_TNIL);
+    dasm_put(Dst, 13281, LJ_TSTR);
     break;
   case BC_TGETS:
-    dasm_put(Dst, 13114, LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), LJ_TNIL);
-    dasm_put(Dst, 13198, LJ_TNIL, DtB(->next), Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
+    dasm_put(Dst, 13299, LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), LJ_TNIL);
+    dasm_put(Dst, 13383, LJ_TNIL, DtB(->next), Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
     break;
   case BC_TGETB:
-    dasm_put(Dst, 13269, LJ_TTAB, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
-    dasm_put(Dst, 13364, LJ_TNIL);
+    dasm_put(Dst, 13454, LJ_TTAB, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
+    dasm_put(Dst, 13549, LJ_TNIL);
     break;
 
   case BC_TSETV:
-    dasm_put(Dst, 13381, LJ_TTAB);
+    dasm_put(Dst, 13566, LJ_TTAB);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 12954, LJ_TISNUM);
+      dasm_put(Dst, 13139, LJ_TISNUM);
     } else {
-      dasm_put(Dst, 12968, LJ_TISNUM);
+      dasm_put(Dst, 13153, LJ_TISNUM);
       if (sse) {
-	dasm_put(Dst, 12979);
+	dasm_put(Dst, 13164);
       } else {
       }
-      dasm_put(Dst, 13404);
+      dasm_put(Dst, 13589);
     }
-    dasm_put(Dst, 13409, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex);
-    dasm_put(Dst, 13489, LJ_TSTR, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
+    dasm_put(Dst, 13594, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex);
+    dasm_put(Dst, 13674, LJ_TSTR, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
     break;
   case BC_TSETS:
-    dasm_put(Dst, 13546, LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->nomm), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), LJ_TNIL);
-    dasm_put(Dst, 13622, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, DtB(->next));
-    dasm_put(Dst, 13710, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, LJ_TSTR, Dt1(->base), Dt1(->base), Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
+    dasm_put(Dst, 13731, LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->nomm), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), LJ_TNIL);
+    dasm_put(Dst, 13807, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, DtB(->next));
+    dasm_put(Dst, 13895, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, LJ_TSTR, Dt1(->base), Dt1(->base), Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
     break;
   case BC_TSETB:
-    dasm_put(Dst, 13801, LJ_TTAB, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable));
-    dasm_put(Dst, 13895, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
+    dasm_put(Dst, 13986, LJ_TTAB, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable));
+    dasm_put(Dst, 14080, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
     break;
 
   case BC_TSETM:
-    dasm_put(Dst, 13941, Dt6(->marked), LJ_GC_BLACK, Dt6(->asize), Dt6(->array), Dt1(->base), Dt1(->base));
-    dasm_put(Dst, 14084, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
+    dasm_put(Dst, 14126, Dt6(->marked), LJ_GC_BLACK, Dt6(->asize), Dt6(->array), Dt1(->base), Dt1(->base));
+    dasm_put(Dst, 14269, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
     break;
 
   /* -- Calls and vararg handling ----------------------------------------- */
 
   case BC_CALL: case BC_CALLM:
-    dasm_put(Dst, 11279);
+    dasm_put(Dst, 11464);
     if (op == BC_CALLM) {
-      dasm_put(Dst, 14102);
+      dasm_put(Dst, 14287);
     }
-    dasm_put(Dst, 14107, LJ_TFUNC, Dt7(->pc));
+    dasm_put(Dst, 14292, LJ_TFUNC, Dt7(->pc));
     break;
 
   case BC_CALLMT:
-    dasm_put(Dst, 14102);
+    dasm_put(Dst, 14287);
     break;
   case BC_CALLT:
-    dasm_put(Dst, 14149, LJ_TFUNC, FRAME_TYPE, Dt7(->ffid), Dt7(->pc));
-    dasm_put(Dst, 14264, FRAME_TYPE, Dt7(->pc), PC2PROTO(k), FRAME_VARG, FRAME_TYPEP, FRAME_VARG);
+    dasm_put(Dst, 14334, LJ_TFUNC, FRAME_TYPE, Dt7(->ffid), Dt7(->pc));
+    dasm_put(Dst, 14449, FRAME_TYPE, Dt7(->pc), PC2PROTO(k), FRAME_VARG, FRAME_TYPEP, FRAME_VARG);
     break;
 
   case BC_ITERC:
-    dasm_put(Dst, 14335, LJ_TFUNC, 2+1, Dt7(->pc));
+    dasm_put(Dst, 14520, LJ_TFUNC, 2+1, Dt7(->pc));
     break;
 
   case BC_ITERN:
 #if LJ_HASJIT
 #endif
-    dasm_put(Dst, 14406, Dt6(->asize), Dt6(->array), LJ_TNIL);
+    dasm_put(Dst, 14591, Dt6(->asize), Dt6(->array), LJ_TNIL);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 11146, LJ_TISNUM);
+      dasm_put(Dst, 11331, LJ_TISNUM);
     } else if (sse) {
-      dasm_put(Dst, 11240);
+      dasm_put(Dst, 11425);
     } else {
-      dasm_put(Dst, 14452);
+      dasm_put(Dst, 14637);
     }
-    dasm_put(Dst, 14458);
+    dasm_put(Dst, 14643);
     if (LJ_DUALNUM) {
     } else if (sse) {
-      dasm_put(Dst, 11111);
+      dasm_put(Dst, 11296);
     } else {
-      dasm_put(Dst, 11123);
+      dasm_put(Dst, 11308);
     }
-    dasm_put(Dst, 14471, -BCBIAS_J*4);
+    dasm_put(Dst, 14656, -BCBIAS_J*4);
     if (!LJ_DUALNUM && !sse) {
-      dasm_put(Dst, 14523);
+      dasm_put(Dst, 14708);
     }
-    dasm_put(Dst, 14529, Dt6(->hmask), sizeof(Node), Dt6(->node), DtB(->val.it), LJ_TNIL, DtB(->key), DtB(->val));
+    dasm_put(Dst, 14714, Dt6(->hmask), sizeof(Node), Dt6(->node), DtB(->val.it), LJ_TNIL, DtB(->key), DtB(->val));
     break;
 
   case BC_ISNEXT:
-    dasm_put(Dst, 14601, LJ_TFUNC, LJ_TTAB, LJ_TNIL, Dt8(->ffid), FF_next_N, -BCBIAS_J*4, BC_JMP, -BCBIAS_J*4, BC_ITERC);
+    dasm_put(Dst, 14786, LJ_TFUNC, LJ_TTAB, LJ_TNIL, Dt8(->ffid), FF_next_N, -BCBIAS_J*4, BC_JMP, -BCBIAS_J*4, BC_ITERC);
     break;
 
   case BC_VARG:
-    dasm_put(Dst, 14701, (8+FRAME_VARG), LJ_TNIL, Dt1(->maxstack));
-    dasm_put(Dst, 14861, Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top));
+    dasm_put(Dst, 14886, (8+FRAME_VARG), LJ_TNIL, Dt1(->maxstack));
+    dasm_put(Dst, 15046, Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top));
     break;
 
   /* -- Returns ----------------------------------------------------------- */
 
   case BC_RETM:
-    dasm_put(Dst, 14102);
+    dasm_put(Dst, 14287);
     break;
 
   case BC_RET: case BC_RET0: case BC_RET1:
     if (op != BC_RET0) {
-      dasm_put(Dst, 14927);
+      dasm_put(Dst, 15112);
     }
-    dasm_put(Dst, 14931, FRAME_TYPE);
+    dasm_put(Dst, 15116, FRAME_TYPE);
     switch (op) {
     case BC_RET:
-      dasm_put(Dst, 14950);
+      dasm_put(Dst, 15135);
       break;
     case BC_RET1:
-      dasm_put(Dst, 15002);
+      dasm_put(Dst, 15187);
       /* fallthrough */
     case BC_RET0:
-      dasm_put(Dst, 15012);
+      dasm_put(Dst, 15197);
     default:
       break;
     }
-    dasm_put(Dst, 15023, Dt7(->pc), PC2PROTO(k));
+    dasm_put(Dst, 15208, Dt7(->pc), PC2PROTO(k));
     if (op == BC_RET) {
-      dasm_put(Dst, 15067, LJ_TNIL);
+      dasm_put(Dst, 15252, LJ_TNIL);
     } else {
-      dasm_put(Dst, 15076, LJ_TNIL);
+      dasm_put(Dst, 15261, LJ_TNIL);
     }
-    dasm_put(Dst, 15083, -FRAME_VARG, FRAME_TYPEP);
+    dasm_put(Dst, 15268, -FRAME_VARG, FRAME_TYPEP);
     if (op != BC_RET0) {
-      dasm_put(Dst, 15107);
+      dasm_put(Dst, 15292);
     }
-    dasm_put(Dst, 4708);
+    dasm_put(Dst, 4717);
     break;
 
   /* -- Loops and branches ------------------------------------------------ */
@@ -2775,7 +2807,7 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
 
   case BC_FORL:
 #if LJ_HASJIT
-    dasm_put(Dst, 15111, HOTCOUNT_PCMASK, GG_DISP2HOT);
+    dasm_put(Dst, 15296, HOTCOUNT_PCMASK, GG_DISP2HOT, HOTCOUNT_LOOP);
 #endif
     break;
 
@@ -2787,111 +2819,111 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
   case BC_FORI:
   case BC_IFORL:
     vk = (op == BC_IFORL || op == BC_JFORL);
-    dasm_put(Dst, 15132);
+    dasm_put(Dst, 15317);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 15136, LJ_TISNUM);
+      dasm_put(Dst, 15321, LJ_TISNUM);
       if (!vk) {
-	dasm_put(Dst, 15146, LJ_TISNUM, LJ_TISNUM);
+	dasm_put(Dst, 15331, LJ_TISNUM, LJ_TISNUM);
       } else {
 #ifdef LUA_USE_ASSERT
-	dasm_put(Dst, 15175, LJ_TISNUM, LJ_TISNUM);
+	dasm_put(Dst, 15360, LJ_TISNUM, LJ_TISNUM);
 #endif
-	dasm_put(Dst, 15194);
+	dasm_put(Dst, 15379);
       }
-      dasm_put(Dst, 15213, LJ_TISNUM);
+      dasm_put(Dst, 15398, LJ_TISNUM);
       if (op == BC_FORI) {
-	dasm_put(Dst, 15224, -BCBIAS_J*4);
+	dasm_put(Dst, 15409, -BCBIAS_J*4);
       } else if (op == BC_JFORI) {
-	dasm_put(Dst, 15238, -BCBIAS_J*4, BC_JLOOP);
+	dasm_put(Dst, 15423, -BCBIAS_J*4, BC_JLOOP);
       } else if (op == BC_IFORL) {
-	dasm_put(Dst, 15256, -BCBIAS_J*4);
+	dasm_put(Dst, 15441, -BCBIAS_J*4);
       } else {
-	dasm_put(Dst, 15248, BC_JLOOP);
+	dasm_put(Dst, 15433, BC_JLOOP);
       }
-      dasm_put(Dst, 15270);
+      dasm_put(Dst, 15455);
       if (vk) {
-	dasm_put(Dst, 15294);
+	dasm_put(Dst, 15479);
       }
-      dasm_put(Dst, 15213, LJ_TISNUM);
+      dasm_put(Dst, 15398, LJ_TISNUM);
       if (op == BC_FORI) {
-	dasm_put(Dst, 15303);
+	dasm_put(Dst, 15488);
       } else if (op == BC_JFORI) {
-	dasm_put(Dst, 15308, -BCBIAS_J*4, BC_JLOOP);
+	dasm_put(Dst, 15493, -BCBIAS_J*4, BC_JLOOP);
       } else if (op == BC_IFORL) {
-	dasm_put(Dst, 15322);
+	dasm_put(Dst, 15507);
       } else {
-	dasm_put(Dst, 15318, BC_JLOOP);
+	dasm_put(Dst, 15503, BC_JLOOP);
       }
-      dasm_put(Dst, 15327);
+      dasm_put(Dst, 15512);
     } else if (!vk) {
-      dasm_put(Dst, 15334, LJ_TISNUM);
+      dasm_put(Dst, 15519, LJ_TISNUM);
     }
     if (!vk) {
-      dasm_put(Dst, 15340, LJ_TISNUM);
+      dasm_put(Dst, 15525, LJ_TISNUM);
     } else {
 #ifdef LUA_USE_ASSERT
-      dasm_put(Dst, 15354, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 15539, LJ_TISNUM, LJ_TISNUM);
 #endif
     }
-    dasm_put(Dst, 15373);
+    dasm_put(Dst, 15558);
     if (!vk) {
-      dasm_put(Dst, 15377, LJ_TISNUM);
+      dasm_put(Dst, 15562, LJ_TISNUM);
     }
     if (sse) {
-      dasm_put(Dst, 15386);
+      dasm_put(Dst, 15571);
       if (vk) {
-	dasm_put(Dst, 15398);
+	dasm_put(Dst, 15583);
       } else {
-	dasm_put(Dst, 15417);
+	dasm_put(Dst, 15602);
       }
-      dasm_put(Dst, 15422);
+      dasm_put(Dst, 15607);
     } else {
-      dasm_put(Dst, 15435);
+      dasm_put(Dst, 15620);
       if (vk) {
-	dasm_put(Dst, 15441);
+	dasm_put(Dst, 15626);
       } else {
-	dasm_put(Dst, 15457);
+	dasm_put(Dst, 15642);
       }
-      dasm_put(Dst, 15465);
+      dasm_put(Dst, 15650);
       if (cmov) {
-      dasm_put(Dst, 10210);
+      dasm_put(Dst, 10392);
       } else {
-      dasm_put(Dst, 10216);
+      dasm_put(Dst, 10398);
       }
       if (!cmov) {
-	dasm_put(Dst, 15470);
+	dasm_put(Dst, 15655);
       }
     }
     if (op == BC_FORI) {
       if (LJ_DUALNUM) {
-	dasm_put(Dst, 15476);
+	dasm_put(Dst, 15661);
       } else {
-	dasm_put(Dst, 15481, -BCBIAS_J*4);
+	dasm_put(Dst, 15666, -BCBIAS_J*4);
       }
     } else if (op == BC_JFORI) {
-      dasm_put(Dst, 15491, -BCBIAS_J*4, BC_JLOOP);
+      dasm_put(Dst, 15676, -BCBIAS_J*4, BC_JLOOP);
     } else if (op == BC_IFORL) {
       if (LJ_DUALNUM) {
-	dasm_put(Dst, 15505);
+	dasm_put(Dst, 15690);
       } else {
-	dasm_put(Dst, 15510, -BCBIAS_J*4);
+	dasm_put(Dst, 15695, -BCBIAS_J*4);
       }
     } else {
-      dasm_put(Dst, 15501, BC_JLOOP);
+      dasm_put(Dst, 15686, BC_JLOOP);
     }
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 10139);
+      dasm_put(Dst, 10321);
     } else {
-      dasm_put(Dst, 10896);
+      dasm_put(Dst, 11081);
     }
     if (sse) {
-      dasm_put(Dst, 15520);
+      dasm_put(Dst, 15705);
     }
     break;
 
   case BC_ITERL:
 #if LJ_HASJIT
-    dasm_put(Dst, 15111, HOTCOUNT_PCMASK, GG_DISP2HOT);
+    dasm_put(Dst, 15296, HOTCOUNT_PCMASK, GG_DISP2HOT, HOTCOUNT_LOOP);
 #endif
     break;
 
@@ -2900,33 +2932,33 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
     break;
 #endif
   case BC_IITERL:
-    dasm_put(Dst, 15531, LJ_TNIL);
+    dasm_put(Dst, 15716, LJ_TNIL);
     if (op == BC_JITERL) {
-      dasm_put(Dst, 15546, BC_JLOOP);
+      dasm_put(Dst, 15731, BC_JLOOP);
     } else {
-      dasm_put(Dst, 15560, -BCBIAS_J*4);
+      dasm_put(Dst, 15745, -BCBIAS_J*4);
     }
-    dasm_put(Dst, 10253);
+    dasm_put(Dst, 10430);
     break;
 
   case BC_LOOP:
 #if LJ_HASJIT
-    dasm_put(Dst, 15111, HOTCOUNT_PCMASK, GG_DISP2HOT);
+    dasm_put(Dst, 15296, HOTCOUNT_PCMASK, GG_DISP2HOT, HOTCOUNT_LOOP);
 #endif
     break;
 
   case BC_ILOOP:
-    dasm_put(Dst, 10255);
+    dasm_put(Dst, 10432);
     break;
 
   case BC_JLOOP:
 #if LJ_HASJIT
-    dasm_put(Dst, 15576, DISPATCH_J(trace), DtD(->mcode), DISPATCH_GL(jit_base), DISPATCH_GL(jit_L), 9*16+4*8, -1*16, -2*16, -3*16, -4*16, -5*16, -6*16, -7*16, -8*16, -9*16);
+    dasm_put(Dst, 15761, DISPATCH_J(trace), DtD(->mcode), DISPATCH_GL(jit_base), DISPATCH_GL(jit_L), 9*16+4*8, -1*16, -2*16, -3*16, -4*16, -5*16, -6*16, -7*16, -8*16, -9*16);
 #endif
     break;
 
   case BC_JMP:
-    dasm_put(Dst, 15685, -BCBIAS_J*4);
+    dasm_put(Dst, 15870, -BCBIAS_J*4);
     break;
 
   /* -- Function headers -------------------------------------------------- */
@@ -2940,7 +2972,7 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
 
   case BC_FUNCF:
 #if LJ_HASJIT
-    dasm_put(Dst, 15710, HOTCOUNT_PCMASK, GG_DISP2HOT);
+    dasm_put(Dst, 15895, HOTCOUNT_PCMASK, GG_DISP2HOT, HOTCOUNT_CALL);
 #endif
   case BC_FUNCV:  /* NYI: compiled vararg functions. */
     break;
@@ -2950,47 +2982,47 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
     break;
 #endif
   case BC_IFUNCF:
-    dasm_put(Dst, 15731, -4+PC2PROTO(k), Dt1(->maxstack), -4+PC2PROTO(numparams));
+    dasm_put(Dst, 15916, -4+PC2PROTO(k), Dt1(->maxstack), -4+PC2PROTO(numparams));
     if (op == BC_JFUNCF) {
-      dasm_put(Dst, 15761, BC_JLOOP);
+      dasm_put(Dst, 15946, BC_JLOOP);
     } else {
-      dasm_put(Dst, 10255);
+      dasm_put(Dst, 10432);
     }
-    dasm_put(Dst, 15770, LJ_TNIL);
+    dasm_put(Dst, 15955, LJ_TNIL);
     break;
 
   case BC_JFUNCV:
 #if !LJ_HASJIT
     break;
 #endif
-    dasm_put(Dst, 9400);
+    dasm_put(Dst, 9409);
     break;  /* NYI: compiled vararg functions. */
 
   case BC_IFUNCV:
-    dasm_put(Dst, 15792, FRAME_VARG, Dt1(->maxstack), -4+PC2PROTO(numparams), LJ_TNIL);
+    dasm_put(Dst, 15977, FRAME_VARG, Dt1(->maxstack), -4+PC2PROTO(numparams), LJ_TNIL);
     if (op == BC_JFUNCV) {
-      dasm_put(Dst, 15761, BC_JLOOP);
+      dasm_put(Dst, 15946, BC_JLOOP);
     } else {
-      dasm_put(Dst, 15883, -4+PC2PROTO(k));
+      dasm_put(Dst, 16068, -4+PC2PROTO(k));
     }
-    dasm_put(Dst, 15906, LJ_TNIL);
+    dasm_put(Dst, 16091, LJ_TNIL);
     break;
 
   case BC_FUNCC:
   case BC_FUNCCW:
-    dasm_put(Dst, 15928, Dt8(->f), Dt1(->base), 8*LUA_MINSTACK, Dt1(->maxstack), Dt1(->top));
+    dasm_put(Dst, 16113, Dt8(->f), Dt1(->base), 8*LUA_MINSTACK, Dt1(->maxstack), Dt1(->top));
     if (op == BC_FUNCC) {
-      dasm_put(Dst, 2372);
+      dasm_put(Dst, 2381);
     } else {
-      dasm_put(Dst, 15958);
+      dasm_put(Dst, 16143);
     }
-    dasm_put(Dst, 15966, DISPATCH_GL(vmstate), ~LJ_VMST_C);
+    dasm_put(Dst, 16151, DISPATCH_GL(vmstate), ~LJ_VMST_C);
     if (op == BC_FUNCC) {
-      dasm_put(Dst, 15975);
+      dasm_put(Dst, 16160);
     } else {
-      dasm_put(Dst, 15979, DISPATCH_GL(wrapf));
+      dasm_put(Dst, 16164, DISPATCH_GL(wrapf));
     }
-    dasm_put(Dst, 15984, DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base), Dt1(->top));
+    dasm_put(Dst, 16169, DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base), Dt1(->top));
     break;
 
   /* ---------------------------------------------------------------------- */
@@ -3018,7 +3050,7 @@ static int build_backend(BuildCtx *ctx)
 
   build_subroutines(ctx, cmov, sse);
 
-  dasm_put(Dst, 16009);
+  dasm_put(Dst, 16194);
   for (op = 0; op < BC__MAX; op++)
     build_ins(ctx, (BCOp)op, op, cmov, sse);
 
@@ -3028,6 +3060,7 @@ static int build_backend(BuildCtx *ctx)
 /* Emit pseudo frame-info for all assembler functions. */
 static void emit_asm_debug(BuildCtx *ctx)
 {
+  int fcofs = (int)((uint8_t *)ctx->glob[GLOB_vm_ffi_call] - ctx->code);
 #if LJ_64
 #define SZPTR	"8"
 #define BSZPTR	"3"
@@ -3061,22 +3094,49 @@ static void emit_asm_debug(BuildCtx *ctx)
 	"\t.long .LEFDE0-.LASFDE0\n"
 	".LASFDE0:\n"
 	"\t.long .Lframe0\n"
-	"\t.long .Lbegin\n"
-	"\t.long %d\n"
-	"\t.byte 0xe\n\t.uleb128 %d\n"		/* def_cfa_offset */
 #if LJ_64
+	"\t.quad .Lbegin\n"
+	"\t.quad %d\n"
+	"\t.byte 0xe\n\t.uleb128 %d\n"		/* def_cfa_offset */
 	"\t.byte 0x86\n\t.uleb128 0x2\n"	/* offset rbp */
 	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset rbx */
 	"\t.byte 0x8f\n\t.uleb128 0x4\n"	/* offset r15 */
 	"\t.byte 0x8e\n\t.uleb128 0x5\n"	/* offset r14 */
 #else
+	"\t.long .Lbegin\n"
+	"\t.long %d\n"
+	"\t.byte 0xe\n\t.uleb128 %d\n"		/* def_cfa_offset */
 	"\t.byte 0x85\n\t.uleb128 0x2\n"	/* offset ebp */
 	"\t.byte 0x87\n\t.uleb128 0x3\n"	/* offset edi */
 	"\t.byte 0x86\n\t.uleb128 0x4\n"	/* offset esi */
 	"\t.byte 0x83\n\t.uleb128 0x5\n"	/* offset ebx */
 #endif
 	"\t.align " SZPTR "\n"
-	".LEFDE0:\n\n", (int)ctx->codesz, CFRAME_SIZE);
+	".LEFDE0:\n\n", fcofs, CFRAME_SIZE);
+#if LJ_HASFFI
+    fprintf(ctx->fp,
+	".LSFDE1:\n"
+	"\t.long .LEFDE1-.LASFDE1\n"
+	".LASFDE1:\n"
+	"\t.long .Lframe0\n"
+#if LJ_64
+	"\t.quad lj_vm_ffi_call\n"
+	"\t.quad %d\n"
+	"\t.byte 0xe\n\t.uleb128 16\n"		/* def_cfa_offset */
+	"\t.byte 0x86\n\t.uleb128 0x2\n"	/* offset rbp */
+	"\t.byte 0xd\n\t.uleb128 0x6\n"		/* def_cfa_register rbp */
+	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset rbx */
+#else
+	"\t.long lj_vm_ffi_call\n"
+	"\t.long %d\n"
+	"\t.byte 0xe\n\t.uleb128 8\n"		/* def_cfa_offset */
+	"\t.byte 0x85\n\t.uleb128 0x2\n"	/* offset ebp */
+	"\t.byte 0xd\n\t.uleb128 0x5\n"		/* def_cfa_register ebp */
+	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset ebx */
+#endif
+	"\t.align " SZPTR "\n"
+	".LEFDE1:\n\n", (int)ctx->codesz - fcofs);
+#endif
 #if (defined(__sun__) && defined(__svr4__)) || defined(__solaris_)
     fprintf(ctx->fp, "\t.section .eh_frame,\"aw\",@progbits\n");
 #else
@@ -3101,10 +3161,10 @@ static void emit_asm_debug(BuildCtx *ctx)
 	"\t.align " SZPTR "\n"
 	".LECIE1:\n\n");
     fprintf(ctx->fp,
-	".LSFDE1:\n"
-	"\t.long .LEFDE1-.LASFDE1\n"
-	".LASFDE1:\n"
-	"\t.long .LASFDE1-.Lframe1\n"
+	".LSFDE2:\n"
+	"\t.long .LEFDE2-.LASFDE2\n"
+	".LASFDE2:\n"
+	"\t.long .LASFDE2-.Lframe1\n"
 	"\t.long .Lbegin-.\n"
 	"\t.long %d\n"
 	"\t.uleb128 0\n"			/* augmentation length */
@@ -3121,7 +3181,46 @@ static void emit_asm_debug(BuildCtx *ctx)
 	"\t.byte 0x83\n\t.uleb128 0x5\n"	/* offset ebx */
 #endif
 	"\t.align " SZPTR "\n"
-	".LEFDE1:\n\n", (int)ctx->codesz, CFRAME_SIZE);
+	".LEFDE2:\n\n", fcofs, CFRAME_SIZE);
+#if LJ_HASFFI
+    fprintf(ctx->fp,
+	".Lframe2:\n"
+	"\t.long .LECIE2-.LSCIE2\n"
+	".LSCIE2:\n"
+	"\t.long 0\n"
+	"\t.byte 0x1\n"
+	"\t.string \"zR\"\n"
+	"\t.uleb128 0x1\n"
+	"\t.sleb128 -" SZPTR "\n"
+	"\t.byte " REG_RA "\n"
+	"\t.uleb128 1\n"			/* augmentation length */
+	"\t.byte 0x1b\n"			/* pcrel|sdata4 */
+	"\t.byte 0xc\n\t.uleb128 " REG_SP "\n\t.uleb128 " SZPTR "\n"
+	"\t.byte 0x80+" REG_RA "\n\t.uleb128 0x1\n"
+	"\t.align " SZPTR "\n"
+	".LECIE2:\n\n");
+    fprintf(ctx->fp,
+	".LSFDE3:\n"
+	"\t.long .LEFDE3-.LASFDE3\n"
+	".LASFDE3:\n"
+	"\t.long .LASFDE3-.Lframe2\n"
+	"\t.long lj_vm_ffi_call-.\n"
+	"\t.long %d\n"
+	"\t.uleb128 0\n"			/* augmentation length */
+#if LJ_64
+	"\t.byte 0xe\n\t.uleb128 16\n"		/* def_cfa_offset */
+	"\t.byte 0x86\n\t.uleb128 0x2\n"	/* offset rbp */
+	"\t.byte 0xd\n\t.uleb128 0x6\n"		/* def_cfa_register rbp */
+	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset rbx */
+#else
+	"\t.byte 0xe\n\t.uleb128 8\n"		/* def_cfa_offset */
+	"\t.byte 0x85\n\t.uleb128 0x2\n"	/* offset ebp */
+	"\t.byte 0xd\n\t.uleb128 0x5\n"		/* def_cfa_register ebp */
+	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset ebx */
+#endif
+	"\t.align " SZPTR "\n"
+	".LEFDE3:\n\n", (int)ctx->codesz - fcofs);
+#endif
     break;
   case BUILD_coffasm:
     fprintf(ctx->fp, "\t.section .eh_frame,\"dr\"\n");
@@ -3172,6 +3271,9 @@ static void emit_asm_debug(BuildCtx *ctx)
   ** Or a linker. Or a plastic case. But I digress.
   */
   case BUILD_machasm: {
+#if LJ_HASFFI
+    int fcsize = 0;
+#endif
     int i;
     fprintf(ctx->fp, "\t.section __TEXT,__eh_frame,coalesced,no_toc+strip_static_syms+live_support\n");
     fprintf(ctx->fp,
@@ -3203,6 +3305,9 @@ static void emit_asm_debug(BuildCtx *ctx)
       const char *name = ctx->sym[i].name;
       int32_t size = ctx->sym[i+1].ofs - ctx->sym[i].ofs;
       if (size == 0) continue;
+#if LJ_HASFFI
+      if (!strcmp(name, "_lj_vm_ffi_call")) { fcsize = size; continue; }
+#endif
       fprintf(ctx->fp,
 	  "%s.eh:\n"
 	  "LSFDE%d:\n"
@@ -3212,23 +3317,72 @@ static void emit_asm_debug(BuildCtx *ctx)
 	  "\t.long LASFDE%d-EH_frame1\n"
 	  "\t.long %s-.\n"
 	  "\t.long %d\n"
-	  "\t.byte 0\n"			/* augmentation length */
+	  "\t.byte 0\n"				/* augmentation length */
 	  "\t.byte 0xe\n\t.byte %d\n"		/* def_cfa_offset */
 #if LJ_64
-	  "\t.byte 0x86\n\t.byte 0x2\n"	/* offset rbp */
-	  "\t.byte 0x83\n\t.byte 0x3\n"	/* offset rbx */
-	  "\t.byte 0x8f\n\t.byte 0x4\n"	/* offset r15 */
-	  "\t.byte 0x8e\n\t.byte 0x5\n"	/* offset r14 */
+	  "\t.byte 0x86\n\t.byte 0x2\n"		/* offset rbp */
+	  "\t.byte 0x83\n\t.byte 0x3\n"		/* offset rbx */
+	  "\t.byte 0x8f\n\t.byte 0x4\n"		/* offset r15 */
+	  "\t.byte 0x8e\n\t.byte 0x5\n"		/* offset r14 */
 #else
-	  "\t.byte 0x84\n\t.byte 0x2\n"	/* offset ebp (4 for MACH-O)*/
-	  "\t.byte 0x87\n\t.byte 0x3\n"	/* offset edi */
-	  "\t.byte 0x86\n\t.byte 0x4\n"	/* offset esi */
-	  "\t.byte 0x83\n\t.byte 0x5\n"	/* offset ebx */
+	  "\t.byte 0x84\n\t.byte 0x2\n"		/* offset ebp (4 for MACH-O)*/
+	  "\t.byte 0x87\n\t.byte 0x3\n"		/* offset edi */
+	  "\t.byte 0x86\n\t.byte 0x4\n"		/* offset esi */
+	  "\t.byte 0x83\n\t.byte 0x5\n"		/* offset ebx */
 #endif
 	  "\t.align " BSZPTR "\n"
 	  "LEFDE%d:\n\n",
 	  name, i, i, i, i, i, i, i, name, size, CFRAME_SIZE, i);
     }
+#if LJ_HASFFI
+    if (fcsize) {
+      fprintf(ctx->fp,
+	  "EH_frame2:\n"
+	  "\t.set L$set$y,LECIEY-LSCIEY\n"
+	  "\t.long L$set$y\n"
+	  "LSCIEY:\n"
+	  "\t.long 0\n"
+	  "\t.byte 0x1\n"
+	  "\t.ascii \"zR\\0\"\n"
+	  "\t.byte 0x1\n"
+	  "\t.byte 128-" SZPTR "\n"
+	  "\t.byte " REG_RA "\n"
+	  "\t.byte 1\n"				/* augmentation length */
+#if LJ_64
+	  "\t.byte 0x1b\n"			/* pcrel|sdata4 */
+	  "\t.byte 0xc\n\t.byte " REG_SP "\n\t.byte " SZPTR "\n"
+#else
+	  "\t.byte 0x1b\n"			/* pcrel|sdata4 */
+	  "\t.byte 0xc\n\t.byte 0x5\n\t.byte 0x4\n"  /* esp=5 on 32 bit MACH. */
+#endif
+	  "\t.byte 0x80+" REG_RA "\n\t.byte 0x1\n"
+	  "\t.align " BSZPTR "\n"
+	  "LECIEY:\n\n");
+      fprintf(ctx->fp,
+	  "_lj_vm_ffi_call.eh:\n"
+	  "LSFDEY:\n"
+	  "\t.set L$set$yy,LEFDEY-LASFDEY\n"
+	  "\t.long L$set$yy\n"
+	  "LASFDEY:\n"
+	  "\t.long LASFDEY-EH_frame2\n"
+	  "\t.long _lj_vm_ffi_call-.\n"
+	  "\t.long %d\n"
+	  "\t.byte 0\n"				/* augmentation length */
+#if LJ_64
+	  "\t.byte 0xe\n\t.byte 16\n"		/* def_cfa_offset */
+	  "\t.byte 0x86\n\t.byte 0x2\n"		/* offset rbp */
+	  "\t.byte 0xd\n\t.uleb128 0x6\n"	/* def_cfa_register rbp */
+	  "\t.byte 0x83\n\t.byte 0x3\n"		/* offset rbx */
+#else
+	  "\t.byte 0xe\n\t.byte 8\n"		/* def_cfa_offset */
+	  "\t.byte 0x84\n\t.byte 0x2\n"		/* offset ebp (4 for MACH-O)*/
+	  "\t.byte 0xd\n\t.uleb128 0x4\n"	/* def_cfa_register ebp */
+	  "\t.byte 0x83\n\t.byte 0x3\n"		/* offset ebx */
+#endif
+	  "\t.align " BSZPTR "\n"
+	  "LEFDEY:\n\n", fcsize);
+    }
+#endif
 #if LJ_64
     fprintf(ctx->fp, "\t.subsections_via_symbols\n");
 #else
diff --git a/third_party/luajit/src/buildvm_x86.dasc b/third_party/luajit/src/buildvm_x86.dasc
index effd0737918e26ab7dff2bf74107e23080b6b47b..d6dfde88a7b908d7aa09606a4ccc08d8ce970397 100644
--- a/third_party/luajit/src/buildvm_x86.dasc
+++ b/third_party/luajit/src/buildvm_x86.dasc
@@ -114,10 +114,13 @@
 |.if not X64		// x86 stack layout.
 |
 |.define CFRAME_SPACE,	aword*7			// Delta for esp (see <--).
-|.macro saveregs
-|  push ebp; push edi; push esi; push ebx
+|.macro saveregs_
+|  push edi; push esi; push ebx
 |  sub esp, CFRAME_SPACE
 |.endmacro
+|.macro saveregs
+|  push ebp; saveregs_
+|.endmacro
 |.macro restoreregs
 |  add esp, CFRAME_SPACE
 |  pop ebx; pop esi; pop edi; pop ebp
@@ -166,10 +169,13 @@
 |.elif X64WIN		// x64/Windows stack layout
 |
 |.define CFRAME_SPACE,	aword*5			// Delta for rsp (see <--).
-|.macro saveregs
-|  push rbp; push rdi; push rsi; push rbx
+|.macro saveregs_
+|  push rdi; push rsi; push rbx
 |  sub rsp, CFRAME_SPACE
 |.endmacro
+|.macro saveregs
+|  push rbp; saveregs_
+|.endmacro
 |.macro restoreregs
 |  add rsp, CFRAME_SPACE
 |  pop rbx; pop rsi; pop rdi; pop rbp
@@ -206,10 +212,13 @@
 |.else			// x64/POSIX stack layout
 |
 |.define CFRAME_SPACE,	aword*5			// Delta for rsp (see <--).
-|.macro saveregs
-|  push rbp; push rbx; push r15; push r14
+|.macro saveregs_
+|  push rbx; push r15; push r14
 |  sub rsp, CFRAME_SPACE
 |.endmacro
+|.macro saveregs
+|  push rbp; saveregs_
+|.endmacro
 |.macro restoreregs
 |  add rsp, CFRAME_SPACE
 |  pop r14; pop r15; pop rbx; pop rbp
@@ -333,16 +342,16 @@
 |  mov reg, PC
 |  shr reg, 1
 |  and reg, HOTCOUNT_PCMASK
-|  sub word [DISPATCH+reg+GG_DISP2HOT], 1
-|  jz ->vm_hotloop
+|  sub word [DISPATCH+reg+GG_DISP2HOT], HOTCOUNT_LOOP
+|  jb ->vm_hotloop
 |.endmacro
 |
 |.macro hotcall, reg
 |  mov reg, PC
 |  shr reg, 1
 |  and reg, HOTCOUNT_PCMASK
-|  sub word [DISPATCH+reg+GG_DISP2HOT], 1
-|  jz ->vm_hotcall
+|  sub word [DISPATCH+reg+GG_DISP2HOT], HOTCOUNT_CALL
+|  jb ->vm_hotcall
 |.endmacro
 |
 |// Set current VM state.
@@ -760,14 +769,18 @@ static void build_subroutines(BuildCtx *ctx, int cmov, int sse)
   |  mov PC, [RB-12]			// Restore PC from [cont|PC].
   |.if X64
   |  movsxd RAa, dword [RB-16]		// May be negative on WIN64 with debug.
-  |  test RA, RA
-  |  jz >1
+#if LJ_HASFFI
+  |  cmp RA, 1
+  |  jbe >1
+#endif
   |  lea KBASEa, qword [=>0]
   |  add RAa, KBASEa
   |.else
   |  mov RA, dword [RB-16]
-  |  test RA, RA
-  |  jz >1
+#if LJ_HASFFI
+  |  cmp RA, 1
+  |  jbe >1
+#endif
   |.endif
   |  mov LFUNC:KBASE, [BASE-8]
   |  mov KBASE, LFUNC:KBASE->pc
@@ -775,11 +788,15 @@ static void build_subroutines(BuildCtx *ctx, int cmov, int sse)
   |  // BASE = base, RC = result, RB = meta base
   |  jmp RAa				// Jump to continuation.
   |
-  |1:  // Tail call from C function.
+#if LJ_HASFFI
+  |1:
+  |  je ->cont_ffi_callback		// cont = 1: return from FFI callback.
+  |  // cont = 0: Tail call from C function.
   |  sub RB, BASE
   |  shr RB, 3
   |  lea RD, [RB-1]
   |  jmp ->vm_call_tail
+#endif
   |
   |->cont_cat:				// BASE = base, RC = result, RB = mbase
   |  movzx RA, PC_RB
@@ -3687,10 +3704,118 @@ static void build_subroutines(BuildCtx *ctx, int cmov, int sse)
   |.endif
   |
   |//-----------------------------------------------------------------------
+  |//-- Assertions ---------------------------------------------------------
+  |//-----------------------------------------------------------------------
+  |
+  |->assert_bad_for_arg_type:
+#ifdef LUA_USE_ASSERT
+  |  int3
+#endif
+  |  int3
+  |
+  |//-----------------------------------------------------------------------
   |//-- FFI helper functions -----------------------------------------------
   |//-----------------------------------------------------------------------
   |
-  |->vm_ffi_call@4:
+  |// Handler for callback functions. Callback slot number in ah/al.
+  |->vm_ffi_callback:
+#if LJ_HASFFI
+  |.type CTSTATE, CTState, PC
+  |.if not X64
+  |  sub esp, 16			// Leave room for SAVE_ERRF etc.
+  |.endif
+  |  saveregs_	// ebp/rbp already saved. ebp now holds global_State *.
+  |  lea DISPATCH, [ebp+GG_G2DISP]
+  |  mov CTSTATE, GL:ebp->ctype_state
+  |  movzx eax, ax
+  |  mov CTSTATE->cb.slot, eax
+  |.if X64
+  |  mov CTSTATE->cb.gpr[0], CARG1
+  |  mov CTSTATE->cb.gpr[1], CARG2
+  |  mov CTSTATE->cb.gpr[2], CARG3
+  |  mov CTSTATE->cb.gpr[3], CARG4
+  |  movsd qword CTSTATE->cb.fpr[0], xmm0
+  |  movsd qword CTSTATE->cb.fpr[1], xmm1
+  |  movsd qword CTSTATE->cb.fpr[2], xmm2
+  |  movsd qword CTSTATE->cb.fpr[3], xmm3
+  |.if X64WIN
+  |  lea rax, [rsp+CFRAME_SIZE+4*8]
+  |.else
+  |  lea rax, [rsp+CFRAME_SIZE]
+  |  mov CTSTATE->cb.gpr[4], CARG5
+  |  mov CTSTATE->cb.gpr[5], CARG6
+  |  movsd qword CTSTATE->cb.fpr[4], xmm4
+  |  movsd qword CTSTATE->cb.fpr[5], xmm5
+  |  movsd qword CTSTATE->cb.fpr[6], xmm6
+  |  movsd qword CTSTATE->cb.fpr[7], xmm7
+  |.endif
+  |  mov CTSTATE->cb.stack, rax
+  |  mov CARG2, rsp
+  |.else
+  |  lea eax, [esp+CFRAME_SIZE+16]
+  |  mov CTSTATE->cb.gpr[0], FCARG1
+  |  mov CTSTATE->cb.gpr[1], FCARG2
+  |  mov CTSTATE->cb.stack, eax
+  |  mov FCARG1, [esp+CFRAME_SIZE+12]	// Move around misplaced retaddr/ebp.
+  |  mov FCARG2, [esp+CFRAME_SIZE+8]
+  |  mov SAVE_RET, FCARG1
+  |  mov SAVE_R4, FCARG2
+  |  mov FCARG2, esp
+  |.endif
+  |  mov SAVE_PC, CTSTATE		// Any value outside of bytecode is ok.
+  |  mov FCARG1, CTSTATE
+  |  call extern lj_ccallback_enter@8	// (CTState *cts, void *cf)
+  |  // lua_State * returned in eax (RD).
+  |  set_vmstate INTERP
+  |  mov BASE, L:RD->base
+  |  mov RD, L:RD->top
+  |  sub RD, BASE
+  |  mov LFUNC:RB, [BASE-8]
+  |  shr RD, 3
+  |  add RD, 1
+  |  ins_callt
+#endif
+  |
+  |->cont_ffi_callback:			// Return from FFI callback.
+#if LJ_HASFFI
+  |  mov L:RA, SAVE_L
+  |  mov CTSTATE, [DISPATCH+DISPATCH_GL(ctype_state)]
+  |  mov aword CTSTATE->L, L:RAa
+  |  mov L:RA->base, BASE
+  |  mov L:RA->top, RB
+  |  mov FCARG1, CTSTATE
+  |  mov FCARG2, RC
+  |  call extern lj_ccallback_leave@8	// (CTState *cts, TValue *o)
+  |.if X64
+  |  mov rax, CTSTATE->cb.gpr[0]
+  |  movsd xmm0, qword CTSTATE->cb.fpr[0]
+  |  jmp ->vm_leave_unw
+  |.else
+  |  mov L:RB, SAVE_L
+  |  mov eax, CTSTATE->cb.gpr[0]
+  |  mov edx, CTSTATE->cb.gpr[1]
+  |  cmp dword CTSTATE->cb.gpr[2], 1
+  |  jb >7
+  |  je >6
+  |  fld qword CTSTATE->cb.fpr[0].d
+  |  jmp >7
+  |6:
+  |  fld dword CTSTATE->cb.fpr[0].f
+  |7:
+  |  mov ecx, L:RB->top
+  |  movzx ecx, word [ecx+6]		// Get stack adjustment and copy up.
+  |  mov SAVE_L, ecx			// Must be one slot above SAVE_RET
+  |  restoreregs
+  |  pop ecx				// Move return addr from SAVE_RET.
+  |  add esp, [esp]			// Adjust stack.
+  |  add esp, 16
+  |  push ecx
+  |  ret
+  |.endif
+#endif
+  |
+  |->vm_ffi_call@4:			// Call C function via FFI.
+  |  // Caveat: needs special frame unwinding, see below.
 #if LJ_HASFFI
   |.if X64
   |  .type CCSTATE, CCallState, rbx
@@ -3786,16 +3911,7 @@ static void build_subroutines(BuildCtx *ctx, int cmov, int sse)
   |  mov ebx, [ebp-4]; leave; ret
   |.endif
 #endif
-  |
-  |//-----------------------------------------------------------------------
-  |//-- Assertions ---------------------------------------------------------
-  |//-----------------------------------------------------------------------
-  |
-  |->assert_bad_for_arg_type:
-#ifdef LUA_USE_ASSERT
-  |  int3
-#endif
-  |  int3
+  |// Note: vm_ffi_call must be the last function in this object file!
   |
   |//-----------------------------------------------------------------------
 }
@@ -4022,6 +4138,10 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
       |  je <1				// Same GCobjs or pvalues?
       |  cmp RB, LJ_TISTABUD
       |  ja <2				// Different objects and not table/ud?
+      |.if X64
+      |  cmp RB, LJ_TUDATA		// And not 64 bit lightuserdata.
+      |  jb <2
+      |.endif
       |
       |  // Different tables or userdatas. Need to check __eq metamethod.
       |  // Field metatable must be at same offset for GCtab and GCudata!
@@ -5997,6 +6117,7 @@ static int build_backend(BuildCtx *ctx)
 /* Emit pseudo frame-info for all assembler functions. */
 static void emit_asm_debug(BuildCtx *ctx)
 {
+  int fcofs = (int)((uint8_t *)ctx->glob[GLOB_vm_ffi_call] - ctx->code);
 #if LJ_64
 #define SZPTR	"8"
 #define BSZPTR	"3"
@@ -6030,22 +6151,49 @@ static void emit_asm_debug(BuildCtx *ctx)
 	"\t.long .LEFDE0-.LASFDE0\n"
 	".LASFDE0:\n"
 	"\t.long .Lframe0\n"
-	"\t.long .Lbegin\n"
-	"\t.long %d\n"
-	"\t.byte 0xe\n\t.uleb128 %d\n"		/* def_cfa_offset */
 #if LJ_64
+	"\t.quad .Lbegin\n"
+	"\t.quad %d\n"
+	"\t.byte 0xe\n\t.uleb128 %d\n"		/* def_cfa_offset */
 	"\t.byte 0x86\n\t.uleb128 0x2\n"	/* offset rbp */
 	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset rbx */
 	"\t.byte 0x8f\n\t.uleb128 0x4\n"	/* offset r15 */
 	"\t.byte 0x8e\n\t.uleb128 0x5\n"	/* offset r14 */
 #else
+	"\t.long .Lbegin\n"
+	"\t.long %d\n"
+	"\t.byte 0xe\n\t.uleb128 %d\n"		/* def_cfa_offset */
 	"\t.byte 0x85\n\t.uleb128 0x2\n"	/* offset ebp */
 	"\t.byte 0x87\n\t.uleb128 0x3\n"	/* offset edi */
 	"\t.byte 0x86\n\t.uleb128 0x4\n"	/* offset esi */
 	"\t.byte 0x83\n\t.uleb128 0x5\n"	/* offset ebx */
 #endif
 	"\t.align " SZPTR "\n"
-	".LEFDE0:\n\n", (int)ctx->codesz, CFRAME_SIZE);
+	".LEFDE0:\n\n", fcofs, CFRAME_SIZE);
+#if LJ_HASFFI
+    fprintf(ctx->fp,
+	".LSFDE1:\n"
+	"\t.long .LEFDE1-.LASFDE1\n"
+	".LASFDE1:\n"
+	"\t.long .Lframe0\n"
+#if LJ_64
+	"\t.quad lj_vm_ffi_call\n"
+	"\t.quad %d\n"
+	"\t.byte 0xe\n\t.uleb128 16\n"		/* def_cfa_offset */
+	"\t.byte 0x86\n\t.uleb128 0x2\n"	/* offset rbp */
+	"\t.byte 0xd\n\t.uleb128 0x6\n"		/* def_cfa_register rbp */
+	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset rbx */
+#else
+	"\t.long lj_vm_ffi_call\n"
+	"\t.long %d\n"
+	"\t.byte 0xe\n\t.uleb128 8\n"		/* def_cfa_offset */
+	"\t.byte 0x85\n\t.uleb128 0x2\n"	/* offset ebp */
+	"\t.byte 0xd\n\t.uleb128 0x5\n"		/* def_cfa_register ebp */
+	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset ebx */
+#endif
+	"\t.align " SZPTR "\n"
+	".LEFDE1:\n\n", (int)ctx->codesz - fcofs);
+#endif
 #if (defined(__sun__) && defined(__svr4__)) || defined(__solaris_)
     fprintf(ctx->fp, "\t.section .eh_frame,\"aw\",@progbits\n");
 #else
@@ -6070,10 +6218,10 @@ static void emit_asm_debug(BuildCtx *ctx)
 	"\t.align " SZPTR "\n"
 	".LECIE1:\n\n");
     fprintf(ctx->fp,
-	".LSFDE1:\n"
-	"\t.long .LEFDE1-.LASFDE1\n"
-	".LASFDE1:\n"
-	"\t.long .LASFDE1-.Lframe1\n"
+	".LSFDE2:\n"
+	"\t.long .LEFDE2-.LASFDE2\n"
+	".LASFDE2:\n"
+	"\t.long .LASFDE2-.Lframe1\n"
 	"\t.long .Lbegin-.\n"
 	"\t.long %d\n"
 	"\t.uleb128 0\n"			/* augmentation length */
@@ -6090,7 +6238,46 @@ static void emit_asm_debug(BuildCtx *ctx)
 	"\t.byte 0x83\n\t.uleb128 0x5\n"	/* offset ebx */
 #endif
 	"\t.align " SZPTR "\n"
-	".LEFDE1:\n\n", (int)ctx->codesz, CFRAME_SIZE);
+	".LEFDE2:\n\n", fcofs, CFRAME_SIZE);
+#if LJ_HASFFI
+    fprintf(ctx->fp,
+	".Lframe2:\n"
+	"\t.long .LECIE2-.LSCIE2\n"
+	".LSCIE2:\n"
+	"\t.long 0\n"
+	"\t.byte 0x1\n"
+	"\t.string \"zR\"\n"
+	"\t.uleb128 0x1\n"
+	"\t.sleb128 -" SZPTR "\n"
+	"\t.byte " REG_RA "\n"
+	"\t.uleb128 1\n"			/* augmentation length */
+	"\t.byte 0x1b\n"			/* pcrel|sdata4 */
+	"\t.byte 0xc\n\t.uleb128 " REG_SP "\n\t.uleb128 " SZPTR "\n"
+	"\t.byte 0x80+" REG_RA "\n\t.uleb128 0x1\n"
+	"\t.align " SZPTR "\n"
+	".LECIE2:\n\n");
+    fprintf(ctx->fp,
+	".LSFDE3:\n"
+	"\t.long .LEFDE3-.LASFDE3\n"
+	".LASFDE3:\n"
+	"\t.long .LASFDE3-.Lframe2\n"
+	"\t.long lj_vm_ffi_call-.\n"
+	"\t.long %d\n"
+	"\t.uleb128 0\n"			/* augmentation length */
+#if LJ_64
+	"\t.byte 0xe\n\t.uleb128 16\n"		/* def_cfa_offset */
+	"\t.byte 0x86\n\t.uleb128 0x2\n"	/* offset rbp */
+	"\t.byte 0xd\n\t.uleb128 0x6\n"		/* def_cfa_register rbp */
+	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset rbx */
+#else
+	"\t.byte 0xe\n\t.uleb128 8\n"		/* def_cfa_offset */
+	"\t.byte 0x85\n\t.uleb128 0x2\n"	/* offset ebp */
+	"\t.byte 0xd\n\t.uleb128 0x5\n"		/* def_cfa_register ebp */
+	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset ebx */
+#endif
+	"\t.align " SZPTR "\n"
+	".LEFDE3:\n\n", (int)ctx->codesz - fcofs);
+#endif
     break;
   case BUILD_coffasm:
     fprintf(ctx->fp, "\t.section .eh_frame,\"dr\"\n");
@@ -6141,6 +6328,9 @@ static void emit_asm_debug(BuildCtx *ctx)
   ** Or a linker. Or a plastic case. But I digress.
   */
   case BUILD_machasm: {
+#if LJ_HASFFI
+    int fcsize = 0;
+#endif
     int i;
     fprintf(ctx->fp, "\t.section __TEXT,__eh_frame,coalesced,no_toc+strip_static_syms+live_support\n");
     fprintf(ctx->fp,
@@ -6172,6 +6362,9 @@ static void emit_asm_debug(BuildCtx *ctx)
       const char *name = ctx->sym[i].name;
       int32_t size = ctx->sym[i+1].ofs - ctx->sym[i].ofs;
       if (size == 0) continue;
+#if LJ_HASFFI
+      if (!strcmp(name, "_lj_vm_ffi_call")) { fcsize = size; continue; }
+#endif
       fprintf(ctx->fp,
 	  "%s.eh:\n"
 	  "LSFDE%d:\n"
@@ -6181,23 +6374,72 @@ static void emit_asm_debug(BuildCtx *ctx)
 	  "\t.long LASFDE%d-EH_frame1\n"
 	  "\t.long %s-.\n"
 	  "\t.long %d\n"
-	  "\t.byte 0\n"			/* augmentation length */
+	  "\t.byte 0\n"				/* augmentation length */
 	  "\t.byte 0xe\n\t.byte %d\n"		/* def_cfa_offset */
 #if LJ_64
-	  "\t.byte 0x86\n\t.byte 0x2\n"	/* offset rbp */
-	  "\t.byte 0x83\n\t.byte 0x3\n"	/* offset rbx */
-	  "\t.byte 0x8f\n\t.byte 0x4\n"	/* offset r15 */
-	  "\t.byte 0x8e\n\t.byte 0x5\n"	/* offset r14 */
+	  "\t.byte 0x86\n\t.byte 0x2\n"		/* offset rbp */
+	  "\t.byte 0x83\n\t.byte 0x3\n"		/* offset rbx */
+	  "\t.byte 0x8f\n\t.byte 0x4\n"		/* offset r15 */
+	  "\t.byte 0x8e\n\t.byte 0x5\n"		/* offset r14 */
 #else
-	  "\t.byte 0x84\n\t.byte 0x2\n"	/* offset ebp (4 for MACH-O)*/
-	  "\t.byte 0x87\n\t.byte 0x3\n"	/* offset edi */
-	  "\t.byte 0x86\n\t.byte 0x4\n"	/* offset esi */
-	  "\t.byte 0x83\n\t.byte 0x5\n"	/* offset ebx */
+	  "\t.byte 0x84\n\t.byte 0x2\n"		/* offset ebp (4 for MACH-O)*/
+	  "\t.byte 0x87\n\t.byte 0x3\n"		/* offset edi */
+	  "\t.byte 0x86\n\t.byte 0x4\n"		/* offset esi */
+	  "\t.byte 0x83\n\t.byte 0x5\n"		/* offset ebx */
 #endif
 	  "\t.align " BSZPTR "\n"
 	  "LEFDE%d:\n\n",
 	  name, i, i, i, i, i, i, i, name, size, CFRAME_SIZE, i);
     }
+#if LJ_HASFFI
+    if (fcsize) {
+      fprintf(ctx->fp,
+	  "EH_frame2:\n"
+	  "\t.set L$set$y,LECIEY-LSCIEY\n"
+	  "\t.long L$set$y\n"
+	  "LSCIEY:\n"
+	  "\t.long 0\n"
+	  "\t.byte 0x1\n"
+	  "\t.ascii \"zR\\0\"\n"
+	  "\t.byte 0x1\n"
+	  "\t.byte 128-" SZPTR "\n"
+	  "\t.byte " REG_RA "\n"
+	  "\t.byte 1\n"				/* augmentation length */
+#if LJ_64
+	  "\t.byte 0x1b\n"			/* pcrel|sdata4 */
+	  "\t.byte 0xc\n\t.byte " REG_SP "\n\t.byte " SZPTR "\n"
+#else
+	  "\t.byte 0x1b\n"			/* pcrel|sdata4 */
+	  "\t.byte 0xc\n\t.byte 0x5\n\t.byte 0x4\n"  /* esp=5 on 32 bit MACH. */
+#endif
+	  "\t.byte 0x80+" REG_RA "\n\t.byte 0x1\n"
+	  "\t.align " BSZPTR "\n"
+	  "LECIEY:\n\n");
+      fprintf(ctx->fp,
+	  "_lj_vm_ffi_call.eh:\n"
+	  "LSFDEY:\n"
+	  "\t.set L$set$yy,LEFDEY-LASFDEY\n"
+	  "\t.long L$set$yy\n"
+	  "LASFDEY:\n"
+	  "\t.long LASFDEY-EH_frame2\n"
+	  "\t.long _lj_vm_ffi_call-.\n"
+	  "\t.long %d\n"
+	  "\t.byte 0\n"				/* augmentation length */
+#if LJ_64
+	  "\t.byte 0xe\n\t.byte 16\n"		/* def_cfa_offset */
+	  "\t.byte 0x86\n\t.byte 0x2\n"		/* offset rbp */
+	  "\t.byte 0xd\n\t.uleb128 0x6\n"	/* def_cfa_register rbp */
+	  "\t.byte 0x83\n\t.byte 0x3\n"		/* offset rbx */
+#else
+	  "\t.byte 0xe\n\t.byte 8\n"		/* def_cfa_offset */
+	  "\t.byte 0x84\n\t.byte 0x2\n"		/* offset ebp (4 for MACH-O)*/
+	  "\t.byte 0xd\n\t.uleb128 0x4\n"	/* def_cfa_register ebp */
+	  "\t.byte 0x83\n\t.byte 0x3\n"		/* offset ebx */
+#endif
+	  "\t.align " BSZPTR "\n"
+	  "LEFDEY:\n\n", fcsize);
+    }
+#endif
 #if LJ_64
     fprintf(ctx->fp, "\t.subsections_via_symbols\n");
 #else
diff --git a/third_party/luajit/src/buildvm_x86.h b/third_party/luajit/src/buildvm_x86.h
index 7adb2637e52e6937a4a36537b5b9c48d9809b846..cd33cf877caca672b2856e1c51e22cb5b8431aad 100644
--- a/third_party/luajit/src/buildvm_x86.h
+++ b/third_party/luajit/src/buildvm_x86.h
@@ -12,7 +12,7 @@
 #define DASM_SECTION_CODE_OP	0
 #define DASM_SECTION_CODE_SUB	1
 #define DASM_MAXSECTION		2
-static const unsigned char build_actionlist[17111] = {
+static const unsigned char build_actionlist[17321] = {
   254,1,248,10,252,247,198,237,15,132,244,11,131,230,252,248,41,252,242,141,
   76,49,252,248,139,114,252,252,199,68,10,4,237,248,12,131,192,1,137,68,36,
   20,252,247,198,237,15,132,244,13,248,14,129,252,246,239,252,247,198,237,15,
@@ -49,795 +49,806 @@ static const unsigned char build_actionlist[17111] = {
   56,137,68,36,8,137,76,36,4,137,44,36,139,189,233,137,124,36,52,137,165,233,
   252,255,210,133,192,15,132,244,15,137,193,190,237,252,233,244,2,248,11,1,
   209,131,230,252,248,137,213,41,252,242,199,68,193,252,252,237,137,200,139,
-  117,252,244,139,77,252,240,133,201,15,132,244,247,255,139,122,252,248,139,
-  191,233,139,191,233,252,255,225,248,1,41,213,193,252,237,3,141,69,252,255,
-  252,233,244,32,248,33,15,182,78,252,255,131,252,237,16,141,12,202,41,252,
-  233,15,132,244,34,252,247,217,193,252,233,3,137,76,36,8,139,72,4,139,0,137,
-  77,4,137,69,0,137,108,36,4,252,233,244,35,248,36,137,68,36,16,199,68,36,20,
-  237,141,68,36,16,128,126,252,252,235,15,133,244,247,141,139,233,137,41,199,
-  65,4,237,137,205,252,233,244,248,248,37,255,15,182,70,252,254,255,199,68,
-  36,20,237,137,68,36,16,255,252,242,15,42,192,252,242,15,17,68,36,16,255,137,
-  68,36,12,219,68,36,12,221,92,36,16,255,141,68,36,16,252,233,244,247,248,38,
-  15,182,70,252,254,141,4,194,248,1,15,182,110,252,255,141,44,252,234,248,2,
-  137,108,36,4,139,108,36,48,137,68,36,8,137,44,36,137,149,233,137,116,36,24,
-  232,251,1,1,139,149,233,133,192,15,132,244,249,248,34,15,182,78,252,253,139,
-  104,4,139,0,137,108,202,4,137,4,202,139,6,15,182,204,15,182,232,131,198,4,
-  193,232,16,252,255,36,171,248,3,139,141,233,137,113,252,244,141,177,233,41,
-  214,139,105,252,248,184,237,252,233,244,30,248,39,137,68,36,16,199,68,36,
-  20,237,141,68,36,16,128,126,252,252,235,15,133,244,247,255,141,139,233,137,
-  41,199,65,4,237,137,205,252,233,244,248,248,40,15,182,70,252,254,255,141,
-  68,36,16,252,233,244,247,248,41,15,182,70,252,254,141,4,194,248,1,15,182,
+  117,252,244,255,139,77,252,240,255,131,252,249,1,15,134,244,247,255,139,122,
+  252,248,139,191,233,139,191,233,252,255,225,255,248,1,15,132,244,32,41,213,
+  193,252,237,3,141,69,252,255,252,233,244,33,255,248,34,15,182,78,252,255,
+  131,252,237,16,141,12,202,41,252,233,15,132,244,35,252,247,217,193,252,233,
+  3,137,76,36,8,139,72,4,139,0,137,77,4,137,69,0,137,108,36,4,252,233,244,36,
+  248,37,137,68,36,16,199,68,36,20,237,141,68,36,16,128,126,252,252,235,15,
+  133,244,247,141,139,233,137,41,199,65,4,237,137,205,252,233,244,248,248,38,
+  15,182,70,252,254,255,199,68,36,20,237,137,68,36,16,255,252,242,15,42,192,
+  252,242,15,17,68,36,16,255,137,68,36,12,219,68,36,12,221,92,36,16,255,141,
+  68,36,16,252,233,244,247,248,39,15,182,70,252,254,141,4,194,248,1,15,182,
   110,252,255,141,44,252,234,248,2,137,108,36,4,139,108,36,48,137,68,36,8,137,
-  44,36,137,149,233,137,116,36,24,232,251,1,2,139,149,233,133,192,15,132,244,
-  249,15,182,78,252,253,139,108,202,4,139,12,202,137,104,4,137,8,248,42,139,
+  44,36,137,149,233,137,116,36,24,232,251,1,1,139,149,233,133,192,15,132,244,
+  249,248,35,15,182,78,252,253,139,104,4,139,0,137,108,202,4,137,4,202,139,
   6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,3,139,141,
-  233,137,113,252,244,15,182,70,252,253,139,108,194,4,139,4,194,137,105,20,
-  137,65,16,141,177,233,41,214,139,105,252,248,184,237,252,233,244,30,248,43,
-  15,182,110,252,252,141,4,194,141,12,202,137,108,36,12,139,108,36,48,137,68,
-  36,8,137,76,36,4,137,44,36,137,149,233,137,116,36,24,232,251,1,3,248,3,139,
-  149,233,255,131,252,248,1,15,135,244,44,248,4,141,118,4,15,130,244,252,248,
-  5,15,183,70,252,254,141,180,253,134,233,248,6,139,6,15,182,204,15,182,232,
-  131,198,4,193,232,16,252,255,36,171,248,45,131,198,4,129,120,253,4,239,15,
-  130,244,5,252,233,244,6,248,46,129,120,253,4,239,252,233,244,4,248,47,131,
-  252,238,4,137,108,36,12,139,108,36,48,137,68,36,8,137,76,36,4,137,44,36,137,
-  149,233,255,137,116,36,24,232,251,1,4,252,233,244,3,248,48,255,131,252,238,
-  4,139,108,36,48,137,149,233,137,252,233,139,86,252,252,137,116,36,24,232,
-  251,1,5,252,233,244,3,255,248,49,255,15,182,110,252,255,255,248,50,141,4,
-  199,252,233,244,247,248,51,255,248,52,141,4,199,141,44,252,234,149,252,233,
-  244,248,248,53,141,4,194,137,197,252,233,244,248,248,54,255,248,55,141,4,
-  194,248,1,141,44,252,234,248,2,141,12,202,137,108,36,8,139,108,36,48,137,
-  68,36,12,15,182,70,252,252,137,76,36,4,137,68,36,16,137,44,36,137,149,233,
-  137,116,36,24,232,251,1,6,139,149,233,133,192,15,132,244,42,248,44,137,193,
-  41,208,137,113,252,244,141,176,233,184,237,252,233,244,28,248,56,139,108,
-  36,48,137,149,233,141,20,194,137,252,233,137,116,36,24,232,251,1,7,139,149,
-  233,255,133,192,15,133,244,44,15,183,70,252,254,139,12,194,252,233,244,57,
-  255,252,233,244,44,255,248,58,141,76,202,8,248,29,137,76,36,20,137,68,36,
-  16,131,252,233,8,141,4,193,139,108,36,48,137,76,36,4,137,68,36,8,137,44,36,
-  137,149,233,137,116,36,24,232,251,1,8,139,149,233,139,76,36,20,139,68,36,
-  16,139,105,252,248,131,192,1,57,215,15,132,244,59,137,202,137,114,252,252,
-  139,181,233,139,14,15,182,252,233,15,182,205,131,198,4,252,255,36,171,248,
-  60,139,108,36,48,137,149,233,137,202,137,252,233,137,116,36,24,232,251,1,
-  9,139,149,233,139,70,252,252,15,182,204,15,182,232,193,232,16,252,255,164,
-  253,171,233,248,61,129,252,248,239,15,130,244,62,139,106,4,129,252,253,239,
-  15,131,244,62,139,114,252,252,137,68,36,20,137,106,252,252,139,42,137,106,
-  252,248,131,232,2,15,132,244,248,255,137,209,248,1,131,193,8,139,105,4,137,
-  105,252,252,139,41,137,105,252,248,131,232,1,15,133,244,1,248,2,139,68,36,
-  20,252,233,244,63,248,64,129,252,248,239,15,130,244,62,139,106,4,184,237,
-  252,247,213,57,232,255,15,71,197,255,15,134,244,247,137,232,248,1,255,248,
-  2,139,106,252,248,139,132,253,197,233,139,114,252,252,199,66,252,252,237,
-  137,66,252,248,252,233,244,65,248,66,129,252,248,239,15,130,244,62,139,106,
-  4,139,114,252,252,129,252,253,239,15,133,244,252,248,1,139,42,139,173,233,
-  248,2,133,252,237,199,66,252,252,237,15,132,244,65,139,131,233,199,66,252,
-  252,237,255,137,106,252,248,139,141,233,35,136,233,105,201,239,3,141,233,
-  248,3,129,185,233,239,15,133,244,250,57,129,233,15,132,244,251,248,4,139,
-  137,233,133,201,15,133,244,3,252,233,244,65,248,5,139,105,4,129,252,253,239,
-  255,15,132,244,65,139,1,137,106,252,252,137,66,252,248,252,233,244,65,248,
-  6,129,252,253,239,15,132,244,1,129,252,253,239,15,135,244,254,189,237,248,
-  8,252,247,213,139,172,253,171,233,252,233,244,2,248,67,129,252,248,239,15,
-  130,244,62,255,129,122,253,4,239,15,133,244,62,139,42,131,189,233,0,15,133,
-  244,62,129,122,253,12,239,15,133,244,62,139,66,8,137,133,233,139,114,252,
-  252,199,66,252,252,237,137,106,252,248,252,246,133,233,235,15,132,244,247,
-  128,165,233,235,139,131,233,137,171,233,137,133,233,248,1,255,252,233,244,
-  65,248,68,129,252,248,239,15,130,244,62,129,122,253,4,239,15,133,244,62,139,
-  2,139,108,36,48,137,68,36,4,137,44,36,137,213,131,194,8,137,84,36,8,232,251,
-  1,10,137,252,234,139,40,139,64,4,139,114,252,252,137,106,252,248,137,66,252,
-  252,252,233,244,65,248,69,129,252,248,239,15,133,244,62,129,122,253,4,239,
-  255,15,133,244,247,139,42,252,233,244,70,248,1,15,135,244,62,255,15,131,244,
-  62,255,252,242,15,16,2,252,233,244,71,255,221,2,252,233,244,72,255,248,73,
-  129,252,248,239,15,130,244,62,139,114,252,252,129,122,253,4,239,15,133,244,
-  249,139,2,248,2,199,66,252,252,237,137,66,252,248,252,233,244,65,248,3,129,
-  122,253,4,239,15,135,244,62,131,187,233,0,15,133,244,62,139,171,233,59,171,
-  233,255,15,130,244,247,232,244,74,248,1,139,108,36,48,137,149,233,137,116,
-  36,24,137,252,233,255,232,251,1,11,255,232,251,1,12,255,139,149,233,252,233,
-  244,2,248,75,129,252,248,239,15,130,244,62,15,132,244,248,248,1,129,122,253,
-  4,239,15,133,244,62,139,108,36,48,137,149,233,137,149,233,139,114,252,252,
-  139,2,137,68,36,4,137,44,36,131,194,8,137,84,36,8,137,116,36,24,232,251,1,
-  13,139,149,233,133,192,15,132,244,249,139,106,8,139,66,12,137,106,252,248,
-  137,66,252,252,139,106,16,139,66,20,137,42,137,66,4,248,76,184,237,255,252,
-  233,244,77,248,2,199,66,12,237,252,233,244,1,248,3,199,66,252,252,237,252,
-  233,244,65,248,78,129,252,248,239,15,130,244,62,139,42,129,122,253,4,239,
-  15,133,244,62,255,131,189,233,0,15,133,244,62,255,139,106,252,248,139,133,
-  233,139,114,252,252,199,66,252,252,237,137,66,252,248,199,66,12,237,184,237,
-  252,233,244,77,248,79,129,252,248,239,15,130,244,62,129,122,253,4,239,15,
-  133,244,62,129,122,253,12,239,255,139,114,252,252,255,139,66,8,131,192,1,
-  199,66,252,252,237,137,66,252,248,255,252,242,15,16,66,8,189,0,0,252,240,
-  63,102,15,110,205,102,15,112,201,81,252,242,15,88,193,252,242,15,45,192,252,
-  242,15,17,66,252,248,255,221,66,8,217,232,222,193,219,20,36,221,90,252,248,
-  139,4,36,255,139,42,59,133,233,15,131,244,248,193,224,3,3,133,233,248,1,129,
-  120,253,4,239,15,132,244,80,139,40,139,64,4,137,42,137,66,4,252,233,244,76,
-  248,2,131,189,233,0,15,132,244,80,137,252,233,137,213,137,194,232,251,1,14,
-  137,252,234,133,192,15,133,244,1,248,80,184,237,252,233,244,77,248,81,255,
-  139,106,252,248,139,133,233,139,114,252,252,199,66,252,252,237,137,66,252,
-  248,255,199,66,12,237,199,66,8,0,0,0,0,255,15,87,192,252,242,15,17,66,8,255,
-  217,252,238,221,90,8,255,184,237,252,233,244,77,248,82,129,252,248,239,15,
-  130,244,62,141,74,8,131,232,1,190,237,248,1,15,182,171,233,193,252,237,235,
-  131,229,1,1,252,238,252,233,244,28,248,83,129,252,248,239,15,130,244,62,129,
-  122,253,12,239,15,133,244,62,255,139,106,4,137,106,12,199,66,4,237,139,42,
-  139,114,8,137,106,8,137,50,141,74,16,131,232,2,190,237,252,233,244,1,248,
-  84,129,252,248,239,15,130,244,62,139,42,139,114,252,252,137,116,36,24,137,
-  44,36,129,122,253,4,239,15,133,244,62,131,189,233,0,15,133,244,62,128,189,
-  233,235,15,135,244,62,139,141,233,15,132,244,247,255,59,141,233,15,132,244,
-  62,248,1,141,116,193,252,240,59,181,233,15,135,244,62,137,181,233,139,108,
-  36,48,137,149,233,131,194,8,137,149,233,141,108,194,232,41,252,245,57,206,
-  15,132,244,249,248,2,139,68,46,4,137,70,252,252,139,4,46,137,70,252,248,131,
-  252,238,8,57,206,15,133,244,2,248,3,137,76,36,4,49,201,137,76,36,12,137,76,
-  36,8,232,244,25,199,131,233,237,255,139,108,36,48,139,52,36,139,149,233,129,
-  252,248,239,15,135,244,254,248,4,139,142,233,139,190,233,137,142,233,137,
-  252,254,41,206,15,132,244,252,141,4,50,193,252,238,3,59,133,233,15,135,244,
-  255,137,213,41,205,248,5,139,1,137,4,41,139,65,4,137,68,41,4,131,193,8,57,
-  252,249,15,133,244,5,248,6,141,70,2,199,66,252,252,237,248,7,139,116,36,24,
-  137,68,36,20,185,252,248,252,255,252,255,252,255,252,247,198,237,255,15,132,
-  244,13,252,233,244,14,248,8,199,66,252,252,237,139,142,233,131,252,233,8,
-  137,142,233,139,1,137,2,139,65,4,137,66,4,184,237,252,233,244,7,248,9,139,
-  12,36,137,185,233,137,252,242,137,252,233,232,251,1,0,139,52,36,139,149,233,
-  252,233,244,4,248,85,139,106,252,248,139,173,233,139,114,252,252,137,116,
-  36,24,137,44,36,131,189,233,0,15,133,244,62,255,128,189,233,235,15,135,244,
-  62,139,141,233,15,132,244,247,59,141,233,15,132,244,62,248,1,141,116,193,
-  252,248,59,181,233,15,135,244,62,137,181,233,139,108,36,48,137,149,233,137,
-  149,233,141,108,194,252,240,41,252,245,57,206,15,132,244,249,248,2,255,139,
-  68,46,4,137,70,252,252,139,4,46,137,70,252,248,131,252,238,8,57,206,15,133,
-  244,2,248,3,137,76,36,4,49,201,137,76,36,12,137,76,36,8,232,244,25,199,131,
-  233,237,139,108,36,48,139,52,36,139,149,233,129,252,248,239,15,135,244,254,
-  248,4,139,142,233,139,190,233,137,142,233,137,252,254,41,206,15,132,244,252,
-  141,4,50,193,252,238,3,59,133,233,15,135,244,255,255,137,213,41,205,248,5,
-  139,1,137,4,41,139,65,4,137,68,41,4,131,193,8,57,252,249,15,133,244,5,248,
-  6,141,70,1,248,7,139,116,36,24,137,68,36,20,49,201,252,247,198,237,15,132,
-  244,13,252,233,244,14,248,8,137,252,242,137,252,233,232,251,1,15,248,9,139,
-  12,36,137,185,233,137,252,242,137,252,233,232,251,1,0,139,52,36,139,149,233,
-  252,233,244,4,248,86,139,108,36,48,252,247,133,233,237,15,132,244,62,255,
-  137,149,233,141,68,194,252,248,137,133,233,49,192,137,133,233,176,235,136,
-  133,233,252,233,244,16,255,248,70,255,248,72,139,114,252,252,221,90,252,248,
-  252,233,244,65,255,248,87,129,252,248,239,15,130,244,62,255,129,122,253,4,
-  239,15,133,244,248,139,42,131,252,253,0,15,137,244,70,252,247,221,15,136,
-  244,247,248,88,248,70,139,114,252,252,199,66,252,252,237,137,106,252,248,
-  252,233,244,65,248,1,139,114,252,252,199,66,252,252,0,0,224,65,199,66,252,
-  248,0,0,0,0,252,233,244,65,248,2,15,135,244,62,255,129,122,253,4,239,15,131,
-  244,62,255,252,242,15,16,2,102,15,252,239,201,102,15,118,201,102,15,115,209,
-  1,15,84,193,248,71,139,114,252,252,252,242,15,17,66,252,248,255,221,2,217,
-  225,248,71,248,72,139,114,252,252,221,90,252,248,255,248,65,184,237,248,77,
-  137,68,36,20,248,63,252,247,198,237,15,133,244,253,248,5,56,70,252,255,15,
-  135,244,252,15,182,78,252,253,252,247,209,141,20,202,139,6,15,182,204,15,
-  182,232,131,198,4,193,232,16,252,255,36,171,248,6,199,68,194,252,244,237,
-  131,192,1,252,233,244,5,248,7,185,252,248,252,255,252,255,252,255,252,233,
-  244,14,248,89,255,129,122,253,4,239,15,133,244,247,139,42,252,233,244,70,
-  248,1,15,135,244,62,255,252,242,15,16,2,232,244,90,255,252,242,15,45,232,
-  129,252,253,0,0,0,128,15,133,244,70,252,242,15,42,205,102,15,46,193,15,138,
-  244,71,15,132,244,70,255,221,2,232,244,90,255,219,20,36,139,44,36,129,252,
-  253,0,0,0,128,15,133,244,248,217,192,219,4,36,255,223,252,233,221,216,255,
-  218,252,233,223,224,158,255,15,138,244,72,15,133,244,72,248,2,221,216,252,
-  233,244,70,255,248,91,255,252,242,15,16,2,232,244,92,255,221,2,232,244,92,
-  255,248,93,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,
-  252,242,15,81,2,252,233,244,71,255,248,93,129,252,248,239,15,130,244,62,129,
-  122,253,4,239,15,131,244,62,221,2,217,252,250,252,233,244,72,255,248,94,129,
-  252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,217,252,237,221,
-  2,217,252,241,252,233,244,72,248,95,129,252,248,239,15,130,244,62,129,122,
-  253,4,239,15,131,244,62,217,252,236,221,2,217,252,241,252,233,244,72,248,
-  96,129,252,248,239,255,15,130,244,62,129,122,253,4,239,15,131,244,62,221,
-  2,232,244,97,252,233,244,72,248,98,129,252,248,239,15,130,244,62,129,122,
-  253,4,239,15,131,244,62,221,2,217,252,254,252,233,244,72,248,99,129,252,248,
-  239,255,15,130,244,62,129,122,253,4,239,15,131,244,62,221,2,217,252,255,252,
-  233,244,72,248,100,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,
-  244,62,221,2,217,252,242,221,216,252,233,244,72,248,101,129,252,248,239,15,
-  130,244,62,255,129,122,253,4,239,15,131,244,62,221,2,217,192,216,200,217,
-  232,222,225,217,252,250,217,252,243,252,233,244,72,248,102,129,252,248,239,
-  15,130,244,62,129,122,253,4,239,15,131,244,62,221,2,217,192,216,200,217,232,
-  222,225,217,252,250,217,201,217,252,243,252,233,244,72,248,103,129,252,248,
-  239,15,130,244,62,129,122,253,4,239,15,131,244,62,255,221,2,217,232,217,252,
-  243,252,233,244,72,255,248,104,129,252,248,239,15,130,244,62,129,122,253,
-  4,239,15,131,244,62,252,242,15,16,2,252,242,15,17,4,36,255,248,104,129,252,
-  248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,221,2,221,28,36,255,
-  137,213,232,251,1,16,137,252,234,252,233,244,72,255,248,105,129,252,248,239,
-  15,130,244,62,129,122,253,4,239,15,131,244,62,252,242,15,16,2,252,242,15,
-  17,4,36,255,248,105,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,
-  244,62,221,2,221,28,36,255,137,213,232,251,1,17,137,252,234,252,233,244,72,
-  255,248,106,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,
-  252,242,15,16,2,252,242,15,17,4,36,255,248,106,129,252,248,239,15,130,244,
-  62,129,122,253,4,239,15,131,244,62,221,2,221,28,36,255,137,213,232,251,1,
-  18,137,252,234,252,233,244,72,248,107,255,248,108,129,252,248,239,15,130,
-  244,62,129,122,253,4,239,15,131,244,62,252,242,15,16,2,139,106,252,248,252,
-  242,15,89,133,233,252,233,244,71,255,248,108,129,252,248,239,15,130,244,62,
-  129,122,253,4,239,15,131,244,62,221,2,139,106,252,248,220,141,233,252,233,
-  244,72,255,248,109,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,
-  244,62,129,122,253,12,239,15,131,244,62,221,2,221,66,8,217,252,243,252,233,
-  244,72,248,110,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,
-  62,129,122,253,12,239,255,15,131,244,62,221,66,8,221,2,217,252,253,221,217,
-  252,233,244,72,248,111,129,252,248,239,15,130,244,62,139,106,4,129,252,253,
-  239,15,131,244,62,139,114,252,252,139,2,137,106,252,252,137,66,252,248,209,
-  229,129,252,253,0,0,224,252,255,15,131,244,249,9,232,15,132,244,249,184,252,
-  254,3,0,0,129,252,253,0,0,32,0,15,130,244,250,248,1,193,252,237,21,41,197,
-  255,252,242,15,42,197,255,137,108,36,16,219,68,36,16,255,139,106,252,252,
-  129,229,252,255,252,255,15,128,129,205,0,0,224,63,137,106,252,252,248,2,255,
-  252,242,15,17,2,255,221,26,255,184,237,252,233,244,77,248,3,255,15,87,192,
-  252,233,244,2,255,217,252,238,252,233,244,2,255,248,4,255,252,242,15,16,2,
-  189,0,0,80,67,102,15,110,205,102,15,112,201,81,252,242,15,89,193,252,242,
-  15,17,66,252,248,255,221,2,199,68,36,16,0,0,128,90,216,76,36,16,221,90,252,
-  248,255,139,106,252,252,184,52,4,0,0,209,229,252,233,244,1,255,248,112,129,
-  252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,252,242,15,16,2,
-  255,248,112,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,
-  221,2,255,139,106,4,139,114,252,252,209,229,129,252,253,0,0,224,252,255,15,
-  132,244,250,255,15,40,224,232,244,113,252,242,15,92,224,248,1,252,242,15,
-  17,66,252,248,252,242,15,17,34,255,217,192,232,244,113,220,252,233,248,1,
-  221,90,252,248,221,26,255,139,66,252,252,139,106,4,49,232,15,136,244,249,
-  248,2,184,237,252,233,244,77,248,3,129,252,245,0,0,0,128,137,106,4,252,233,
-  244,2,248,4,255,15,87,228,252,233,244,1,255,217,252,238,217,201,252,233,244,
-  1,255,248,114,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,
-  62,129,122,253,12,239,15,131,244,62,221,66,8,221,2,248,1,217,252,248,223,
-  224,158,15,138,244,1,221,217,252,233,244,72,255,248,115,129,252,248,239,15,
-  130,244,62,129,122,253,4,239,15,131,244,62,129,122,253,12,239,15,131,244,
-  62,252,242,15,16,2,252,242,15,16,74,8,232,244,116,252,233,244,71,255,248,
-  115,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,129,122,
-  253,12,239,15,131,244,62,221,2,221,66,8,232,244,116,252,233,244,72,255,248,
-  117,185,2,0,0,0,129,122,253,4,239,255,15,133,244,250,139,42,248,1,57,193,
-  15,131,244,70,129,124,253,202,252,252,239,15,133,244,249,59,108,202,252,248,
-  15,79,108,202,252,248,131,193,1,252,233,244,1,248,3,15,135,244,62,255,252,
-  233,244,252,248,4,15,135,244,62,255,252,242,15,16,2,248,5,57,193,15,131,244,
-  71,129,124,253,202,252,252,239,255,15,130,244,252,15,135,244,62,252,242,15,
-  42,76,202,252,248,252,233,244,253,255,248,6,252,242,15,16,76,202,252,248,
-  248,7,252,242,15,93,193,131,193,1,252,233,244,5,255,221,2,248,5,57,193,15,
-  131,244,72,129,124,253,202,252,252,239,255,15,130,244,252,15,135,244,255,
-  219,68,202,252,248,252,233,244,253,255,15,131,244,255,255,248,6,221,68,202,
-  252,248,248,7,255,219,252,233,219,209,221,217,255,80,221,225,223,224,252,
-  246,196,1,15,132,244,248,217,201,248,2,221,216,88,255,248,118,185,2,0,0,0,
-  129,122,253,4,239,255,15,133,244,250,139,42,248,1,57,193,15,131,244,70,129,
-  124,253,202,252,252,239,15,133,244,249,59,108,202,252,248,15,76,108,202,252,
-  248,131,193,1,252,233,244,1,248,3,15,135,244,62,255,248,6,252,242,15,16,76,
-  202,252,248,248,7,252,242,15,95,193,131,193,1,252,233,244,5,255,219,252,233,
-  218,209,221,217,255,80,221,225,223,224,252,246,196,1,15,133,244,248,217,201,
-  248,2,221,216,88,255,248,9,221,216,252,233,244,62,255,248,119,129,252,248,
-  239,15,130,244,62,129,122,253,4,239,15,133,244,62,139,42,255,139,173,233,
-  252,233,244,70,255,252,242,15,42,133,233,252,233,244,71,255,219,133,233,252,
-  233,244,72,255,248,120,129,252,248,239,15,133,244,62,129,122,253,4,239,15,
-  133,244,62,139,42,139,114,252,252,131,189,233,1,15,130,244,80,15,182,173,
-  233,255,252,242,15,42,197,252,233,244,71,255,137,108,36,16,219,68,36,16,252,
-  233,244,72,255,248,121,139,171,233,59,171,233,15,130,244,247,232,244,74,248,
-  1,129,252,248,239,15,133,244,62,129,122,253,4,239,255,15,133,244,62,139,42,
-  129,252,253,252,255,0,0,0,15,135,244,62,137,108,36,20,255,15,131,244,62,252,
-  242,15,44,42,129,252,253,252,255,0,0,0,15,135,244,62,137,108,36,20,255,15,
-  131,244,62,221,2,219,92,36,20,129,124,36,20,252,255,0,0,0,15,135,244,62,255,
-  199,68,36,8,1,0,0,0,141,68,36,20,248,122,139,108,36,48,137,149,233,137,68,
-  36,4,137,44,36,137,116,36,24,232,251,1,19,139,149,233,139,114,252,252,199,
-  66,252,252,237,137,66,252,248,252,233,244,65,248,123,139,171,233,59,171,233,
-  15,130,244,247,232,244,74,248,1,199,68,36,20,252,255,252,255,252,255,252,
-  255,129,252,248,239,15,130,244,62,15,134,244,247,129,122,253,20,239,255,15,
-  133,244,62,139,106,16,137,108,36,20,255,15,131,244,62,252,242,15,44,106,16,
-  137,108,36,20,255,15,131,244,62,221,66,16,219,92,36,20,255,248,1,129,122,
-  253,4,239,15,133,244,62,129,122,253,12,239,255,139,42,137,108,36,12,139,173,
-  233,255,139,74,8,255,252,242,15,44,74,8,255,221,66,8,219,92,36,8,139,76,36,
-  8,255,139,68,36,20,57,197,15,130,244,251,248,2,133,201,15,142,244,253,248,
-  3,139,108,36,12,41,200,15,140,244,124,141,172,253,13,233,131,192,1,248,4,
-  137,68,36,8,137,232,252,233,244,122,248,5,15,140,244,252,141,68,40,1,252,
-  233,244,2,248,6,137,232,252,233,244,2,248,7,255,15,132,244,254,1,252,233,
-  131,193,1,15,143,244,3,248,8,185,1,0,0,0,252,233,244,3,248,124,49,192,252,
-  233,244,4,248,125,129,252,248,239,15,130,244,62,139,171,233,59,171,233,15,
-  130,244,247,232,244,74,248,1,255,129,122,253,4,239,15,133,244,62,129,122,
-  253,12,239,139,42,255,15,133,244,62,139,66,8,255,15,131,244,62,252,242,15,
-  44,66,8,255,15,131,244,62,221,66,8,219,92,36,20,139,68,36,20,255,133,192,
-  15,142,244,124,131,189,233,1,15,130,244,124,15,133,244,126,57,131,233,15,
-  130,244,126,15,182,141,233,139,171,233,137,68,36,8,248,1,136,77,0,131,197,
-  1,131,232,1,15,133,244,1,139,131,233,252,233,244,122,248,127,129,252,248,
-  239,255,15,130,244,62,139,171,233,59,171,233,15,130,244,247,232,244,74,248,
-  1,129,122,253,4,239,15,133,244,62,139,42,139,133,233,133,192,15,132,244,124,
-  57,131,233,15,130,244,128,129,197,239,137,116,36,20,137,68,36,8,139,179,233,
-  248,1,255,15,182,77,0,131,197,1,131,232,1,136,12,6,15,133,244,1,137,252,240,
-  139,116,36,20,252,233,244,122,248,129,129,252,248,239,15,130,244,62,139,171,
-  233,59,171,233,15,130,244,247,232,244,74,248,1,129,122,253,4,239,15,133,244,
-  62,139,42,139,133,233,57,131,233,255,15,130,244,128,129,197,239,137,116,36,
-  20,137,68,36,8,139,179,233,252,233,244,249,248,1,15,182,76,5,0,131,252,249,
-  65,15,130,244,248,131,252,249,90,15,135,244,248,131,252,241,32,248,2,136,
-  12,6,248,3,131,232,1,15,137,244,1,137,252,240,139,116,36,20,252,233,244,122,
-  248,130,129,252,248,239,15,130,244,62,255,139,171,233,59,171,233,15,130,244,
-  247,232,244,74,248,1,129,122,253,4,239,15,133,244,62,139,42,139,133,233,57,
-  131,233,15,130,244,128,129,197,239,137,116,36,20,137,68,36,8,139,179,233,
-  252,233,244,249,248,1,15,182,76,5,0,131,252,249,97,15,130,244,248,255,131,
-  252,249,122,15,135,244,248,131,252,241,32,248,2,136,12,6,248,3,131,232,1,
-  15,137,244,1,137,252,240,139,116,36,20,252,233,244,122,248,131,129,252,248,
-  239,15,130,244,62,129,122,253,4,239,15,133,244,62,137,213,139,10,232,251,
-  1,20,137,252,234,255,137,197,252,233,244,70,255,252,242,15,42,192,252,233,
-  244,71,255,137,4,36,219,4,36,252,233,244,72,255,248,132,129,252,248,239,15,
-  130,244,62,129,122,253,4,239,255,15,133,244,247,139,42,252,233,244,88,248,
-  1,15,135,244,62,255,252,242,15,16,2,189,0,0,56,67,102,15,110,205,102,15,112,
-  201,81,252,242,15,88,193,102,15,126,197,255,221,2,199,68,36,16,0,0,192,89,
-  216,68,36,16,221,28,36,255,139,44,36,255,252,233,244,88,255,248,133,129,252,
-  248,239,15,130,244,62,255,189,0,0,56,67,102,15,110,205,102,15,112,201,81,
-  255,199,68,36,16,0,0,192,89,255,15,133,244,247,139,42,252,233,244,248,248,
-  1,15,135,244,62,255,252,242,15,16,2,252,242,15,88,193,102,15,126,197,255,
-  221,2,216,68,36,16,221,28,36,139,44,36,255,248,2,137,68,36,20,141,68,194,
-  252,240,248,1,57,208,15,134,244,88,129,120,253,4,239,255,15,133,244,248,35,
-  40,131,232,8,252,233,244,1,248,2,15,135,244,134,255,15,131,244,134,255,252,
-  242,15,16,0,252,242,15,88,193,102,15,126,193,33,205,255,221,0,216,68,36,16,
-  221,28,36,35,44,36,255,131,232,8,252,233,244,1,248,135,129,252,248,239,15,
-  130,244,62,255,15,133,244,248,11,40,131,232,8,252,233,244,1,248,2,15,135,
-  244,134,255,252,242,15,16,0,252,242,15,88,193,102,15,126,193,9,205,255,221,
-  0,216,68,36,16,221,28,36,11,44,36,255,131,232,8,252,233,244,1,248,136,129,
-  252,248,239,15,130,244,62,255,15,133,244,248,51,40,131,232,8,252,233,244,
-  1,248,2,15,135,244,134,255,252,242,15,16,0,252,242,15,88,193,102,15,126,193,
-  49,205,255,221,0,216,68,36,16,221,28,36,51,44,36,255,131,232,8,252,233,244,
-  1,248,137,129,252,248,239,15,130,244,62,129,122,253,4,239,255,221,2,199,68,
-  36,16,0,0,192,89,216,68,36,16,221,28,36,139,44,36,255,248,2,15,205,252,233,
-  244,88,248,138,129,252,248,239,15,130,244,62,129,122,253,4,239,255,248,2,
-  252,247,213,255,248,88,252,242,15,42,197,252,233,244,71,255,248,88,137,44,
-  36,219,4,36,252,233,244,72,255,248,134,139,68,36,20,252,233,244,62,255,248,
-  139,129,252,248,239,15,130,244,62,129,122,253,4,239,255,248,2,129,122,253,
-  12,239,15,133,244,62,139,74,8,255,248,139,129,252,248,239,15,130,244,62,129,
-  122,253,4,239,15,131,244,62,129,122,253,12,239,15,131,244,62,252,242,15,16,
-  2,252,242,15,16,74,8,189,0,0,56,67,102,15,110,213,102,15,112,210,81,252,242,
-  15,88,194,252,242,15,88,202,102,15,126,197,102,15,126,201,255,248,139,129,
-  252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,129,122,253,12,
-  239,15,131,244,62,221,2,221,66,8,199,68,36,16,0,0,192,89,216,68,36,16,221,
-  92,36,8,216,68,36,16,221,28,36,139,76,36,8,139,44,36,255,211,229,252,233,
-  244,88,255,248,140,129,252,248,239,15,130,244,62,129,122,253,4,239,255,248,
-  140,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,129,122,
-  253,12,239,15,131,244,62,252,242,15,16,2,252,242,15,16,74,8,189,0,0,56,67,
-  102,15,110,213,102,15,112,210,81,252,242,15,88,194,252,242,15,88,202,102,
-  15,126,197,102,15,126,201,255,248,140,129,252,248,239,15,130,244,62,129,122,
-  253,4,239,15,131,244,62,129,122,253,12,239,15,131,244,62,221,2,221,66,8,199,
-  68,36,16,0,0,192,89,216,68,36,16,221,92,36,8,216,68,36,16,221,28,36,139,76,
-  36,8,139,44,36,255,211,252,237,252,233,244,88,255,248,141,129,252,248,239,
-  15,130,244,62,129,122,253,4,239,255,248,141,129,252,248,239,15,130,244,62,
-  129,122,253,4,239,15,131,244,62,129,122,253,12,239,15,131,244,62,252,242,
-  15,16,2,252,242,15,16,74,8,189,0,0,56,67,102,15,110,213,102,15,112,210,81,
-  252,242,15,88,194,252,242,15,88,202,102,15,126,197,102,15,126,201,255,248,
-  141,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,129,122,
-  253,12,239,15,131,244,62,221,2,221,66,8,199,68,36,16,0,0,192,89,216,68,36,
-  16,221,92,36,8,216,68,36,16,221,28,36,139,76,36,8,139,44,36,255,211,252,253,
-  252,233,244,88,255,248,142,129,252,248,239,15,130,244,62,129,122,253,4,239,
-  255,248,142,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,
-  129,122,253,12,239,15,131,244,62,252,242,15,16,2,252,242,15,16,74,8,189,0,
-  0,56,67,102,15,110,213,102,15,112,210,81,252,242,15,88,194,252,242,15,88,
-  202,102,15,126,197,102,15,126,201,255,248,142,129,252,248,239,15,130,244,
-  62,129,122,253,4,239,15,131,244,62,129,122,253,12,239,15,131,244,62,221,2,
-  221,66,8,199,68,36,16,0,0,192,89,216,68,36,16,221,92,36,8,216,68,36,16,221,
-  28,36,139,76,36,8,139,44,36,255,211,197,252,233,244,88,255,248,143,129,252,
-  248,239,15,130,244,62,129,122,253,4,239,255,248,143,129,252,248,239,15,130,
-  244,62,129,122,253,4,239,15,131,244,62,129,122,253,12,239,15,131,244,62,252,
-  242,15,16,2,252,242,15,16,74,8,189,0,0,56,67,102,15,110,213,102,15,112,210,
-  81,252,242,15,88,194,252,242,15,88,202,102,15,126,197,102,15,126,201,255,
-  248,143,129,252,248,239,15,130,244,62,129,122,253,4,239,15,131,244,62,129,
-  122,253,12,239,15,131,244,62,221,2,221,66,8,199,68,36,16,0,0,192,89,216,68,
-  36,16,221,92,36,8,216,68,36,16,221,28,36,139,76,36,8,139,44,36,255,211,205,
-  252,233,244,88,248,126,184,237,252,233,244,62,248,128,184,237,248,62,139,
-  108,36,48,139,114,252,252,137,116,36,24,137,149,233,141,68,194,252,248,141,
-  136,233,137,133,233,139,66,252,248,59,141,233,15,135,244,251,137,44,36,252,
-  255,144,233,139,149,233,133,192,15,143,244,77,248,1,255,139,141,233,41,209,
-  193,252,233,3,133,192,141,65,1,139,106,252,248,15,133,244,32,139,181,233,
-  139,14,15,182,252,233,15,182,205,131,198,4,252,255,36,171,248,32,137,209,
-  252,247,198,237,15,133,244,249,15,182,110,252,253,252,247,213,141,20,252,
-  234,252,233,244,28,248,3,137,252,245,131,229,252,248,41,252,234,252,233,244,
-  28,248,5,186,237,137,252,233,232,251,1,0,139,149,233,49,192,252,233,244,1,
-  248,74,93,137,108,36,16,139,108,36,48,137,116,36,24,137,149,233,255,141,68,
-  194,252,248,137,252,233,137,133,233,232,251,1,21,139,149,233,139,133,233,
-  41,208,193,232,3,131,192,1,139,108,36,16,85,195,248,144,255,15,182,131,233,
-  168,235,15,133,244,251,168,235,15,133,244,247,168,235,15,132,244,247,252,
-  255,139,233,252,233,244,247,255,248,145,15,182,131,233,168,235,15,133,244,
-  251,252,233,244,247,248,146,15,182,131,233,168,235,15,133,244,251,168,235,
-  15,132,244,251,252,255,139,233,15,132,244,247,168,235,15,132,244,251,248,
-  1,255,139,108,36,48,137,149,233,137,252,242,137,252,233,232,251,1,22,248,
-  3,139,149,233,248,4,15,182,78,252,253,248,5,15,182,110,252,252,15,183,70,
-  252,254,252,255,164,253,171,233,248,147,131,198,4,139,77,232,137,76,36,20,
-  252,233,244,4,248,148,255,139,106,252,248,139,173,233,15,182,133,233,141,
-  4,194,139,108,36,48,137,149,233,137,133,233,137,252,242,141,139,233,137,171,
-  233,137,116,36,24,232,251,1,23,252,233,244,3,255,248,149,137,116,36,24,255,
-  248,150,255,137,116,36,24,131,206,1,248,1,255,141,68,194,252,248,139,108,
-  36,48,137,149,233,137,133,233,137,252,242,137,252,233,232,251,1,24,199,68,
-  36,24,0,0,0,0,255,131,230,252,254,255,139,149,233,137,193,139,133,233,41,
-  208,137,205,15,182,78,252,253,193,232,3,131,192,1,252,255,229,248,151,255,
-  85,141,108,36,12,85,83,82,81,80,15,182,69,252,252,138,101,252,248,137,125,
-  252,252,137,117,252,248,139,93,0,139,139,233,199,131,233,237,137,131,233,
-  137,139,233,129,252,236,239,252,242,15,17,125,216,252,242,15,17,117,208,252,
-  242,15,17,109,200,252,242,15,17,101,192,252,242,15,17,93,184,252,242,15,17,
-  85,176,252,242,15,17,77,168,252,242,15,17,69,160,139,171,233,139,147,233,
-  137,171,233,199,131,233,0,0,0,0,137,149,233,141,84,36,16,141,139,233,232,
-  251,1,25,139,141,233,129,225,239,137,204,137,169,233,139,149,233,139,177,
-  233,255,248,152,255,133,192,15,136,244,249,137,68,36,20,139,122,252,248,139,
-  191,233,139,191,233,199,131,233,0,0,0,0,199,131,233,237,139,6,15,182,204,
-  15,182,232,131,198,4,193,232,16,129,252,253,239,15,130,244,248,139,68,36,
-  20,248,2,252,255,36,171,248,3,252,247,216,137,252,233,137,194,232,251,1,26,
-  255,248,90,255,217,124,36,4,137,68,36,8,102,184,0,4,102,11,68,36,4,102,37,
-  252,255,252,247,102,137,68,36,6,217,108,36,6,217,252,252,217,108,36,4,139,
-  68,36,8,195,255,248,153,102,15,252,239,210,102,15,118,210,102,15,115,210,
+  233,137,113,252,244,141,177,233,41,214,139,105,252,248,184,237,252,233,244,
+  30,248,40,137,68,36,16,199,68,36,20,237,141,68,36,16,128,126,252,252,235,
+  15,133,244,247,255,141,139,233,137,41,199,65,4,237,137,205,252,233,244,248,
+  248,41,15,182,70,252,254,255,141,68,36,16,252,233,244,247,248,42,15,182,70,
+  252,254,141,4,194,248,1,15,182,110,252,255,141,44,252,234,248,2,137,108,36,
+  4,139,108,36,48,137,68,36,8,137,44,36,137,149,233,137,116,36,24,232,251,1,
+  2,139,149,233,133,192,15,132,244,249,15,182,78,252,253,139,108,202,4,139,
+  12,202,137,104,4,137,8,248,43,139,6,15,182,204,15,182,232,131,198,4,193,232,
+  16,252,255,36,171,248,3,139,141,233,137,113,252,244,15,182,70,252,253,139,
+  108,194,4,139,4,194,137,105,20,137,65,16,141,177,233,41,214,139,105,252,248,
+  184,237,252,233,244,30,248,44,15,182,110,252,252,141,4,194,141,12,202,137,
+  108,36,12,139,108,36,48,137,68,36,8,137,76,36,4,137,44,36,137,149,233,137,
+  116,36,24,232,251,1,3,248,3,139,149,233,255,131,252,248,1,15,135,244,45,248,
+  4,141,118,4,15,130,244,252,248,5,15,183,70,252,254,141,180,253,134,233,248,
+  6,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,46,
+  131,198,4,129,120,253,4,239,15,130,244,5,252,233,244,6,248,47,129,120,253,
+  4,239,252,233,244,4,248,48,131,252,238,4,137,108,36,12,139,108,36,48,137,
+  68,36,8,137,76,36,4,137,44,36,137,149,233,255,137,116,36,24,232,251,1,4,252,
+  233,244,3,248,49,255,131,252,238,4,139,108,36,48,137,149,233,137,252,233,
+  139,86,252,252,137,116,36,24,232,251,1,5,252,233,244,3,255,248,50,255,15,
+  182,110,252,255,255,248,51,141,4,199,252,233,244,247,248,52,255,248,53,141,
+  4,199,141,44,252,234,149,252,233,244,248,248,54,141,4,194,137,197,252,233,
+  244,248,248,55,255,248,56,141,4,194,248,1,141,44,252,234,248,2,141,12,202,
+  137,108,36,8,139,108,36,48,137,68,36,12,15,182,70,252,252,137,76,36,4,137,
+  68,36,16,137,44,36,137,149,233,137,116,36,24,232,251,1,6,139,149,233,133,
+  192,15,132,244,43,248,45,137,193,41,208,137,113,252,244,141,176,233,184,237,
+  252,233,244,28,248,57,139,108,36,48,137,149,233,141,20,194,137,252,233,137,
+  116,36,24,232,251,1,7,139,149,233,255,133,192,15,133,244,45,15,183,70,252,
+  254,139,12,194,252,233,244,58,255,252,233,244,45,255,248,59,141,76,202,8,
+  248,29,137,76,36,20,137,68,36,16,131,252,233,8,141,4,193,139,108,36,48,137,
+  76,36,4,137,68,36,8,137,44,36,137,149,233,137,116,36,24,232,251,1,8,139,149,
+  233,139,76,36,20,139,68,36,16,139,105,252,248,131,192,1,57,215,15,132,244,
+  60,137,202,137,114,252,252,139,181,233,139,14,15,182,252,233,15,182,205,131,
+  198,4,252,255,36,171,248,61,139,108,36,48,137,149,233,137,202,137,252,233,
+  137,116,36,24,232,251,1,9,139,149,233,139,70,252,252,15,182,204,15,182,232,
+  193,232,16,252,255,164,253,171,233,248,62,129,252,248,239,15,130,244,63,139,
+  106,4,129,252,253,239,15,131,244,63,139,114,252,252,137,68,36,20,137,106,
+  252,252,139,42,137,106,252,248,131,232,2,15,132,244,248,255,137,209,248,1,
+  131,193,8,139,105,4,137,105,252,252,139,41,137,105,252,248,131,232,1,15,133,
+  244,1,248,2,139,68,36,20,252,233,244,64,248,65,129,252,248,239,15,130,244,
+  63,139,106,4,184,237,252,247,213,57,232,255,15,71,197,255,15,134,244,247,
+  137,232,248,1,255,248,2,139,106,252,248,139,132,253,197,233,139,114,252,252,
+  199,66,252,252,237,137,66,252,248,252,233,244,66,248,67,129,252,248,239,15,
+  130,244,63,139,106,4,139,114,252,252,129,252,253,239,15,133,244,252,248,1,
+  139,42,139,173,233,248,2,133,252,237,199,66,252,252,237,15,132,244,66,139,
+  131,233,199,66,252,252,237,255,137,106,252,248,139,141,233,35,136,233,105,
+  201,239,3,141,233,248,3,129,185,233,239,15,133,244,250,57,129,233,15,132,
+  244,251,248,4,139,137,233,133,201,15,133,244,3,252,233,244,66,248,5,139,105,
+  4,129,252,253,239,255,15,132,244,66,139,1,137,106,252,252,137,66,252,248,
+  252,233,244,66,248,6,129,252,253,239,15,132,244,1,129,252,253,239,15,135,
+  244,254,189,237,248,8,252,247,213,139,172,253,171,233,252,233,244,2,248,68,
+  129,252,248,239,15,130,244,63,255,129,122,253,4,239,15,133,244,63,139,42,
+  131,189,233,0,15,133,244,63,129,122,253,12,239,15,133,244,63,139,66,8,137,
+  133,233,139,114,252,252,199,66,252,252,237,137,106,252,248,252,246,133,233,
+  235,15,132,244,247,128,165,233,235,139,131,233,137,171,233,137,133,233,248,
+  1,255,252,233,244,66,248,69,129,252,248,239,15,130,244,63,129,122,253,4,239,
+  15,133,244,63,139,2,139,108,36,48,137,68,36,4,137,44,36,137,213,131,194,8,
+  137,84,36,8,232,251,1,10,137,252,234,139,40,139,64,4,139,114,252,252,137,
+  106,252,248,137,66,252,252,252,233,244,66,248,70,129,252,248,239,15,133,244,
+  63,129,122,253,4,239,255,15,133,244,247,139,42,252,233,244,71,248,1,15,135,
+  244,63,255,15,131,244,63,255,252,242,15,16,2,252,233,244,72,255,221,2,252,
+  233,244,73,255,248,74,129,252,248,239,15,130,244,63,139,114,252,252,129,122,
+  253,4,239,15,133,244,249,139,2,248,2,199,66,252,252,237,137,66,252,248,252,
+  233,244,66,248,3,129,122,253,4,239,15,135,244,63,131,187,233,0,15,133,244,
+  63,139,171,233,59,171,233,255,15,130,244,247,232,244,75,248,1,139,108,36,
+  48,137,149,233,137,116,36,24,137,252,233,255,232,251,1,11,255,232,251,1,12,
+  255,139,149,233,252,233,244,2,248,76,129,252,248,239,15,130,244,63,15,132,
+  244,248,248,1,129,122,253,4,239,15,133,244,63,139,108,36,48,137,149,233,137,
+  149,233,139,114,252,252,139,2,137,68,36,4,137,44,36,131,194,8,137,84,36,8,
+  137,116,36,24,232,251,1,13,139,149,233,133,192,15,132,244,249,139,106,8,139,
+  66,12,137,106,252,248,137,66,252,252,139,106,16,139,66,20,137,42,137,66,4,
+  248,77,184,237,255,252,233,244,78,248,2,199,66,12,237,252,233,244,1,248,3,
+  199,66,252,252,237,252,233,244,66,248,79,129,252,248,239,15,130,244,63,139,
+  42,129,122,253,4,239,15,133,244,63,255,131,189,233,0,15,133,244,63,255,139,
+  106,252,248,139,133,233,139,114,252,252,199,66,252,252,237,137,66,252,248,
+  199,66,12,237,184,237,252,233,244,78,248,80,129,252,248,239,15,130,244,63,
+  129,122,253,4,239,15,133,244,63,129,122,253,12,239,255,139,114,252,252,255,
+  139,66,8,131,192,1,199,66,252,252,237,137,66,252,248,255,252,242,15,16,66,
+  8,189,0,0,252,240,63,102,15,110,205,102,15,112,201,81,252,242,15,88,193,252,
+  242,15,45,192,252,242,15,17,66,252,248,255,221,66,8,217,232,222,193,219,20,
+  36,221,90,252,248,139,4,36,255,139,42,59,133,233,15,131,244,248,193,224,3,
+  3,133,233,248,1,129,120,253,4,239,15,132,244,81,139,40,139,64,4,137,42,137,
+  66,4,252,233,244,77,248,2,131,189,233,0,15,132,244,81,137,252,233,137,213,
+  137,194,232,251,1,14,137,252,234,133,192,15,133,244,1,248,81,184,237,252,
+  233,244,78,248,82,255,139,106,252,248,139,133,233,139,114,252,252,199,66,
+  252,252,237,137,66,252,248,255,199,66,12,237,199,66,8,0,0,0,0,255,15,87,192,
+  252,242,15,17,66,8,255,217,252,238,221,90,8,255,184,237,252,233,244,78,248,
+  83,129,252,248,239,15,130,244,63,141,74,8,131,232,1,190,237,248,1,15,182,
+  171,233,193,252,237,235,131,229,1,1,252,238,252,233,244,28,248,84,129,252,
+  248,239,15,130,244,63,129,122,253,12,239,15,133,244,63,255,139,106,4,137,
+  106,12,199,66,4,237,139,42,139,114,8,137,106,8,137,50,141,74,16,131,232,2,
+  190,237,252,233,244,1,248,85,129,252,248,239,15,130,244,63,139,42,139,114,
+  252,252,137,116,36,24,137,44,36,129,122,253,4,239,15,133,244,63,131,189,233,
+  0,15,133,244,63,128,189,233,235,15,135,244,63,139,141,233,15,132,244,247,
+  255,59,141,233,15,132,244,63,248,1,141,116,193,252,240,59,181,233,15,135,
+  244,63,137,181,233,139,108,36,48,137,149,233,131,194,8,137,149,233,141,108,
+  194,232,41,252,245,57,206,15,132,244,249,248,2,139,68,46,4,137,70,252,252,
+  139,4,46,137,70,252,248,131,252,238,8,57,206,15,133,244,2,248,3,137,76,36,
+  4,49,201,137,76,36,12,137,76,36,8,232,244,25,199,131,233,237,255,139,108,
+  36,48,139,52,36,139,149,233,129,252,248,239,15,135,244,254,248,4,139,142,
+  233,139,190,233,137,142,233,137,252,254,41,206,15,132,244,252,141,4,50,193,
+  252,238,3,59,133,233,15,135,244,255,137,213,41,205,248,5,139,1,137,4,41,139,
+  65,4,137,68,41,4,131,193,8,57,252,249,15,133,244,5,248,6,141,70,2,199,66,
+  252,252,237,248,7,139,116,36,24,137,68,36,20,185,252,248,252,255,252,255,
+  252,255,252,247,198,237,255,15,132,244,13,252,233,244,14,248,8,199,66,252,
+  252,237,139,142,233,131,252,233,8,137,142,233,139,1,137,2,139,65,4,137,66,
+  4,184,237,252,233,244,7,248,9,139,12,36,137,185,233,137,252,242,137,252,233,
+  232,251,1,0,139,52,36,139,149,233,252,233,244,4,248,86,139,106,252,248,139,
+  173,233,139,114,252,252,137,116,36,24,137,44,36,131,189,233,0,15,133,244,
+  63,255,128,189,233,235,15,135,244,63,139,141,233,15,132,244,247,59,141,233,
+  15,132,244,63,248,1,141,116,193,252,248,59,181,233,15,135,244,63,137,181,
+  233,139,108,36,48,137,149,233,137,149,233,141,108,194,252,240,41,252,245,
+  57,206,15,132,244,249,248,2,255,139,68,46,4,137,70,252,252,139,4,46,137,70,
+  252,248,131,252,238,8,57,206,15,133,244,2,248,3,137,76,36,4,49,201,137,76,
+  36,12,137,76,36,8,232,244,25,199,131,233,237,139,108,36,48,139,52,36,139,
+  149,233,129,252,248,239,15,135,244,254,248,4,139,142,233,139,190,233,137,
+  142,233,137,252,254,41,206,15,132,244,252,141,4,50,193,252,238,3,59,133,233,
+  15,135,244,255,255,137,213,41,205,248,5,139,1,137,4,41,139,65,4,137,68,41,
+  4,131,193,8,57,252,249,15,133,244,5,248,6,141,70,1,248,7,139,116,36,24,137,
+  68,36,20,49,201,252,247,198,237,15,132,244,13,252,233,244,14,248,8,137,252,
+  242,137,252,233,232,251,1,15,248,9,139,12,36,137,185,233,137,252,242,137,
+  252,233,232,251,1,0,139,52,36,139,149,233,252,233,244,4,248,87,139,108,36,
+  48,252,247,133,233,237,15,132,244,63,255,137,149,233,141,68,194,252,248,137,
+  133,233,49,192,137,133,233,176,235,136,133,233,252,233,244,16,255,248,71,
+  255,248,73,139,114,252,252,221,90,252,248,252,233,244,66,255,248,88,129,252,
+  248,239,15,130,244,63,255,129,122,253,4,239,15,133,244,248,139,42,131,252,
+  253,0,15,137,244,71,252,247,221,15,136,244,247,248,89,248,71,139,114,252,
+  252,199,66,252,252,237,137,106,252,248,252,233,244,66,248,1,139,114,252,252,
+  199,66,252,252,0,0,224,65,199,66,252,248,0,0,0,0,252,233,244,66,248,2,15,
+  135,244,63,255,129,122,253,4,239,15,131,244,63,255,252,242,15,16,2,102,15,
+  252,239,201,102,15,118,201,102,15,115,209,1,15,84,193,248,72,139,114,252,
+  252,252,242,15,17,66,252,248,255,221,2,217,225,248,72,248,73,139,114,252,
+  252,221,90,252,248,255,248,66,184,237,248,78,137,68,36,20,248,64,252,247,
+  198,237,15,133,244,253,248,5,56,70,252,255,15,135,244,252,15,182,78,252,253,
+  252,247,209,141,20,202,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,
+  255,36,171,248,6,199,68,194,252,244,237,131,192,1,252,233,244,5,248,7,185,
+  252,248,252,255,252,255,252,255,252,233,244,14,248,90,255,129,122,253,4,239,
+  15,133,244,247,139,42,252,233,244,71,248,1,15,135,244,63,255,252,242,15,16,
+  2,232,244,91,255,252,242,15,45,232,129,252,253,0,0,0,128,15,133,244,71,252,
+  242,15,42,205,102,15,46,193,15,138,244,72,15,132,244,71,255,221,2,232,244,
+  91,255,219,20,36,139,44,36,129,252,253,0,0,0,128,15,133,244,248,217,192,219,
+  4,36,255,223,252,233,221,216,255,218,252,233,223,224,158,255,15,138,244,73,
+  15,133,244,73,248,2,221,216,252,233,244,71,255,248,92,255,252,242,15,16,2,
+  232,244,93,255,221,2,232,244,93,255,248,94,129,252,248,239,15,130,244,63,
+  129,122,253,4,239,15,131,244,63,252,242,15,81,2,252,233,244,72,255,248,94,
+  129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,221,2,217,252,
+  250,252,233,244,73,255,248,95,129,252,248,239,15,130,244,63,129,122,253,4,
+  239,15,131,244,63,217,252,237,221,2,217,252,241,252,233,244,73,248,96,129,
+  252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,217,252,236,221,
+  2,217,252,241,252,233,244,73,248,97,129,252,248,239,255,15,130,244,63,129,
+  122,253,4,239,15,131,244,63,221,2,232,244,98,252,233,244,73,248,99,129,252,
+  248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,221,2,217,252,254,252,
+  233,244,73,248,100,129,252,248,239,255,15,130,244,63,129,122,253,4,239,15,
+  131,244,63,221,2,217,252,255,252,233,244,73,248,101,129,252,248,239,15,130,
+  244,63,129,122,253,4,239,15,131,244,63,221,2,217,252,242,221,216,252,233,
+  244,73,248,102,129,252,248,239,15,130,244,63,255,129,122,253,4,239,15,131,
+  244,63,221,2,217,192,216,200,217,232,222,225,217,252,250,217,252,243,252,
+  233,244,73,248,103,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,
+  244,63,221,2,217,192,216,200,217,232,222,225,217,252,250,217,201,217,252,
+  243,252,233,244,73,248,104,129,252,248,239,15,130,244,63,129,122,253,4,239,
+  15,131,244,63,255,221,2,217,232,217,252,243,252,233,244,73,255,248,105,129,
+  252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,252,242,15,16,2,
+  252,242,15,17,4,36,255,248,105,129,252,248,239,15,130,244,63,129,122,253,
+  4,239,15,131,244,63,221,2,221,28,36,255,137,213,232,251,1,16,137,252,234,
+  252,233,244,73,255,248,106,129,252,248,239,15,130,244,63,129,122,253,4,239,
+  15,131,244,63,252,242,15,16,2,252,242,15,17,4,36,255,248,106,129,252,248,
+  239,15,130,244,63,129,122,253,4,239,15,131,244,63,221,2,221,28,36,255,137,
+  213,232,251,1,17,137,252,234,252,233,244,73,255,248,107,129,252,248,239,15,
+  130,244,63,129,122,253,4,239,15,131,244,63,252,242,15,16,2,252,242,15,17,
+  4,36,255,248,107,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,
+  63,221,2,221,28,36,255,137,213,232,251,1,18,137,252,234,252,233,244,73,248,
+  108,255,248,109,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,
+  63,252,242,15,16,2,139,106,252,248,252,242,15,89,133,233,252,233,244,72,255,
+  248,109,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,221,
+  2,139,106,252,248,220,141,233,252,233,244,73,255,248,110,129,252,248,239,
+  15,130,244,63,129,122,253,4,239,15,131,244,63,129,122,253,12,239,15,131,244,
+  63,221,2,221,66,8,217,252,243,252,233,244,73,248,111,129,252,248,239,15,130,
+  244,63,129,122,253,4,239,15,131,244,63,129,122,253,12,239,255,15,131,244,
+  63,221,66,8,221,2,217,252,253,221,217,252,233,244,73,248,112,129,252,248,
+  239,15,130,244,63,139,106,4,129,252,253,239,15,131,244,63,139,114,252,252,
+  139,2,137,106,252,252,137,66,252,248,209,229,129,252,253,0,0,224,252,255,
+  15,131,244,249,9,232,15,132,244,249,184,252,254,3,0,0,129,252,253,0,0,32,
+  0,15,130,244,250,248,1,193,252,237,21,41,197,255,252,242,15,42,197,255,137,
+  108,36,16,219,68,36,16,255,139,106,252,252,129,229,252,255,252,255,15,128,
+  129,205,0,0,224,63,137,106,252,252,248,2,255,252,242,15,17,2,255,221,26,255,
+  184,237,252,233,244,78,248,3,255,15,87,192,252,233,244,2,255,217,252,238,
+  252,233,244,2,255,248,4,255,252,242,15,16,2,189,0,0,80,67,102,15,110,205,
+  102,15,112,201,81,252,242,15,89,193,252,242,15,17,66,252,248,255,221,2,199,
+  68,36,16,0,0,128,90,216,76,36,16,221,90,252,248,255,139,106,252,252,184,52,
+  4,0,0,209,229,252,233,244,1,255,248,113,129,252,248,239,15,130,244,63,129,
+  122,253,4,239,15,131,244,63,252,242,15,16,2,255,248,113,129,252,248,239,15,
+  130,244,63,129,122,253,4,239,15,131,244,63,221,2,255,139,106,4,139,114,252,
+  252,209,229,129,252,253,0,0,224,252,255,15,132,244,250,255,15,40,224,232,
+  244,114,252,242,15,92,224,248,1,252,242,15,17,66,252,248,252,242,15,17,34,
+  255,217,192,232,244,114,220,252,233,248,1,221,90,252,248,221,26,255,139,66,
+  252,252,139,106,4,49,232,15,136,244,249,248,2,184,237,252,233,244,78,248,
+  3,129,252,245,0,0,0,128,137,106,4,252,233,244,2,248,4,255,15,87,228,252,233,
+  244,1,255,217,252,238,217,201,252,233,244,1,255,248,115,129,252,248,239,15,
+  130,244,63,129,122,253,4,239,15,131,244,63,129,122,253,12,239,15,131,244,
+  63,221,66,8,221,2,248,1,217,252,248,223,224,158,15,138,244,1,221,217,252,
+  233,244,73,255,248,116,129,252,248,239,15,130,244,63,129,122,253,4,239,15,
+  131,244,63,129,122,253,12,239,15,131,244,63,252,242,15,16,2,252,242,15,16,
+  74,8,232,244,117,252,233,244,72,255,248,116,129,252,248,239,15,130,244,63,
+  129,122,253,4,239,15,131,244,63,129,122,253,12,239,15,131,244,63,221,2,221,
+  66,8,232,244,117,252,233,244,73,255,248,118,185,2,0,0,0,129,122,253,4,239,
+  255,15,133,244,250,139,42,248,1,57,193,15,131,244,71,129,124,253,202,252,
+  252,239,15,133,244,249,59,108,202,252,248,15,79,108,202,252,248,131,193,1,
+  252,233,244,1,248,3,15,135,244,63,255,252,233,244,252,248,4,15,135,244,63,
+  255,252,242,15,16,2,248,5,57,193,15,131,244,72,129,124,253,202,252,252,239,
+  255,15,130,244,252,15,135,244,63,252,242,15,42,76,202,252,248,252,233,244,
+  253,255,248,6,252,242,15,16,76,202,252,248,248,7,252,242,15,93,193,131,193,
+  1,252,233,244,5,255,221,2,248,5,57,193,15,131,244,73,129,124,253,202,252,
+  252,239,255,15,130,244,252,15,135,244,255,219,68,202,252,248,252,233,244,
+  253,255,15,131,244,255,255,248,6,221,68,202,252,248,248,7,255,219,252,233,
+  219,209,221,217,255,80,221,225,223,224,252,246,196,1,15,132,244,248,217,201,
+  248,2,221,216,88,255,248,119,185,2,0,0,0,129,122,253,4,239,255,15,133,244,
+  250,139,42,248,1,57,193,15,131,244,71,129,124,253,202,252,252,239,15,133,
+  244,249,59,108,202,252,248,15,76,108,202,252,248,131,193,1,252,233,244,1,
+  248,3,15,135,244,63,255,248,6,252,242,15,16,76,202,252,248,248,7,252,242,
+  15,95,193,131,193,1,252,233,244,5,255,219,252,233,218,209,221,217,255,80,
+  221,225,223,224,252,246,196,1,15,133,244,248,217,201,248,2,221,216,88,255,
+  248,9,221,216,252,233,244,63,255,248,120,129,252,248,239,15,130,244,63,129,
+  122,253,4,239,15,133,244,63,139,42,255,139,173,233,252,233,244,71,255,252,
+  242,15,42,133,233,252,233,244,72,255,219,133,233,252,233,244,73,255,248,121,
+  129,252,248,239,15,133,244,63,129,122,253,4,239,15,133,244,63,139,42,139,
+  114,252,252,131,189,233,1,15,130,244,81,15,182,173,233,255,252,242,15,42,
+  197,252,233,244,72,255,137,108,36,16,219,68,36,16,252,233,244,73,255,248,
+  122,139,171,233,59,171,233,15,130,244,247,232,244,75,248,1,129,252,248,239,
+  15,133,244,63,129,122,253,4,239,255,15,133,244,63,139,42,129,252,253,252,
+  255,0,0,0,15,135,244,63,137,108,36,20,255,15,131,244,63,252,242,15,44,42,
+  129,252,253,252,255,0,0,0,15,135,244,63,137,108,36,20,255,15,131,244,63,221,
+  2,219,92,36,20,129,124,36,20,252,255,0,0,0,15,135,244,63,255,199,68,36,8,
+  1,0,0,0,141,68,36,20,248,123,139,108,36,48,137,149,233,137,68,36,4,137,44,
+  36,137,116,36,24,232,251,1,19,139,149,233,139,114,252,252,199,66,252,252,
+  237,137,66,252,248,252,233,244,66,248,124,139,171,233,59,171,233,15,130,244,
+  247,232,244,75,248,1,199,68,36,20,252,255,252,255,252,255,252,255,129,252,
+  248,239,15,130,244,63,15,134,244,247,129,122,253,20,239,255,15,133,244,63,
+  139,106,16,137,108,36,20,255,15,131,244,63,252,242,15,44,106,16,137,108,36,
+  20,255,15,131,244,63,221,66,16,219,92,36,20,255,248,1,129,122,253,4,239,15,
+  133,244,63,129,122,253,12,239,255,139,42,137,108,36,12,139,173,233,255,139,
+  74,8,255,252,242,15,44,74,8,255,221,66,8,219,92,36,8,139,76,36,8,255,139,
+  68,36,20,57,197,15,130,244,251,248,2,133,201,15,142,244,253,248,3,139,108,
+  36,12,41,200,15,140,244,125,141,172,253,13,233,131,192,1,248,4,137,68,36,
+  8,137,232,252,233,244,123,248,5,15,140,244,252,141,68,40,1,252,233,244,2,
+  248,6,137,232,252,233,244,2,248,7,255,15,132,244,254,1,252,233,131,193,1,
+  15,143,244,3,248,8,185,1,0,0,0,252,233,244,3,248,125,49,192,252,233,244,4,
+  248,126,129,252,248,239,15,130,244,63,139,171,233,59,171,233,15,130,244,247,
+  232,244,75,248,1,255,129,122,253,4,239,15,133,244,63,129,122,253,12,239,139,
+  42,255,15,133,244,63,139,66,8,255,15,131,244,63,252,242,15,44,66,8,255,15,
+  131,244,63,221,66,8,219,92,36,20,139,68,36,20,255,133,192,15,142,244,125,
+  131,189,233,1,15,130,244,125,15,133,244,127,57,131,233,15,130,244,127,15,
+  182,141,233,139,171,233,137,68,36,8,248,1,136,77,0,131,197,1,131,232,1,15,
+  133,244,1,139,131,233,252,233,244,123,248,128,129,252,248,239,255,15,130,
+  244,63,139,171,233,59,171,233,15,130,244,247,232,244,75,248,1,129,122,253,
+  4,239,15,133,244,63,139,42,139,133,233,133,192,15,132,244,125,57,131,233,
+  15,130,244,129,129,197,239,137,116,36,20,137,68,36,8,139,179,233,248,1,255,
+  15,182,77,0,131,197,1,131,232,1,136,12,6,15,133,244,1,137,252,240,139,116,
+  36,20,252,233,244,123,248,130,129,252,248,239,15,130,244,63,139,171,233,59,
+  171,233,15,130,244,247,232,244,75,248,1,129,122,253,4,239,15,133,244,63,139,
+  42,139,133,233,57,131,233,255,15,130,244,129,129,197,239,137,116,36,20,137,
+  68,36,8,139,179,233,252,233,244,249,248,1,15,182,76,5,0,131,252,249,65,15,
+  130,244,248,131,252,249,90,15,135,244,248,131,252,241,32,248,2,136,12,6,248,
+  3,131,232,1,15,137,244,1,137,252,240,139,116,36,20,252,233,244,123,248,131,
+  129,252,248,239,15,130,244,63,255,139,171,233,59,171,233,15,130,244,247,232,
+  244,75,248,1,129,122,253,4,239,15,133,244,63,139,42,139,133,233,57,131,233,
+  15,130,244,129,129,197,239,137,116,36,20,137,68,36,8,139,179,233,252,233,
+  244,249,248,1,15,182,76,5,0,131,252,249,97,15,130,244,248,255,131,252,249,
+  122,15,135,244,248,131,252,241,32,248,2,136,12,6,248,3,131,232,1,15,137,244,
+  1,137,252,240,139,116,36,20,252,233,244,123,248,132,129,252,248,239,15,130,
+  244,63,129,122,253,4,239,15,133,244,63,137,213,139,10,232,251,1,20,137,252,
+  234,255,137,197,252,233,244,71,255,252,242,15,42,192,252,233,244,72,255,137,
+  4,36,219,4,36,252,233,244,73,255,248,133,129,252,248,239,15,130,244,63,129,
+  122,253,4,239,255,15,133,244,247,139,42,252,233,244,89,248,1,15,135,244,63,
+  255,252,242,15,16,2,189,0,0,56,67,102,15,110,205,102,15,112,201,81,252,242,
+  15,88,193,102,15,126,197,255,221,2,199,68,36,16,0,0,192,89,216,68,36,16,221,
+  28,36,255,139,44,36,255,252,233,244,89,255,248,134,129,252,248,239,15,130,
+  244,63,255,189,0,0,56,67,102,15,110,205,102,15,112,201,81,255,199,68,36,16,
+  0,0,192,89,255,15,133,244,247,139,42,252,233,244,248,248,1,15,135,244,63,
+  255,252,242,15,16,2,252,242,15,88,193,102,15,126,197,255,221,2,216,68,36,
+  16,221,28,36,139,44,36,255,248,2,137,68,36,20,141,68,194,252,240,248,1,57,
+  208,15,134,244,89,129,120,253,4,239,255,15,133,244,248,35,40,131,232,8,252,
+  233,244,1,248,2,15,135,244,135,255,15,131,244,135,255,252,242,15,16,0,252,
+  242,15,88,193,102,15,126,193,33,205,255,221,0,216,68,36,16,221,28,36,35,44,
+  36,255,131,232,8,252,233,244,1,248,136,129,252,248,239,15,130,244,63,255,
+  15,133,244,248,11,40,131,232,8,252,233,244,1,248,2,15,135,244,135,255,252,
+  242,15,16,0,252,242,15,88,193,102,15,126,193,9,205,255,221,0,216,68,36,16,
+  221,28,36,11,44,36,255,131,232,8,252,233,244,1,248,137,129,252,248,239,15,
+  130,244,63,255,15,133,244,248,51,40,131,232,8,252,233,244,1,248,2,15,135,
+  244,135,255,252,242,15,16,0,252,242,15,88,193,102,15,126,193,49,205,255,221,
+  0,216,68,36,16,221,28,36,51,44,36,255,131,232,8,252,233,244,1,248,138,129,
+  252,248,239,15,130,244,63,129,122,253,4,239,255,221,2,199,68,36,16,0,0,192,
+  89,216,68,36,16,221,28,36,139,44,36,255,248,2,15,205,252,233,244,89,248,139,
+  129,252,248,239,15,130,244,63,129,122,253,4,239,255,248,2,252,247,213,255,
+  248,89,252,242,15,42,197,252,233,244,72,255,248,89,137,44,36,219,4,36,252,
+  233,244,73,255,248,135,139,68,36,20,252,233,244,63,255,248,140,129,252,248,
+  239,15,130,244,63,129,122,253,4,239,255,248,2,129,122,253,12,239,15,133,244,
+  63,139,74,8,255,248,140,129,252,248,239,15,130,244,63,129,122,253,4,239,15,
+  131,244,63,129,122,253,12,239,15,131,244,63,252,242,15,16,2,252,242,15,16,
+  74,8,189,0,0,56,67,102,15,110,213,102,15,112,210,81,252,242,15,88,194,252,
+  242,15,88,202,102,15,126,197,102,15,126,201,255,248,140,129,252,248,239,15,
+  130,244,63,129,122,253,4,239,15,131,244,63,129,122,253,12,239,15,131,244,
+  63,221,2,221,66,8,199,68,36,16,0,0,192,89,216,68,36,16,221,92,36,8,216,68,
+  36,16,221,28,36,139,76,36,8,139,44,36,255,211,229,252,233,244,89,255,248,
+  141,129,252,248,239,15,130,244,63,129,122,253,4,239,255,248,141,129,252,248,
+  239,15,130,244,63,129,122,253,4,239,15,131,244,63,129,122,253,12,239,15,131,
+  244,63,252,242,15,16,2,252,242,15,16,74,8,189,0,0,56,67,102,15,110,213,102,
+  15,112,210,81,252,242,15,88,194,252,242,15,88,202,102,15,126,197,102,15,126,
+  201,255,248,141,129,252,248,239,15,130,244,63,129,122,253,4,239,15,131,244,
+  63,129,122,253,12,239,15,131,244,63,221,2,221,66,8,199,68,36,16,0,0,192,89,
+  216,68,36,16,221,92,36,8,216,68,36,16,221,28,36,139,76,36,8,139,44,36,255,
+  211,252,237,252,233,244,89,255,248,142,129,252,248,239,15,130,244,63,129,
+  122,253,4,239,255,248,142,129,252,248,239,15,130,244,63,129,122,253,4,239,
+  15,131,244,63,129,122,253,12,239,15,131,244,63,252,242,15,16,2,252,242,15,
+  16,74,8,189,0,0,56,67,102,15,110,213,102,15,112,210,81,252,242,15,88,194,
+  252,242,15,88,202,102,15,126,197,102,15,126,201,255,248,142,129,252,248,239,
+  15,130,244,63,129,122,253,4,239,15,131,244,63,129,122,253,12,239,15,131,244,
+  63,221,2,221,66,8,199,68,36,16,0,0,192,89,216,68,36,16,221,92,36,8,216,68,
+  36,16,221,28,36,139,76,36,8,139,44,36,255,211,252,253,252,233,244,89,255,
+  248,143,129,252,248,239,15,130,244,63,129,122,253,4,239,255,248,143,129,252,
+  248,239,15,130,244,63,129,122,253,4,239,15,131,244,63,129,122,253,12,239,
+  15,131,244,63,252,242,15,16,2,252,242,15,16,74,8,189,0,0,56,67,102,15,110,
+  213,102,15,112,210,81,252,242,15,88,194,252,242,15,88,202,102,15,126,197,
+  102,15,126,201,255,248,143,129,252,248,239,15,130,244,63,129,122,253,4,239,
+  15,131,244,63,129,122,253,12,239,15,131,244,63,221,2,221,66,8,199,68,36,16,
+  0,0,192,89,216,68,36,16,221,92,36,8,216,68,36,16,221,28,36,139,76,36,8,139,
+  44,36,255,211,197,252,233,244,89,255,248,144,129,252,248,239,15,130,244,63,
+  129,122,253,4,239,255,248,144,129,252,248,239,15,130,244,63,129,122,253,4,
+  239,15,131,244,63,129,122,253,12,239,15,131,244,63,252,242,15,16,2,252,242,
+  15,16,74,8,189,0,0,56,67,102,15,110,213,102,15,112,210,81,252,242,15,88,194,
+  252,242,15,88,202,102,15,126,197,102,15,126,201,255,248,144,129,252,248,239,
+  15,130,244,63,129,122,253,4,239,15,131,244,63,129,122,253,12,239,15,131,244,
+  63,221,2,221,66,8,199,68,36,16,0,0,192,89,216,68,36,16,221,92,36,8,216,68,
+  36,16,221,28,36,139,76,36,8,139,44,36,255,211,205,252,233,244,89,248,127,
+  184,237,252,233,244,63,248,129,184,237,248,63,139,108,36,48,139,114,252,252,
+  137,116,36,24,137,149,233,141,68,194,252,248,141,136,233,137,133,233,139,
+  66,252,248,59,141,233,15,135,244,251,137,44,36,252,255,144,233,139,149,233,
+  133,192,15,143,244,78,248,1,255,139,141,233,41,209,193,252,233,3,133,192,
+  141,65,1,139,106,252,248,15,133,244,33,139,181,233,139,14,15,182,252,233,
+  15,182,205,131,198,4,252,255,36,171,248,33,137,209,252,247,198,237,15,133,
+  244,249,15,182,110,252,253,252,247,213,141,20,252,234,252,233,244,28,248,
+  3,137,252,245,131,229,252,248,41,252,234,252,233,244,28,248,5,186,237,137,
+  252,233,232,251,1,0,139,149,233,49,192,252,233,244,1,248,75,93,137,108,36,
+  16,139,108,36,48,137,116,36,24,137,149,233,255,141,68,194,252,248,137,252,
+  233,137,133,233,232,251,1,21,139,149,233,139,133,233,41,208,193,232,3,131,
+  192,1,139,108,36,16,85,195,248,145,255,15,182,131,233,168,235,15,133,244,
+  251,168,235,15,133,244,247,168,235,15,132,244,247,252,255,139,233,252,233,
+  244,247,255,248,146,15,182,131,233,168,235,15,133,244,251,252,233,244,247,
+  248,147,15,182,131,233,168,235,15,133,244,251,168,235,15,132,244,251,252,
+  255,139,233,15,132,244,247,168,235,15,132,244,251,248,1,255,139,108,36,48,
+  137,149,233,137,252,242,137,252,233,232,251,1,22,248,3,139,149,233,248,4,
+  15,182,78,252,253,248,5,15,182,110,252,252,15,183,70,252,254,252,255,164,
+  253,171,233,248,148,131,198,4,139,77,232,137,76,36,20,252,233,244,4,248,149,
+  255,139,106,252,248,139,173,233,15,182,133,233,141,4,194,139,108,36,48,137,
+  149,233,137,133,233,137,252,242,141,139,233,137,171,233,137,116,36,24,232,
+  251,1,23,252,233,244,3,255,248,150,137,116,36,24,255,248,151,255,137,116,
+  36,24,131,206,1,248,1,255,141,68,194,252,248,139,108,36,48,137,149,233,137,
+  133,233,137,252,242,137,252,233,232,251,1,24,199,68,36,24,0,0,0,0,255,131,
+  230,252,254,255,139,149,233,137,193,139,133,233,41,208,137,205,15,182,78,
+  252,253,193,232,3,131,192,1,252,255,229,248,152,255,85,141,108,36,12,85,83,
+  82,81,80,15,182,69,252,252,138,101,252,248,137,125,252,252,137,117,252,248,
+  139,93,0,139,139,233,199,131,233,237,137,131,233,137,139,233,129,252,236,
+  239,252,242,15,17,125,216,252,242,15,17,117,208,252,242,15,17,109,200,252,
+  242,15,17,101,192,252,242,15,17,93,184,252,242,15,17,85,176,252,242,15,17,
+  77,168,252,242,15,17,69,160,139,171,233,139,147,233,137,171,233,199,131,233,
+  0,0,0,0,137,149,233,141,84,36,16,141,139,233,232,251,1,25,139,141,233,129,
+  225,239,137,204,137,169,233,139,149,233,139,177,233,255,248,153,255,133,192,
+  15,136,244,249,137,68,36,20,139,122,252,248,139,191,233,139,191,233,199,131,
+  233,0,0,0,0,199,131,233,237,139,6,15,182,204,15,182,232,131,198,4,193,232,
+  16,129,252,253,239,15,130,244,248,139,68,36,20,248,2,252,255,36,171,248,3,
+  252,247,216,137,252,233,137,194,232,251,1,26,255,248,91,255,217,124,36,4,
+  137,68,36,8,102,184,0,4,102,11,68,36,4,102,37,252,255,252,247,102,137,68,
+  36,6,217,108,36,6,217,252,252,217,108,36,4,139,68,36,8,195,255,248,154,102,
+  15,252,239,210,102,15,118,210,102,15,115,210,1,184,0,0,48,67,102,15,110,216,
+  102,15,112,219,81,15,40,200,102,15,84,202,102,15,46,217,15,134,244,247,102,
+  15,85,208,252,242,15,88,203,252,242,15,92,203,102,15,86,202,184,0,0,252,240,
+  63,102,15,110,208,102,15,112,210,81,252,242,15,194,193,1,102,15,84,194,252,
+  242,15,92,200,15,40,193,248,1,195,248,93,255,217,124,36,4,137,68,36,8,102,
+  184,0,8,102,11,68,36,4,102,37,252,255,252,251,102,137,68,36,6,217,108,36,
+  6,217,252,252,217,108,36,4,139,68,36,8,195,255,248,155,102,15,252,239,210,
+  102,15,118,210,102,15,115,210,1,184,0,0,48,67,102,15,110,216,102,15,112,219,
+  81,15,40,200,102,15,84,202,102,15,46,217,15,134,244,247,102,15,85,208,252,
+  242,15,88,203,252,242,15,92,203,102,15,86,202,184,0,0,252,240,191,102,15,
+  110,208,102,15,112,210,81,252,242,15,194,193,6,102,15,84,194,252,242,15,92,
+  200,15,40,193,248,1,195,248,114,255,217,124,36,4,137,68,36,8,102,184,0,12,
+  102,11,68,36,4,102,137,68,36,6,217,108,36,6,217,252,252,217,108,36,4,139,
+  68,36,8,195,255,248,156,102,15,252,239,210,102,15,118,210,102,15,115,210,
   1,184,0,0,48,67,102,15,110,216,102,15,112,219,81,15,40,200,102,15,84,202,
-  102,15,46,217,15,134,244,247,102,15,85,208,252,242,15,88,203,252,242,15,92,
-  203,102,15,86,202,184,0,0,252,240,63,102,15,110,208,102,15,112,210,81,252,
-  242,15,194,193,1,102,15,84,194,252,242,15,92,200,15,40,193,248,1,195,248,
-  92,255,217,124,36,4,137,68,36,8,102,184,0,8,102,11,68,36,4,102,37,252,255,
-  252,251,102,137,68,36,6,217,108,36,6,217,252,252,217,108,36,4,139,68,36,8,
-  195,255,248,154,102,15,252,239,210,102,15,118,210,102,15,115,210,1,184,0,
-  0,48,67,102,15,110,216,102,15,112,219,81,15,40,200,102,15,84,202,102,15,46,
-  217,15,134,244,247,102,15,85,208,252,242,15,88,203,252,242,15,92,203,102,
-  15,86,202,184,0,0,252,240,191,102,15,110,208,102,15,112,210,81,252,242,15,
-  194,193,6,102,15,84,194,252,242,15,92,200,15,40,193,248,1,195,248,113,255,
-  217,124,36,4,137,68,36,8,102,184,0,12,102,11,68,36,4,102,137,68,36,6,217,
-  108,36,6,217,252,252,217,108,36,4,139,68,36,8,195,255,248,155,102,15,252,
-  239,210,102,15,118,210,102,15,115,210,1,184,0,0,48,67,102,15,110,216,102,
-  15,112,219,81,15,40,200,102,15,84,202,102,15,46,217,15,134,244,247,102,15,
-  85,208,15,40,193,252,242,15,88,203,252,242,15,92,203,184,0,0,252,240,63,102,
-  15,110,216,102,15,112,219,81,252,242,15,194,193,1,102,15,84,195,252,242,15,
-  92,200,102,15,86,202,15,40,193,248,1,195,248,156,255,15,40,232,252,242,15,
-  94,193,102,15,252,239,210,102,15,118,210,102,15,115,210,1,184,0,0,48,67,102,
-  15,110,216,102,15,112,219,81,15,40,224,102,15,84,226,102,15,46,220,15,134,
-  244,247,102,15,85,208,252,242,15,88,227,252,242,15,92,227,102,15,86,226,184,
-  0,0,252,240,63,102,15,110,208,102,15,112,210,81,252,242,15,194,196,1,102,
-  15,84,194,252,242,15,92,224,15,40,197,252,242,15,89,204,252,242,15,92,193,
-  195,248,1,252,242,15,89,200,15,40,197,252,242,15,92,193,195,255,217,193,216,
-  252,241,217,124,36,4,102,184,0,4,102,11,68,36,4,102,37,252,255,252,247,102,
-  137,68,36,6,217,108,36,6,217,252,252,217,108,36,4,222,201,222,252,233,195,
-  255,248,97,217,252,234,222,201,248,157,217,84,36,4,129,124,36,4,0,0,128,127,
-  15,132,244,247,129,124,36,4,0,0,128,252,255,15,132,244,248,248,158,217,192,
-  217,252,252,220,252,233,217,201,217,252,240,217,232,222,193,217,252,253,221,
-  217,248,1,195,248,2,221,216,217,252,238,195,255,248,116,219,84,36,4,219,68,
-  36,4,255,223,252,233,255,221,252,233,223,224,158,255,15,133,244,254,15,138,
-  244,255,221,216,139,68,36,4,131,252,248,1,15,142,244,252,248,1,169,1,0,0,
-  0,15,133,244,248,216,200,209,232,252,233,244,1,248,2,209,232,15,132,244,251,
-  217,192,248,3,216,200,209,232,15,132,244,250,15,131,244,3,220,201,252,233,
-  244,3,248,4,255,222,201,248,5,195,248,6,15,132,244,5,15,130,244,253,217,232,
-  222,252,241,252,247,216,131,252,248,1,15,132,244,5,252,233,244,1,248,7,221,
-  216,217,232,195,248,8,217,84,36,4,217,201,217,84,36,8,139,68,36,4,209,224,
-  61,0,0,0,252,255,15,132,244,248,139,68,36,8,209,224,15,132,244,250,61,0,0,
-  0,252,255,15,132,244,250,217,252,241,252,233,244,158,248,9,255,217,232,255,
-  223,252,234,255,221,252,234,223,224,158,255,15,132,244,247,217,201,248,1,
-  221,216,195,248,2,217,225,217,232,255,15,132,244,249,221,216,217,225,217,
-  252,238,184,0,0,0,0,15,146,208,209,200,51,68,36,4,15,137,244,249,217,201,
-  248,3,221,217,217,225,195,248,4,131,124,36,4,0,15,141,244,3,221,216,221,216,
-  133,192,15,132,244,251,217,252,238,195,248,5,199,68,36,4,0,0,128,127,217,
-  68,36,4,195,255,248,116,255,248,159,252,242,15,45,193,252,242,15,42,208,102,
-  15,46,202,15,133,244,254,15,138,244,255,248,160,131,252,248,1,15,142,244,
-  252,248,1,169,1,0,0,0,15,133,244,248,252,242,15,89,192,209,232,252,233,244,
-  1,248,2,209,232,15,132,244,251,15,40,200,248,3,252,242,15,89,192,209,232,
-  15,132,244,250,15,131,244,3,255,252,242,15,89,200,252,233,244,3,248,4,252,
-  242,15,89,193,248,5,195,248,6,15,132,244,5,15,130,244,253,252,247,216,232,
-  244,1,184,0,0,252,240,63,102,15,110,200,102,15,112,201,81,252,242,15,94,200,
-  15,40,193,195,248,7,184,0,0,252,240,63,102,15,110,192,102,15,112,192,81,195,
-  248,8,252,242,15,17,76,36,12,252,242,15,17,68,36,4,131,124,36,12,0,15,133,
-  244,247,139,68,36,16,209,224,61,0,0,224,252,255,15,132,244,248,248,1,131,
-  124,36,4,0,15,133,244,247,255,139,68,36,8,209,224,15,132,244,250,61,0,0,224,
-  252,255,15,132,244,251,248,1,221,68,36,12,221,68,36,4,217,252,241,217,192,
-  217,252,252,220,252,233,217,201,217,252,240,217,232,222,193,217,252,253,221,
-  217,221,92,36,4,252,242,15,16,68,36,4,195,248,9,184,0,0,252,240,63,102,15,
-  110,208,102,15,112,210,81,102,15,46,194,15,132,244,247,15,40,193,248,1,195,
-  248,2,102,15,252,239,210,102,15,118,210,102,15,115,210,1,102,15,84,194,184,
-  0,0,252,240,63,102,15,110,208,102,15,112,210,81,102,15,46,194,15,132,244,
-  1,102,15,80,193,15,87,192,136,196,15,146,208,48,224,15,133,244,1,248,3,184,
-  0,0,252,240,127,102,15,110,192,102,15,112,192,81,195,248,4,102,15,80,193,
-  133,192,15,133,244,3,15,87,192,195,248,5,102,15,80,193,133,192,15,132,244,
-  3,255,15,87,192,195,248,161,255,139,68,36,12,252,242,15,16,68,36,4,131,252,
-  248,1,15,132,244,247,15,135,244,248,232,244,90,252,233,244,253,248,1,232,
-  244,92,252,233,244,253,248,2,131,252,248,3,15,132,244,247,15,135,244,248,
-  232,244,113,255,252,233,244,253,248,1,252,242,15,81,192,248,7,252,242,15,
-  17,68,36,4,221,68,36,4,195,248,2,221,68,36,4,131,252,248,5,15,130,244,97,
-  15,132,244,157,248,2,131,252,248,7,15,132,244,247,15,135,244,248,217,252,
-  237,217,201,217,252,241,195,248,1,217,232,217,201,217,252,241,195,248,2,131,
-  252,248,9,15,132,244,247,15,135,244,248,255,217,252,236,217,201,217,252,241,
-  195,248,1,217,252,254,195,248,2,131,252,248,11,15,132,244,247,15,135,244,
-  255,217,252,255,195,248,1,217,252,242,221,216,195,255,139,68,36,12,221,68,
-  36,4,131,252,248,1,15,130,244,90,15,132,244,92,131,252,248,3,15,130,244,113,
-  15,135,244,248,217,252,250,195,248,2,131,252,248,5,15,130,244,97,15,132,244,
-  157,131,252,248,7,15,132,244,247,15,135,244,248,217,252,237,217,201,217,252,
-  241,195,248,1,217,232,217,201,217,252,241,195,248,2,131,252,248,9,15,132,
-  244,247,255,15,135,244,248,217,252,236,217,201,217,252,241,195,248,1,217,
-  252,254,195,248,2,131,252,248,11,15,132,244,247,15,135,244,255,217,252,255,
-  195,248,1,217,252,242,221,216,195,255,248,9,204,255,248,162,255,139,68,36,
-  20,252,242,15,16,68,36,4,252,242,15,16,76,36,12,131,252,248,1,15,132,244,
-  247,15,135,244,248,252,242,15,88,193,248,7,252,242,15,17,68,36,4,221,68,36,
-  4,195,248,1,252,242,15,92,193,252,233,244,7,248,2,131,252,248,3,15,132,244,
-  247,15,135,244,248,252,242,15,89,193,252,233,244,7,248,1,252,242,15,94,193,
-  252,233,244,7,248,2,131,252,248,5,15,132,244,247,255,15,135,244,248,232,244,
-  156,252,233,244,7,248,1,90,232,244,116,82,252,233,244,7,248,2,131,252,248,
-  7,15,132,244,247,15,135,244,248,184,0,0,0,128,102,15,110,200,102,15,112,201,
-  81,15,87,193,252,233,244,7,248,1,102,15,252,239,201,102,15,118,201,102,15,
-  115,209,1,15,84,193,252,233,244,7,248,2,255,131,252,248,9,15,135,244,248,
-  221,68,36,4,221,68,36,12,15,132,244,247,217,252,243,195,248,1,217,201,217,
-  252,253,221,217,195,248,2,131,252,248,11,15,132,244,247,15,135,244,255,252,
-  242,15,93,193,252,233,244,7,248,1,252,242,15,95,193,252,233,244,7,248,9,204,
-  255,139,68,36,20,221,68,36,4,221,68,36,12,131,252,248,1,15,132,244,247,15,
-  135,244,248,222,193,195,248,1,222,252,233,195,248,2,131,252,248,3,15,132,
-  244,247,15,135,244,248,222,201,195,248,1,222,252,249,195,248,2,131,252,248,
-  5,15,130,244,156,15,132,244,116,131,252,248,7,15,132,244,247,15,135,244,248,
-  255,221,216,217,224,195,248,1,221,216,217,225,195,248,2,131,252,248,9,15,
-  132,244,247,15,135,244,248,217,252,243,195,248,1,217,201,217,252,253,221,
-  217,195,248,2,131,252,248,11,15,132,244,247,15,135,244,255,255,219,252,233,
-  219,209,221,217,195,248,1,219,252,233,218,209,221,217,195,255,221,225,223,
-  224,252,246,196,1,15,132,244,248,217,201,248,2,221,216,195,248,1,221,225,
-  223,224,252,246,196,1,15,133,244,248,217,201,248,2,221,216,195,255,248,163,
-  156,90,137,209,129,252,242,0,0,32,0,82,157,156,90,49,192,57,209,15,132,244,
-  247,139,68,36,4,87,83,15,162,139,124,36,16,137,7,137,95,4,137,79,8,137,87,
-  12,91,95,248,1,195,248,164,255,85,137,229,83,137,203,43,163,233,255,137,163,
-  233,255,15,182,139,233,131,252,233,1,15,136,244,248,248,1,139,132,253,139,
-  233,137,4,140,131,252,233,1,15,137,244,1,248,2,139,139,233,139,147,233,252,
-  255,147,233,137,131,233,137,147,233,128,187,233,1,15,130,244,253,15,132,244,
-  252,221,155,233,252,233,244,253,248,6,255,217,155,233,248,7,255,41,163,233,
-  255,139,93,252,252,201,195,255,248,165,255,249,255,129,124,253,202,4,239,
-  15,133,244,253,129,124,253,194,4,239,15,133,244,254,139,44,202,131,198,4,
-  59,44,194,255,15,141,244,255,255,15,140,244,255,255,15,143,244,255,255,15,
-  142,244,255,255,248,6,15,183,70,252,254,141,180,253,134,233,248,9,139,6,15,
-  182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,7,15,135,244,43,
-  129,124,253,194,4,239,15,130,244,247,15,133,244,43,255,252,242,15,42,4,194,
-  252,233,244,248,255,221,4,202,219,4,194,252,233,244,249,255,248,8,15,135,
-  244,43,255,252,242,15,42,12,202,252,242,15,16,4,194,131,198,4,102,15,46,193,
-  255,15,134,244,9,255,15,135,244,9,255,15,130,244,9,255,15,131,244,9,255,252,
-  233,244,6,255,219,4,202,252,233,244,248,255,129,124,253,202,4,239,15,131,
-  244,43,129,124,253,194,4,239,15,131,244,43,255,248,1,252,242,15,16,4,194,
-  248,2,131,198,4,102,15,46,4,202,248,3,255,248,1,221,4,202,248,2,221,4,194,
-  248,3,131,198,4,255,15,134,244,247,255,15,135,244,247,255,15,130,244,247,
-  255,15,131,244,247,255,15,183,70,252,254,141,180,253,134,233,248,1,139,6,
-  15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,255,139,108,194,
-  4,131,198,4,255,129,252,253,239,15,133,244,253,129,124,253,202,4,239,15,133,
-  244,254,139,44,194,59,44,202,255,15,133,244,255,255,15,132,244,255,255,15,
-  183,70,252,254,141,180,253,134,233,248,9,139,6,15,182,204,15,182,232,131,
-  198,4,193,232,16,252,255,36,171,248,7,15,135,244,251,129,124,253,202,4,239,
-  15,130,244,247,15,133,244,251,255,252,242,15,42,4,202,255,219,4,202,255,252,
-  233,244,248,248,8,15,135,244,251,255,252,242,15,42,4,194,102,15,46,4,202,
-  255,219,4,194,221,4,202,255,252,233,244,250,255,129,252,253,239,15,131,244,
-  251,129,124,253,202,4,239,15,131,244,251,255,248,1,252,242,15,16,4,202,248,
-  2,102,15,46,4,194,248,4,255,248,1,221,4,202,248,2,221,4,194,248,4,255,15,
-  138,244,248,15,133,244,248,255,15,138,244,248,15,132,244,247,255,248,1,15,
-  183,70,252,254,141,180,253,134,233,248,2,255,248,2,15,183,70,252,254,141,
-  180,253,134,233,248,1,255,252,233,244,9,255,248,5,255,129,252,253,239,15,
-  132,244,48,129,124,253,202,4,239,15,132,244,48,255,57,108,202,4,15,133,244,
-  2,129,252,253,239,15,131,244,1,139,12,202,139,4,194,57,193,15,132,244,1,129,
-  252,253,239,15,135,244,2,139,169,233,133,252,237,15,132,244,2,252,246,133,
-  233,235,15,133,244,2,255,49,252,237,255,189,1,0,0,0,255,252,233,244,47,255,
-  248,3,129,252,253,239,255,15,133,244,9,255,252,233,244,48,255,252,247,208,
-  139,108,202,4,131,198,4,129,252,253,239,15,133,244,249,139,12,202,59,12,135,
-  255,139,108,202,4,131,198,4,255,129,252,253,239,15,133,244,253,129,124,253,
-  199,4,239,15,133,244,254,139,44,199,59,44,202,255,15,183,70,252,254,141,180,
-  253,134,233,248,9,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,
-  36,171,248,7,15,135,244,249,129,124,253,199,4,239,15,130,244,247,255,252,
-  242,15,42,4,199,255,219,4,199,255,252,233,244,248,248,8,255,252,242,15,42,
-  4,202,102,15,46,4,199,255,219,4,202,221,4,199,255,129,252,253,239,15,131,
-  244,249,255,248,1,252,242,15,16,4,199,248,2,102,15,46,4,202,248,4,255,248,
-  1,221,4,199,248,2,221,4,202,248,4,255,252,247,208,139,108,202,4,131,198,4,
-  57,197,255,15,133,244,249,15,183,70,252,254,141,180,253,134,233,248,2,139,
-  6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,3,129,252,
-  253,239,15,133,244,2,252,233,244,48,255,15,132,244,248,129,252,253,239,15,
-  132,244,48,15,183,70,252,254,141,180,253,134,233,248,2,139,6,15,182,204,15,
-  182,232,131,198,4,193,232,16,252,255,36,171,255,139,108,194,4,131,198,4,129,
-  252,253,239,255,137,108,202,4,139,44,194,137,44,202,255,139,108,194,4,139,
-  4,194,137,108,202,4,137,4,202,139,6,15,182,204,15,182,232,131,198,4,193,232,
-  16,252,255,36,171,255,49,252,237,129,124,253,194,4,239,129,213,239,137,108,
-  202,4,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,255,
-  129,124,253,194,4,239,15,133,244,251,139,44,194,252,247,221,15,128,244,250,
-  199,68,202,4,237,137,44,202,248,9,139,6,15,182,204,15,182,232,131,198,4,193,
-  232,16,252,255,36,171,248,4,199,68,202,4,0,0,224,65,199,4,202,0,0,0,0,252,
-  233,244,9,248,5,15,135,244,53,255,129,124,253,194,4,239,15,131,244,53,255,
-  252,242,15,16,4,194,184,0,0,0,128,102,15,110,200,102,15,112,201,81,15,87,
-  193,252,242,15,17,4,202,255,221,4,194,217,224,221,28,202,255,129,124,253,
-  194,4,239,15,133,244,248,139,4,194,255,139,128,233,248,1,199,68,202,4,237,
-  137,4,202,255,15,87,192,252,242,15,42,128,233,248,1,252,242,15,17,4,202,255,
-  219,128,233,248,1,221,28,202,255,139,6,15,182,204,15,182,232,131,198,4,193,
-  232,16,252,255,36,171,248,2,129,124,253,194,4,239,15,133,244,56,139,12,194,
-  255,139,169,233,131,252,253,0,15,133,244,255,248,3,255,248,57,137,213,232,
-  251,1,20,255,252,242,15,42,192,255,137,4,36,219,4,36,255,137,252,234,15,182,
-  78,252,253,252,233,244,1,255,248,9,252,246,133,233,235,15,133,244,3,252,233,
-  244,56,255,15,182,252,236,15,182,192,255,129,124,253,252,234,4,239,15,133,
-  244,50,129,124,253,199,4,239,15,133,244,50,139,44,252,234,3,44,199,15,128,
-  244,49,255,129,124,253,252,234,4,239,15,133,244,52,129,124,253,199,4,239,
-  15,133,244,52,139,4,199,3,4,252,234,15,128,244,51,255,129,124,253,252,234,
-  4,239,15,133,244,55,129,124,253,194,4,239,15,133,244,55,139,44,252,234,3,
-  44,194,15,128,244,54,255,199,68,202,4,237,255,129,124,253,252,234,4,239,15,
-  131,244,50,255,129,124,253,199,4,239,15,131,244,50,255,252,242,15,16,4,252,
-  234,252,242,15,88,4,199,255,221,4,252,234,220,4,199,255,129,124,253,252,234,
-  4,239,15,131,244,52,255,129,124,253,199,4,239,15,131,244,52,255,252,242,15,
-  16,4,199,252,242,15,88,4,252,234,255,221,4,199,220,4,252,234,255,129,124,
-  253,252,234,4,239,15,131,244,55,129,124,253,194,4,239,15,131,244,55,255,252,
-  242,15,16,4,252,234,252,242,15,88,4,194,255,221,4,252,234,220,4,194,255,129,
-  124,253,252,234,4,239,15,133,244,50,129,124,253,199,4,239,15,133,244,50,139,
-  44,252,234,43,44,199,15,128,244,49,255,129,124,253,252,234,4,239,15,133,244,
-  52,129,124,253,199,4,239,15,133,244,52,139,4,199,43,4,252,234,15,128,244,
-  51,255,129,124,253,252,234,4,239,15,133,244,55,129,124,253,194,4,239,15,133,
-  244,55,139,44,252,234,43,44,194,15,128,244,54,255,252,242,15,16,4,252,234,
-  252,242,15,92,4,199,255,221,4,252,234,220,36,199,255,252,242,15,16,4,199,
-  252,242,15,92,4,252,234,255,221,4,199,220,36,252,234,255,252,242,15,16,4,
-  252,234,252,242,15,92,4,194,255,221,4,252,234,220,36,194,255,129,124,253,
-  252,234,4,239,15,133,244,50,129,124,253,199,4,239,15,133,244,50,139,44,252,
-  234,15,175,44,199,15,128,244,49,255,129,124,253,252,234,4,239,15,133,244,
-  52,129,124,253,199,4,239,15,133,244,52,139,4,199,15,175,4,252,234,15,128,
-  244,51,255,129,124,253,252,234,4,239,15,133,244,55,129,124,253,194,4,239,
-  15,133,244,55,139,44,252,234,15,175,44,194,15,128,244,54,255,252,242,15,16,
-  4,252,234,252,242,15,89,4,199,255,221,4,252,234,220,12,199,255,252,242,15,
-  16,4,199,252,242,15,89,4,252,234,255,221,4,199,220,12,252,234,255,252,242,
-  15,16,4,252,234,252,242,15,89,4,194,255,221,4,252,234,220,12,194,255,252,
-  242,15,16,4,252,234,252,242,15,94,4,199,255,221,4,252,234,220,52,199,255,
-  252,242,15,16,4,199,252,242,15,94,4,252,234,255,221,4,199,220,52,252,234,
-  255,252,242,15,16,4,252,234,252,242,15,94,4,194,255,221,4,252,234,220,52,
-  194,255,252,242,15,16,4,252,234,252,242,15,16,12,199,255,221,4,252,234,221,
-  4,199,255,252,242,15,16,4,199,252,242,15,16,12,252,234,255,221,4,199,221,
-  4,252,234,255,252,242,15,16,4,252,234,252,242,15,16,12,194,255,221,4,252,
-  234,221,4,194,255,248,166,232,244,156,255,252,233,244,166,255,232,244,116,
-  255,15,182,252,236,15,182,192,141,12,194,41,232,137,76,36,4,137,68,36,8,248,
-  35,139,108,36,48,137,44,36,137,149,233,137,116,36,24,232,251,1,27,139,149,
-  233,133,192,15,133,244,44,15,182,110,252,255,15,182,78,252,253,139,68,252,
-  234,4,139,44,252,234,137,68,202,4,137,44,202,139,6,15,182,204,15,182,232,
-  131,198,4,193,232,16,252,255,36,171,255,252,247,208,139,4,135,199,68,202,
-  4,237,137,4,202,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,
-  36,171,255,15,191,192,199,68,202,4,237,137,4,202,255,15,191,192,252,242,15,
-  42,192,252,242,15,17,4,202,255,223,70,252,254,221,28,202,255,252,242,15,16,
-  4,199,252,242,15,17,4,202,255,221,4,199,221,28,202,255,252,247,208,137,68,
-  202,4,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,255,
-  141,76,202,12,141,68,194,4,189,237,137,105,252,248,248,1,137,41,131,193,8,
-  57,193,15,134,244,1,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,
-  255,36,171,255,139,106,252,248,139,172,253,133,233,139,173,233,139,69,4,139,
-  109,0,137,68,202,4,137,44,202,139,6,15,182,204,15,182,232,131,198,4,193,232,
-  16,252,255,36,171,255,139,106,252,248,139,172,253,141,233,128,189,233,0,139,
-  173,233,139,12,194,139,68,194,4,137,77,0,137,69,4,15,132,244,247,252,246,
-  133,233,235,15,133,244,248,248,1,139,6,15,182,204,15,182,232,131,198,4,193,
-  232,16,252,255,36,171,248,2,129,232,239,129,252,248,239,15,134,244,1,252,
-  246,129,233,235,15,132,244,1,135,213,141,139,233,255,232,251,1,28,137,252,
-  234,252,233,244,1,255,252,247,208,139,106,252,248,139,172,253,141,233,139,
-  12,135,139,133,233,137,8,199,64,4,237,252,246,133,233,235,15,133,244,248,
-  248,1,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,
-  2,252,246,129,233,235,15,132,244,1,128,189,233,0,15,132,244,1,137,213,137,
-  194,141,139,233,232,251,1,28,137,252,234,252,233,244,1,255,139,106,252,248,
-  255,252,242,15,16,4,199,255,139,172,253,141,233,139,141,233,255,252,242,15,
-  17,1,255,221,25,255,252,247,208,139,106,252,248,139,172,253,141,233,139,141,
-  233,137,65,4,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,
-  171,255,141,180,253,134,233,139,108,36,48,131,189,233,0,15,132,244,247,137,
-  149,233,141,20,202,137,252,233,232,251,1,29,139,149,233,248,1,139,6,15,182,
-  204,15,182,232,131,198,4,193,232,16,252,255,36,171,255,252,247,208,139,74,
-  252,248,139,4,135,139,108,36,48,137,76,36,8,137,68,36,4,137,44,36,137,149,
-  233,137,116,36,24,232,251,1,30,139,149,233,15,182,78,252,253,137,4,202,199,
-  68,202,4,237,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,
-  171,255,139,108,36,48,137,149,233,139,139,233,59,139,233,137,116,36,24,15,
-  131,244,251,248,1,137,193,37,252,255,7,0,0,193,252,233,11,137,76,36,8,61,
-  252,255,7,0,0,15,132,244,249,248,2,137,44,36,137,68,36,4,232,251,1,31,139,
-  149,233,15,182,78,252,253,137,4,202,199,68,202,4,237,139,6,15,182,204,15,
-  182,232,131,198,4,193,232,16,252,255,36,171,248,3,184,1,8,0,0,252,233,244,
-  2,248,5,137,252,233,232,251,1,32,15,183,70,252,254,252,233,244,1,255,252,
-  247,208,139,108,36,48,139,139,233,137,116,36,24,59,139,233,137,149,233,15,
-  131,244,249,248,2,139,20,135,137,252,233,232,251,1,33,139,149,233,15,182,
-  78,252,253,137,4,202,199,68,202,4,237,139,6,15,182,204,15,182,232,131,198,
-  4,193,232,16,252,255,36,171,248,3,137,252,233,232,251,1,32,15,183,70,252,
-  254,252,247,208,252,233,244,2,255,252,247,208,139,106,252,248,139,173,233,
-  139,4,135,252,233,244,167,255,252,247,208,139,106,252,248,139,173,233,139,
-  4,135,252,233,244,168,255,15,182,252,236,15,182,192,129,124,253,252,234,4,
-  239,15,133,244,38,139,44,252,234,255,129,124,253,194,4,239,15,133,244,251,
-  139,4,194,255,129,124,253,194,4,239,15,131,244,251,255,252,242,15,16,4,194,
-  252,242,15,45,192,252,242,15,42,200,102,15,46,193,255,221,4,194,219,20,36,
-  219,4,36,255,15,133,244,38,255,59,133,233,15,131,244,38,193,224,3,3,133,233,
-  129,120,253,4,239,15,132,244,248,139,40,139,64,4,137,44,202,137,68,202,4,
-  248,1,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,
-  2,131,189,233,0,15,132,244,249,139,141,233,252,246,129,233,235,15,132,244,
-  38,15,182,78,252,253,248,3,199,68,202,4,237,252,233,244,1,248,5,255,129,124,
-  253,194,4,239,15,133,244,38,139,4,194,252,233,244,167,255,15,182,252,236,
-  15,182,192,252,247,208,139,4,135,129,124,253,252,234,4,239,15,133,244,36,
-  139,44,252,234,248,167,139,141,233,35,136,233,105,201,239,3,141,233,248,1,
-  129,185,233,239,15,133,244,250,57,129,233,15,133,244,250,129,121,253,4,239,
-  15,132,244,251,15,182,70,252,253,139,41,139,73,4,137,44,194,137,76,194,4,
-  248,2,255,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,
-  248,3,15,182,70,252,253,199,68,194,4,237,252,233,244,2,248,4,139,137,233,
-  133,201,15,133,244,1,248,5,139,141,233,133,201,15,132,244,3,252,246,129,233,
-  235,15,133,244,3,252,233,244,36,255,15,182,252,236,15,182,192,129,124,253,
-  252,234,4,239,15,133,244,37,139,44,252,234,59,133,233,15,131,244,37,193,224,
-  3,3,133,233,129,120,253,4,239,15,132,244,248,139,40,139,64,4,137,44,202,137,
-  68,202,4,248,1,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,
-  171,248,2,131,189,233,0,15,132,244,249,139,141,233,252,246,129,233,235,15,
-  132,244,37,255,15,182,78,252,253,248,3,199,68,202,4,237,252,233,244,1,255,
-  15,182,252,236,15,182,192,129,124,253,252,234,4,239,15,133,244,41,139,44,
-  252,234,255,15,133,244,41,255,59,133,233,15,131,244,41,193,224,3,3,133,233,
-  129,120,253,4,239,15,132,244,249,248,1,252,246,133,233,235,15,133,244,253,
-  248,2,139,108,202,4,139,12,202,137,104,4,137,8,139,6,15,182,204,15,182,232,
-  131,198,4,193,232,16,252,255,36,171,248,3,131,189,233,0,15,132,244,1,139,
-  141,233,252,246,129,233,235,255,15,132,244,41,15,182,78,252,253,252,233,244,
-  1,248,5,129,124,253,194,4,239,15,133,244,41,139,4,194,252,233,244,168,248,
-  7,128,165,233,235,139,139,233,137,171,233,137,141,233,15,182,78,252,253,252,
-  233,244,2,255,15,182,252,236,15,182,192,252,247,208,139,4,135,129,124,253,
-  252,234,4,239,15,133,244,39,139,44,252,234,248,168,139,141,233,35,136,233,
-  105,201,239,198,133,233,0,3,141,233,248,1,129,185,233,239,15,133,244,251,
-  57,129,233,15,133,244,251,129,121,253,4,239,15,132,244,250,248,2,255,252,
-  246,133,233,235,15,133,244,253,248,3,15,182,70,252,253,139,108,194,4,139,
-  4,194,137,105,4,137,1,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,
-  255,36,171,248,4,131,189,233,0,15,132,244,2,137,76,36,16,139,141,233,252,
-  246,129,233,235,15,132,244,39,139,76,36,16,252,233,244,2,248,5,139,137,233,
-  133,201,15,133,244,1,255,139,141,233,133,201,15,132,244,252,252,246,129,233,
-  235,15,132,244,39,248,6,137,68,36,16,199,68,36,20,237,137,108,36,12,141,68,
-  36,16,137,108,36,4,139,108,36,48,137,68,36,8,137,44,36,137,149,233,137,116,
-  36,24,232,251,1,34,139,149,233,139,108,36,12,137,193,252,233,244,2,248,7,
-  128,165,233,235,139,131,233,137,171,233,137,133,233,252,233,244,3,255,15,
-  182,252,236,15,182,192,129,124,253,252,234,4,239,15,133,244,40,139,44,252,
-  234,59,133,233,15,131,244,40,193,224,3,3,133,233,129,120,253,4,239,15,132,
-  244,249,248,1,252,246,133,233,235,15,133,244,253,248,2,139,108,202,4,139,
-  12,202,137,104,4,137,8,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,
-  255,36,171,248,3,131,189,233,0,15,132,244,1,255,139,141,233,252,246,129,233,
-  235,15,132,244,40,15,182,78,252,253,252,233,244,1,248,7,128,165,233,235,139,
-  139,233,137,171,233,137,141,233,15,182,78,252,253,252,233,244,2,255,137,124,
-  36,16,139,60,199,248,1,141,12,202,139,105,252,248,252,246,133,233,235,15,
-  133,244,253,248,2,139,68,36,20,131,232,1,15,132,244,250,1,252,248,59,133,
-  233,15,135,244,251,41,252,248,193,231,3,3,189,233,248,3,139,41,137,47,139,
-  105,4,131,193,8,137,111,4,131,199,8,131,232,1,15,133,244,3,248,4,139,124,
-  36,16,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,
-  5,137,108,36,4,139,108,36,48,137,149,233,137,68,36,8,137,44,36,137,116,36,
-  24,232,251,1,35,139,149,233,15,182,78,252,253,252,233,244,1,248,7,255,128,
-  165,233,235,139,131,233,137,171,233,137,133,233,252,233,244,2,255,3,68,36,
-  20,255,129,124,253,202,4,239,139,44,202,15,133,244,58,141,84,202,8,137,114,
-  252,252,139,181,233,139,14,15,182,252,233,15,182,205,131,198,4,252,255,36,
-  171,255,141,76,202,8,137,215,139,105,252,248,129,121,253,252,252,239,15,133,
-  244,29,248,59,139,114,252,252,252,247,198,237,15,133,244,253,248,1,137,106,
-  252,248,137,68,36,20,131,232,1,15,132,244,249,248,2,139,41,137,47,139,105,
-  4,131,193,8,137,111,4,131,199,8,131,232,1,15,133,244,2,139,106,252,248,248,
-  3,139,68,36,20,128,189,233,1,15,135,244,251,248,4,139,181,233,139,14,15,182,
-  252,233,15,182,205,131,198,4,252,255,36,171,248,5,255,252,247,198,237,15,
-  133,244,4,15,182,78,252,253,252,247,209,141,12,202,139,121,252,248,139,191,
-  233,139,191,233,252,233,244,4,248,7,129,252,238,239,252,247,198,237,15,133,
-  244,254,41,252,242,137,215,139,114,252,252,252,233,244,1,248,8,129,198,239,
-  252,233,244,1,255,141,76,202,8,139,105,232,139,65,252,236,137,41,137,65,4,
-  139,105,252,240,139,65,252,244,137,105,8,137,65,12,139,105,224,139,65,228,
-  137,105,252,248,137,65,252,252,129,252,248,239,184,237,15,133,244,29,137,
-  202,137,114,252,252,139,181,233,139,14,15,182,252,233,15,182,205,131,198,
-  4,252,255,36,171,255,137,124,36,16,137,92,36,20,139,108,202,252,240,139,68,
-  202,252,248,139,157,233,131,198,4,139,189,233,248,1,57,216,15,131,244,251,
-  129,124,253,199,4,239,15,132,244,250,255,219,68,202,252,248,255,139,108,199,
-  4,137,108,202,12,139,44,199,137,108,202,8,131,192,1,255,137,68,202,252,248,
-  248,2,15,183,70,252,254,141,180,253,134,233,248,3,139,92,36,20,139,124,36,
-  16,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,4,
-  131,192,1,255,137,68,202,252,248,255,252,233,244,1,248,5,41,216,248,6,59,
-  133,233,15,135,244,3,105,252,248,239,3,189,233,129,191,233,239,15,132,244,
-  253,141,92,24,1,139,175,233,139,135,233,137,44,202,137,68,202,4,139,175,233,
-  139,135,233,137,108,202,8,137,68,202,12,137,92,202,252,248,252,233,244,2,
-  248,7,255,131,192,1,252,233,244,6,255,129,124,253,202,252,236,239,15,133,
-  244,251,139,108,202,232,129,124,253,202,252,244,239,15,133,244,251,129,124,
-  253,202,252,252,239,15,133,244,251,128,189,233,235,15,133,244,251,141,180,
-  253,134,233,199,68,202,252,248,0,0,0,0,248,1,139,6,15,182,204,15,182,232,
-  131,198,4,193,232,16,252,255,36,171,248,5,198,70,252,252,235,141,180,253,
-  134,233,198,6,235,252,233,244,1,255,15,182,252,236,15,182,192,137,124,36,
-  16,141,188,253,194,233,141,12,202,43,122,252,252,133,252,237,15,132,244,251,
-  141,108,252,233,252,248,57,215,15,131,244,248,248,1,139,71,252,248,137,1,
-  139,71,252,252,131,199,8,137,65,4,131,193,8,57,252,233,15,131,244,249,57,
-  215,15,130,244,1,248,2,199,65,4,237,131,193,8,57,252,233,15,130,244,2,248,
-  3,139,124,36,16,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,
-  36,171,248,5,199,68,36,20,1,0,0,0,137,208,41,252,248,15,134,244,3,137,197,
-  193,252,237,3,131,197,1,137,108,36,20,139,108,36,48,1,200,59,133,233,15,135,
-  244,253,248,6,255,139,71,252,248,137,1,139,71,252,252,131,199,8,137,65,4,
-  131,193,8,57,215,15,130,244,6,252,233,244,3,248,7,137,149,233,137,141,233,
-  137,116,36,24,41,215,139,84,36,20,131,252,234,1,137,252,233,232,251,1,0,139,
-  149,233,139,141,233,1,215,252,233,244,6,255,193,225,3,255,248,1,139,114,252,
-  252,137,68,36,20,252,247,198,237,15,133,244,253,255,248,13,137,215,131,232,
-  1,15,132,244,249,248,2,139,44,15,137,111,252,248,139,108,15,4,137,111,252,
-  252,131,199,8,131,232,1,15,133,244,2,248,3,139,68,36,20,15,182,110,252,255,
-  248,5,57,197,15,135,244,252,255,139,108,10,4,137,106,252,252,139,44,10,137,
-  106,252,248,255,248,5,56,70,252,255,15,135,244,252,255,15,182,78,252,253,
-  252,247,209,141,20,202,139,122,252,248,139,191,233,139,191,233,139,6,15,182,
-  204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,6,255,199,71,252,252,
-  237,131,199,8,255,199,68,194,252,244,237,255,131,192,1,252,233,244,5,248,
-  7,141,174,233,252,247,197,237,15,133,244,14,41,252,234,255,1,252,233,255,
-  137,252,245,209,252,237,129,229,239,102,131,172,253,43,233,1,15,132,244,148,
-  255,141,12,202,255,129,121,253,4,239,15,133,244,255,255,129,121,253,12,239,
-  15,133,244,60,129,121,253,20,239,15,133,244,60,139,41,131,121,16,0,15,140,
-  244,251,255,129,121,253,12,239,15,133,244,165,129,121,253,20,239,15,133,244,
-  165,255,139,105,16,133,252,237,15,136,244,251,3,41,15,128,244,247,137,41,
-  255,59,105,8,199,65,28,237,137,105,24,255,15,142,244,253,248,1,248,6,141,
-  180,253,134,233,255,141,180,253,134,233,15,183,70,252,254,15,142,245,248,
-  1,248,6,255,15,143,244,253,248,6,141,180,253,134,233,248,1,255,248,7,139,
-  6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,5,255,3,41,
-  15,128,244,1,137,41,255,15,141,244,7,255,141,180,253,134,233,15,183,70,252,
-  254,15,141,245,255,15,140,244,7,255,252,233,244,6,248,9,255,129,121,253,4,
-  239,255,15,131,244,60,129,121,253,12,239,15,131,244,60,255,129,121,253,12,
-  239,15,131,244,165,129,121,253,20,239,15,131,244,165,255,139,105,20,255,129,
-  252,253,239,15,131,244,60,255,252,242,15,16,1,252,242,15,16,73,8,255,252,
-  242,15,88,65,16,252,242,15,17,1,133,252,237,15,136,244,249,255,15,140,244,
-  249,255,102,15,46,200,248,1,252,242,15,17,65,24,255,221,65,8,221,1,255,220,
-  65,16,221,17,221,81,24,133,252,237,15,136,244,247,255,221,81,24,15,140,244,
-  247,255,217,201,248,1,255,15,183,70,252,254,255,15,131,244,7,255,15,131,244,
-  248,141,180,253,134,233,255,141,180,253,134,233,15,183,70,252,254,15,131,
-  245,255,15,130,244,7,255,15,130,244,248,141,180,253,134,233,255,248,3,102,
-  15,46,193,252,233,244,1,255,141,12,202,139,105,4,129,252,253,239,15,132,244,
-  247,255,137,105,252,252,139,41,137,105,252,248,252,233,245,255,141,180,253,
-  134,233,139,1,137,105,252,252,137,65,252,248,255,139,139,233,139,4,129,139,
-  128,233,139,108,36,48,137,147,233,137,171,233,252,255,224,255,141,180,253,
-  134,233,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,255,
-  137,252,245,209,252,237,129,229,239,102,131,172,253,43,233,1,15,132,244,150,
-  255,139,190,233,139,108,36,48,141,12,202,59,141,233,15,135,244,24,15,182,
-  142,233,57,200,15,134,244,249,248,2,255,15,183,70,252,254,252,233,245,255,
-  248,3,199,68,194,252,252,237,131,192,1,57,200,15,134,244,3,252,233,244,2,
-  255,141,44,197,237,141,4,194,139,122,252,248,137,104,252,252,137,120,252,
-  248,139,108,36,48,141,12,200,59,141,233,15,135,244,23,137,209,137,194,15,
-  182,174,233,133,252,237,15,132,244,248,248,1,131,193,8,57,209,15,131,244,
-  249,139,121,252,248,137,56,139,121,252,252,137,120,4,131,192,8,199,65,252,
-  252,237,131,252,237,1,15,133,244,1,248,2,255,139,190,233,139,6,15,182,204,
-  15,182,232,131,198,4,193,232,16,252,255,36,171,255,248,3,199,64,4,237,131,
-  192,8,131,252,237,1,15,133,244,3,252,233,244,2,255,139,106,252,248,139,189,
-  233,139,108,36,48,141,68,194,252,248,137,149,233,141,136,233,59,141,233,137,
-  133,233,255,137,44,36,255,137,124,36,4,137,44,36,255,15,135,244,22,199,131,
-  233,237,255,252,255,215,255,252,255,147,233,255,199,131,233,237,139,149,233,
-  141,12,194,252,247,217,3,141,233,139,114,252,252,252,233,244,12,255,254,0
+  102,15,46,217,15,134,244,247,102,15,85,208,15,40,193,252,242,15,88,203,252,
+  242,15,92,203,184,0,0,252,240,63,102,15,110,216,102,15,112,219,81,252,242,
+  15,194,193,1,102,15,84,195,252,242,15,92,200,102,15,86,202,15,40,193,248,
+  1,195,248,157,255,15,40,232,252,242,15,94,193,102,15,252,239,210,102,15,118,
+  210,102,15,115,210,1,184,0,0,48,67,102,15,110,216,102,15,112,219,81,15,40,
+  224,102,15,84,226,102,15,46,220,15,134,244,247,102,15,85,208,252,242,15,88,
+  227,252,242,15,92,227,102,15,86,226,184,0,0,252,240,63,102,15,110,208,102,
+  15,112,210,81,252,242,15,194,196,1,102,15,84,194,252,242,15,92,224,15,40,
+  197,252,242,15,89,204,252,242,15,92,193,195,248,1,252,242,15,89,200,15,40,
+  197,252,242,15,92,193,195,255,217,193,216,252,241,217,124,36,4,102,184,0,
+  4,102,11,68,36,4,102,37,252,255,252,247,102,137,68,36,6,217,108,36,6,217,
+  252,252,217,108,36,4,222,201,222,252,233,195,255,248,98,217,252,234,222,201,
+  248,158,217,84,36,4,129,124,36,4,0,0,128,127,15,132,244,247,129,124,36,4,
+  0,0,128,252,255,15,132,244,248,248,159,217,192,217,252,252,220,252,233,217,
+  201,217,252,240,217,232,222,193,217,252,253,221,217,248,1,195,248,2,221,216,
+  217,252,238,195,255,248,117,219,84,36,4,219,68,36,4,255,223,252,233,255,221,
+  252,233,223,224,158,255,15,133,244,254,15,138,244,255,221,216,139,68,36,4,
+  131,252,248,1,15,142,244,252,248,1,169,1,0,0,0,15,133,244,248,216,200,209,
+  232,252,233,244,1,248,2,209,232,15,132,244,251,217,192,248,3,216,200,209,
+  232,15,132,244,250,15,131,244,3,220,201,252,233,244,3,248,4,255,222,201,248,
+  5,195,248,6,15,132,244,5,15,130,244,253,217,232,222,252,241,252,247,216,131,
+  252,248,1,15,132,244,5,252,233,244,1,248,7,221,216,217,232,195,248,8,217,
+  84,36,4,217,201,217,84,36,8,139,68,36,4,209,224,61,0,0,0,252,255,15,132,244,
+  248,139,68,36,8,209,224,15,132,244,250,61,0,0,0,252,255,15,132,244,250,217,
+  252,241,252,233,244,159,248,9,255,217,232,255,223,252,234,255,221,252,234,
+  223,224,158,255,15,132,244,247,217,201,248,1,221,216,195,248,2,217,225,217,
+  232,255,15,132,244,249,221,216,217,225,217,252,238,184,0,0,0,0,15,146,208,
+  209,200,51,68,36,4,15,137,244,249,217,201,248,3,221,217,217,225,195,248,4,
+  131,124,36,4,0,15,141,244,3,221,216,221,216,133,192,15,132,244,251,217,252,
+  238,195,248,5,199,68,36,4,0,0,128,127,217,68,36,4,195,255,248,117,255,248,
+  160,252,242,15,45,193,252,242,15,42,208,102,15,46,202,15,133,244,254,15,138,
+  244,255,248,161,131,252,248,1,15,142,244,252,248,1,169,1,0,0,0,15,133,244,
+  248,252,242,15,89,192,209,232,252,233,244,1,248,2,209,232,15,132,244,251,
+  15,40,200,248,3,252,242,15,89,192,209,232,15,132,244,250,15,131,244,3,255,
+  252,242,15,89,200,252,233,244,3,248,4,252,242,15,89,193,248,5,195,248,6,15,
+  132,244,5,15,130,244,253,252,247,216,232,244,1,184,0,0,252,240,63,102,15,
+  110,200,102,15,112,201,81,252,242,15,94,200,15,40,193,195,248,7,184,0,0,252,
+  240,63,102,15,110,192,102,15,112,192,81,195,248,8,252,242,15,17,76,36,12,
+  252,242,15,17,68,36,4,131,124,36,12,0,15,133,244,247,139,68,36,16,209,224,
+  61,0,0,224,252,255,15,132,244,248,248,1,131,124,36,4,0,15,133,244,247,255,
+  139,68,36,8,209,224,15,132,244,250,61,0,0,224,252,255,15,132,244,251,248,
+  1,221,68,36,12,221,68,36,4,217,252,241,217,192,217,252,252,220,252,233,217,
+  201,217,252,240,217,232,222,193,217,252,253,221,217,221,92,36,4,252,242,15,
+  16,68,36,4,195,248,9,184,0,0,252,240,63,102,15,110,208,102,15,112,210,81,
+  102,15,46,194,15,132,244,247,15,40,193,248,1,195,248,2,102,15,252,239,210,
+  102,15,118,210,102,15,115,210,1,102,15,84,194,184,0,0,252,240,63,102,15,110,
+  208,102,15,112,210,81,102,15,46,194,15,132,244,1,102,15,80,193,15,87,192,
+  136,196,15,146,208,48,224,15,133,244,1,248,3,184,0,0,252,240,127,102,15,110,
+  192,102,15,112,192,81,195,248,4,102,15,80,193,133,192,15,133,244,3,15,87,
+  192,195,248,5,102,15,80,193,133,192,15,132,244,3,255,15,87,192,195,248,162,
+  255,139,68,36,12,252,242,15,16,68,36,4,131,252,248,1,15,132,244,247,15,135,
+  244,248,232,244,91,252,233,244,253,248,1,232,244,93,252,233,244,253,248,2,
+  131,252,248,3,15,132,244,247,15,135,244,248,232,244,114,255,252,233,244,253,
+  248,1,252,242,15,81,192,248,7,252,242,15,17,68,36,4,221,68,36,4,195,248,2,
+  221,68,36,4,131,252,248,5,15,130,244,98,15,132,244,158,248,2,131,252,248,
+  7,15,132,244,247,15,135,244,248,217,252,237,217,201,217,252,241,195,248,1,
+  217,232,217,201,217,252,241,195,248,2,131,252,248,9,15,132,244,247,15,135,
+  244,248,255,217,252,236,217,201,217,252,241,195,248,1,217,252,254,195,248,
+  2,131,252,248,11,15,132,244,247,15,135,244,255,217,252,255,195,248,1,217,
+  252,242,221,216,195,255,139,68,36,12,221,68,36,4,131,252,248,1,15,130,244,
+  91,15,132,244,93,131,252,248,3,15,130,244,114,15,135,244,248,217,252,250,
+  195,248,2,131,252,248,5,15,130,244,98,15,132,244,158,131,252,248,7,15,132,
+  244,247,15,135,244,248,217,252,237,217,201,217,252,241,195,248,1,217,232,
+  217,201,217,252,241,195,248,2,131,252,248,9,15,132,244,247,255,15,135,244,
+  248,217,252,236,217,201,217,252,241,195,248,1,217,252,254,195,248,2,131,252,
+  248,11,15,132,244,247,15,135,244,255,217,252,255,195,248,1,217,252,242,221,
+  216,195,255,248,9,204,255,248,163,255,139,68,36,20,252,242,15,16,68,36,4,
+  252,242,15,16,76,36,12,131,252,248,1,15,132,244,247,15,135,244,248,252,242,
+  15,88,193,248,7,252,242,15,17,68,36,4,221,68,36,4,195,248,1,252,242,15,92,
+  193,252,233,244,7,248,2,131,252,248,3,15,132,244,247,15,135,244,248,252,242,
+  15,89,193,252,233,244,7,248,1,252,242,15,94,193,252,233,244,7,248,2,131,252,
+  248,5,15,132,244,247,255,15,135,244,248,232,244,157,252,233,244,7,248,1,90,
+  232,244,117,82,252,233,244,7,248,2,131,252,248,7,15,132,244,247,15,135,244,
+  248,184,0,0,0,128,102,15,110,200,102,15,112,201,81,15,87,193,252,233,244,
+  7,248,1,102,15,252,239,201,102,15,118,201,102,15,115,209,1,15,84,193,252,
+  233,244,7,248,2,255,131,252,248,9,15,135,244,248,221,68,36,4,221,68,36,12,
+  15,132,244,247,217,252,243,195,248,1,217,201,217,252,253,221,217,195,248,
+  2,131,252,248,11,15,132,244,247,15,135,244,255,252,242,15,93,193,252,233,
+  244,7,248,1,252,242,15,95,193,252,233,244,7,248,9,204,255,139,68,36,20,221,
+  68,36,4,221,68,36,12,131,252,248,1,15,132,244,247,15,135,244,248,222,193,
+  195,248,1,222,252,233,195,248,2,131,252,248,3,15,132,244,247,15,135,244,248,
+  222,201,195,248,1,222,252,249,195,248,2,131,252,248,5,15,130,244,157,15,132,
+  244,117,131,252,248,7,15,132,244,247,15,135,244,248,255,221,216,217,224,195,
+  248,1,221,216,217,225,195,248,2,131,252,248,9,15,132,244,247,15,135,244,248,
+  217,252,243,195,248,1,217,201,217,252,253,221,217,195,248,2,131,252,248,11,
+  15,132,244,247,15,135,244,255,255,219,252,233,219,209,221,217,195,248,1,219,
+  252,233,218,209,221,217,195,255,221,225,223,224,252,246,196,1,15,132,244,
+  248,217,201,248,2,221,216,195,248,1,221,225,223,224,252,246,196,1,15,133,
+  244,248,217,201,248,2,221,216,195,255,248,164,156,90,137,209,129,252,242,
+  0,0,32,0,82,157,156,90,49,192,57,209,15,132,244,247,139,68,36,4,87,83,15,
+  162,139,124,36,16,137,7,137,95,4,137,79,8,137,87,12,91,95,248,1,195,248,165,
+  255,204,248,166,255,131,252,236,16,87,86,83,131,252,236,28,141,157,233,139,
+  181,233,15,183,192,137,134,233,141,132,253,36,233,137,142,233,137,150,233,
+  137,134,233,139,140,253,36,233,139,148,253,36,233,137,76,36,44,137,84,36,
+  40,137,226,137,116,36,24,137,252,241,232,251,1,27,199,131,233,237,139,144,
+  233,139,128,233,41,208,139,106,252,248,193,232,3,131,192,1,139,181,233,139,
+  14,15,182,252,233,15,182,205,131,198,4,252,255,36,171,255,248,32,255,139,
+  76,36,48,139,179,233,137,142,233,137,145,233,137,169,233,137,252,241,137,
+  194,232,251,1,28,139,108,36,48,139,134,233,139,150,233,131,190,233,1,15,130,
+  244,253,15,132,244,252,221,134,233,252,233,244,253,248,6,217,134,233,248,
+  7,139,141,233,15,183,73,6,137,76,36,48,131,196,28,91,94,95,93,89,3,36,36,
+  131,196,16,81,195,255,248,167,255,85,137,229,83,137,203,43,163,233,255,137,
+  163,233,255,15,182,139,233,131,252,233,1,15,136,244,248,248,1,139,132,253,
+  139,233,137,4,140,131,252,233,1,15,137,244,1,248,2,139,139,233,139,147,233,
+  252,255,147,233,137,131,233,137,147,233,128,187,233,1,15,130,244,253,15,132,
+  244,252,221,155,233,252,233,244,253,248,6,255,217,155,233,248,7,255,41,163,
+  233,255,139,93,252,252,201,195,255,249,255,129,124,253,202,4,239,15,133,244,
+  253,129,124,253,194,4,239,15,133,244,254,139,44,202,131,198,4,59,44,194,255,
+  15,141,244,255,255,15,140,244,255,255,15,143,244,255,255,15,142,244,255,255,
+  248,6,15,183,70,252,254,141,180,253,134,233,248,9,139,6,15,182,204,15,182,
+  232,131,198,4,193,232,16,252,255,36,171,248,7,15,135,244,44,129,124,253,194,
+  4,239,15,130,244,247,15,133,244,44,255,252,242,15,42,4,194,252,233,244,248,
+  255,221,4,202,219,4,194,252,233,244,249,255,248,8,15,135,244,44,255,252,242,
+  15,42,12,202,252,242,15,16,4,194,131,198,4,102,15,46,193,255,15,134,244,9,
+  255,15,135,244,9,255,15,130,244,9,255,15,131,244,9,255,252,233,244,6,255,
+  219,4,202,252,233,244,248,255,129,124,253,202,4,239,15,131,244,44,129,124,
+  253,194,4,239,15,131,244,44,255,248,1,252,242,15,16,4,194,248,2,131,198,4,
+  102,15,46,4,202,248,3,255,248,1,221,4,202,248,2,221,4,194,248,3,131,198,4,
+  255,15,135,244,247,255,15,130,244,247,255,15,131,244,247,255,15,183,70,252,
+  254,141,180,253,134,233,248,1,139,6,15,182,204,15,182,232,131,198,4,193,232,
+  16,252,255,36,171,255,139,108,194,4,131,198,4,255,129,252,253,239,15,133,
+  244,253,129,124,253,202,4,239,15,133,244,254,139,44,194,59,44,202,255,15,
+  133,244,255,255,15,132,244,255,255,15,183,70,252,254,141,180,253,134,233,
+  248,9,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,
+  7,15,135,244,251,129,124,253,202,4,239,15,130,244,247,15,133,244,251,255,
+  252,242,15,42,4,202,255,219,4,202,255,252,233,244,248,248,8,15,135,244,251,
+  255,252,242,15,42,4,194,102,15,46,4,202,255,219,4,194,221,4,202,255,252,233,
+  244,250,255,129,252,253,239,15,131,244,251,129,124,253,202,4,239,15,131,244,
+  251,255,248,1,252,242,15,16,4,202,248,2,102,15,46,4,194,248,4,255,248,1,221,
+  4,202,248,2,221,4,194,248,4,255,15,138,244,248,15,133,244,248,255,15,138,
+  244,248,15,132,244,247,255,248,1,15,183,70,252,254,141,180,253,134,233,248,
+  2,255,248,2,15,183,70,252,254,141,180,253,134,233,248,1,255,252,233,244,9,
+  255,248,5,255,129,252,253,239,15,132,244,49,129,124,253,202,4,239,15,132,
+  244,49,255,57,108,202,4,15,133,244,2,129,252,253,239,15,131,244,1,139,12,
+  202,139,4,194,57,193,15,132,244,1,129,252,253,239,15,135,244,2,139,169,233,
+  133,252,237,15,132,244,2,252,246,133,233,235,15,133,244,2,255,49,252,237,
+  255,189,1,0,0,0,255,252,233,244,48,255,248,3,129,252,253,239,255,15,133,244,
+  9,255,252,233,244,49,255,252,247,208,139,108,202,4,131,198,4,129,252,253,
+  239,15,133,244,249,139,12,202,59,12,135,255,139,108,202,4,131,198,4,255,129,
+  252,253,239,15,133,244,253,129,124,253,199,4,239,15,133,244,254,139,44,199,
+  59,44,202,255,15,183,70,252,254,141,180,253,134,233,248,9,139,6,15,182,204,
+  15,182,232,131,198,4,193,232,16,252,255,36,171,248,7,15,135,244,249,129,124,
+  253,199,4,239,15,130,244,247,255,252,242,15,42,4,199,255,219,4,199,255,252,
+  233,244,248,248,8,255,252,242,15,42,4,202,102,15,46,4,199,255,219,4,202,221,
+  4,199,255,129,252,253,239,15,131,244,249,255,248,1,252,242,15,16,4,199,248,
+  2,102,15,46,4,202,248,4,255,248,1,221,4,199,248,2,221,4,202,248,4,255,252,
+  247,208,139,108,202,4,131,198,4,57,197,255,15,133,244,249,15,183,70,252,254,
+  141,180,253,134,233,248,2,139,6,15,182,204,15,182,232,131,198,4,193,232,16,
+  252,255,36,171,248,3,129,252,253,239,15,133,244,2,252,233,244,49,255,15,132,
+  244,248,129,252,253,239,15,132,244,49,15,183,70,252,254,141,180,253,134,233,
+  248,2,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,255,
+  139,108,194,4,131,198,4,129,252,253,239,255,137,108,202,4,139,44,194,137,
+  44,202,255,139,108,194,4,139,4,194,137,108,202,4,137,4,202,139,6,15,182,204,
+  15,182,232,131,198,4,193,232,16,252,255,36,171,255,49,252,237,129,124,253,
+  194,4,239,129,213,239,137,108,202,4,139,6,15,182,204,15,182,232,131,198,4,
+  193,232,16,252,255,36,171,255,129,124,253,194,4,239,15,133,244,251,139,44,
+  194,252,247,221,15,128,244,250,199,68,202,4,237,137,44,202,248,9,139,6,15,
+  182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,4,199,68,202,4,
+  0,0,224,65,199,4,202,0,0,0,0,252,233,244,9,248,5,15,135,244,54,255,129,124,
+  253,194,4,239,15,131,244,54,255,252,242,15,16,4,194,184,0,0,0,128,102,15,
+  110,200,102,15,112,201,81,15,87,193,252,242,15,17,4,202,255,221,4,194,217,
+  224,221,28,202,255,129,124,253,194,4,239,15,133,244,248,139,4,194,255,139,
+  128,233,248,1,199,68,202,4,237,137,4,202,255,15,87,192,252,242,15,42,128,
+  233,248,1,252,242,15,17,4,202,255,219,128,233,248,1,221,28,202,255,139,6,
+  15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,2,129,124,253,
+  194,4,239,15,133,244,57,139,12,194,255,139,169,233,131,252,253,0,15,133,244,
+  255,248,3,255,248,58,137,213,232,251,1,20,255,252,242,15,42,192,255,137,4,
+  36,219,4,36,255,137,252,234,15,182,78,252,253,252,233,244,1,255,248,9,252,
+  246,133,233,235,15,133,244,3,252,233,244,57,255,15,182,252,236,15,182,192,
+  255,129,124,253,252,234,4,239,15,133,244,51,129,124,253,199,4,239,15,133,
+  244,51,139,44,252,234,3,44,199,15,128,244,50,255,129,124,253,252,234,4,239,
+  15,133,244,53,129,124,253,199,4,239,15,133,244,53,139,4,199,3,4,252,234,15,
+  128,244,52,255,129,124,253,252,234,4,239,15,133,244,56,129,124,253,194,4,
+  239,15,133,244,56,139,44,252,234,3,44,194,15,128,244,55,255,199,68,202,4,
+  237,255,129,124,253,252,234,4,239,15,131,244,51,255,129,124,253,199,4,239,
+  15,131,244,51,255,252,242,15,16,4,252,234,252,242,15,88,4,199,255,221,4,252,
+  234,220,4,199,255,129,124,253,252,234,4,239,15,131,244,53,255,129,124,253,
+  199,4,239,15,131,244,53,255,252,242,15,16,4,199,252,242,15,88,4,252,234,255,
+  221,4,199,220,4,252,234,255,129,124,253,252,234,4,239,15,131,244,56,129,124,
+  253,194,4,239,15,131,244,56,255,252,242,15,16,4,252,234,252,242,15,88,4,194,
+  255,221,4,252,234,220,4,194,255,129,124,253,252,234,4,239,15,133,244,51,129,
+  124,253,199,4,239,15,133,244,51,139,44,252,234,43,44,199,15,128,244,50,255,
+  129,124,253,252,234,4,239,15,133,244,53,129,124,253,199,4,239,15,133,244,
+  53,139,4,199,43,4,252,234,15,128,244,52,255,129,124,253,252,234,4,239,15,
+  133,244,56,129,124,253,194,4,239,15,133,244,56,139,44,252,234,43,44,194,15,
+  128,244,55,255,252,242,15,16,4,252,234,252,242,15,92,4,199,255,221,4,252,
+  234,220,36,199,255,252,242,15,16,4,199,252,242,15,92,4,252,234,255,221,4,
+  199,220,36,252,234,255,252,242,15,16,4,252,234,252,242,15,92,4,194,255,221,
+  4,252,234,220,36,194,255,129,124,253,252,234,4,239,15,133,244,51,129,124,
+  253,199,4,239,15,133,244,51,139,44,252,234,15,175,44,199,15,128,244,50,255,
+  129,124,253,252,234,4,239,15,133,244,53,129,124,253,199,4,239,15,133,244,
+  53,139,4,199,15,175,4,252,234,15,128,244,52,255,129,124,253,252,234,4,239,
+  15,133,244,56,129,124,253,194,4,239,15,133,244,56,139,44,252,234,15,175,44,
+  194,15,128,244,55,255,252,242,15,16,4,252,234,252,242,15,89,4,199,255,221,
+  4,252,234,220,12,199,255,252,242,15,16,4,199,252,242,15,89,4,252,234,255,
+  221,4,199,220,12,252,234,255,252,242,15,16,4,252,234,252,242,15,89,4,194,
+  255,221,4,252,234,220,12,194,255,252,242,15,16,4,252,234,252,242,15,94,4,
+  199,255,221,4,252,234,220,52,199,255,252,242,15,16,4,199,252,242,15,94,4,
+  252,234,255,221,4,199,220,52,252,234,255,252,242,15,16,4,252,234,252,242,
+  15,94,4,194,255,221,4,252,234,220,52,194,255,252,242,15,16,4,252,234,252,
+  242,15,16,12,199,255,221,4,252,234,221,4,199,255,252,242,15,16,4,199,252,
+  242,15,16,12,252,234,255,221,4,199,221,4,252,234,255,252,242,15,16,4,252,
+  234,252,242,15,16,12,194,255,221,4,252,234,221,4,194,255,248,168,232,244,
+  157,255,252,233,244,168,255,232,244,117,255,15,182,252,236,15,182,192,141,
+  12,194,41,232,137,76,36,4,137,68,36,8,248,36,139,108,36,48,137,44,36,137,
+  149,233,137,116,36,24,232,251,1,29,139,149,233,133,192,15,133,244,45,15,182,
+  110,252,255,15,182,78,252,253,139,68,252,234,4,139,44,252,234,137,68,202,
+  4,137,44,202,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,
+  171,255,252,247,208,139,4,135,199,68,202,4,237,137,4,202,139,6,15,182,204,
+  15,182,232,131,198,4,193,232,16,252,255,36,171,255,15,191,192,199,68,202,
+  4,237,137,4,202,255,15,191,192,252,242,15,42,192,252,242,15,17,4,202,255,
+  223,70,252,254,221,28,202,255,252,242,15,16,4,199,252,242,15,17,4,202,255,
+  221,4,199,221,28,202,255,252,247,208,137,68,202,4,139,6,15,182,204,15,182,
+  232,131,198,4,193,232,16,252,255,36,171,255,141,76,202,12,141,68,194,4,189,
+  237,137,105,252,248,248,1,137,41,131,193,8,57,193,15,134,244,1,139,6,15,182,
+  204,15,182,232,131,198,4,193,232,16,252,255,36,171,255,139,106,252,248,139,
+  172,253,133,233,139,173,233,139,69,4,139,109,0,137,68,202,4,137,44,202,139,
+  6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,255,139,106,252,
+  248,139,172,253,141,233,128,189,233,0,139,173,233,139,12,194,139,68,194,4,
+  137,77,0,137,69,4,15,132,244,247,252,246,133,233,235,15,133,244,248,248,1,
+  139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,2,129,
+  232,239,129,252,248,239,15,134,244,1,252,246,129,233,235,15,132,244,1,135,
+  213,141,139,233,255,232,251,1,30,137,252,234,252,233,244,1,255,252,247,208,
+  139,106,252,248,139,172,253,141,233,139,12,135,139,133,233,137,8,199,64,4,
+  237,252,246,133,233,235,15,133,244,248,248,1,139,6,15,182,204,15,182,232,
+  131,198,4,193,232,16,252,255,36,171,248,2,252,246,129,233,235,15,132,244,
+  1,128,189,233,0,15,132,244,1,137,213,137,194,141,139,233,232,251,1,30,137,
+  252,234,252,233,244,1,255,139,106,252,248,255,252,242,15,16,4,199,255,139,
+  172,253,141,233,139,141,233,255,252,242,15,17,1,255,221,25,255,252,247,208,
+  139,106,252,248,139,172,253,141,233,139,141,233,137,65,4,139,6,15,182,204,
+  15,182,232,131,198,4,193,232,16,252,255,36,171,255,141,180,253,134,233,139,
+  108,36,48,131,189,233,0,15,132,244,247,137,149,233,141,20,202,137,252,233,
+  232,251,1,31,139,149,233,248,1,139,6,15,182,204,15,182,232,131,198,4,193,
+  232,16,252,255,36,171,255,252,247,208,139,74,252,248,139,4,135,139,108,36,
+  48,137,76,36,8,137,68,36,4,137,44,36,137,149,233,137,116,36,24,232,251,1,
+  32,139,149,233,15,182,78,252,253,137,4,202,199,68,202,4,237,139,6,15,182,
+  204,15,182,232,131,198,4,193,232,16,252,255,36,171,255,139,108,36,48,137,
+  149,233,139,139,233,59,139,233,137,116,36,24,15,131,244,251,248,1,137,193,
+  37,252,255,7,0,0,193,252,233,11,137,76,36,8,61,252,255,7,0,0,15,132,244,249,
+  248,2,137,44,36,137,68,36,4,232,251,1,33,139,149,233,15,182,78,252,253,137,
+  4,202,199,68,202,4,237,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,
+  255,36,171,248,3,184,1,8,0,0,252,233,244,2,248,5,137,252,233,232,251,1,34,
+  15,183,70,252,254,252,233,244,1,255,252,247,208,139,108,36,48,139,139,233,
+  137,116,36,24,59,139,233,137,149,233,15,131,244,249,248,2,139,20,135,137,
+  252,233,232,251,1,35,139,149,233,15,182,78,252,253,137,4,202,199,68,202,4,
+  237,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,3,
+  137,252,233,232,251,1,34,15,183,70,252,254,252,247,208,252,233,244,2,255,
+  252,247,208,139,106,252,248,139,173,233,139,4,135,252,233,244,169,255,252,
+  247,208,139,106,252,248,139,173,233,139,4,135,252,233,244,170,255,15,182,
+  252,236,15,182,192,129,124,253,252,234,4,239,15,133,244,39,139,44,252,234,
+  255,129,124,253,194,4,239,15,133,244,251,139,4,194,255,129,124,253,194,4,
+  239,15,131,244,251,255,252,242,15,16,4,194,252,242,15,45,192,252,242,15,42,
+  200,102,15,46,193,255,221,4,194,219,20,36,219,4,36,255,15,133,244,39,255,
+  59,133,233,15,131,244,39,193,224,3,3,133,233,129,120,253,4,239,15,132,244,
+  248,139,40,139,64,4,137,44,202,137,68,202,4,248,1,139,6,15,182,204,15,182,
+  232,131,198,4,193,232,16,252,255,36,171,248,2,131,189,233,0,15,132,244,249,
+  139,141,233,252,246,129,233,235,15,132,244,39,15,182,78,252,253,248,3,199,
+  68,202,4,237,252,233,244,1,248,5,255,129,124,253,194,4,239,15,133,244,39,
+  139,4,194,252,233,244,169,255,15,182,252,236,15,182,192,252,247,208,139,4,
+  135,129,124,253,252,234,4,239,15,133,244,37,139,44,252,234,248,169,139,141,
+  233,35,136,233,105,201,239,3,141,233,248,1,129,185,233,239,15,133,244,250,
+  57,129,233,15,133,244,250,129,121,253,4,239,15,132,244,251,15,182,70,252,
+  253,139,41,139,73,4,137,44,194,137,76,194,4,248,2,255,139,6,15,182,204,15,
+  182,232,131,198,4,193,232,16,252,255,36,171,248,3,15,182,70,252,253,199,68,
+  194,4,237,252,233,244,2,248,4,139,137,233,133,201,15,133,244,1,248,5,139,
+  141,233,133,201,15,132,244,3,252,246,129,233,235,15,133,244,3,252,233,244,
+  37,255,15,182,252,236,15,182,192,129,124,253,252,234,4,239,15,133,244,38,
+  139,44,252,234,59,133,233,15,131,244,38,193,224,3,3,133,233,129,120,253,4,
+  239,15,132,244,248,139,40,139,64,4,137,44,202,137,68,202,4,248,1,139,6,15,
+  182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,2,131,189,233,
+  0,15,132,244,249,139,141,233,252,246,129,233,235,15,132,244,38,255,15,182,
+  78,252,253,248,3,199,68,202,4,237,252,233,244,1,255,15,182,252,236,15,182,
+  192,129,124,253,252,234,4,239,15,133,244,42,139,44,252,234,255,15,133,244,
+  42,255,59,133,233,15,131,244,42,193,224,3,3,133,233,129,120,253,4,239,15,
+  132,244,249,248,1,252,246,133,233,235,15,133,244,253,248,2,139,108,202,4,
+  139,12,202,137,104,4,137,8,139,6,15,182,204,15,182,232,131,198,4,193,232,
+  16,252,255,36,171,248,3,131,189,233,0,15,132,244,1,139,141,233,252,246,129,
+  233,235,255,15,132,244,42,15,182,78,252,253,252,233,244,1,248,5,129,124,253,
+  194,4,239,15,133,244,42,139,4,194,252,233,244,170,248,7,128,165,233,235,139,
+  139,233,137,171,233,137,141,233,15,182,78,252,253,252,233,244,2,255,15,182,
+  252,236,15,182,192,252,247,208,139,4,135,129,124,253,252,234,4,239,15,133,
+  244,40,139,44,252,234,248,170,139,141,233,35,136,233,105,201,239,198,133,
+  233,0,3,141,233,248,1,129,185,233,239,15,133,244,251,57,129,233,15,133,244,
+  251,129,121,253,4,239,15,132,244,250,248,2,255,252,246,133,233,235,15,133,
+  244,253,248,3,15,182,70,252,253,139,108,194,4,139,4,194,137,105,4,137,1,139,
+  6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,4,131,189,
+  233,0,15,132,244,2,137,76,36,16,139,141,233,252,246,129,233,235,15,132,244,
+  40,139,76,36,16,252,233,244,2,248,5,139,137,233,133,201,15,133,244,1,255,
+  139,141,233,133,201,15,132,244,252,252,246,129,233,235,15,132,244,40,248,
+  6,137,68,36,16,199,68,36,20,237,137,108,36,12,141,68,36,16,137,108,36,4,139,
+  108,36,48,137,68,36,8,137,44,36,137,149,233,137,116,36,24,232,251,1,36,139,
+  149,233,139,108,36,12,137,193,252,233,244,2,248,7,128,165,233,235,139,131,
+  233,137,171,233,137,133,233,252,233,244,3,255,15,182,252,236,15,182,192,129,
+  124,253,252,234,4,239,15,133,244,41,139,44,252,234,59,133,233,15,131,244,
+  41,193,224,3,3,133,233,129,120,253,4,239,15,132,244,249,248,1,252,246,133,
+  233,235,15,133,244,253,248,2,139,108,202,4,139,12,202,137,104,4,137,8,139,
+  6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,3,131,189,
+  233,0,15,132,244,1,255,139,141,233,252,246,129,233,235,15,132,244,41,15,182,
+  78,252,253,252,233,244,1,248,7,128,165,233,235,139,139,233,137,171,233,137,
+  141,233,15,182,78,252,253,252,233,244,2,255,137,124,36,16,139,60,199,248,
+  1,141,12,202,139,105,252,248,252,246,133,233,235,15,133,244,253,248,2,139,
+  68,36,20,131,232,1,15,132,244,250,1,252,248,59,133,233,15,135,244,251,41,
+  252,248,193,231,3,3,189,233,248,3,139,41,137,47,139,105,4,131,193,8,137,111,
+  4,131,199,8,131,232,1,15,133,244,3,248,4,139,124,36,16,139,6,15,182,204,15,
+  182,232,131,198,4,193,232,16,252,255,36,171,248,5,137,108,36,4,139,108,36,
+  48,137,149,233,137,68,36,8,137,44,36,137,116,36,24,232,251,1,37,139,149,233,
+  15,182,78,252,253,252,233,244,1,248,7,255,128,165,233,235,139,131,233,137,
+  171,233,137,133,233,252,233,244,2,255,3,68,36,20,255,129,124,253,202,4,239,
+  139,44,202,15,133,244,59,141,84,202,8,137,114,252,252,139,181,233,139,14,
+  15,182,252,233,15,182,205,131,198,4,252,255,36,171,255,141,76,202,8,137,215,
+  139,105,252,248,129,121,253,252,252,239,15,133,244,29,248,60,139,114,252,
+  252,252,247,198,237,15,133,244,253,248,1,137,106,252,248,137,68,36,20,131,
+  232,1,15,132,244,249,248,2,139,41,137,47,139,105,4,131,193,8,137,111,4,131,
+  199,8,131,232,1,15,133,244,2,139,106,252,248,248,3,139,68,36,20,128,189,233,
+  1,15,135,244,251,248,4,139,181,233,139,14,15,182,252,233,15,182,205,131,198,
+  4,252,255,36,171,248,5,255,252,247,198,237,15,133,244,4,15,182,78,252,253,
+  252,247,209,141,12,202,139,121,252,248,139,191,233,139,191,233,252,233,244,
+  4,248,7,129,252,238,239,252,247,198,237,15,133,244,254,41,252,242,137,215,
+  139,114,252,252,252,233,244,1,248,8,129,198,239,252,233,244,1,255,141,76,
+  202,8,139,105,232,139,65,252,236,137,41,137,65,4,139,105,252,240,139,65,252,
+  244,137,105,8,137,65,12,139,105,224,139,65,228,137,105,252,248,137,65,252,
+  252,129,252,248,239,184,237,15,133,244,29,137,202,137,114,252,252,139,181,
+  233,139,14,15,182,252,233,15,182,205,131,198,4,252,255,36,171,255,137,124,
+  36,16,137,92,36,20,139,108,202,252,240,139,68,202,252,248,139,157,233,131,
+  198,4,139,189,233,248,1,57,216,15,131,244,251,129,124,253,199,4,239,15,132,
+  244,250,255,219,68,202,252,248,255,139,108,199,4,137,108,202,12,139,44,199,
+  137,108,202,8,131,192,1,255,137,68,202,252,248,248,2,15,183,70,252,254,141,
+  180,253,134,233,248,3,139,92,36,20,139,124,36,16,139,6,15,182,204,15,182,
+  232,131,198,4,193,232,16,252,255,36,171,248,4,131,192,1,255,137,68,202,252,
+  248,255,252,233,244,1,248,5,41,216,248,6,59,133,233,15,135,244,3,105,252,
+  248,239,3,189,233,129,191,233,239,15,132,244,253,141,92,24,1,139,175,233,
+  139,135,233,137,44,202,137,68,202,4,139,175,233,139,135,233,137,108,202,8,
+  137,68,202,12,137,92,202,252,248,252,233,244,2,248,7,255,131,192,1,252,233,
+  244,6,255,129,124,253,202,252,236,239,15,133,244,251,139,108,202,232,129,
+  124,253,202,252,244,239,15,133,244,251,129,124,253,202,252,252,239,15,133,
+  244,251,128,189,233,235,15,133,244,251,141,180,253,134,233,199,68,202,252,
+  248,0,0,0,0,248,1,139,6,15,182,204,15,182,232,131,198,4,193,232,16,252,255,
+  36,171,248,5,198,70,252,252,235,141,180,253,134,233,198,6,235,252,233,244,
+  1,255,15,182,252,236,15,182,192,137,124,36,16,141,188,253,194,233,141,12,
+  202,43,122,252,252,133,252,237,15,132,244,251,141,108,252,233,252,248,57,
+  215,15,131,244,248,248,1,139,71,252,248,137,1,139,71,252,252,131,199,8,137,
+  65,4,131,193,8,57,252,233,15,131,244,249,57,215,15,130,244,1,248,2,199,65,
+  4,237,131,193,8,57,252,233,15,130,244,2,248,3,139,124,36,16,139,6,15,182,
+  204,15,182,232,131,198,4,193,232,16,252,255,36,171,248,5,199,68,36,20,1,0,
+  0,0,137,208,41,252,248,15,134,244,3,137,197,193,252,237,3,131,197,1,137,108,
+  36,20,139,108,36,48,1,200,59,133,233,15,135,244,253,248,6,255,139,71,252,
+  248,137,1,139,71,252,252,131,199,8,137,65,4,131,193,8,57,215,15,130,244,6,
+  252,233,244,3,248,7,137,149,233,137,141,233,137,116,36,24,41,215,139,84,36,
+  20,131,252,234,1,137,252,233,232,251,1,0,139,149,233,139,141,233,1,215,252,
+  233,244,6,255,193,225,3,255,248,1,139,114,252,252,137,68,36,20,252,247,198,
+  237,15,133,244,253,255,248,13,137,215,131,232,1,15,132,244,249,248,2,139,
+  44,15,137,111,252,248,139,108,15,4,137,111,252,252,131,199,8,131,232,1,15,
+  133,244,2,248,3,139,68,36,20,15,182,110,252,255,248,5,57,197,15,135,244,252,
+  255,139,108,10,4,137,106,252,252,139,44,10,137,106,252,248,255,248,5,56,70,
+  252,255,15,135,244,252,255,15,182,78,252,253,252,247,209,141,20,202,139,122,
+  252,248,139,191,233,139,191,233,139,6,15,182,204,15,182,232,131,198,4,193,
+  232,16,252,255,36,171,248,6,255,199,71,252,252,237,131,199,8,255,199,68,194,
+  252,244,237,255,131,192,1,252,233,244,5,248,7,141,174,233,252,247,197,237,
+  15,133,244,14,41,252,234,255,1,252,233,255,137,252,245,209,252,237,129,229,
+  239,102,129,172,253,43,233,238,15,130,244,149,255,141,12,202,255,129,121,
+  253,4,239,15,133,244,255,255,129,121,253,12,239,15,133,244,61,129,121,253,
+  20,239,15,133,244,61,139,41,131,121,16,0,15,140,244,251,255,129,121,253,12,
+  239,15,133,244,165,129,121,253,20,239,15,133,244,165,255,139,105,16,133,252,
+  237,15,136,244,251,3,41,15,128,244,247,137,41,255,59,105,8,199,65,28,237,
+  137,105,24,255,15,142,244,253,248,1,248,6,141,180,253,134,233,255,141,180,
+  253,134,233,15,183,70,252,254,15,142,245,248,1,248,6,255,15,143,244,253,248,
+  6,141,180,253,134,233,248,1,255,248,7,139,6,15,182,204,15,182,232,131,198,
+  4,193,232,16,252,255,36,171,248,5,255,3,41,15,128,244,1,137,41,255,15,141,
+  244,7,255,141,180,253,134,233,15,183,70,252,254,15,141,245,255,15,140,244,
+  7,255,252,233,244,6,248,9,255,129,121,253,4,239,255,15,131,244,61,129,121,
+  253,12,239,15,131,244,61,255,129,121,253,12,239,15,131,244,165,129,121,253,
+  20,239,15,131,244,165,255,139,105,20,255,129,252,253,239,15,131,244,61,255,
+  252,242,15,16,1,252,242,15,16,73,8,255,252,242,15,88,65,16,252,242,15,17,
+  1,133,252,237,15,136,244,249,255,15,140,244,249,255,102,15,46,200,248,1,252,
+  242,15,17,65,24,255,221,65,8,221,1,255,220,65,16,221,17,221,81,24,133,252,
+  237,15,136,244,247,255,221,81,24,15,140,244,247,255,217,201,248,1,255,15,
+  183,70,252,254,255,15,131,244,7,255,15,131,244,248,141,180,253,134,233,255,
+  141,180,253,134,233,15,183,70,252,254,15,131,245,255,15,130,244,7,255,15,
+  130,244,248,141,180,253,134,233,255,248,3,102,15,46,193,252,233,244,1,255,
+  141,12,202,139,105,4,129,252,253,239,15,132,244,247,255,137,105,252,252,139,
+  41,137,105,252,248,252,233,245,255,141,180,253,134,233,139,1,137,105,252,
+  252,137,65,252,248,255,139,139,233,139,4,129,139,128,233,139,108,36,48,137,
+  147,233,137,171,233,252,255,224,255,141,180,253,134,233,139,6,15,182,204,
+  15,182,232,131,198,4,193,232,16,252,255,36,171,255,137,252,245,209,252,237,
+  129,229,239,102,129,172,253,43,233,238,15,130,244,151,255,139,190,233,139,
+  108,36,48,141,12,202,59,141,233,15,135,244,24,15,182,142,233,57,200,15,134,
+  244,249,248,2,255,15,183,70,252,254,252,233,245,255,248,3,199,68,194,252,
+  252,237,131,192,1,57,200,15,134,244,3,252,233,244,2,255,141,44,197,237,141,
+  4,194,139,122,252,248,137,104,252,252,137,120,252,248,139,108,36,48,141,12,
+  200,59,141,233,15,135,244,23,137,209,137,194,15,182,174,233,133,252,237,15,
+  132,244,248,248,1,131,193,8,57,209,15,131,244,249,139,121,252,248,137,56,
+  139,121,252,252,137,120,4,131,192,8,199,65,252,252,237,131,252,237,1,15,133,
+  244,1,248,2,255,139,190,233,139,6,15,182,204,15,182,232,131,198,4,193,232,
+  16,252,255,36,171,255,248,3,199,64,4,237,131,192,8,131,252,237,1,15,133,244,
+  3,252,233,244,2,255,139,106,252,248,139,189,233,139,108,36,48,141,68,194,
+  252,248,137,149,233,141,136,233,59,141,233,137,133,233,255,137,44,36,255,
+  137,124,36,4,137,44,36,255,15,135,244,22,199,131,233,237,255,252,255,215,
+  255,252,255,147,233,255,199,131,233,237,139,149,233,141,12,194,252,247,217,
+  3,141,233,139,114,252,252,252,233,244,12,255,254,0
 };
 
 enum {
@@ -863,6 +874,7 @@ enum {
   GLOB_vmeta_call,
   GLOB_vm_call_dispatch_f,
   GLOB_vm_cpcall,
+  GLOB_cont_ffi_callback,
   GLOB_vm_call_tail,
   GLOB_cont_cat,
   GLOB_cont_ra,
@@ -995,8 +1007,9 @@ enum {
   GLOB_vm_foldfpm,
   GLOB_vm_foldarith,
   GLOB_vm_cpuid,
-  GLOB_vm_ffi_call,
   GLOB_assert_bad_for_arg_type,
+  GLOB_vm_ffi_callback,
+  GLOB_vm_ffi_call,
   GLOB_BC_MODVN_Z,
   GLOB_BC_TGETS_Z,
   GLOB_BC_TSETS_Z,
@@ -1025,6 +1038,7 @@ static const char *const globnames[] = {
   "vmeta_call",
   "vm_call_dispatch_f",
   "vm_cpcall",
+  "cont_ffi_callback",
   "vm_call_tail",
   "cont_cat",
   "cont_ra",
@@ -1157,8 +1171,9 @@ static const char *const globnames[] = {
   "vm_foldfpm",
   "vm_foldarith",
   "vm_cpuid",
-  "vm_ffi_call@4",
   "assert_bad_for_arg_type",
+  "vm_ffi_callback",
+  "vm_ffi_call@4",
   "BC_MODVN_Z",
   "BC_TGETS_Z",
   "BC_TSETS_Z",
@@ -1192,6 +1207,8 @@ static const char *const extnames[] = {
   "lj_dispatch_call@8",
   "lj_trace_exit@8",
   "lj_err_throw@8",
+  "lj_ccallback_enter@8",
+  "lj_ccallback_leave@8",
   "lj_meta_cat",
   "lj_gc_barrieruv@8",
   "lj_func_closeuv@8",
@@ -1232,771 +1249,788 @@ static void build_subroutines(BuildCtx *ctx, int cmov, int sse)
   dasm_put(Dst, 353, Dt1(->top), Dt1(->base), Dt1(->top), Dt7(->pc), FRAME_CP, CFRAME_RESUME, Dt1(->glref), GG_G2DISP, Dt1(->cframe), Dt1(->status), DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->status), Dt1(->base), Dt1(->top), FRAME_TYPE);
   dasm_put(Dst, 495, FRAME_CP, FRAME_C, Dt1(->cframe), Dt1(->cframe), Dt1(->glref), GG_G2DISP, DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base));
   dasm_put(Dst, 573, Dt1(->top), LJ_TFUNC, Dt7(->pc), Dt1(->stack), Dt1(->top), Dt1(->cframe), Dt1(->cframe), FRAME_CP, LJ_TNIL);
-  dasm_put(Dst, 753, Dt7(->pc), PC2PROTO(k), LJ_TSTR, BC_GGET, DISPATCH_GL(tmptv), LJ_TTAB);
-  dasm_put(Dst, 875);
+#if LJ_HASFFI
+#endif
+  dasm_put(Dst, 743);
+#if LJ_HASFFI
+  dasm_put(Dst, 748);
+#endif
+  dasm_put(Dst, 757, Dt7(->pc), PC2PROTO(k));
+#if LJ_HASFFI
+  dasm_put(Dst, 771);
+#endif
+  dasm_put(Dst, 792, LJ_TSTR, BC_GGET, DISPATCH_GL(tmptv), LJ_TTAB);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 881, LJ_TISNUM);
+    dasm_put(Dst, 890, LJ_TISNUM);
   } else if (sse) {
-    dasm_put(Dst, 891);
+    dasm_put(Dst, 900);
   } else {
-    dasm_put(Dst, 904);
+    dasm_put(Dst, 913);
   }
-  dasm_put(Dst, 917, Dt1(->base), Dt1(->base), Dt1(->top), FRAME_CONT, 2+1, LJ_TSTR, BC_GSET);
-  dasm_put(Dst, 1069, DISPATCH_GL(tmptv), LJ_TTAB);
+  dasm_put(Dst, 926, Dt1(->base), Dt1(->base), Dt1(->top), FRAME_CONT, 2+1, LJ_TSTR, BC_GSET);
+  dasm_put(Dst, 1078, DISPATCH_GL(tmptv), LJ_TTAB);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 881, LJ_TISNUM);
+    dasm_put(Dst, 890, LJ_TISNUM);
   } else if (sse) {
-    dasm_put(Dst, 891);
+    dasm_put(Dst, 900);
   } else {
-    dasm_put(Dst, 904);
+    dasm_put(Dst, 913);
   }
-  dasm_put(Dst, 1092, Dt1(->base), Dt1(->base), Dt1(->top), FRAME_CONT, 3+1, Dt1(->base), Dt1(->base));
-  dasm_put(Dst, 1286, -BCBIAS_J*4, LJ_TISTRUECOND, LJ_TISTRUECOND, Dt1(->base));
-  dasm_put(Dst, 1393);
+  dasm_put(Dst, 1101, Dt1(->base), Dt1(->base), Dt1(->top), FRAME_CONT, 3+1, Dt1(->base), Dt1(->base));
+  dasm_put(Dst, 1295, -BCBIAS_J*4, LJ_TISTRUECOND, LJ_TISTRUECOND, Dt1(->base));
+  dasm_put(Dst, 1402);
 #if LJ_HASFFI
-  dasm_put(Dst, 1408, Dt1(->base));
+  dasm_put(Dst, 1417, Dt1(->base));
 #endif
-  dasm_put(Dst, 1439);
+  dasm_put(Dst, 1448);
 #if LJ_DUALNUM
-  dasm_put(Dst, 1442);
+  dasm_put(Dst, 1451);
 #endif
-  dasm_put(Dst, 1448);
+  dasm_put(Dst, 1457);
 #if LJ_DUALNUM
-  dasm_put(Dst, 875);
+  dasm_put(Dst, 884);
 #endif
-  dasm_put(Dst, 1460);
+  dasm_put(Dst, 1469);
 #if LJ_DUALNUM
-  dasm_put(Dst, 1442);
+  dasm_put(Dst, 1451);
 #endif
-  dasm_put(Dst, 1488, Dt1(->base), Dt1(->base), FRAME_CONT, 2+1, Dt1(->base), Dt1(->base));
+  dasm_put(Dst, 1497, Dt1(->base), Dt1(->base), FRAME_CONT, 2+1, Dt1(->base), Dt1(->base));
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-  dasm_put(Dst, 1598);
+  dasm_put(Dst, 1607);
 #else
-  dasm_put(Dst, 1617);
+  dasm_put(Dst, 1626);
 #endif
-  dasm_put(Dst, 1622, Dt1(->base), Dt1(->base), Dt7(->pc), Dt1(->base), Dt1(->base), GG_DISP2STATIC, 1+1, LJ_TISTRUECOND);
-  dasm_put(Dst, 1811, 1+1, ~LJ_TNUMX);
+  dasm_put(Dst, 1631, Dt1(->base), Dt1(->base), Dt7(->pc), Dt1(->base), Dt1(->base), GG_DISP2STATIC, 1+1, LJ_TISTRUECOND);
+  dasm_put(Dst, 1820, 1+1, ~LJ_TNUMX);
   if (cmov) {
-  dasm_put(Dst, 1869);
+  dasm_put(Dst, 1878);
   } else {
-  dasm_put(Dst, 1873);
+  dasm_put(Dst, 1882);
   }
-  dasm_put(Dst, 1882, ((char *)(&((GCfuncC *)0)->upvalue)), LJ_TSTR, 1+1, LJ_TTAB, Dt6(->metatable), LJ_TNIL, DISPATCH_GL(gcroot)+4*(GCROOT_MMNAME+MM_metatable), LJ_TTAB);
-  dasm_put(Dst, 1965, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), DtB(->next), LJ_TNIL);
-  dasm_put(Dst, 2023, LJ_TUDATA, LJ_TISNUM, LJ_TNUMX, DISPATCH_GL(gcroot[GCROOT_BASEMT]), 2+1);
-  dasm_put(Dst, 2086, LJ_TTAB, Dt6(->metatable), LJ_TTAB, Dt6(->metatable), LJ_TTAB, Dt6(->marked), LJ_GC_BLACK, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
-  dasm_put(Dst, 2158, 2+1, LJ_TTAB, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 1891, ((char *)(&((GCfuncC *)0)->upvalue)), LJ_TSTR, 1+1, LJ_TTAB, Dt6(->metatable), LJ_TNIL, DISPATCH_GL(gcroot)+4*(GCROOT_MMNAME+MM_metatable), LJ_TTAB);
+  dasm_put(Dst, 1974, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), DtB(->next), LJ_TNIL);
+  dasm_put(Dst, 2032, LJ_TUDATA, LJ_TISNUM, LJ_TNUMX, DISPATCH_GL(gcroot[GCROOT_BASEMT]), 2+1);
+  dasm_put(Dst, 2095, LJ_TTAB, Dt6(->metatable), LJ_TTAB, Dt6(->metatable), LJ_TTAB, Dt6(->marked), LJ_GC_BLACK, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
+  dasm_put(Dst, 2167, 2+1, LJ_TTAB, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 2247);
+    dasm_put(Dst, 2256);
   } else {
-    dasm_put(Dst, 2264);
+    dasm_put(Dst, 2273);
   }
   if (sse) {
-    dasm_put(Dst, 2269);
+    dasm_put(Dst, 2278);
   } else {
-    dasm_put(Dst, 2279);
+    dasm_put(Dst, 2288);
   }
-  dasm_put(Dst, 2286, 1+1, LJ_TSTR, LJ_TSTR, LJ_TISNUM, DISPATCH_GL(gcroot[GCROOT_BASEMT_NUM]), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
-  dasm_put(Dst, 2352, Dt1(->base));
+  dasm_put(Dst, 2295, 1+1, LJ_TSTR, LJ_TSTR, LJ_TISNUM, DISPATCH_GL(gcroot[GCROOT_BASEMT_NUM]), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
+  dasm_put(Dst, 2361, Dt1(->base));
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 2376);
+    dasm_put(Dst, 2385);
   } else {
-    dasm_put(Dst, 2381);
+    dasm_put(Dst, 2390);
   }
-  dasm_put(Dst, 2386, Dt1(->base), 1+1, LJ_TTAB, Dt1(->base), Dt1(->top), Dt1(->base), 1+2);
-  dasm_put(Dst, 2495, LJ_TNIL, LJ_TNIL, 1+1, LJ_TTAB);
+  dasm_put(Dst, 2395, Dt1(->base), 1+1, LJ_TTAB, Dt1(->base), Dt1(->top), Dt1(->base), 1+2);
+  dasm_put(Dst, 2504, LJ_TNIL, LJ_TNIL, 1+1, LJ_TTAB);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-  dasm_put(Dst, 2542, Dt6(->metatable));
+  dasm_put(Dst, 2551, Dt6(->metatable));
 #endif
-  dasm_put(Dst, 2551, Dt8(->upvalue[0]), LJ_TFUNC, LJ_TNIL, 1+3, 1+1, LJ_TTAB, LJ_TISNUM);
+  dasm_put(Dst, 2560, Dt8(->upvalue[0]), LJ_TFUNC, LJ_TNIL, 1+3, 1+1, LJ_TTAB, LJ_TISNUM);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 2537);
+    dasm_put(Dst, 2546);
   } else {
-    dasm_put(Dst, 2264);
+    dasm_put(Dst, 2273);
   }
-  dasm_put(Dst, 2606);
+  dasm_put(Dst, 2615);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 2611, LJ_TISNUM);
+    dasm_put(Dst, 2620, LJ_TISNUM);
   } else if (sse) {
-    dasm_put(Dst, 2627);
+    dasm_put(Dst, 2636);
   } else {
-    dasm_put(Dst, 2666);
+    dasm_put(Dst, 2675);
   }
-  dasm_put(Dst, 2684, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->hmask), 1+0);
-  dasm_put(Dst, 2522, 1+1, LJ_TTAB);
+  dasm_put(Dst, 2693, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->hmask), 1+0);
+  dasm_put(Dst, 2531, 1+1, LJ_TTAB);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-  dasm_put(Dst, 2542, Dt6(->metatable));
+  dasm_put(Dst, 2551, Dt6(->metatable));
 #endif
-  dasm_put(Dst, 2765, Dt8(->upvalue[0]), LJ_TFUNC);
+  dasm_put(Dst, 2774, Dt8(->upvalue[0]), LJ_TFUNC);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 2786, LJ_TISNUM);
+    dasm_put(Dst, 2795, LJ_TISNUM);
   } else if (sse) {
-    dasm_put(Dst, 2798);
-  } else {
-    dasm_put(Dst, 2808);
-  }
-  dasm_put(Dst, 2815, 1+3, 1+1, 8+FRAME_PCALL, DISPATCH_GL(hookmask), HOOK_ACTIVE_SHIFT, 2+1, LJ_TFUNC);
-  dasm_put(Dst, 2879, LJ_TFUNC, 16+FRAME_PCALL, 1+1, LJ_TTHREAD, Dt1(->cframe), Dt1(->status), LUA_YIELD, Dt1(->top));
-  dasm_put(Dst, 2967, Dt1(->base), Dt1(->maxstack), Dt1(->top), Dt1(->base), Dt1(->top), DISPATCH_GL(vmstate), ~LJ_VMST_INTERP);
-  dasm_put(Dst, 3068, Dt1(->base), LUA_YIELD, Dt1(->base), Dt1(->top), Dt1(->top), Dt1(->maxstack), LJ_TTRUE, FRAME_TYPE);
-  dasm_put(Dst, 3182, LJ_TFALSE, Dt1(->top), Dt1(->top), 1+2, Dt1(->top), Dt1(->base), Dt8(->upvalue[0].gcr), Dt1(->cframe));
-  dasm_put(Dst, 3280, Dt1(->status), LUA_YIELD, Dt1(->top), Dt1(->base), Dt1(->maxstack), Dt1(->top), Dt1(->base), Dt1(->top));
-  dasm_put(Dst, 3346, DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base), LUA_YIELD, Dt1(->base), Dt1(->top), Dt1(->top), Dt1(->maxstack));
-  dasm_put(Dst, 3447, FRAME_TYPE, Dt1(->top), Dt1(->base), Dt1(->cframe), CFRAME_RESUME);
-  dasm_put(Dst, 3560, Dt1(->base), Dt1(->top), Dt1(->cframe), LUA_YIELD, Dt1(->status));
+    dasm_put(Dst, 2807);
+  } else {
+    dasm_put(Dst, 2817);
+  }
+  dasm_put(Dst, 2824, 1+3, 1+1, 8+FRAME_PCALL, DISPATCH_GL(hookmask), HOOK_ACTIVE_SHIFT, 2+1, LJ_TFUNC);
+  dasm_put(Dst, 2888, LJ_TFUNC, 16+FRAME_PCALL, 1+1, LJ_TTHREAD, Dt1(->cframe), Dt1(->status), LUA_YIELD, Dt1(->top));
+  dasm_put(Dst, 2976, Dt1(->base), Dt1(->maxstack), Dt1(->top), Dt1(->base), Dt1(->top), DISPATCH_GL(vmstate), ~LJ_VMST_INTERP);
+  dasm_put(Dst, 3077, Dt1(->base), LUA_YIELD, Dt1(->base), Dt1(->top), Dt1(->top), Dt1(->maxstack), LJ_TTRUE, FRAME_TYPE);
+  dasm_put(Dst, 3191, LJ_TFALSE, Dt1(->top), Dt1(->top), 1+2, Dt1(->top), Dt1(->base), Dt8(->upvalue[0].gcr), Dt1(->cframe));
+  dasm_put(Dst, 3289, Dt1(->status), LUA_YIELD, Dt1(->top), Dt1(->base), Dt1(->maxstack), Dt1(->top), Dt1(->base), Dt1(->top));
+  dasm_put(Dst, 3355, DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base), LUA_YIELD, Dt1(->base), Dt1(->top), Dt1(->top), Dt1(->maxstack));
+  dasm_put(Dst, 3456, FRAME_TYPE, Dt1(->top), Dt1(->base), Dt1(->cframe), CFRAME_RESUME);
+  dasm_put(Dst, 3569, Dt1(->base), Dt1(->top), Dt1(->cframe), LUA_YIELD, Dt1(->status));
   if (!LJ_DUALNUM) {
-    dasm_put(Dst, 3586);
+    dasm_put(Dst, 3595);
   }
   if (sse) {
-    dasm_put(Dst, 3589);
+    dasm_put(Dst, 3598);
   }
-  dasm_put(Dst, 3604, 1+1);
+  dasm_put(Dst, 3613, 1+1);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 3615, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 3624, LJ_TISNUM, LJ_TISNUM);
   } else {
-    dasm_put(Dst, 3695, LJ_TISNUM);
+    dasm_put(Dst, 3704, LJ_TISNUM);
   }
   if (sse) {
-    dasm_put(Dst, 3705);
+    dasm_put(Dst, 3714);
   } else {
-    dasm_put(Dst, 3741);
+    dasm_put(Dst, 3750);
   }
-  dasm_put(Dst, 3758, 1+1, FRAME_TYPE, LJ_TNIL);
+  dasm_put(Dst, 3767, 1+1, FRAME_TYPE, LJ_TNIL);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 3850, LJ_TISNUM);
+  dasm_put(Dst, 3859, LJ_TISNUM);
   } else {
-  dasm_put(Dst, 3695, LJ_TISNUM);
+  dasm_put(Dst, 3704, LJ_TISNUM);
   }
   if (sse) {
-  dasm_put(Dst, 3872);
-    if (LJ_DUALNUM) {
   dasm_put(Dst, 3881);
+    if (LJ_DUALNUM) {
+  dasm_put(Dst, 3890);
     }
-  dasm_put(Dst, 2274);
+  dasm_put(Dst, 2283);
   } else {
-  dasm_put(Dst, 3915);
+  dasm_put(Dst, 3924);
     if (LJ_DUALNUM) {
-  dasm_put(Dst, 3921);
+  dasm_put(Dst, 3930);
   if (cmov) {
-  dasm_put(Dst, 3944);
+  dasm_put(Dst, 3953);
   } else {
-  dasm_put(Dst, 3950);
+  dasm_put(Dst, 3959);
   }
-  dasm_put(Dst, 3957);
+  dasm_put(Dst, 3966);
     } else {
-  dasm_put(Dst, 2281);
+  dasm_put(Dst, 2290);
     }
   }
-  dasm_put(Dst, 3974);
+  dasm_put(Dst, 3983);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 3850, LJ_TISNUM);
+  dasm_put(Dst, 3859, LJ_TISNUM);
   } else {
-  dasm_put(Dst, 3695, LJ_TISNUM);
+  dasm_put(Dst, 3704, LJ_TISNUM);
   }
   if (sse) {
-  dasm_put(Dst, 3977);
+  dasm_put(Dst, 3986);
     if (LJ_DUALNUM) {
-  dasm_put(Dst, 3881);
+  dasm_put(Dst, 3890);
     }
-  dasm_put(Dst, 2274);
+  dasm_put(Dst, 2283);
   } else {
-  dasm_put(Dst, 3986);
+  dasm_put(Dst, 3995);
     if (LJ_DUALNUM) {
-  dasm_put(Dst, 3921);
+  dasm_put(Dst, 3930);
   if (cmov) {
-  dasm_put(Dst, 3944);
+  dasm_put(Dst, 3953);
   } else {
-  dasm_put(Dst, 3950);
+  dasm_put(Dst, 3959);
   }
-  dasm_put(Dst, 3957);
+  dasm_put(Dst, 3966);
     } else {
-  dasm_put(Dst, 2281);
+  dasm_put(Dst, 2290);
     }
   }
   if (sse) {
-    dasm_put(Dst, 3992, 1+1, LJ_TISNUM);
+    dasm_put(Dst, 4001, 1+1, LJ_TISNUM);
   } else {
-    dasm_put(Dst, 4021, 1+1, LJ_TISNUM);
+    dasm_put(Dst, 4030, 1+1, LJ_TISNUM);
   }
-  dasm_put(Dst, 4050, 1+1, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1);
-  dasm_put(Dst, 4119, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1);
-  dasm_put(Dst, 4176, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1);
-  dasm_put(Dst, 4239, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1, LJ_TISNUM);
-  dasm_put(Dst, 4329);
+  dasm_put(Dst, 4059, 1+1, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1);
+  dasm_put(Dst, 4128, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1);
+  dasm_put(Dst, 4185, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1);
+  dasm_put(Dst, 4248, LJ_TISNUM, 1+1, LJ_TISNUM, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 4338);
   if (sse) {
-  dasm_put(Dst, 4341, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 4350, 1+1, LJ_TISNUM);
   } else {
-  dasm_put(Dst, 4372, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 4381, 1+1, LJ_TISNUM);
   }
-  dasm_put(Dst, 4397);
+  dasm_put(Dst, 4406);
   if (sse) {
-  dasm_put(Dst, 4411, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 4420, 1+1, LJ_TISNUM);
   } else {
-  dasm_put(Dst, 4442, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 4451, 1+1, LJ_TISNUM);
   }
-  dasm_put(Dst, 4467);
+  dasm_put(Dst, 4476);
   if (sse) {
-  dasm_put(Dst, 4481, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 4490, 1+1, LJ_TISNUM);
   } else {
-  dasm_put(Dst, 4512, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 4521, 1+1, LJ_TISNUM);
   }
-  dasm_put(Dst, 4537);
+  dasm_put(Dst, 4546);
   if (sse) {
-    dasm_put(Dst, 4553, 1+1, LJ_TISNUM, Dt8(->upvalue[0]));
+    dasm_put(Dst, 4562, 1+1, LJ_TISNUM, Dt8(->upvalue[0]));
   } else {
-    dasm_put(Dst, 4592, 1+1, LJ_TISNUM, Dt8(->upvalue[0]));
+    dasm_put(Dst, 4601, 1+1, LJ_TISNUM, Dt8(->upvalue[0]));
   }
-  dasm_put(Dst, 4625, 2+1, LJ_TISNUM, LJ_TISNUM, 2+1, LJ_TISNUM, LJ_TISNUM);
-  dasm_put(Dst, 4690, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 4634, 2+1, LJ_TISNUM, LJ_TISNUM, 2+1, LJ_TISNUM, LJ_TISNUM);
+  dasm_put(Dst, 4699, 1+1, LJ_TISNUM);
   if (sse) {
-    dasm_put(Dst, 4789);
+    dasm_put(Dst, 4798);
   } else {
-    dasm_put(Dst, 4795);
+    dasm_put(Dst, 4804);
   }
-  dasm_put(Dst, 4804);
+  dasm_put(Dst, 4813);
   if (sse) {
-    dasm_put(Dst, 4829);
+    dasm_put(Dst, 4838);
   } else {
-    dasm_put(Dst, 4835);
+    dasm_put(Dst, 4844);
   }
-  dasm_put(Dst, 4838, 1+2);
+  dasm_put(Dst, 4847, 1+2);
   if (sse) {
-    dasm_put(Dst, 4847);
+    dasm_put(Dst, 4856);
   } else {
-    dasm_put(Dst, 4855);
+    dasm_put(Dst, 4864);
   }
-  dasm_put(Dst, 4863);
+  dasm_put(Dst, 4872);
   if (sse) {
-    dasm_put(Dst, 4866);
+    dasm_put(Dst, 4875);
   } else {
-    dasm_put(Dst, 4898);
+    dasm_put(Dst, 4907);
   }
-  dasm_put(Dst, 4917);
+  dasm_put(Dst, 4926);
   if (sse) {
-    dasm_put(Dst, 4933, 1+1, LJ_TISNUM);
+    dasm_put(Dst, 4942, 1+1, LJ_TISNUM);
   } else {
-    dasm_put(Dst, 4958, 1+1, LJ_TISNUM);
+    dasm_put(Dst, 4967, 1+1, LJ_TISNUM);
   }
-  dasm_put(Dst, 4980);
+  dasm_put(Dst, 4989);
   if (sse) {
-    dasm_put(Dst, 5002);
+    dasm_put(Dst, 5011);
   } else {
-    dasm_put(Dst, 5028);
+    dasm_put(Dst, 5037);
   }
-  dasm_put(Dst, 5045, 1+2);
+  dasm_put(Dst, 5054, 1+2);
   if (sse) {
-    dasm_put(Dst, 5085);
+    dasm_put(Dst, 5094);
   } else {
-    dasm_put(Dst, 5093);
+    dasm_put(Dst, 5102);
   }
-  dasm_put(Dst, 5103, 2+1, LJ_TISNUM, LJ_TISNUM);
+  dasm_put(Dst, 5112, 2+1, LJ_TISNUM, LJ_TISNUM);
   if (sse) {
-    dasm_put(Dst, 5155, 2+1, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 5164, 2+1, LJ_TISNUM, LJ_TISNUM);
   } else {
-    dasm_put(Dst, 5202, 2+1, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 5211, 2+1, LJ_TISNUM, LJ_TISNUM);
   }
-  dasm_put(Dst, 5243, LJ_TISNUM);
+  dasm_put(Dst, 5252, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 5256, LJ_TISNUM);
+  dasm_put(Dst, 5265, LJ_TISNUM);
   if (sse) {
-  dasm_put(Dst, 4789);
+  dasm_put(Dst, 4798);
   } else {
-  dasm_put(Dst, 4795);
+  dasm_put(Dst, 4804);
   }
-  dasm_put(Dst, 5306);
+  dasm_put(Dst, 5315);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 5317, LJ_TISNUM);
+  dasm_put(Dst, 5326, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 5338);
+  dasm_put(Dst, 5347);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
-  dasm_put(Dst, 5359);
+  dasm_put(Dst, 5368);
   } else {
-  dasm_put(Dst, 5384, LJ_TISNUM);
+  dasm_put(Dst, 5393, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 5402);
+  dasm_put(Dst, 5411);
   } else {
-  dasm_put(Dst, 5420);
+  dasm_put(Dst, 5429);
   }
-  dasm_put(Dst, 5425);
+  dasm_put(Dst, 5434);
   if (cmov) {
-  dasm_put(Dst, 5435);
+  dasm_put(Dst, 5444);
   } else {
-  dasm_put(Dst, 5443);
+  dasm_put(Dst, 5452);
   }
-  dasm_put(Dst, 5376);
+  dasm_put(Dst, 5385);
   }
-  dasm_put(Dst, 5464, LJ_TISNUM);
+  dasm_put(Dst, 5473, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 5477, LJ_TISNUM);
+  dasm_put(Dst, 5486, LJ_TISNUM);
   if (sse) {
-  dasm_put(Dst, 4789);
+  dasm_put(Dst, 4798);
   } else {
-  dasm_put(Dst, 4795);
+  dasm_put(Dst, 4804);
   }
-  dasm_put(Dst, 5306);
+  dasm_put(Dst, 5315);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 5317, LJ_TISNUM);
+  dasm_put(Dst, 5326, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 5338);
+  dasm_put(Dst, 5347);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
-  dasm_put(Dst, 5527);
+  dasm_put(Dst, 5536);
   } else {
-  dasm_put(Dst, 5384, LJ_TISNUM);
+  dasm_put(Dst, 5393, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 5402);
+  dasm_put(Dst, 5411);
   } else {
-  dasm_put(Dst, 5420);
+  dasm_put(Dst, 5429);
   }
-  dasm_put(Dst, 5425);
+  dasm_put(Dst, 5434);
   if (cmov) {
-  dasm_put(Dst, 5552);
+  dasm_put(Dst, 5561);
   } else {
-  dasm_put(Dst, 5560);
+  dasm_put(Dst, 5569);
   }
-  dasm_put(Dst, 5376);
+  dasm_put(Dst, 5385);
   }
   if (!sse) {
-    dasm_put(Dst, 5581);
+    dasm_put(Dst, 5590);
   }
-  dasm_put(Dst, 5590, 1+1, LJ_TSTR);
+  dasm_put(Dst, 5599, 1+1, LJ_TSTR);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 5612, Dt5(->len));
+    dasm_put(Dst, 5621, Dt5(->len));
   } else if (sse) {
-    dasm_put(Dst, 5620, Dt5(->len));
+    dasm_put(Dst, 5629, Dt5(->len));
   } else {
-    dasm_put(Dst, 5631, Dt5(->len));
+    dasm_put(Dst, 5640, Dt5(->len));
   }
-  dasm_put(Dst, 5639, 1+1, LJ_TSTR, Dt5(->len), Dt5([1]));
+  dasm_put(Dst, 5648, 1+1, LJ_TSTR, Dt5(->len), Dt5([1]));
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 3969);
+    dasm_put(Dst, 3978);
   } else if (sse) {
-    dasm_put(Dst, 5677);
+    dasm_put(Dst, 5686);
   } else {
-    dasm_put(Dst, 5687);
+    dasm_put(Dst, 5696);
   }
-  dasm_put(Dst, 5700, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), 1+1, LJ_TISNUM);
+  dasm_put(Dst, 5709, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 5731);
+    dasm_put(Dst, 5740);
   } else if (sse) {
-    dasm_put(Dst, 5754);
+    dasm_put(Dst, 5763);
   } else {
-    dasm_put(Dst, 5780);
+    dasm_put(Dst, 5789);
   }
-  dasm_put(Dst, 5804, Dt1(->base), Dt1(->base), LJ_TSTR, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), 1+2, LJ_TISNUM);
+  dasm_put(Dst, 5813, Dt1(->base), Dt1(->base), LJ_TSTR, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), 1+2, LJ_TISNUM);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 5907);
+    dasm_put(Dst, 5916);
   } else if (sse) {
-    dasm_put(Dst, 5919);
+    dasm_put(Dst, 5928);
   } else {
-    dasm_put(Dst, 5934);
+    dasm_put(Dst, 5943);
   }
-  dasm_put(Dst, 5946, LJ_TSTR, LJ_TISNUM);
+  dasm_put(Dst, 5955, LJ_TSTR, LJ_TISNUM);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 2537);
+    dasm_put(Dst, 2546);
   } else {
-    dasm_put(Dst, 2264);
+    dasm_put(Dst, 2273);
   }
-  dasm_put(Dst, 5963, Dt5(->len));
+  dasm_put(Dst, 5972, Dt5(->len));
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 5973);
+    dasm_put(Dst, 5982);
   } else if (sse) {
-    dasm_put(Dst, 5977);
+    dasm_put(Dst, 5986);
   } else {
-    dasm_put(Dst, 5984);
+    dasm_put(Dst, 5993);
   }
-  dasm_put(Dst, 5996, sizeof(GCstr)-1);
-  dasm_put(Dst, 6071, 2+1, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
-  dasm_put(Dst, 6130, LJ_TSTR, LJ_TISNUM);
+  dasm_put(Dst, 6005, sizeof(GCstr)-1);
+  dasm_put(Dst, 6080, 2+1, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold));
+  dasm_put(Dst, 6139, LJ_TSTR, LJ_TISNUM);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 6147);
+    dasm_put(Dst, 6156);
   } else if (sse) {
-    dasm_put(Dst, 6155);
+    dasm_put(Dst, 6164);
   } else {
-    dasm_put(Dst, 6166);
+    dasm_put(Dst, 6175);
   }
-  dasm_put(Dst, 6182, Dt5(->len), DISPATCH_GL(tmpbuf.sz), Dt5([1]), DISPATCH_GL(tmpbuf.buf), DISPATCH_GL(tmpbuf.buf), 1+1);
-  dasm_put(Dst, 6247, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf));
-  dasm_put(Dst, 6310, 1+1, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz));
-  dasm_put(Dst, 6381, sizeof(GCstr), DISPATCH_GL(tmpbuf.buf), 1+1);
-  dasm_put(Dst, 6466, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf));
-  dasm_put(Dst, 6536, 1+1, LJ_TTAB);
+  dasm_put(Dst, 6191, Dt5(->len), DISPATCH_GL(tmpbuf.sz), Dt5([1]), DISPATCH_GL(tmpbuf.buf), DISPATCH_GL(tmpbuf.buf), 1+1);
+  dasm_put(Dst, 6256, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf));
+  dasm_put(Dst, 6319, 1+1, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz));
+  dasm_put(Dst, 6390, sizeof(GCstr), DISPATCH_GL(tmpbuf.buf), 1+1);
+  dasm_put(Dst, 6475, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), LJ_TSTR, Dt5(->len), DISPATCH_GL(tmpbuf.sz), sizeof(GCstr), DISPATCH_GL(tmpbuf.buf));
+  dasm_put(Dst, 6545, 1+1, LJ_TTAB);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 6604);
+    dasm_put(Dst, 6613);
   } else if (sse) {
-    dasm_put(Dst, 6611);
+    dasm_put(Dst, 6620);
   } else {
-    dasm_put(Dst, 6621);
+    dasm_put(Dst, 6630);
   }
-  dasm_put(Dst, 6632, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 6641, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6648);
+  dasm_put(Dst, 6657);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6665);
+  dasm_put(Dst, 6674);
   } else {
-  dasm_put(Dst, 6694);
+  dasm_put(Dst, 6703);
   }
   dasm_put(Dst, 111);
   if (LJ_DUALNUM || sse) {
     if (!sse) {
-      dasm_put(Dst, 6712);
+      dasm_put(Dst, 6721);
     }
-    dasm_put(Dst, 6716);
+    dasm_put(Dst, 6725);
   } else {
-    dasm_put(Dst, 6624);
+    dasm_put(Dst, 6633);
   }
-  dasm_put(Dst, 6721, 1+1);
+  dasm_put(Dst, 6730, 1+1);
   if (sse) {
-  dasm_put(Dst, 6732);
+  dasm_put(Dst, 6741);
   } else {
-  dasm_put(Dst, 6747);
+  dasm_put(Dst, 6756);
   }
-  dasm_put(Dst, 2241, LJ_TISNUM);
+  dasm_put(Dst, 2250, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6756);
+  dasm_put(Dst, 6765);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6773);
+  dasm_put(Dst, 6782);
   } else {
-  dasm_put(Dst, 6788);
+  dasm_put(Dst, 6797);
   }
-  dasm_put(Dst, 6801, LJ_TISNUM);
+  dasm_put(Dst, 6810, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6826);
+  dasm_put(Dst, 6835);
   } else {
-  dasm_put(Dst, 6846);
+  dasm_put(Dst, 6855);
   }
   if (sse) {
-  dasm_put(Dst, 6851);
+  dasm_put(Dst, 6860);
   } else {
-  dasm_put(Dst, 6868);
+  dasm_put(Dst, 6877);
   }
-  dasm_put(Dst, 6881, 1+1);
+  dasm_put(Dst, 6890, 1+1);
   if (sse) {
-  dasm_put(Dst, 6732);
+  dasm_put(Dst, 6741);
   } else {
-  dasm_put(Dst, 6747);
+  dasm_put(Dst, 6756);
   }
-  dasm_put(Dst, 2241, LJ_TISNUM);
+  dasm_put(Dst, 2250, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6756);
+  dasm_put(Dst, 6765);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6773);
+  dasm_put(Dst, 6782);
   } else {
-  dasm_put(Dst, 6788);
+  dasm_put(Dst, 6797);
   }
-  dasm_put(Dst, 6801, LJ_TISNUM);
+  dasm_put(Dst, 6810, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6899);
+  dasm_put(Dst, 6908);
   } else {
-  dasm_put(Dst, 6846);
+  dasm_put(Dst, 6855);
   }
   if (sse) {
-  dasm_put(Dst, 6919);
+  dasm_put(Dst, 6928);
   } else {
-  dasm_put(Dst, 6936);
+  dasm_put(Dst, 6945);
   }
-  dasm_put(Dst, 6949, 1+1);
+  dasm_put(Dst, 6958, 1+1);
   if (sse) {
-  dasm_put(Dst, 6732);
+  dasm_put(Dst, 6741);
   } else {
-  dasm_put(Dst, 6747);
+  dasm_put(Dst, 6756);
   }
-  dasm_put(Dst, 2241, LJ_TISNUM);
+  dasm_put(Dst, 2250, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6756);
+  dasm_put(Dst, 6765);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6773);
+  dasm_put(Dst, 6782);
   } else {
-  dasm_put(Dst, 6788);
+  dasm_put(Dst, 6797);
   }
-  dasm_put(Dst, 6801, LJ_TISNUM);
+  dasm_put(Dst, 6810, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6967);
+  dasm_put(Dst, 6976);
   } else {
-  dasm_put(Dst, 6846);
+  dasm_put(Dst, 6855);
   }
   if (sse) {
-  dasm_put(Dst, 6987);
+  dasm_put(Dst, 6996);
   } else {
-  dasm_put(Dst, 7004);
+  dasm_put(Dst, 7013);
   }
-  dasm_put(Dst, 7017, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 7026, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6756);
+  dasm_put(Dst, 6765);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6665);
+  dasm_put(Dst, 6674);
   } else {
-  dasm_put(Dst, 7040);
+  dasm_put(Dst, 7049);
   }
-  dasm_put(Dst, 7061, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 7070, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6756);
+  dasm_put(Dst, 6765);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6665);
+  dasm_put(Dst, 6674);
   } else {
-  dasm_put(Dst, 7040);
+  dasm_put(Dst, 7049);
   }
-  dasm_put(Dst, 7085);
+  dasm_put(Dst, 7094);
   if (LJ_DUALNUM) {
-    dasm_put(Dst, 6716);
+    dasm_put(Dst, 6725);
   } else if (sse) {
-    dasm_put(Dst, 7091);
+    dasm_put(Dst, 7100);
   } else {
-    dasm_put(Dst, 7103);
+    dasm_put(Dst, 7112);
   }
-  dasm_put(Dst, 7116);
+  dasm_put(Dst, 7125);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 7127, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 7136, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6756);
+  dasm_put(Dst, 6765);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6665);
+  dasm_put(Dst, 6674);
   } else {
-  dasm_put(Dst, 7040);
+  dasm_put(Dst, 7049);
   }
-  dasm_put(Dst, 7143, LJ_TISNUM);
+  dasm_put(Dst, 7152, LJ_TISNUM);
   } else if (sse) {
-  dasm_put(Dst, 7158, 2+1, LJ_TISNUM, LJ_TISNUM);
+  dasm_put(Dst, 7167, 2+1, LJ_TISNUM, LJ_TISNUM);
   } else {
-  dasm_put(Dst, 7230, 2+1, LJ_TISNUM, LJ_TISNUM);
+  dasm_put(Dst, 7239, 2+1, LJ_TISNUM, LJ_TISNUM);
   }
-  dasm_put(Dst, 7294);
+  dasm_put(Dst, 7303);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 7301, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 7310, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6756);
+  dasm_put(Dst, 6765);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6665);
+  dasm_put(Dst, 6674);
   } else {
-  dasm_put(Dst, 7040);
+  dasm_put(Dst, 7049);
   }
-  dasm_put(Dst, 7143, LJ_TISNUM);
+  dasm_put(Dst, 7152, LJ_TISNUM);
   } else if (sse) {
-  dasm_put(Dst, 7317, 2+1, LJ_TISNUM, LJ_TISNUM);
+  dasm_put(Dst, 7326, 2+1, LJ_TISNUM, LJ_TISNUM);
   } else {
-  dasm_put(Dst, 7389, 2+1, LJ_TISNUM, LJ_TISNUM);
+  dasm_put(Dst, 7398, 2+1, LJ_TISNUM, LJ_TISNUM);
   }
-  dasm_put(Dst, 7453);
+  dasm_put(Dst, 7462);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 7461, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 7470, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6756);
+  dasm_put(Dst, 6765);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6665);
+  dasm_put(Dst, 6674);
   } else {
-  dasm_put(Dst, 7040);
+  dasm_put(Dst, 7049);
   }
-  dasm_put(Dst, 7143, LJ_TISNUM);
+  dasm_put(Dst, 7152, LJ_TISNUM);
   } else if (sse) {
-  dasm_put(Dst, 7477, 2+1, LJ_TISNUM, LJ_TISNUM);
+  dasm_put(Dst, 7486, 2+1, LJ_TISNUM, LJ_TISNUM);
   } else {
-  dasm_put(Dst, 7549, 2+1, LJ_TISNUM, LJ_TISNUM);
+  dasm_put(Dst, 7558, 2+1, LJ_TISNUM, LJ_TISNUM);
   }
-  dasm_put(Dst, 7613);
+  dasm_put(Dst, 7622);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 7621, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 7630, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6756);
+  dasm_put(Dst, 6765);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6665);
+  dasm_put(Dst, 6674);
   } else {
-  dasm_put(Dst, 7040);
+  dasm_put(Dst, 7049);
   }
-  dasm_put(Dst, 7143, LJ_TISNUM);
+  dasm_put(Dst, 7152, LJ_TISNUM);
   } else if (sse) {
-  dasm_put(Dst, 7637, 2+1, LJ_TISNUM, LJ_TISNUM);
+  dasm_put(Dst, 7646, 2+1, LJ_TISNUM, LJ_TISNUM);
   } else {
-  dasm_put(Dst, 7709, 2+1, LJ_TISNUM, LJ_TISNUM);
+  dasm_put(Dst, 7718, 2+1, LJ_TISNUM, LJ_TISNUM);
   }
-  dasm_put(Dst, 7773);
+  dasm_put(Dst, 7782);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 7780, 1+1, LJ_TISNUM);
+  dasm_put(Dst, 7789, 1+1, LJ_TISNUM);
   if (LJ_DUALNUM) {
-  dasm_put(Dst, 6756);
+  dasm_put(Dst, 6765);
   } else {
-  dasm_put(Dst, 2264);
+  dasm_put(Dst, 2273);
   }
   if (sse) {
-  dasm_put(Dst, 6665);
+  dasm_put(Dst, 6674);
   } else {
-  dasm_put(Dst, 7040);
+  dasm_put(Dst, 7049);
   }
-  dasm_put(Dst, 7143, LJ_TISNUM);
+  dasm_put(Dst, 7152, LJ_TISNUM);
   } else if (sse) {
-  dasm_put(Dst, 7796, 2+1, LJ_TISNUM, LJ_TISNUM);
+  dasm_put(Dst, 7805, 2+1, LJ_TISNUM, LJ_TISNUM);
   } else {
-  dasm_put(Dst, 7868, 2+1, LJ_TISNUM, LJ_TISNUM);
+  dasm_put(Dst, 7877, 2+1, LJ_TISNUM, LJ_TISNUM);
   }
-  dasm_put(Dst, 7932, 1+2, 1+1, Dt1(->base), 8*LUA_MINSTACK, Dt1(->top), Dt1(->maxstack), Dt8(->f), Dt1(->base));
-  dasm_put(Dst, 8008, Dt1(->top), Dt7(->pc), FRAME_TYPE, LUA_MINSTACK, Dt1(->base), Dt1(->base));
-  dasm_put(Dst, 8132, Dt1(->top), Dt1(->base), Dt1(->top));
+  dasm_put(Dst, 7941, 1+2, 1+1, Dt1(->base), 8*LUA_MINSTACK, Dt1(->top), Dt1(->maxstack), Dt8(->f), Dt1(->base));
+  dasm_put(Dst, 8017, Dt1(->top), Dt7(->pc), FRAME_TYPE, LUA_MINSTACK, Dt1(->base), Dt1(->base));
+  dasm_put(Dst, 8141, Dt1(->top), Dt1(->base), Dt1(->top));
 #if LJ_HASJIT
-  dasm_put(Dst, 8170, DISPATCH_GL(hookmask), HOOK_VMEVENT, HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount));
+  dasm_put(Dst, 8179, DISPATCH_GL(hookmask), HOOK_VMEVENT, HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount));
 #endif
-  dasm_put(Dst, 8201, DISPATCH_GL(hookmask), HOOK_ACTIVE, DISPATCH_GL(hookmask), HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount), LUA_MASKLINE);
-  dasm_put(Dst, 8252, Dt1(->base), Dt1(->base), GG_DISP2STATIC);
+  dasm_put(Dst, 8210, DISPATCH_GL(hookmask), HOOK_ACTIVE, DISPATCH_GL(hookmask), HOOK_ACTIVE, LUA_MASKLINE|LUA_MASKCOUNT, DISPATCH_GL(hookcount), LUA_MASKLINE);
+  dasm_put(Dst, 8261, Dt1(->base), Dt1(->base), GG_DISP2STATIC);
 #if LJ_HASJIT
-  dasm_put(Dst, 8318, Dt7(->pc), PC2PROTO(framesize), Dt1(->base), Dt1(->top), GG_DISP2J, DISPATCH_J(L));
+  dasm_put(Dst, 8327, Dt7(->pc), PC2PROTO(framesize), Dt1(->base), Dt1(->top), GG_DISP2J, DISPATCH_J(L));
 #endif
-  dasm_put(Dst, 8364);
+  dasm_put(Dst, 8373);
 #if LJ_HASJIT
-  dasm_put(Dst, 8196);
+  dasm_put(Dst, 8205);
 #endif
-  dasm_put(Dst, 8371);
+  dasm_put(Dst, 8380);
 #if LJ_HASJIT
-  dasm_put(Dst, 8374);
+  dasm_put(Dst, 8383);
 #endif
-  dasm_put(Dst, 8384, Dt1(->base), Dt1(->top));
+  dasm_put(Dst, 8393, Dt1(->base), Dt1(->top));
 #if LJ_HASJIT
-  dasm_put(Dst, 8418);
+  dasm_put(Dst, 8427);
 #endif
-  dasm_put(Dst, 8423, Dt1(->base), Dt1(->top));
+  dasm_put(Dst, 8432, Dt1(->base), Dt1(->top));
 #if LJ_HASJIT
-  dasm_put(Dst, 8452, DISPATCH_GL(vmstate), DISPATCH_GL(vmstate), ~LJ_VMST_EXIT, DISPATCH_J(exitno), DISPATCH_J(parent), 8*8+16, DISPATCH_GL(jit_L), DISPATCH_GL(jit_base), DISPATCH_J(L), DISPATCH_GL(jit_L), Dt1(->base), GG_DISP2J, Dt1(->cframe), CFRAME_RAWMASK, CFRAME_OFS_L, Dt1(->base), CFRAME_OFS_PC);
+  dasm_put(Dst, 8461, DISPATCH_GL(vmstate), DISPATCH_GL(vmstate), ~LJ_VMST_EXIT, DISPATCH_J(exitno), DISPATCH_J(parent), 8*8+16, DISPATCH_GL(jit_L), DISPATCH_GL(jit_base), DISPATCH_J(L), DISPATCH_GL(jit_L), Dt1(->base), GG_DISP2J, Dt1(->cframe), CFRAME_RAWMASK, CFRAME_OFS_L, Dt1(->base), CFRAME_OFS_PC);
 #endif
-  dasm_put(Dst, 8595);
+  dasm_put(Dst, 8604);
 #if LJ_HASJIT
-  dasm_put(Dst, 8598, Dt7(->pc), PC2PROTO(k), DISPATCH_GL(jit_L), DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, BC_FUNCF);
+  dasm_put(Dst, 8607, Dt7(->pc), PC2PROTO(k), DISPATCH_GL(jit_L), DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, BC_FUNCF);
 #endif
-  dasm_put(Dst, 8676);
+  dasm_put(Dst, 8685);
   if (!sse) {
-  dasm_put(Dst, 8679);
+  dasm_put(Dst, 8688);
   }
-  dasm_put(Dst, 8724);
+  dasm_put(Dst, 8733);
   if (!sse) {
-  dasm_put(Dst, 8826);
+  dasm_put(Dst, 8835);
   }
-  dasm_put(Dst, 8871);
+  dasm_put(Dst, 8880);
   if (!sse) {
-  dasm_put(Dst, 8973);
+  dasm_put(Dst, 8982);
   }
-  dasm_put(Dst, 9012);
+  dasm_put(Dst, 9021);
   if (sse) {
-    dasm_put(Dst, 9117);
+    dasm_put(Dst, 9126);
   } else {
-    dasm_put(Dst, 9247);
+    dasm_put(Dst, 9256);
   }
-  dasm_put(Dst, 9294);
+  dasm_put(Dst, 9303);
   if (!sse) {
-  dasm_put(Dst, 9368);
+  dasm_put(Dst, 9377);
   if (cmov) {
-  dasm_put(Dst, 9379);
+  dasm_put(Dst, 9388);
   } else {
-  dasm_put(Dst, 9383);
+  dasm_put(Dst, 9392);
   }
-  dasm_put(Dst, 9390);
-  dasm_put(Dst, 9464);
-  dasm_put(Dst, 9564);
+  dasm_put(Dst, 9399);
+  dasm_put(Dst, 9473);
+  dasm_put(Dst, 9573);
   if (cmov) {
-  dasm_put(Dst, 9567);
+  dasm_put(Dst, 9576);
   } else {
-  dasm_put(Dst, 9571);
+  dasm_put(Dst, 9580);
   }
-  dasm_put(Dst, 9578);
+  dasm_put(Dst, 9587);
   if (cmov) {
-  dasm_put(Dst, 9379);
+  dasm_put(Dst, 9388);
   } else {
-  dasm_put(Dst, 9383);
+  dasm_put(Dst, 9392);
   }
-  dasm_put(Dst, 9596);
+  dasm_put(Dst, 9605);
   } else {
-    dasm_put(Dst, 9675);
+    dasm_put(Dst, 9684);
   }
-  dasm_put(Dst, 9678);
-  dasm_put(Dst, 9763);
-  dasm_put(Dst, 9893);
-  dasm_put(Dst, 10099);
+  dasm_put(Dst, 9687);
+  dasm_put(Dst, 9772);
+  dasm_put(Dst, 9902);
+  dasm_put(Dst, 10108);
 #if LJ_HASJIT
   if (sse) {
-    dasm_put(Dst, 10106);
-    dasm_put(Dst, 10163);
-    dasm_put(Dst, 10254);
+    dasm_put(Dst, 10115);
+    dasm_put(Dst, 10172);
+    dasm_put(Dst, 10263);
   } else {
-    dasm_put(Dst, 10296);
-    dasm_put(Dst, 10388);
+    dasm_put(Dst, 10305);
+    dasm_put(Dst, 10397);
   }
-  dasm_put(Dst, 10434);
+  dasm_put(Dst, 10443);
 #endif
-  dasm_put(Dst, 10438);
+  dasm_put(Dst, 10447);
   if (sse) {
-    dasm_put(Dst, 10441);
-    dasm_put(Dst, 10546);
-    dasm_put(Dst, 10629);
+    dasm_put(Dst, 10450);
+    dasm_put(Dst, 10555);
+    dasm_put(Dst, 10638);
   } else {
-    dasm_put(Dst, 10701);
-    dasm_put(Dst, 10784);
+    dasm_put(Dst, 10710);
+    dasm_put(Dst, 10793);
     if (cmov) {
-    dasm_put(Dst, 10839);
+    dasm_put(Dst, 10848);
     } else {
-    dasm_put(Dst, 10858);
+    dasm_put(Dst, 10867);
     }
-    dasm_put(Dst, 10434);
+    dasm_put(Dst, 10443);
   }
-  dasm_put(Dst, 10899);
+  dasm_put(Dst, 10908);
+#ifdef LUA_USE_ASSERT
+  dasm_put(Dst, 10445);
+#endif
+  dasm_put(Dst, 10964);
 #if LJ_HASFFI
-#define DtE(_V) (int)(ptrdiff_t)&(((CCallState *)0)_V)
-  dasm_put(Dst, 10955, DtE(->spadj));
-#if LJ_TARGET_WINDOWS
-  dasm_put(Dst, 10965, DtE(->spadj));
+#define DtE(_V) (int)(ptrdiff_t)&(((CTState *)0)_V)
+  dasm_put(Dst, 10968, GG_G2DISP, Dt2(->ctype_state), DtE(->cb.slot), CFRAME_SIZE+16, DtE(->cb.gpr[0]), DtE(->cb.gpr[1]), DtE(->cb.stack), CFRAME_SIZE+12, CFRAME_SIZE+8, DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base), Dt1(->top), Dt7(->pc));
+#endif
+  dasm_put(Dst, 11078);
+#if LJ_HASFFI
+  dasm_put(Dst, 11081, DISPATCH_GL(ctype_state), DtE(->L), Dt1(->base), Dt1(->top), DtE(->cb.gpr[0]), DtE(->cb.gpr[1]), DtE(->cb.gpr[2]), DtE(->cb.fpr[0].d), DtE(->cb.fpr[0].f), Dt1(->top));
 #endif
-  dasm_put(Dst, 10969, DtE(->nsp), offsetof(CCallState, stack), DtE(->gpr[0]), DtE(->gpr[1]), DtE(->func), DtE(->gpr[0]), DtE(->gpr[1]), DtE(->resx87), DtE(->fpr[0].d[0]));
-  dasm_put(Dst, 11039, DtE(->fpr[0].f[0]));
+  dasm_put(Dst, 11170);
+#if LJ_HASFFI
+#define DtF(_V) (int)(ptrdiff_t)&(((CCallState *)0)_V)
+  dasm_put(Dst, 11173, DtF(->spadj));
 #if LJ_TARGET_WINDOWS
-  dasm_put(Dst, 11045, DtE(->spadj));
+  dasm_put(Dst, 11183, DtF(->spadj));
 #endif
-  dasm_put(Dst, 11049);
+  dasm_put(Dst, 11187, DtF(->nsp), offsetof(CCallState, stack), DtF(->gpr[0]), DtF(->gpr[1]), DtF(->func), DtF(->gpr[0]), DtF(->gpr[1]), DtF(->resx87), DtF(->fpr[0].d[0]));
+  dasm_put(Dst, 11257, DtF(->fpr[0].f[0]));
+#if LJ_TARGET_WINDOWS
+  dasm_put(Dst, 11263, DtF(->spadj));
 #endif
-  dasm_put(Dst, 11056);
-#ifdef LUA_USE_ASSERT
-  dasm_put(Dst, 10436);
+  dasm_put(Dst, 11267);
 #endif
-  dasm_put(Dst, 10436);
 }
 
 /* Generate the code for a single instruction. */
 static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
 {
   int vk = 0;
-  dasm_put(Dst, 11059, defop);
+  dasm_put(Dst, 11274, defop);
 
   switch (op) {
 
@@ -2007,303 +2041,303 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
 
   case BC_ISLT: case BC_ISGE: case BC_ISLE: case BC_ISGT:
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 11061, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 11276, LJ_TISNUM, LJ_TISNUM);
       switch (op) {
       case BC_ISLT:
-      dasm_put(Dst, 11091);
+      dasm_put(Dst, 11306);
       break;
       case BC_ISGE:
-      dasm_put(Dst, 11096);
+      dasm_put(Dst, 11311);
       break;
       case BC_ISLE:
-      dasm_put(Dst, 11101);
+      dasm_put(Dst, 11316);
       break;
       case BC_ISGT:
-      dasm_put(Dst, 11106);
+      dasm_put(Dst, 11321);
       break;
       default: break;  /* Shut up GCC. */
       }
-      dasm_put(Dst, 11111, -BCBIAS_J*4, LJ_TISNUM);
+      dasm_put(Dst, 11326, -BCBIAS_J*4, LJ_TISNUM);
       if (sse) {
-	dasm_put(Dst, 11164);
+	dasm_put(Dst, 11379);
       } else {
-	dasm_put(Dst, 11175);
+	dasm_put(Dst, 11390);
       }
-      dasm_put(Dst, 11186);
+      dasm_put(Dst, 11401);
       if (sse) {
-	dasm_put(Dst, 11193);
+	dasm_put(Dst, 11408);
 	switch (op) {
 	case BC_ISLT:
-	dasm_put(Dst, 11213);
+	dasm_put(Dst, 11428);
 	break;
 	case BC_ISGE:
-	dasm_put(Dst, 11218);
+	dasm_put(Dst, 11433);
 	break;
 	case BC_ISLE:
-	dasm_put(Dst, 11223);
+	dasm_put(Dst, 11438);
 	break;
 	case BC_ISGT:
-	dasm_put(Dst, 11228);
+	dasm_put(Dst, 11443);
 	break;
 	default: break;  /* Shut up GCC. */
 	}
-	dasm_put(Dst, 11233);
+	dasm_put(Dst, 11448);
       } else {
-	dasm_put(Dst, 11238);
+	dasm_put(Dst, 11453);
       }
     } else {
-      dasm_put(Dst, 11246, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 11461, LJ_TISNUM, LJ_TISNUM);
     }
     if (sse) {
-      dasm_put(Dst, 11267);
+      dasm_put(Dst, 11482);
     } else {
-      dasm_put(Dst, 11288);
+      dasm_put(Dst, 11503);
       if (cmov) {
-      dasm_put(Dst, 3944);
+      dasm_put(Dst, 3953);
       } else {
-      dasm_put(Dst, 3950);
+      dasm_put(Dst, 3959);
       }
     }
     if (LJ_DUALNUM) {
       switch (op) {
       case BC_ISLT:
-      dasm_put(Dst, 11213);
+      dasm_put(Dst, 11428);
       break;
       case BC_ISGE:
-      dasm_put(Dst, 11218);
+      dasm_put(Dst, 11433);
       break;
       case BC_ISLE:
-      dasm_put(Dst, 11223);
+      dasm_put(Dst, 11438);
       break;
       case BC_ISGT:
-      dasm_put(Dst, 11228);
+      dasm_put(Dst, 11443);
       break;
       default: break;  /* Shut up GCC. */
       }
-      dasm_put(Dst, 11233);
+      dasm_put(Dst, 11448);
     } else {
       switch (op) {
       case BC_ISLT:
-      dasm_put(Dst, 11304);
+      dasm_put(Dst, 752);
       break;
       case BC_ISGE:
-      dasm_put(Dst, 11309);
+      dasm_put(Dst, 11519);
       break;
       case BC_ISLE:
-      dasm_put(Dst, 11314);
+      dasm_put(Dst, 11524);
       break;
       case BC_ISGT:
-      dasm_put(Dst, 11319);
+      dasm_put(Dst, 11529);
       break;
       default: break;  /* Shut up GCC. */
       }
-      dasm_put(Dst, 11324, -BCBIAS_J*4);
+      dasm_put(Dst, 11534, -BCBIAS_J*4);
     }
     break;
 
   case BC_ISEQV: case BC_ISNEV:
     vk = op == BC_ISEQV;
-    dasm_put(Dst, 11355);
+    dasm_put(Dst, 11565);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 11363, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 11573, LJ_TISNUM, LJ_TISNUM);
       if (vk) {
-	dasm_put(Dst, 11388);
+	dasm_put(Dst, 11598);
       } else {
-	dasm_put(Dst, 11393);
+	dasm_put(Dst, 11603);
       }
-      dasm_put(Dst, 11398, -BCBIAS_J*4, LJ_TISNUM);
+      dasm_put(Dst, 11608, -BCBIAS_J*4, LJ_TISNUM);
       if (sse) {
-	dasm_put(Dst, 11449);
+	dasm_put(Dst, 11659);
       } else {
-	dasm_put(Dst, 11456);
+	dasm_put(Dst, 11666);
       }
-      dasm_put(Dst, 11460);
+      dasm_put(Dst, 11670);
       if (sse) {
-	dasm_put(Dst, 11471);
+	dasm_put(Dst, 11681);
       } else {
-	dasm_put(Dst, 11483);
+	dasm_put(Dst, 11693);
       }
-      dasm_put(Dst, 11490);
+      dasm_put(Dst, 11700);
     } else {
-      dasm_put(Dst, 11495, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 11705, LJ_TISNUM, LJ_TISNUM);
     }
     if (sse) {
-      dasm_put(Dst, 11514);
+      dasm_put(Dst, 11724);
     } else {
-      dasm_put(Dst, 11532);
+      dasm_put(Dst, 11742);
       if (cmov) {
-      dasm_put(Dst, 3944);
+      dasm_put(Dst, 3953);
       } else {
-      dasm_put(Dst, 3950);
+      dasm_put(Dst, 3959);
       }
     }
   iseqne_fp:
     if (vk) {
-      dasm_put(Dst, 11545);
+      dasm_put(Dst, 11755);
     } else {
-      dasm_put(Dst, 11554);
+      dasm_put(Dst, 11764);
     }
   iseqne_end:
     if (vk) {
-      dasm_put(Dst, 11563, -BCBIAS_J*4);
+      dasm_put(Dst, 11773, -BCBIAS_J*4);
       if (!LJ_HASFFI) {
-	dasm_put(Dst, 4844);
+	dasm_put(Dst, 4853);
       }
     } else {
       if (!LJ_HASFFI) {
-	dasm_put(Dst, 4844);
+	dasm_put(Dst, 4853);
       }
-      dasm_put(Dst, 11578, -BCBIAS_J*4);
+      dasm_put(Dst, 11788, -BCBIAS_J*4);
     }
     if (LJ_DUALNUM && (op == BC_ISEQV || op == BC_ISNEV ||
 		       op == BC_ISEQN || op == BC_ISNEN)) {
-      dasm_put(Dst, 11593);
+      dasm_put(Dst, 11803);
     } else {
-      dasm_put(Dst, 11336);
+      dasm_put(Dst, 11546);
     }
     if (op == BC_ISEQV || op == BC_ISNEV) {
-      dasm_put(Dst, 11598);
+      dasm_put(Dst, 11808);
       if (LJ_HASFFI) {
-	dasm_put(Dst, 11601, LJ_TCDATA, LJ_TCDATA);
+	dasm_put(Dst, 11811, LJ_TCDATA, LJ_TCDATA);
       }
-      dasm_put(Dst, 11620, LJ_TISPRI, LJ_TISTABUD, Dt6(->metatable), Dt6(->nomm), 1<<MM_eq);
+      dasm_put(Dst, 11830, LJ_TISPRI, LJ_TISTABUD, Dt6(->metatable), Dt6(->nomm), 1<<MM_eq);
       if (vk) {
-	dasm_put(Dst, 11676);
+	dasm_put(Dst, 11886);
       } else {
-	dasm_put(Dst, 11680);
+	dasm_put(Dst, 11890);
       }
-      dasm_put(Dst, 11686);
+      dasm_put(Dst, 11896);
     } else if (LJ_HASFFI) {
-      dasm_put(Dst, 11691, LJ_TCDATA);
+      dasm_put(Dst, 11901, LJ_TCDATA);
       if (LJ_DUALNUM && vk) {
-	dasm_put(Dst, 11698);
+	dasm_put(Dst, 11908);
       } else {
-	dasm_put(Dst, 11671);
+	dasm_put(Dst, 11881);
       }
-      dasm_put(Dst, 11703);
+      dasm_put(Dst, 11913);
     }
     break;
   case BC_ISEQS: case BC_ISNES:
     vk = op == BC_ISEQS;
-    dasm_put(Dst, 11708, LJ_TSTR);
+    dasm_put(Dst, 11918, LJ_TSTR);
   iseqne_test:
     if (vk) {
-      dasm_put(Dst, 11549);
+      dasm_put(Dst, 11759);
     } else {
-      dasm_put(Dst, 748);
+      dasm_put(Dst, 2971);
     }
     goto iseqne_end;
   case BC_ISEQN: case BC_ISNEN:
     vk = op == BC_ISEQN;
-    dasm_put(Dst, 11733);
+    dasm_put(Dst, 11943);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 11741, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 11951, LJ_TISNUM, LJ_TISNUM);
       if (vk) {
-	dasm_put(Dst, 11388);
+	dasm_put(Dst, 11598);
       } else {
-	dasm_put(Dst, 11393);
+	dasm_put(Dst, 11603);
       }
-      dasm_put(Dst, 11766, -BCBIAS_J*4, LJ_TISNUM);
+      dasm_put(Dst, 11976, -BCBIAS_J*4, LJ_TISNUM);
       if (sse) {
-	dasm_put(Dst, 11813);
+	dasm_put(Dst, 12023);
       } else {
-	dasm_put(Dst, 11820);
+	dasm_put(Dst, 12030);
       }
-      dasm_put(Dst, 11824);
+      dasm_put(Dst, 12034);
       if (sse) {
-	dasm_put(Dst, 11831);
+	dasm_put(Dst, 12041);
       } else {
-	dasm_put(Dst, 11843);
+	dasm_put(Dst, 12053);
       }
-      dasm_put(Dst, 11490);
+      dasm_put(Dst, 11700);
     } else {
-      dasm_put(Dst, 11850, LJ_TISNUM);
+      dasm_put(Dst, 12060, LJ_TISNUM);
     }
     if (sse) {
-      dasm_put(Dst, 11859);
+      dasm_put(Dst, 12069);
     } else {
-      dasm_put(Dst, 11877);
+      dasm_put(Dst, 12087);
       if (cmov) {
-      dasm_put(Dst, 3944);
+      dasm_put(Dst, 3953);
       } else {
-      dasm_put(Dst, 3950);
+      dasm_put(Dst, 3959);
       }
     }
     goto iseqne_fp;
   case BC_ISEQP: case BC_ISNEP:
     vk = op == BC_ISEQP;
-    dasm_put(Dst, 11890);
+    dasm_put(Dst, 12100);
     if (!LJ_HASFFI) goto iseqne_test;
     if (vk) {
-      dasm_put(Dst, 11903, -BCBIAS_J*4, LJ_TCDATA);
+      dasm_put(Dst, 12113, -BCBIAS_J*4, LJ_TCDATA);
     } else {
-      dasm_put(Dst, 11952, LJ_TCDATA, -BCBIAS_J*4);
+      dasm_put(Dst, 12162, LJ_TCDATA, -BCBIAS_J*4);
     }
     break;
 
   /* -- Unary test and copy ops ------------------------------------------- */
 
   case BC_ISTC: case BC_ISFC: case BC_IST: case BC_ISF:
-    dasm_put(Dst, 11995, LJ_TISTRUECOND);
+    dasm_put(Dst, 12205, LJ_TISTRUECOND);
     if (op == BC_IST || op == BC_ISTC) {
-      dasm_put(Dst, 11319);
+      dasm_put(Dst, 11529);
     } else {
-      dasm_put(Dst, 11314);
+      dasm_put(Dst, 11524);
     }
     if (op == BC_ISTC || op == BC_ISFC) {
-      dasm_put(Dst, 12007);
+      dasm_put(Dst, 12217);
     }
-    dasm_put(Dst, 11324, -BCBIAS_J*4);
+    dasm_put(Dst, 11534, -BCBIAS_J*4);
     break;
 
   /* -- Unary ops --------------------------------------------------------- */
 
   case BC_MOV:
-    dasm_put(Dst, 12018);
+    dasm_put(Dst, 12228);
     break;
   case BC_NOT:
-    dasm_put(Dst, 12051, LJ_TISTRUECOND, LJ_TTRUE);
+    dasm_put(Dst, 12261, LJ_TISTRUECOND, LJ_TTRUE);
     break;
   case BC_UNM:
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 12086, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 12296, LJ_TISNUM, LJ_TISNUM);
     } else {
-      dasm_put(Dst, 12162, LJ_TISNUM);
+      dasm_put(Dst, 12372, LJ_TISNUM);
     }
     if (sse) {
-      dasm_put(Dst, 12173);
+      dasm_put(Dst, 12383);
     } else {
-      dasm_put(Dst, 12203);
+      dasm_put(Dst, 12413);
     }
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 11593);
+      dasm_put(Dst, 11803);
     } else {
-      dasm_put(Dst, 11336);
+      dasm_put(Dst, 11546);
     }
     break;
   case BC_LEN:
-    dasm_put(Dst, 12212, LJ_TSTR);
+    dasm_put(Dst, 12422, LJ_TSTR);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 12226, Dt5(->len), LJ_TISNUM);
+      dasm_put(Dst, 12436, Dt5(->len), LJ_TISNUM);
     } else if (sse) {
-      dasm_put(Dst, 12240, Dt5(->len));
+      dasm_put(Dst, 12450, Dt5(->len));
     } else {
-      dasm_put(Dst, 12258, Dt5(->len));
+      dasm_put(Dst, 12468, Dt5(->len));
     }
-    dasm_put(Dst, 12267, LJ_TTAB);
+    dasm_put(Dst, 12477, LJ_TTAB);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-    dasm_put(Dst, 12301, Dt6(->metatable));
+    dasm_put(Dst, 12511, Dt6(->metatable));
 #endif
-    dasm_put(Dst, 12315);
+    dasm_put(Dst, 12525);
     if (LJ_DUALNUM) {
     } else if (sse) {
-      dasm_put(Dst, 12324);
+      dasm_put(Dst, 12534);
     } else {
-      dasm_put(Dst, 12330);
+      dasm_put(Dst, 12540);
     }
-    dasm_put(Dst, 12337);
+    dasm_put(Dst, 12547);
 #ifdef LUAJIT_ENABLE_LUA52COMPAT
-    dasm_put(Dst, 12350, Dt6(->nomm), 1<<MM_len);
+    dasm_put(Dst, 12560, Dt6(->nomm), 1<<MM_len);
 #endif
     break;
 
@@ -2312,620 +2346,620 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
 
   case BC_ADDVN: case BC_ADDNV: case BC_ADDVV:
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 12366);
+    dasm_put(Dst, 12576);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 12374, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 12584, LJ_TISNUM, LJ_TISNUM);
       break;
     case 1:
-    dasm_put(Dst, 12407, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 12617, LJ_TISNUM, LJ_TISNUM);
       break;
     default:
-    dasm_put(Dst, 12440, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 12650, LJ_TISNUM, LJ_TISNUM);
       break;
     }
-    dasm_put(Dst, 12473, LJ_TISNUM);
+    dasm_put(Dst, 12683, LJ_TISNUM);
     if (vk == 1) {
-    dasm_put(Dst, 12236);
+    dasm_put(Dst, 12446);
     } else {
-    dasm_put(Dst, 12014);
+    dasm_put(Dst, 12224);
     }
-    dasm_put(Dst, 11336);
+    dasm_put(Dst, 11546);
     } else {
-    dasm_put(Dst, 12366);
+    dasm_put(Dst, 12576);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 12479, LJ_TISNUM);
+    dasm_put(Dst, 12689, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 12491, LJ_TISNUM);
+    dasm_put(Dst, 12701, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 12502);
+    dasm_put(Dst, 12712);
     } else {
-    dasm_put(Dst, 12516);
+    dasm_put(Dst, 12726);
     }
       break;
     case 1:
-    dasm_put(Dst, 12524, LJ_TISNUM);
+    dasm_put(Dst, 12734, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 12536, LJ_TISNUM);
+    dasm_put(Dst, 12746, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 12547);
+    dasm_put(Dst, 12757);
     } else {
-    dasm_put(Dst, 12561);
+    dasm_put(Dst, 12771);
     }
       break;
     default:
-    dasm_put(Dst, 12569, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 12779, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 12591);
+    dasm_put(Dst, 12801);
     } else {
-    dasm_put(Dst, 12605);
+    dasm_put(Dst, 12815);
     }
       break;
     }
     if (sse) {
-    dasm_put(Dst, 12196);
+    dasm_put(Dst, 12406);
     } else {
-    dasm_put(Dst, 12208);
+    dasm_put(Dst, 12418);
     }
-    dasm_put(Dst, 11336);
+    dasm_put(Dst, 11546);
     }
     break;
   case BC_SUBVN: case BC_SUBNV: case BC_SUBVV:
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 12366);
+    dasm_put(Dst, 12576);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 12613, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 12823, LJ_TISNUM, LJ_TISNUM);
       break;
     case 1:
-    dasm_put(Dst, 12646, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 12856, LJ_TISNUM, LJ_TISNUM);
       break;
     default:
-    dasm_put(Dst, 12679, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 12889, LJ_TISNUM, LJ_TISNUM);
       break;
     }
-    dasm_put(Dst, 12473, LJ_TISNUM);
+    dasm_put(Dst, 12683, LJ_TISNUM);
     if (vk == 1) {
-    dasm_put(Dst, 12236);
+    dasm_put(Dst, 12446);
     } else {
-    dasm_put(Dst, 12014);
+    dasm_put(Dst, 12224);
     }
-    dasm_put(Dst, 11336);
+    dasm_put(Dst, 11546);
     } else {
-    dasm_put(Dst, 12366);
+    dasm_put(Dst, 12576);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 12479, LJ_TISNUM);
+    dasm_put(Dst, 12689, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 12491, LJ_TISNUM);
+    dasm_put(Dst, 12701, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 12712);
+    dasm_put(Dst, 12922);
     } else {
-    dasm_put(Dst, 12726);
+    dasm_put(Dst, 12936);
     }
       break;
     case 1:
-    dasm_put(Dst, 12524, LJ_TISNUM);
+    dasm_put(Dst, 12734, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 12536, LJ_TISNUM);
+    dasm_put(Dst, 12746, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 12734);
+    dasm_put(Dst, 12944);
     } else {
-    dasm_put(Dst, 12748);
+    dasm_put(Dst, 12958);
     }
       break;
     default:
-    dasm_put(Dst, 12569, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 12779, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 12756);
+    dasm_put(Dst, 12966);
     } else {
-    dasm_put(Dst, 12770);
+    dasm_put(Dst, 12980);
     }
       break;
     }
     if (sse) {
-    dasm_put(Dst, 12196);
+    dasm_put(Dst, 12406);
     } else {
-    dasm_put(Dst, 12208);
+    dasm_put(Dst, 12418);
     }
-    dasm_put(Dst, 11336);
+    dasm_put(Dst, 11546);
     }
     break;
   case BC_MULVN: case BC_MULNV: case BC_MULVV:
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 12366);
+    dasm_put(Dst, 12576);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 12778, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 12988, LJ_TISNUM, LJ_TISNUM);
       break;
     case 1:
-    dasm_put(Dst, 12812, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 13022, LJ_TISNUM, LJ_TISNUM);
       break;
     default:
-    dasm_put(Dst, 12846, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 13056, LJ_TISNUM, LJ_TISNUM);
       break;
     }
-    dasm_put(Dst, 12473, LJ_TISNUM);
+    dasm_put(Dst, 12683, LJ_TISNUM);
     if (vk == 1) {
-    dasm_put(Dst, 12236);
+    dasm_put(Dst, 12446);
     } else {
-    dasm_put(Dst, 12014);
+    dasm_put(Dst, 12224);
     }
-    dasm_put(Dst, 11336);
+    dasm_put(Dst, 11546);
     } else {
-    dasm_put(Dst, 12366);
+    dasm_put(Dst, 12576);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 12479, LJ_TISNUM);
+    dasm_put(Dst, 12689, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 12491, LJ_TISNUM);
+    dasm_put(Dst, 12701, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 12880);
+    dasm_put(Dst, 13090);
     } else {
-    dasm_put(Dst, 12894);
+    dasm_put(Dst, 13104);
     }
       break;
     case 1:
-    dasm_put(Dst, 12524, LJ_TISNUM);
+    dasm_put(Dst, 12734, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 12536, LJ_TISNUM);
+    dasm_put(Dst, 12746, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 12902);
+    dasm_put(Dst, 13112);
     } else {
-    dasm_put(Dst, 12916);
+    dasm_put(Dst, 13126);
     }
       break;
     default:
-    dasm_put(Dst, 12569, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 12779, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 12924);
+    dasm_put(Dst, 13134);
     } else {
-    dasm_put(Dst, 12938);
+    dasm_put(Dst, 13148);
     }
       break;
     }
     if (sse) {
-    dasm_put(Dst, 12196);
+    dasm_put(Dst, 12406);
     } else {
-    dasm_put(Dst, 12208);
+    dasm_put(Dst, 12418);
     }
-    dasm_put(Dst, 11336);
+    dasm_put(Dst, 11546);
     }
     break;
   case BC_DIVVN: case BC_DIVNV: case BC_DIVVV:
-    dasm_put(Dst, 12366);
+    dasm_put(Dst, 12576);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 12479, LJ_TISNUM);
+    dasm_put(Dst, 12689, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 12491, LJ_TISNUM);
+    dasm_put(Dst, 12701, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 12946);
+    dasm_put(Dst, 13156);
     } else {
-    dasm_put(Dst, 12960);
+    dasm_put(Dst, 13170);
     }
       break;
     case 1:
-    dasm_put(Dst, 12524, LJ_TISNUM);
+    dasm_put(Dst, 12734, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 12536, LJ_TISNUM);
+    dasm_put(Dst, 12746, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 12968);
+    dasm_put(Dst, 13178);
     } else {
-    dasm_put(Dst, 12982);
+    dasm_put(Dst, 13192);
     }
       break;
     default:
-    dasm_put(Dst, 12569, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 12779, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 12990);
+    dasm_put(Dst, 13200);
     } else {
-    dasm_put(Dst, 13004);
+    dasm_put(Dst, 13214);
     }
       break;
     }
     if (sse) {
-    dasm_put(Dst, 12196);
+    dasm_put(Dst, 12406);
     } else {
-    dasm_put(Dst, 12208);
+    dasm_put(Dst, 12418);
     }
-    dasm_put(Dst, 11336);
+    dasm_put(Dst, 11546);
     break;
   case BC_MODVN:
-    dasm_put(Dst, 12366);
+    dasm_put(Dst, 12576);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 12479, LJ_TISNUM);
+    dasm_put(Dst, 12689, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 12491, LJ_TISNUM);
+    dasm_put(Dst, 12701, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 13012);
+    dasm_put(Dst, 13222);
     } else {
-    dasm_put(Dst, 13026);
+    dasm_put(Dst, 13236);
     }
       break;
     case 1:
-    dasm_put(Dst, 12524, LJ_TISNUM);
+    dasm_put(Dst, 12734, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 12536, LJ_TISNUM);
+    dasm_put(Dst, 12746, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 13034);
+    dasm_put(Dst, 13244);
     } else {
-    dasm_put(Dst, 13048);
+    dasm_put(Dst, 13258);
     }
       break;
     default:
-    dasm_put(Dst, 12569, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 12779, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 13056);
+    dasm_put(Dst, 13266);
     } else {
-    dasm_put(Dst, 13070);
+    dasm_put(Dst, 13280);
     }
       break;
     }
-    dasm_put(Dst, 13078);
+    dasm_put(Dst, 13288);
     if (sse) {
-    dasm_put(Dst, 12196);
+    dasm_put(Dst, 12406);
     } else {
-    dasm_put(Dst, 12208);
+    dasm_put(Dst, 12418);
     }
-    dasm_put(Dst, 11336);
+    dasm_put(Dst, 11546);
     break;
   case BC_MODNV: case BC_MODVV:
-    dasm_put(Dst, 12366);
+    dasm_put(Dst, 12576);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 12479, LJ_TISNUM);
+    dasm_put(Dst, 12689, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 12491, LJ_TISNUM);
+    dasm_put(Dst, 12701, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 13012);
+    dasm_put(Dst, 13222);
     } else {
-    dasm_put(Dst, 13026);
+    dasm_put(Dst, 13236);
     }
       break;
     case 1:
-    dasm_put(Dst, 12524, LJ_TISNUM);
+    dasm_put(Dst, 12734, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 12536, LJ_TISNUM);
+    dasm_put(Dst, 12746, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 13034);
+    dasm_put(Dst, 13244);
     } else {
-    dasm_put(Dst, 13048);
+    dasm_put(Dst, 13258);
     }
       break;
     default:
-    dasm_put(Dst, 12569, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 12779, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 13056);
+    dasm_put(Dst, 13266);
     } else {
-    dasm_put(Dst, 13070);
+    dasm_put(Dst, 13280);
     }
       break;
     }
-    dasm_put(Dst, 13084);
+    dasm_put(Dst, 13294);
     break;
   case BC_POW:
-    dasm_put(Dst, 12366);
+    dasm_put(Dst, 12576);
     vk = ((int)op - BC_ADDVN) / (BC_ADDNV-BC_ADDVN);
     switch (vk) {
     case 0:
-    dasm_put(Dst, 12479, LJ_TISNUM);
+    dasm_put(Dst, 12689, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 12491, LJ_TISNUM);
+    dasm_put(Dst, 12701, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 13012);
+    dasm_put(Dst, 13222);
     } else {
-    dasm_put(Dst, 13026);
+    dasm_put(Dst, 13236);
     }
       break;
     case 1:
-    dasm_put(Dst, 12524, LJ_TISNUM);
+    dasm_put(Dst, 12734, LJ_TISNUM);
     if (LJ_DUALNUM) {
-    dasm_put(Dst, 12536, LJ_TISNUM);
+    dasm_put(Dst, 12746, LJ_TISNUM);
     }
     if (sse) {
-    dasm_put(Dst, 13034);
+    dasm_put(Dst, 13244);
     } else {
-    dasm_put(Dst, 13048);
+    dasm_put(Dst, 13258);
     }
       break;
     default:
-    dasm_put(Dst, 12569, LJ_TISNUM, LJ_TISNUM);
+    dasm_put(Dst, 12779, LJ_TISNUM, LJ_TISNUM);
     if (sse) {
-    dasm_put(Dst, 13056);
+    dasm_put(Dst, 13266);
     } else {
-    dasm_put(Dst, 13070);
+    dasm_put(Dst, 13280);
     }
       break;
     }
-    dasm_put(Dst, 13089);
+    dasm_put(Dst, 13299);
     if (sse) {
-    dasm_put(Dst, 12196);
+    dasm_put(Dst, 12406);
     } else {
-    dasm_put(Dst, 12208);
+    dasm_put(Dst, 12418);
     }
-    dasm_put(Dst, 11336);
+    dasm_put(Dst, 11546);
     break;
 
   case BC_CAT:
-    dasm_put(Dst, 13093, Dt1(->base), Dt1(->base));
+    dasm_put(Dst, 13303, Dt1(->base), Dt1(->base));
     break;
 
   /* -- Constant ops ------------------------------------------------------ */
 
   case BC_KSTR:
-    dasm_put(Dst, 13187, LJ_TSTR);
+    dasm_put(Dst, 13397, LJ_TSTR);
     break;
   case BC_KCDATA:
 #if LJ_HASFFI
-    dasm_put(Dst, 13187, LJ_TCDATA);
+    dasm_put(Dst, 13397, LJ_TCDATA);
 #endif
     break;
   case BC_KSHORT:
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 13220, LJ_TISNUM);
+      dasm_put(Dst, 13430, LJ_TISNUM);
     } else if (sse) {
-      dasm_put(Dst, 13232);
+      dasm_put(Dst, 13442);
     } else {
-      dasm_put(Dst, 13247);
+      dasm_put(Dst, 13457);
     }
-    dasm_put(Dst, 11336);
+    dasm_put(Dst, 11546);
     break;
   case BC_KNUM:
     if (sse) {
-      dasm_put(Dst, 13255);
+      dasm_put(Dst, 13465);
     } else {
-      dasm_put(Dst, 13268);
+      dasm_put(Dst, 13478);
     }
-    dasm_put(Dst, 11336);
+    dasm_put(Dst, 11546);
     break;
   case BC_KPRI:
-    dasm_put(Dst, 13275);
+    dasm_put(Dst, 13485);
     break;
   case BC_KNIL:
-    dasm_put(Dst, 13301, LJ_TNIL);
+    dasm_put(Dst, 13511, LJ_TNIL);
     break;
 
   /* -- Upvalue and function ops ------------------------------------------ */
 
   case BC_UGET:
-    dasm_put(Dst, 13347, offsetof(GCfuncL, uvptr), DtA(->v));
+    dasm_put(Dst, 13557, offsetof(GCfuncL, uvptr), DtA(->v));
     break;
   case BC_USETV:
 #define TV2MARKOFS \
  ((int32_t)offsetof(GCupval, marked)-(int32_t)offsetof(GCupval, tv))
-    dasm_put(Dst, 13391, offsetof(GCfuncL, uvptr), DtA(->closed), DtA(->v), TV2MARKOFS, LJ_GC_BLACK, LJ_TISGCV, LJ_TISNUM - LJ_TISGCV, Dt4(->gch.marked), LJ_GC_WHITES, GG_DISP2G);
-    dasm_put(Dst, 13481);
+    dasm_put(Dst, 13601, offsetof(GCfuncL, uvptr), DtA(->closed), DtA(->v), TV2MARKOFS, LJ_GC_BLACK, LJ_TISGCV, LJ_TISNUM - LJ_TISGCV, Dt4(->gch.marked), LJ_GC_WHITES, GG_DISP2G);
+    dasm_put(Dst, 13691);
     break;
 #undef TV2MARKOFS
   case BC_USETS:
-    dasm_put(Dst, 13493, offsetof(GCfuncL, uvptr), DtA(->v), LJ_TSTR, DtA(->marked), LJ_GC_BLACK, Dt4(->gch.marked), LJ_GC_WHITES, DtA(->closed), GG_DISP2G);
+    dasm_put(Dst, 13703, offsetof(GCfuncL, uvptr), DtA(->v), LJ_TSTR, DtA(->marked), LJ_GC_BLACK, Dt4(->gch.marked), LJ_GC_WHITES, DtA(->closed), GG_DISP2G);
     break;
   case BC_USETN:
-    dasm_put(Dst, 13584);
+    dasm_put(Dst, 13794);
     if (sse) {
-      dasm_put(Dst, 13589);
+      dasm_put(Dst, 13799);
     } else {
-      dasm_put(Dst, 11846);
+      dasm_put(Dst, 12056);
     }
-    dasm_put(Dst, 13596, offsetof(GCfuncL, uvptr), DtA(->v));
+    dasm_put(Dst, 13806, offsetof(GCfuncL, uvptr), DtA(->v));
     if (sse) {
-      dasm_put(Dst, 13605);
+      dasm_put(Dst, 13815);
     } else {
-      dasm_put(Dst, 13611);
+      dasm_put(Dst, 13821);
     }
-    dasm_put(Dst, 11336);
+    dasm_put(Dst, 11546);
     break;
   case BC_USETP:
-    dasm_put(Dst, 13614, offsetof(GCfuncL, uvptr), DtA(->v));
+    dasm_put(Dst, 13824, offsetof(GCfuncL, uvptr), DtA(->v));
     break;
   case BC_UCLO:
-    dasm_put(Dst, 13651, -BCBIAS_J*4, Dt1(->openupval), Dt1(->base), Dt1(->base));
+    dasm_put(Dst, 13861, -BCBIAS_J*4, Dt1(->openupval), Dt1(->base), Dt1(->base));
     break;
 
   case BC_FNEW:
-    dasm_put(Dst, 13705, Dt1(->base), Dt1(->base), LJ_TFUNC);
+    dasm_put(Dst, 13915, Dt1(->base), Dt1(->base), LJ_TFUNC);
     break;
 
   /* -- Table ops --------------------------------------------------------- */
 
   case BC_TNEW:
-    dasm_put(Dst, 13776, Dt1(->base), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), LJ_TTAB);
+    dasm_put(Dst, 13986, Dt1(->base), DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), LJ_TTAB);
     break;
   case BC_TDUP:
-    dasm_put(Dst, 13902, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), Dt1(->base), LJ_TTAB);
+    dasm_put(Dst, 14112, DISPATCH_GL(gc.total), DISPATCH_GL(gc.threshold), Dt1(->base), Dt1(->base), LJ_TTAB);
     break;
 
   case BC_GGET:
-    dasm_put(Dst, 13994, Dt7(->env));
+    dasm_put(Dst, 14204, Dt7(->env));
     break;
   case BC_GSET:
-    dasm_put(Dst, 14012, Dt7(->env));
+    dasm_put(Dst, 14222, Dt7(->env));
     break;
 
   case BC_TGETV:
-    dasm_put(Dst, 14030, LJ_TTAB);
+    dasm_put(Dst, 14240, LJ_TTAB);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 14053, LJ_TISNUM);
+      dasm_put(Dst, 14263, LJ_TISNUM);
     } else {
-      dasm_put(Dst, 14067, LJ_TISNUM);
+      dasm_put(Dst, 14277, LJ_TISNUM);
       if (sse) {
-	dasm_put(Dst, 14078);
+	dasm_put(Dst, 14288);
       } else {
-	dasm_put(Dst, 14099);
+	dasm_put(Dst, 14309);
 	if (cmov) {
-	dasm_put(Dst, 3944);
+	dasm_put(Dst, 3953);
 	} else {
-	dasm_put(Dst, 3950);
+	dasm_put(Dst, 3959);
 	}
-	dasm_put(Dst, 2680);
+	dasm_put(Dst, 2689);
       }
-      dasm_put(Dst, 14109);
+      dasm_put(Dst, 14319);
     }
-    dasm_put(Dst, 14114, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_index, LJ_TNIL);
-    dasm_put(Dst, 14209, LJ_TSTR);
+    dasm_put(Dst, 14324, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_index, LJ_TNIL);
+    dasm_put(Dst, 14419, LJ_TSTR);
     break;
   case BC_TGETS:
-    dasm_put(Dst, 14227, LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), LJ_TNIL);
-    dasm_put(Dst, 14315, LJ_TNIL, DtB(->next), Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
+    dasm_put(Dst, 14437, LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), LJ_TNIL);
+    dasm_put(Dst, 14525, LJ_TNIL, DtB(->next), Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
     break;
   case BC_TGETB:
-    dasm_put(Dst, 14385, LJ_TTAB, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
-    dasm_put(Dst, 14484, LJ_TNIL);
+    dasm_put(Dst, 14595, LJ_TTAB, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_index);
+    dasm_put(Dst, 14694, LJ_TNIL);
     break;
 
   case BC_TSETV:
-    dasm_put(Dst, 14501, LJ_TTAB);
+    dasm_put(Dst, 14711, LJ_TTAB);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 14053, LJ_TISNUM);
+      dasm_put(Dst, 14263, LJ_TISNUM);
     } else {
-      dasm_put(Dst, 14067, LJ_TISNUM);
+      dasm_put(Dst, 14277, LJ_TISNUM);
       if (sse) {
-	dasm_put(Dst, 14078);
+	dasm_put(Dst, 14288);
       } else {
-	dasm_put(Dst, 14099);
+	dasm_put(Dst, 14309);
 	if (cmov) {
-	dasm_put(Dst, 3944);
+	dasm_put(Dst, 3953);
 	} else {
-	dasm_put(Dst, 3950);
+	dasm_put(Dst, 3959);
 	}
-	dasm_put(Dst, 2680);
+	dasm_put(Dst, 2689);
       }
-      dasm_put(Dst, 14524);
+      dasm_put(Dst, 14734);
     }
-    dasm_put(Dst, 14529, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex);
-    dasm_put(Dst, 14613, LJ_TSTR, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
+    dasm_put(Dst, 14739, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex);
+    dasm_put(Dst, 14823, LJ_TSTR, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
     break;
   case BC_TSETS:
-    dasm_put(Dst, 14670, LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->nomm), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), LJ_TNIL);
-    dasm_put(Dst, 14745, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, DtB(->next));
-    dasm_put(Dst, 14837, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, LJ_TSTR, Dt1(->base), Dt1(->base), Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
+    dasm_put(Dst, 14880, LJ_TTAB, Dt6(->hmask), Dt5(->hash), sizeof(Node), Dt6(->nomm), Dt6(->node), DtB(->key.it), LJ_TSTR, DtB(->key.gcr), LJ_TNIL);
+    dasm_put(Dst, 14955, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable), Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, DtB(->next));
+    dasm_put(Dst, 15047, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, LJ_TSTR, Dt1(->base), Dt1(->base), Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
     break;
   case BC_TSETB:
-    dasm_put(Dst, 14933, LJ_TTAB, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable));
-    dasm_put(Dst, 15031, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
+    dasm_put(Dst, 15143, LJ_TTAB, Dt6(->asize), Dt6(->array), LJ_TNIL, Dt6(->marked), LJ_GC_BLACK, Dt6(->metatable));
+    dasm_put(Dst, 15241, Dt6(->metatable), Dt6(->nomm), 1<<MM_newindex, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
     break;
 
   case BC_TSETM:
-    dasm_put(Dst, 15077, Dt6(->marked), LJ_GC_BLACK, Dt6(->asize), Dt6(->array), Dt1(->base), Dt1(->base));
-    dasm_put(Dst, 15226, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
+    dasm_put(Dst, 15287, Dt6(->marked), LJ_GC_BLACK, Dt6(->asize), Dt6(->array), Dt1(->base), Dt1(->base));
+    dasm_put(Dst, 15436, Dt6(->marked), (uint8_t)~LJ_GC_BLACK, DISPATCH_GL(gc.grayagain), DISPATCH_GL(gc.grayagain), Dt6(->gclist));
     break;
 
   /* -- Calls and vararg handling ----------------------------------------- */
 
   case BC_CALL: case BC_CALLM:
-    dasm_put(Dst, 12370);
+    dasm_put(Dst, 12580);
     if (op == BC_CALLM) {
-      dasm_put(Dst, 15244);
+      dasm_put(Dst, 15454);
     }
-    dasm_put(Dst, 15249, LJ_TFUNC, Dt7(->pc));
+    dasm_put(Dst, 15459, LJ_TFUNC, Dt7(->pc));
     break;
 
   case BC_CALLMT:
-    dasm_put(Dst, 15244);
+    dasm_put(Dst, 15454);
     break;
   case BC_CALLT:
-    dasm_put(Dst, 15290, LJ_TFUNC, FRAME_TYPE, Dt7(->ffid), Dt7(->pc));
-    dasm_put(Dst, 15408, FRAME_TYPE, Dt7(->pc), PC2PROTO(k), FRAME_VARG, FRAME_TYPEP, FRAME_VARG);
+    dasm_put(Dst, 15500, LJ_TFUNC, FRAME_TYPE, Dt7(->ffid), Dt7(->pc));
+    dasm_put(Dst, 15618, FRAME_TYPE, Dt7(->pc), PC2PROTO(k), FRAME_VARG, FRAME_TYPEP, FRAME_VARG);
     break;
 
   case BC_ITERC:
-    dasm_put(Dst, 15478, LJ_TFUNC, 2+1, Dt7(->pc));
+    dasm_put(Dst, 15688, LJ_TFUNC, 2+1, Dt7(->pc));
     break;
 
   case BC_ITERN:
 #if LJ_HASJIT
 #endif
-    dasm_put(Dst, 15558, Dt6(->asize), Dt6(->array), LJ_TNIL);
+    dasm_put(Dst, 15768, Dt6(->asize), Dt6(->array), LJ_TNIL);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 12231, LJ_TISNUM);
+      dasm_put(Dst, 12441, LJ_TISNUM);
     } else if (sse) {
-      dasm_put(Dst, 12324);
+      dasm_put(Dst, 12534);
     } else {
-      dasm_put(Dst, 15604);
+      dasm_put(Dst, 15814);
     }
-    dasm_put(Dst, 15610);
+    dasm_put(Dst, 15820);
     if (LJ_DUALNUM) {
     } else if (sse) {
-      dasm_put(Dst, 12196);
+      dasm_put(Dst, 12406);
     } else {
-      dasm_put(Dst, 12208);
+      dasm_put(Dst, 12418);
     }
-    dasm_put(Dst, 15629, -BCBIAS_J*4);
+    dasm_put(Dst, 15839, -BCBIAS_J*4);
     if (!LJ_DUALNUM && !sse) {
-      dasm_put(Dst, 15680);
+      dasm_put(Dst, 15890);
     }
-    dasm_put(Dst, 15686, Dt6(->hmask), sizeof(Node), Dt6(->node), DtB(->val.it), LJ_TNIL, DtB(->key.gcr), DtB(->key.it), DtB(->val.gcr), DtB(->val.it));
-    dasm_put(Dst, 15761);
+    dasm_put(Dst, 15896, Dt6(->hmask), sizeof(Node), Dt6(->node), DtB(->val.it), LJ_TNIL, DtB(->key.gcr), DtB(->key.it), DtB(->val.gcr), DtB(->val.it));
+    dasm_put(Dst, 15971);
     break;
 
   case BC_ISNEXT:
-    dasm_put(Dst, 15769, LJ_TFUNC, LJ_TTAB, LJ_TNIL, Dt8(->ffid), FF_next_N, -BCBIAS_J*4, BC_JMP, -BCBIAS_J*4, BC_ITERC);
+    dasm_put(Dst, 15979, LJ_TFUNC, LJ_TTAB, LJ_TNIL, Dt8(->ffid), FF_next_N, -BCBIAS_J*4, BC_JMP, -BCBIAS_J*4, BC_ITERC);
     break;
 
   case BC_VARG:
-    dasm_put(Dst, 15868, (8+FRAME_VARG), LJ_TNIL, Dt1(->maxstack));
-    dasm_put(Dst, 16032, Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top));
+    dasm_put(Dst, 16078, (8+FRAME_VARG), LJ_TNIL, Dt1(->maxstack));
+    dasm_put(Dst, 16242, Dt1(->base), Dt1(->top), Dt1(->base), Dt1(->top));
     break;
 
   /* -- Returns ----------------------------------------------------------- */
 
   case BC_RETM:
-    dasm_put(Dst, 15244);
+    dasm_put(Dst, 15454);
     break;
 
   case BC_RET: case BC_RET0: case BC_RET1:
     if (op != BC_RET0) {
-      dasm_put(Dst, 16103);
+      dasm_put(Dst, 16313);
     }
-    dasm_put(Dst, 16107, FRAME_TYPE);
+    dasm_put(Dst, 16317, FRAME_TYPE);
     switch (op) {
     case BC_RET:
-      dasm_put(Dst, 16126);
+      dasm_put(Dst, 16336);
       break;
     case BC_RET1:
-      dasm_put(Dst, 16184);
+      dasm_put(Dst, 16394);
       /* fallthrough */
     case BC_RET0:
-      dasm_put(Dst, 16200);
+      dasm_put(Dst, 16410);
     default:
       break;
     }
-    dasm_put(Dst, 16211, Dt7(->pc), PC2PROTO(k));
+    dasm_put(Dst, 16421, Dt7(->pc), PC2PROTO(k));
     if (op == BC_RET) {
-      dasm_put(Dst, 16253, LJ_TNIL);
+      dasm_put(Dst, 16463, LJ_TNIL);
     } else {
-      dasm_put(Dst, 16262, LJ_TNIL);
+      dasm_put(Dst, 16472, LJ_TNIL);
     }
-    dasm_put(Dst, 16269, -FRAME_VARG, FRAME_TYPEP);
+    dasm_put(Dst, 16479, -FRAME_VARG, FRAME_TYPEP);
     if (op != BC_RET0) {
-      dasm_put(Dst, 16293);
+      dasm_put(Dst, 16503);
     }
-    dasm_put(Dst, 4928);
+    dasm_put(Dst, 4937);
     break;
 
   /* -- Loops and branches ------------------------------------------------ */
@@ -2933,7 +2967,7 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
 
   case BC_FORL:
 #if LJ_HASJIT
-    dasm_put(Dst, 16297, HOTCOUNT_PCMASK, GG_DISP2HOT);
+    dasm_put(Dst, 16507, HOTCOUNT_PCMASK, GG_DISP2HOT, HOTCOUNT_LOOP);
 #endif
     break;
 
@@ -2945,111 +2979,111 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
   case BC_FORI:
   case BC_IFORL:
     vk = (op == BC_IFORL || op == BC_JFORL);
-    dasm_put(Dst, 16318);
+    dasm_put(Dst, 16528);
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 16322, LJ_TISNUM);
+      dasm_put(Dst, 16532, LJ_TISNUM);
       if (!vk) {
-	dasm_put(Dst, 16332, LJ_TISNUM, LJ_TISNUM);
+	dasm_put(Dst, 16542, LJ_TISNUM, LJ_TISNUM);
       } else {
 #ifdef LUA_USE_ASSERT
-	dasm_put(Dst, 16361, LJ_TISNUM, LJ_TISNUM);
+	dasm_put(Dst, 16571, LJ_TISNUM, LJ_TISNUM);
 #endif
-	dasm_put(Dst, 16380);
+	dasm_put(Dst, 16590);
       }
-      dasm_put(Dst, 16399, LJ_TISNUM);
+      dasm_put(Dst, 16609, LJ_TISNUM);
       if (op == BC_FORI) {
-	dasm_put(Dst, 16410, -BCBIAS_J*4);
+	dasm_put(Dst, 16620, -BCBIAS_J*4);
       } else if (op == BC_JFORI) {
-	dasm_put(Dst, 16424, -BCBIAS_J*4, BC_JLOOP);
+	dasm_put(Dst, 16634, -BCBIAS_J*4, BC_JLOOP);
       } else if (op == BC_IFORL) {
-	dasm_put(Dst, 16442, -BCBIAS_J*4);
+	dasm_put(Dst, 16652, -BCBIAS_J*4);
       } else {
-	dasm_put(Dst, 16434, BC_JLOOP);
+	dasm_put(Dst, 16644, BC_JLOOP);
       }
-      dasm_put(Dst, 16456);
+      dasm_put(Dst, 16666);
       if (vk) {
-	dasm_put(Dst, 16479);
+	dasm_put(Dst, 16689);
       }
-      dasm_put(Dst, 16399, LJ_TISNUM);
+      dasm_put(Dst, 16609, LJ_TISNUM);
       if (op == BC_FORI) {
-	dasm_put(Dst, 16488);
+	dasm_put(Dst, 16698);
       } else if (op == BC_JFORI) {
-	dasm_put(Dst, 16493, -BCBIAS_J*4, BC_JLOOP);
+	dasm_put(Dst, 16703, -BCBIAS_J*4, BC_JLOOP);
       } else if (op == BC_IFORL) {
-	dasm_put(Dst, 16507);
+	dasm_put(Dst, 16717);
       } else {
-	dasm_put(Dst, 16503, BC_JLOOP);
+	dasm_put(Dst, 16713, BC_JLOOP);
       }
-      dasm_put(Dst, 16512);
+      dasm_put(Dst, 16722);
     } else if (!vk) {
-      dasm_put(Dst, 16519, LJ_TISNUM);
+      dasm_put(Dst, 16729, LJ_TISNUM);
     }
     if (!vk) {
-      dasm_put(Dst, 16525, LJ_TISNUM);
+      dasm_put(Dst, 16735, LJ_TISNUM);
     } else {
 #ifdef LUA_USE_ASSERT
-      dasm_put(Dst, 16539, LJ_TISNUM, LJ_TISNUM);
+      dasm_put(Dst, 16749, LJ_TISNUM, LJ_TISNUM);
 #endif
     }
-    dasm_put(Dst, 16558);
+    dasm_put(Dst, 16768);
     if (!vk) {
-      dasm_put(Dst, 16562, LJ_TISNUM);
+      dasm_put(Dst, 16772, LJ_TISNUM);
     }
     if (sse) {
-      dasm_put(Dst, 16571);
+      dasm_put(Dst, 16781);
       if (vk) {
-	dasm_put(Dst, 16583);
+	dasm_put(Dst, 16793);
       } else {
-	dasm_put(Dst, 16602);
+	dasm_put(Dst, 16812);
       }
-      dasm_put(Dst, 16607);
+      dasm_put(Dst, 16817);
     } else {
-      dasm_put(Dst, 16620);
+      dasm_put(Dst, 16830);
       if (vk) {
-	dasm_put(Dst, 16626);
+	dasm_put(Dst, 16836);
       } else {
-	dasm_put(Dst, 16642);
+	dasm_put(Dst, 16852);
       }
-      dasm_put(Dst, 16650);
+      dasm_put(Dst, 16860);
       if (cmov) {
-      dasm_put(Dst, 3944);
+      dasm_put(Dst, 3953);
       } else {
-      dasm_put(Dst, 3950);
+      dasm_put(Dst, 3959);
       }
       if (!cmov) {
-	dasm_put(Dst, 16655);
+	dasm_put(Dst, 16865);
       }
     }
     if (op == BC_FORI) {
       if (LJ_DUALNUM) {
-	dasm_put(Dst, 16661);
+	dasm_put(Dst, 16871);
       } else {
-	dasm_put(Dst, 16666, -BCBIAS_J*4);
+	dasm_put(Dst, 16876, -BCBIAS_J*4);
       }
     } else if (op == BC_JFORI) {
-      dasm_put(Dst, 16676, -BCBIAS_J*4, BC_JLOOP);
+      dasm_put(Dst, 16886, -BCBIAS_J*4, BC_JLOOP);
     } else if (op == BC_IFORL) {
       if (LJ_DUALNUM) {
-	dasm_put(Dst, 16690);
+	dasm_put(Dst, 16900);
       } else {
-	dasm_put(Dst, 16695, -BCBIAS_J*4);
+	dasm_put(Dst, 16905, -BCBIAS_J*4);
       }
     } else {
-      dasm_put(Dst, 16686, BC_JLOOP);
+      dasm_put(Dst, 16896, BC_JLOOP);
     }
     if (LJ_DUALNUM) {
-      dasm_put(Dst, 11233);
+      dasm_put(Dst, 11448);
     } else {
-      dasm_put(Dst, 11974);
+      dasm_put(Dst, 12184);
     }
     if (sse) {
-      dasm_put(Dst, 16705);
+      dasm_put(Dst, 16915);
     }
     break;
 
   case BC_ITERL:
 #if LJ_HASJIT
-    dasm_put(Dst, 16297, HOTCOUNT_PCMASK, GG_DISP2HOT);
+    dasm_put(Dst, 16507, HOTCOUNT_PCMASK, GG_DISP2HOT, HOTCOUNT_LOOP);
 #endif
     break;
 
@@ -3058,33 +3092,33 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
     break;
 #endif
   case BC_IITERL:
-    dasm_put(Dst, 16716, LJ_TNIL);
+    dasm_put(Dst, 16926, LJ_TNIL);
     if (op == BC_JITERL) {
-      dasm_put(Dst, 16731, BC_JLOOP);
+      dasm_put(Dst, 16941, BC_JLOOP);
     } else {
-      dasm_put(Dst, 16745, -BCBIAS_J*4);
+      dasm_put(Dst, 16955, -BCBIAS_J*4);
     }
-    dasm_put(Dst, 11334);
+    dasm_put(Dst, 11544);
     break;
 
   case BC_LOOP:
 #if LJ_HASJIT
-    dasm_put(Dst, 16297, HOTCOUNT_PCMASK, GG_DISP2HOT);
+    dasm_put(Dst, 16507, HOTCOUNT_PCMASK, GG_DISP2HOT, HOTCOUNT_LOOP);
 #endif
     break;
 
   case BC_ILOOP:
-    dasm_put(Dst, 11336);
+    dasm_put(Dst, 11546);
     break;
 
   case BC_JLOOP:
 #if LJ_HASJIT
-    dasm_put(Dst, 16761, DISPATCH_J(trace), DtD(->mcode), DISPATCH_GL(jit_base), DISPATCH_GL(jit_L));
+    dasm_put(Dst, 16971, DISPATCH_J(trace), DtD(->mcode), DISPATCH_GL(jit_base), DISPATCH_GL(jit_L));
 #endif
     break;
 
   case BC_JMP:
-    dasm_put(Dst, 16784, -BCBIAS_J*4);
+    dasm_put(Dst, 16994, -BCBIAS_J*4);
     break;
 
   /* -- Function headers -------------------------------------------------- */
@@ -3098,7 +3132,7 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
 
   case BC_FUNCF:
 #if LJ_HASJIT
-    dasm_put(Dst, 16808, HOTCOUNT_PCMASK, GG_DISP2HOT);
+    dasm_put(Dst, 17018, HOTCOUNT_PCMASK, GG_DISP2HOT, HOTCOUNT_CALL);
 #endif
   case BC_FUNCV:  /* NYI: compiled vararg functions. */
     break;
@@ -3108,47 +3142,47 @@ static void build_ins(BuildCtx *ctx, BCOp op, int defop, int cmov, int sse)
     break;
 #endif
   case BC_IFUNCF:
-    dasm_put(Dst, 16829, -4+PC2PROTO(k), Dt1(->maxstack), -4+PC2PROTO(numparams));
+    dasm_put(Dst, 17039, -4+PC2PROTO(k), Dt1(->maxstack), -4+PC2PROTO(numparams));
     if (op == BC_JFUNCF) {
-      dasm_put(Dst, 16859, BC_JLOOP);
+      dasm_put(Dst, 17069, BC_JLOOP);
     } else {
-      dasm_put(Dst, 11336);
+      dasm_put(Dst, 11546);
     }
-    dasm_put(Dst, 16868, LJ_TNIL);
+    dasm_put(Dst, 17078, LJ_TNIL);
     break;
 
   case BC_JFUNCV:
 #if !LJ_HASJIT
     break;
 #endif
-    dasm_put(Dst, 10436);
+    dasm_put(Dst, 10445);
     break;  /* NYI: compiled vararg functions. */
 
   case BC_IFUNCV:
-    dasm_put(Dst, 16890, FRAME_VARG, Dt1(->maxstack), -4+PC2PROTO(numparams), LJ_TNIL);
+    dasm_put(Dst, 17100, FRAME_VARG, Dt1(->maxstack), -4+PC2PROTO(numparams), LJ_TNIL);
     if (op == BC_JFUNCV) {
-      dasm_put(Dst, 16859, BC_JLOOP);
+      dasm_put(Dst, 17069, BC_JLOOP);
     } else {
-      dasm_put(Dst, 16981, -4+PC2PROTO(k));
+      dasm_put(Dst, 17191, -4+PC2PROTO(k));
     }
-    dasm_put(Dst, 17003, LJ_TNIL);
+    dasm_put(Dst, 17213, LJ_TNIL);
     break;
 
   case BC_FUNCC:
   case BC_FUNCCW:
-    dasm_put(Dst, 17025, Dt8(->f), Dt1(->base), 8*LUA_MINSTACK, Dt1(->maxstack), Dt1(->top));
+    dasm_put(Dst, 17235, Dt8(->f), Dt1(->base), 8*LUA_MINSTACK, Dt1(->maxstack), Dt1(->top));
     if (op == BC_FUNCC) {
-      dasm_put(Dst, 17054);
+      dasm_put(Dst, 17264);
     } else {
-      dasm_put(Dst, 17058);
+      dasm_put(Dst, 17268);
     }
-    dasm_put(Dst, 17066, DISPATCH_GL(vmstate), ~LJ_VMST_C);
+    dasm_put(Dst, 17276, DISPATCH_GL(vmstate), ~LJ_VMST_C);
     if (op == BC_FUNCC) {
-      dasm_put(Dst, 17075);
+      dasm_put(Dst, 17285);
     } else {
-      dasm_put(Dst, 17079, DISPATCH_GL(wrapf));
+      dasm_put(Dst, 17289, DISPATCH_GL(wrapf));
     }
-    dasm_put(Dst, 17084, DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base), Dt1(->top));
+    dasm_put(Dst, 17294, DISPATCH_GL(vmstate), ~LJ_VMST_INTERP, Dt1(->base), Dt1(->top));
     break;
 
   /* ---------------------------------------------------------------------- */
@@ -3176,7 +3210,7 @@ static int build_backend(BuildCtx *ctx)
 
   build_subroutines(ctx, cmov, sse);
 
-  dasm_put(Dst, 17109);
+  dasm_put(Dst, 17319);
   for (op = 0; op < BC__MAX; op++)
     build_ins(ctx, (BCOp)op, op, cmov, sse);
 
@@ -3186,6 +3220,7 @@ static int build_backend(BuildCtx *ctx)
 /* Emit pseudo frame-info for all assembler functions. */
 static void emit_asm_debug(BuildCtx *ctx)
 {
+  int fcofs = (int)((uint8_t *)ctx->glob[GLOB_vm_ffi_call] - ctx->code);
 #if LJ_64
 #define SZPTR	"8"
 #define BSZPTR	"3"
@@ -3219,22 +3254,49 @@ static void emit_asm_debug(BuildCtx *ctx)
 	"\t.long .LEFDE0-.LASFDE0\n"
 	".LASFDE0:\n"
 	"\t.long .Lframe0\n"
-	"\t.long .Lbegin\n"
-	"\t.long %d\n"
-	"\t.byte 0xe\n\t.uleb128 %d\n"		/* def_cfa_offset */
 #if LJ_64
+	"\t.quad .Lbegin\n"
+	"\t.quad %d\n"
+	"\t.byte 0xe\n\t.uleb128 %d\n"		/* def_cfa_offset */
 	"\t.byte 0x86\n\t.uleb128 0x2\n"	/* offset rbp */
 	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset rbx */
 	"\t.byte 0x8f\n\t.uleb128 0x4\n"	/* offset r15 */
 	"\t.byte 0x8e\n\t.uleb128 0x5\n"	/* offset r14 */
 #else
+	"\t.long .Lbegin\n"
+	"\t.long %d\n"
+	"\t.byte 0xe\n\t.uleb128 %d\n"		/* def_cfa_offset */
 	"\t.byte 0x85\n\t.uleb128 0x2\n"	/* offset ebp */
 	"\t.byte 0x87\n\t.uleb128 0x3\n"	/* offset edi */
 	"\t.byte 0x86\n\t.uleb128 0x4\n"	/* offset esi */
 	"\t.byte 0x83\n\t.uleb128 0x5\n"	/* offset ebx */
 #endif
 	"\t.align " SZPTR "\n"
-	".LEFDE0:\n\n", (int)ctx->codesz, CFRAME_SIZE);
+	".LEFDE0:\n\n", fcofs, CFRAME_SIZE);
+#if LJ_HASFFI
+    fprintf(ctx->fp,
+	".LSFDE1:\n"
+	"\t.long .LEFDE1-.LASFDE1\n"
+	".LASFDE1:\n"
+	"\t.long .Lframe0\n"
+#if LJ_64
+	"\t.quad lj_vm_ffi_call\n"
+	"\t.quad %d\n"
+	"\t.byte 0xe\n\t.uleb128 16\n"		/* def_cfa_offset */
+	"\t.byte 0x86\n\t.uleb128 0x2\n"	/* offset rbp */
+	"\t.byte 0xd\n\t.uleb128 0x6\n"		/* def_cfa_register rbp */
+	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset rbx */
+#else
+	"\t.long lj_vm_ffi_call\n"
+	"\t.long %d\n"
+	"\t.byte 0xe\n\t.uleb128 8\n"		/* def_cfa_offset */
+	"\t.byte 0x85\n\t.uleb128 0x2\n"	/* offset ebp */
+	"\t.byte 0xd\n\t.uleb128 0x5\n"		/* def_cfa_register ebp */
+	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset ebx */
+#endif
+	"\t.align " SZPTR "\n"
+	".LEFDE1:\n\n", (int)ctx->codesz - fcofs);
+#endif
 #if (defined(__sun__) && defined(__svr4__)) || defined(__solaris_)
     fprintf(ctx->fp, "\t.section .eh_frame,\"aw\",@progbits\n");
 #else
@@ -3259,10 +3321,10 @@ static void emit_asm_debug(BuildCtx *ctx)
 	"\t.align " SZPTR "\n"
 	".LECIE1:\n\n");
     fprintf(ctx->fp,
-	".LSFDE1:\n"
-	"\t.long .LEFDE1-.LASFDE1\n"
-	".LASFDE1:\n"
-	"\t.long .LASFDE1-.Lframe1\n"
+	".LSFDE2:\n"
+	"\t.long .LEFDE2-.LASFDE2\n"
+	".LASFDE2:\n"
+	"\t.long .LASFDE2-.Lframe1\n"
 	"\t.long .Lbegin-.\n"
 	"\t.long %d\n"
 	"\t.uleb128 0\n"			/* augmentation length */
@@ -3279,7 +3341,46 @@ static void emit_asm_debug(BuildCtx *ctx)
 	"\t.byte 0x83\n\t.uleb128 0x5\n"	/* offset ebx */
 #endif
 	"\t.align " SZPTR "\n"
-	".LEFDE1:\n\n", (int)ctx->codesz, CFRAME_SIZE);
+	".LEFDE2:\n\n", fcofs, CFRAME_SIZE);
+#if LJ_HASFFI
+    fprintf(ctx->fp,
+	".Lframe2:\n"
+	"\t.long .LECIE2-.LSCIE2\n"
+	".LSCIE2:\n"
+	"\t.long 0\n"
+	"\t.byte 0x1\n"
+	"\t.string \"zR\"\n"
+	"\t.uleb128 0x1\n"
+	"\t.sleb128 -" SZPTR "\n"
+	"\t.byte " REG_RA "\n"
+	"\t.uleb128 1\n"			/* augmentation length */
+	"\t.byte 0x1b\n"			/* pcrel|sdata4 */
+	"\t.byte 0xc\n\t.uleb128 " REG_SP "\n\t.uleb128 " SZPTR "\n"
+	"\t.byte 0x80+" REG_RA "\n\t.uleb128 0x1\n"
+	"\t.align " SZPTR "\n"
+	".LECIE2:\n\n");
+    fprintf(ctx->fp,
+	".LSFDE3:\n"
+	"\t.long .LEFDE3-.LASFDE3\n"
+	".LASFDE3:\n"
+	"\t.long .LASFDE3-.Lframe2\n"
+	"\t.long lj_vm_ffi_call-.\n"
+	"\t.long %d\n"
+	"\t.uleb128 0\n"			/* augmentation length */
+#if LJ_64
+	"\t.byte 0xe\n\t.uleb128 16\n"		/* def_cfa_offset */
+	"\t.byte 0x86\n\t.uleb128 0x2\n"	/* offset rbp */
+	"\t.byte 0xd\n\t.uleb128 0x6\n"		/* def_cfa_register rbp */
+	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset rbx */
+#else
+	"\t.byte 0xe\n\t.uleb128 8\n"		/* def_cfa_offset */
+	"\t.byte 0x85\n\t.uleb128 0x2\n"	/* offset ebp */
+	"\t.byte 0xd\n\t.uleb128 0x5\n"		/* def_cfa_register ebp */
+	"\t.byte 0x83\n\t.uleb128 0x3\n"	/* offset ebx */
+#endif
+	"\t.align " SZPTR "\n"
+	".LEFDE3:\n\n", (int)ctx->codesz - fcofs);
+#endif
     break;
   case BUILD_coffasm:
     fprintf(ctx->fp, "\t.section .eh_frame,\"dr\"\n");
@@ -3330,6 +3431,9 @@ static void emit_asm_debug(BuildCtx *ctx)
   ** Or a linker. Or a plastic case. But I digress.
   */
   case BUILD_machasm: {
+#if LJ_HASFFI
+    int fcsize = 0;
+#endif
     int i;
     fprintf(ctx->fp, "\t.section __TEXT,__eh_frame,coalesced,no_toc+strip_static_syms+live_support\n");
     fprintf(ctx->fp,
@@ -3361,6 +3465,9 @@ static void emit_asm_debug(BuildCtx *ctx)
       const char *name = ctx->sym[i].name;
       int32_t size = ctx->sym[i+1].ofs - ctx->sym[i].ofs;
       if (size == 0) continue;
+#if LJ_HASFFI
+      if (!strcmp(name, "_lj_vm_ffi_call")) { fcsize = size; continue; }
+#endif
       fprintf(ctx->fp,
 	  "%s.eh:\n"
 	  "LSFDE%d:\n"
@@ -3370,23 +3477,72 @@ static void emit_asm_debug(BuildCtx *ctx)
 	  "\t.long LASFDE%d-EH_frame1\n"
 	  "\t.long %s-.\n"
 	  "\t.long %d\n"
-	  "\t.byte 0\n"			/* augmentation length */
+	  "\t.byte 0\n"				/* augmentation length */
 	  "\t.byte 0xe\n\t.byte %d\n"		/* def_cfa_offset */
 #if LJ_64
-	  "\t.byte 0x86\n\t.byte 0x2\n"	/* offset rbp */
-	  "\t.byte 0x83\n\t.byte 0x3\n"	/* offset rbx */
-	  "\t.byte 0x8f\n\t.byte 0x4\n"	/* offset r15 */
-	  "\t.byte 0x8e\n\t.byte 0x5\n"	/* offset r14 */
+	  "\t.byte 0x86\n\t.byte 0x2\n"		/* offset rbp */
+	  "\t.byte 0x83\n\t.byte 0x3\n"		/* offset rbx */
+	  "\t.byte 0x8f\n\t.byte 0x4\n"		/* offset r15 */
+	  "\t.byte 0x8e\n\t.byte 0x5\n"		/* offset r14 */
 #else
-	  "\t.byte 0x84\n\t.byte 0x2\n"	/* offset ebp (4 for MACH-O)*/
-	  "\t.byte 0x87\n\t.byte 0x3\n"	/* offset edi */
-	  "\t.byte 0x86\n\t.byte 0x4\n"	/* offset esi */
-	  "\t.byte 0x83\n\t.byte 0x5\n"	/* offset ebx */
+	  "\t.byte 0x84\n\t.byte 0x2\n"		/* offset ebp (4 for MACH-O)*/
+	  "\t.byte 0x87\n\t.byte 0x3\n"		/* offset edi */
+	  "\t.byte 0x86\n\t.byte 0x4\n"		/* offset esi */
+	  "\t.byte 0x83\n\t.byte 0x5\n"		/* offset ebx */
 #endif
 	  "\t.align " BSZPTR "\n"
 	  "LEFDE%d:\n\n",
 	  name, i, i, i, i, i, i, i, name, size, CFRAME_SIZE, i);
     }
+#if LJ_HASFFI
+    if (fcsize) {
+      fprintf(ctx->fp,
+	  "EH_frame2:\n"
+	  "\t.set L$set$y,LECIEY-LSCIEY\n"
+	  "\t.long L$set$y\n"
+	  "LSCIEY:\n"
+	  "\t.long 0\n"
+	  "\t.byte 0x1\n"
+	  "\t.ascii \"zR\\0\"\n"
+	  "\t.byte 0x1\n"
+	  "\t.byte 128-" SZPTR "\n"
+	  "\t.byte " REG_RA "\n"
+	  "\t.byte 1\n"				/* augmentation length */
+#if LJ_64
+	  "\t.byte 0x1b\n"			/* pcrel|sdata4 */
+	  "\t.byte 0xc\n\t.byte " REG_SP "\n\t.byte " SZPTR "\n"
+#else
+	  "\t.byte 0x1b\n"			/* pcrel|sdata4 */
+	  "\t.byte 0xc\n\t.byte 0x5\n\t.byte 0x4\n"  /* esp=5 on 32 bit MACH. */
+#endif
+	  "\t.byte 0x80+" REG_RA "\n\t.byte 0x1\n"
+	  "\t.align " BSZPTR "\n"
+	  "LECIEY:\n\n");
+      fprintf(ctx->fp,
+	  "_lj_vm_ffi_call.eh:\n"
+	  "LSFDEY:\n"
+	  "\t.set L$set$yy,LEFDEY-LASFDEY\n"
+	  "\t.long L$set$yy\n"
+	  "LASFDEY:\n"
+	  "\t.long LASFDEY-EH_frame2\n"
+	  "\t.long _lj_vm_ffi_call-.\n"
+	  "\t.long %d\n"
+	  "\t.byte 0\n"				/* augmentation length */
+#if LJ_64
+	  "\t.byte 0xe\n\t.byte 16\n"		/* def_cfa_offset */
+	  "\t.byte 0x86\n\t.byte 0x2\n"		/* offset rbp */
+	  "\t.byte 0xd\n\t.uleb128 0x6\n"	/* def_cfa_register rbp */
+	  "\t.byte 0x83\n\t.byte 0x3\n"		/* offset rbx */
+#else
+	  "\t.byte 0xe\n\t.byte 8\n"		/* def_cfa_offset */
+	  "\t.byte 0x84\n\t.byte 0x2\n"		/* offset ebp (4 for MACH-O)*/
+	  "\t.byte 0xd\n\t.uleb128 0x4\n"	/* def_cfa_register ebp */
+	  "\t.byte 0x83\n\t.byte 0x3\n"		/* offset ebx */
+#endif
+	  "\t.align " BSZPTR "\n"
+	  "LEFDEY:\n\n", fcsize);
+    }
+#endif
 #if LJ_64
     fprintf(ctx->fp, "\t.subsections_via_symbols\n");
 #else
diff --git a/third_party/luajit/src/lib_ffi.c b/third_party/luajit/src/lib_ffi.c
index 582e9bf706c3d5c7a89ec63499ab1a72a68c7271..0a8a7282a5a18b7b427ee7239cf511049dbf1883 100644
--- a/third_party/luajit/src/lib_ffi.c
+++ b/third_party/luajit/src/lib_ffi.c
@@ -27,6 +27,7 @@
 #include "lj_cconv.h"
 #include "lj_carith.h"
 #include "lj_ccall.h"
+#include "lj_ccallback.h"
 #include "lj_clib.h"
 #include "lj_ff.h"
 #include "lj_lib.h"
@@ -207,7 +208,10 @@ LJLIB_CF(ffi_meta___concat)	LJLIB_REC(cdata_arith MM_concat)
 static int ffi_call_meta(lua_State *L, CTypeID id)
 {
   CTState *cts = ctype_cts(L);
-  cTValue *tv = lj_ctype_meta(cts, id, MM_call);
+  CType *ct = ctype_raw(cts, id);
+  cTValue *tv;
+  if (ctype_isptr(ct->info)) id = ctype_cid(ct->info);
+  tv = lj_ctype_meta(cts, id, MM_call);
   if (!tv)
     lj_err_callerv(L, LJ_ERR_FFI_BADCALL, strdata(lj_ctype_repr(L, id, NULL)));
   return lj_meta_tailcall(L, tv);
@@ -325,7 +329,7 @@ static TValue *ffi_clib_index(lua_State *L)
   return lj_clib_index(L, cl, strV(o+1));
 }
 
-LJLIB_CF(ffi_clib___index)	LJLIB_REC(clib_index)
+LJLIB_CF(ffi_clib___index)	LJLIB_REC(clib_index 1)
 {
   TValue *tv = ffi_clib_index(L);
   if (tviscdata(tv)) {
@@ -335,7 +339,9 @@ LJLIB_CF(ffi_clib___index)	LJLIB_REC(clib_index)
     if (ctype_isextern(s->info)) {
       CTypeID sid = ctype_cid(s->info);
       void *sp = *(void **)cdataptr(cd);
-      if (lj_cconv_tv_ct(cts, ctype_raw(cts, sid), sid, L->top-1, sp))
+      CType *ct = ctype_raw(cts, sid);
+      if (ctype_isenum(ct->info)) ct = ctype_child(cts, ct);
+      if (lj_cconv_tv_ct(cts, ct, sid, L->top-1, sp))
 	lj_gc_check(L);
       return 1;
     }
@@ -344,7 +350,7 @@ LJLIB_CF(ffi_clib___index)	LJLIB_REC(clib_index)
   return 1;
 }
 
-LJLIB_CF(ffi_clib___newindex)
+LJLIB_CF(ffi_clib___newindex)	LJLIB_REC(clib_index 0)
 {
   TValue *tv = ffi_clib_index(L);
   TValue *o = L->base+2;
@@ -379,6 +385,50 @@ LJLIB_CF(ffi_clib___gc)
 
 #include "lj_libdef.h"
 
+/* -- Callback function metamethods --------------------------------------- */
+
+#define LJLIB_MODULE_ffi_callback
+
+static int ffi_callback_set(lua_State *L, GCfunc *fn)
+{
+  GCcdata *cd = ffi_checkcdata(L, 1);
+  CTState *cts = ctype_cts(L);
+  CType *ct = ctype_raw(cts, cd->typeid);
+  if (ctype_isptr(ct->info) && (LJ_32 || ct->size == 8)) {
+    MSize slot = lj_ccallback_ptr2slot(cts, *(void **)cdataptr(cd));
+    if (slot < cts->cb.sizeid && cts->cb.cbid[slot] != 0) {
+      GCtab *t = cts->miscmap;
+      TValue *tv = lj_tab_setint(L, t, (int32_t)slot);
+      if (fn) {
+	setfuncV(L, tv, fn);
+	lj_gc_anybarriert(L, t);
+      } else {
+	setnilV(tv);
+	cts->cb.cbid[slot] = 0;
+	cts->cb.topid = slot < cts->cb.topid ? slot : cts->cb.topid;
+      }
+      return 0;
+    }
+  }
+  lj_err_caller(L, LJ_ERR_FFI_BADCBACK);
+  return 0;
+}
+
+LJLIB_CF(ffi_callback_free)
+{
+  return ffi_callback_set(L, NULL);
+}
+
+LJLIB_CF(ffi_callback_set)
+{
+  GCfunc *fn = lj_lib_checkfunc(L, 2);
+  return ffi_callback_set(L, fn);
+}
+
+LJLIB_PUSH(top-1) LJLIB_SET(__index)
+
+#include "lj_libdef.h"
+
 /* -- FFI library functions ----------------------------------------------- */
 
 #define LJLIB_MODULE_ffi
@@ -423,7 +473,7 @@ LJLIB_CF(ffi_new)	LJLIB_REC(.)
 		   o, (MSize)(L->top - o));  /* Initialize cdata. */
   if (ctype_isstruct(ct->info)) {
     /* Handle ctype __gc metamethod. Use the fast lookup here. */
-    cTValue *tv = lj_tab_getint(cts->metatype, (int32_t)id);
+    cTValue *tv = lj_tab_getinth(cts->miscmap, -(int32_t)id);
     if (tv && tvistab(tv) && (tv = lj_meta_fast(L, tabV(tv), MM_gc))) {
       GCtab *t = cts->finalizer;
       if (gcref(t->metatable)) {
@@ -553,7 +603,7 @@ LJLIB_CF(ffi_offsetof)
   return 0;
 }
 
-LJLIB_CF(ffi_errno)
+LJLIB_CF(ffi_errno)	LJLIB_REC(.)
 {
   int err = errno;
   if (L->top > L->base)
@@ -645,21 +695,21 @@ LJLIB_CF(ffi_abi)	LJLIB_REC(.)
 
 #undef H_
 
-LJLIB_PUSH(top-8) LJLIB_SET(!)  /* Store reference to metatype table. */
+LJLIB_PUSH(top-8) LJLIB_SET(!)  /* Store reference to miscmap table. */
 
 LJLIB_CF(ffi_metatype)
 {
   CTState *cts = ctype_cts(L);
   CTypeID id = ffi_checkctype(L, cts);
   GCtab *mt = lj_lib_checktab(L, 2);
-  GCtab *t = cts->metatype;
+  GCtab *t = cts->miscmap;
   CType *ct = ctype_get(cts, id);  /* Only allow raw types. */
   TValue *tv;
   GCcdata *cd;
   if (!(ctype_isstruct(ct->info) || ctype_iscomplex(ct->info) ||
 	ctype_isvector(ct->info)))
     lj_err_arg(L, 1, LJ_ERR_FFI_INVTYPE);
-  tv = lj_tab_setint(L, t, (int32_t)id);
+  tv = lj_tab_setinth(L, t, -(int32_t)id);
   if (!tvisnil(tv))
     lj_err_caller(L, LJ_ERR_PROTMT);
   settabV(L, tv, mt);
@@ -740,12 +790,16 @@ static void ffi_register_module(lua_State *L)
 LUALIB_API int luaopen_ffi(lua_State *L)
 {
   CTState *cts = lj_ctype_init(L);
-  settabV(L, L->top++, (cts->metatype = lj_tab_new(L, 0, 0)));
+  settabV(L, L->top++, (cts->miscmap = lj_tab_new(L, 0, 1)));
   cts->finalizer = ffi_finalizer(L);
   LJ_LIB_REG(L, NULL, ffi_meta);
   /* NOBARRIER: basemt is a GC root. */
   setgcref(basemt_it(G(L), LJ_TCDATA), obj2gco(tabV(L->top-1)));
   LJ_LIB_REG(L, NULL, ffi_clib);
+  LJ_LIB_REG(L, NULL, ffi_callback);
+  /* NOBARRIER: the key is new and lj_tab_newkey() handles the barrier. */
+  settabV(L, lj_tab_setstr(L, cts->miscmap, &cts->g->strempty), tabV(L->top-1));
+  L->top--;
   lj_clib_default(L, tabV(L->top-1));  /* Create ffi.C default namespace. */
   lua_pushliteral(L, LJ_OS_NAME);
   lua_pushliteral(L, LJ_ARCH_NAME);
diff --git a/third_party/luajit/src/lib_jit.c b/third_party/luajit/src/lib_jit.c
index 66b3856aee37065e2009010e4d74bae124b56b4e..d4277add768c3ea487f5a4681afa4ea5b2f60aab 100644
--- a/third_party/luajit/src/lib_jit.c
+++ b/third_party/luajit/src/lib_jit.c
@@ -276,18 +276,26 @@ static GCtrace *jit_checktrace(lua_State *L)
   return NULL;
 }
 
+/* Names of link types. ORDER LJ_TRLINK */
+static const char *const jit_trlinkname[] = {
+  "none", "root", "loop", "tail-recursion", "up-recursion", "down-recursion",
+  "interpreter", "return"
+};
+
 /* local info = jit.util.traceinfo(tr) */
 LJLIB_CF(jit_util_traceinfo)
 {
   GCtrace *T = jit_checktrace(L);
   if (T) {
     GCtab *t;
-    lua_createtable(L, 0, 4);  /* Increment hash size if fields are added. */
+    lua_createtable(L, 0, 8);  /* Increment hash size if fields are added. */
     t = tabV(L->top-1);
     setintfield(L, t, "nins", (int32_t)T->nins - REF_BIAS - 1);
     setintfield(L, t, "nk", REF_BIAS - (int32_t)T->nk);
     setintfield(L, t, "link", T->link);
     setintfield(L, t, "nexit", T->nsnap);
+    setstrV(L, L->top++, lj_str_newz(L, jit_trlinkname[T->linktype]));
+    lua_setfield(L, -2, "linktype");
     /* There are many more fields. Add them only when needed. */
     return 1;
   }
@@ -369,15 +377,27 @@ LJLIB_CF(jit_util_tracemc)
   return 0;
 }
 
-/* local addr = jit.util.traceexitstub(idx) */
+/* local addr = jit.util.traceexitstub([tr,] exitno) */
 LJLIB_CF(jit_util_traceexitstub)
 {
+#ifdef EXITSTUBS_PER_GROUP
   ExitNo exitno = (ExitNo)lj_lib_checkint(L, 1);
   jit_State *J = L2J(L);
   if (exitno < EXITSTUBS_PER_GROUP*LJ_MAX_EXITSTUBGR) {
     setintptrV(L->top-1, (intptr_t)(void *)exitstub_addr(J, exitno));
     return 1;
   }
+#else
+  if (L->top > L->base+1) {  /* Don't throw for one-argument variant. */
+    GCtrace *T = jit_checktrace(L);
+    ExitNo exitno = (ExitNo)lj_lib_checkint(L, 2);
+    ExitNo maxexit = T->root ? T->nsnap+1 : T->nsnap;
+    if (T && T->mcode != NULL && exitno < maxexit) {
+      setintptrV(L->top-1, (intptr_t)(void *)exitstub_trace_addr(T, exitno));
+      return 1;
+    }
+  }
+#endif
   return 0;
 }
 
@@ -569,6 +589,7 @@ static uint32_t jit_cpudetect(lua_State *L)
 #endif
 #endif
 #elif LJ_TARGET_ARM
+#if LJ_HASJIT
   /* Compile-time ARM CPU detection. */
 #if __ARM_ARCH_7__ || __ARM_ARCH_7A__ || __ARM_ARCH_7R__
   flags |= JIT_F_ARMV6|JIT_F_ARMV6T2|JIT_F_ARMV7;
@@ -590,7 +611,8 @@ static uint32_t jit_cpudetect(lua_State *L)
     }
   }
 #endif
-#elif LJ_TARGET_PPC
+#endif
+#elif LJ_TARGET_PPC || LJ_TARGET_PPCSPE
   /* Nothing to do. */
 #else
 #error "Missing CPU detection for this architecture"
diff --git a/third_party/luajit/src/lib_package.c b/third_party/luajit/src/lib_package.c
index 71e0826b122848985293e06a70f48eba459b6cd4..a13c45baf7c4df312e230828c106334558394644 100644
--- a/third_party/luajit/src/lib_package.c
+++ b/third_party/luajit/src/lib_package.c
@@ -22,11 +22,16 @@
 /* Error codes for ll_loadfunc. */
 #define PACKAGE_ERR_LIB		1
 #define PACKAGE_ERR_FUNC	2
+#define PACKAGE_ERR_LOAD	3
 
 /* Redefined in platform specific part. */
 #define PACKAGE_LIB_FAIL	"open"
 #define setprogdir(L)		((void)0)
 
+/* Symbol name prefixes. */
+#define SYMPREFIX_CF		"luaopen_%s"
+#define SYMPREFIX_BC		"luaJIT_BC_%s"
+
 #if LJ_TARGET_DLOPEN
 
 #include <dlfcn.h>
@@ -50,11 +55,30 @@ static lua_CFunction ll_sym(lua_State *L, void *lib, const char *sym)
   return f;
 }
 
+static const char *ll_bcsym(void *lib, const char *sym)
+{
+#if defined(RTLD_DEFAULT)
+  if (lib == NULL) lib = RTLD_DEFAULT;
+#elif LJ_TARGET_OSX || LJ_TARGET_BSD
+  if (lib == NULL) lib = (void *)(intptr_t)-2;
+#endif
+  return (const char *)dlsym(lib, sym);
+}
+
 #elif LJ_TARGET_WINDOWS
 
 #define WIN32_LEAN_AND_MEAN
+#ifndef WINVER
+#define WINVER 0x0500
+#endif
 #include <windows.h>
 
+#ifndef GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS
+#define GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS  4
+#define GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT  2
+BOOL WINAPI GetModuleHandleExA(DWORD, LPCSTR, HMODULE*);
+#endif
+
 #undef setprogdir
 
 static void setprogdir(lua_State *L)
@@ -102,6 +126,20 @@ static lua_CFunction ll_sym(lua_State *L, void *lib, const char *sym)
   return f;
 }
 
+static const char *ll_bcsym(void *lib, const char *sym)
+{
+  if (lib) {
+    return (const char *)GetProcAddress((HINSTANCE)lib, sym);
+  } else {
+    HINSTANCE h = GetModuleHandleA(NULL);
+    const char *p = (const char *)GetProcAddress(h, sym);
+    if (p == NULL && GetModuleHandleExA(GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS|GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT,
+					(const char *)ll_bcsym, &h))
+      p = (const char *)GetProcAddress(h, sym);
+    return p;
+  }
+}
+
 #else
 
 #undef PACKAGE_LIB_FAIL
@@ -127,6 +165,13 @@ static lua_CFunction ll_sym(lua_State *L, void *lib, const char *sym)
   lua_pushliteral(L, DLMSG);
   return NULL;
 }
+
+static const char *ll_bcsym(void *lib, const char *sym)
+{
+  (void)lib; (void)sym;
+  return NULL;
+}
+
 #endif
 
 /* ------------------------------------------------------------------------ */
@@ -151,18 +196,41 @@ static void **ll_register(lua_State *L, const char *path)
   return plib;
 }
 
-static int ll_loadfunc(lua_State *L, const char *path, const char *sym)
+static const char *mksymname(lua_State *L, const char *modname,
+			     const char *prefix)
+{
+  const char *funcname;
+  const char *mark = strchr(modname, *LUA_IGMARK);
+  if (mark) modname = mark + 1;
+  funcname = luaL_gsub(L, modname, ".", "_");
+  funcname = lua_pushfstring(L, prefix, funcname);
+  lua_remove(L, -2);  /* remove 'gsub' result */
+  return funcname;
+}
+
+static int ll_loadfunc(lua_State *L, const char *path, const char *name, int r)
 {
   void **reg = ll_register(L, path);
   if (*reg == NULL) *reg = ll_load(L, path);
   if (*reg == NULL) {
     return PACKAGE_ERR_LIB;  /* unable to load library */
   } else {
+    const char *sym = r ? name : mksymname(L, name, SYMPREFIX_CF);
     lua_CFunction f = ll_sym(L, *reg, sym);
-    if (f == NULL)
-      return PACKAGE_ERR_FUNC;  /* unable to find function */
-    lua_pushcfunction(L, f);
-    return 0;  /* return function */
+    if (f) {
+      lua_pushcfunction(L, f);
+      return 0;
+    }
+    if (!r) {
+      const char *bcdata = ll_bcsym(*reg, mksymname(L, name, SYMPREFIX_BC));
+      lua_pop(L, 1);
+      if (bcdata) {
+	if (luaL_loadbuffer(L, bcdata, ~(size_t)0, name) != 0)
+	  return PACKAGE_ERR_LOAD;
+	return 0;
+      }
+    }
+    return PACKAGE_ERR_FUNC;  /* unable to find function */
   }
 }
 
@@ -170,7 +238,7 @@ static int lj_cf_package_loadlib(lua_State *L)
 {
   const char *path = luaL_checkstring(L, 1);
   const char *init = luaL_checkstring(L, 2);
-  int st = ll_loadfunc(L, path, init);
+  int st = ll_loadfunc(L, path, init, 1);
   if (st == 0) {  /* no errors? */
     return 1;  /* return the loaded function */
   } else {  /* error; error message is on stack top */
@@ -268,32 +336,18 @@ static int lj_cf_package_loader_lua(lua_State *L)
   return 1;  /* library loaded successfully */
 }
 
-static const char *mkfuncname(lua_State *L, const char *modname)
-{
-  const char *funcname;
-  const char *mark = strchr(modname, *LUA_IGMARK);
-  if (mark) modname = mark + 1;
-  funcname = luaL_gsub(L, modname, ".", "_");
-  funcname = lua_pushfstring(L, "luaopen_%s", funcname);
-  lua_remove(L, -2);  /* remove 'gsub' result */
-  return funcname;
-}
-
 static int lj_cf_package_loader_c(lua_State *L)
 {
-  const char *funcname;
   const char *name = luaL_checkstring(L, 1);
   const char *filename = findfile(L, name, "cpath");
   if (filename == NULL) return 1;  /* library not found in this path */
-  funcname = mkfuncname(L, name);
-  if (ll_loadfunc(L, filename, funcname) != 0)
+  if (ll_loadfunc(L, filename, name, 0) != 0)
     loaderror(L, filename);
   return 1;  /* library loaded successfully */
 }
 
 static int lj_cf_package_loader_croot(lua_State *L)
 {
-  const char *funcname;
   const char *filename;
   const char *name = luaL_checkstring(L, 1);
   const char *p = strchr(name, '.');
@@ -302,8 +356,7 @@ static int lj_cf_package_loader_croot(lua_State *L)
   lua_pushlstring(L, name, (size_t)(p - name));
   filename = findfile(L, lua_tostring(L, -1), "cpath");
   if (filename == NULL) return 1;  /* root not found */
-  funcname = mkfuncname(L, name);
-  if ((st = ll_loadfunc(L, filename, funcname)) != 0) {
+  if ((st = ll_loadfunc(L, filename, name, 0)) != 0) {
     if (st != PACKAGE_ERR_FUNC) loaderror(L, filename);  /* real error */
     lua_pushfstring(L, "\n\tno module " LUA_QS " in file " LUA_QS,
 		    name, filename);
@@ -319,8 +372,12 @@ static int lj_cf_package_loader_preload(lua_State *L)
   if (!lua_istable(L, -1))
     luaL_error(L, LUA_QL("package.preload") " must be a table");
   lua_getfield(L, -1, name);
-  if (lua_isnil(L, -1))  /* not found? */
-    lua_pushfstring(L, "\n\tno field package.preload['%s']", name);
+  if (lua_isnil(L, -1)) {  /* Not found? */
+    const char *bcname = mksymname(L, name, SYMPREFIX_BC);
+    const char *bcdata = ll_bcsym(NULL, bcname);
+    if (bcdata == NULL || luaL_loadbuffer(L, bcdata, ~(size_t)0, name) != 0)
+      lua_pushfstring(L, "\n\tno field package.preload['%s']", name);
+  }
   return 1;
 }
 
diff --git a/third_party/luajit/src/lj_alloc.c b/third_party/luajit/src/lj_alloc.c
index 8d4edb5eab01da13bd682b941e0db03d372a5246..c1aac00d0defc39496beff335bf7fc131febfbc3 100644
--- a/third_party/luajit/src/lj_alloc.c
+++ b/third_party/luajit/src/lj_alloc.c
@@ -91,7 +91,7 @@ static PNTAVM ntavm;
 
 static void INIT_MMAP(void)
 {
-  ntavm = (PNTAVM)GetProcAddress(GetModuleHandle("ntdll.dll"),
+  ntavm = (PNTAVM)GetProcAddress(GetModuleHandleA("ntdll.dll"),
 				 "NtAllocateVirtualMemory");
 }
 
diff --git a/third_party/luajit/src/lj_api.c b/third_party/luajit/src/lj_api.c
index a6fbb1c6aaf05862a7acec886feffb9185b827af..5ef2dff1068bc59c18ee7b39b83f3d8f402fac45 100644
--- a/third_party/luajit/src/lj_api.c
+++ b/third_party/luajit/src/lj_api.c
@@ -437,6 +437,7 @@ LUA_API const char *lua_tolstring(lua_State *L, int idx, size_t *len)
     lj_gc_check(L);
     o = index2adr(L, idx);  /* GC may move the stack. */
     s = lj_str_fromnumber(L, o);
+    setstrV(L, o, s);
   } else {
     if (len != NULL) *len = 0;
     return NULL;
@@ -455,6 +456,7 @@ LUALIB_API const char *luaL_checklstring(lua_State *L, int idx, size_t *len)
     lj_gc_check(L);
     o = index2adr(L, idx);  /* GC may move the stack. */
     s = lj_str_fromnumber(L, o);
+    setstrV(L, o, s);
   } else {
     lj_err_argt(L, idx, LUA_TSTRING);
   }
@@ -476,6 +478,7 @@ LUALIB_API const char *luaL_optlstring(lua_State *L, int idx,
     lj_gc_check(L);
     o = index2adr(L, idx);  /* GC may move the stack. */
     s = lj_str_fromnumber(L, o);
+    setstrV(L, o, s);
   } else {
     lj_err_argt(L, idx, LUA_TSTRING);
   }
@@ -499,16 +502,19 @@ LUALIB_API int luaL_checkoption(lua_State *L, int idx, const char *def,
 LUA_API size_t lua_objlen(lua_State *L, int idx)
 {
   TValue *o = index2adr(L, idx);
-  if (tvisstr(o))
+  if (tvisstr(o)) {
     return strV(o)->len;
-  else if (tvistab(o))
+  } else if (tvistab(o)) {
     return (size_t)lj_tab_len(tabV(o));
-  else if (tvisudata(o))
+  } else if (tvisudata(o)) {
     return udataV(o)->len;
-  else if (tvisnumber(o))
-    return lj_str_fromnumber(L, o)->len;
-  else
+  } else if (tvisnumber(o)) {
+    GCstr *s = lj_str_fromnumber(L, o);
+    setstrV(L, o, s);
+    return s->len;
+  } else {
     return 0;
+  }
 }
 
 LUA_API lua_CFunction lua_tocfunction(lua_State *L, int idx)
diff --git a/third_party/luajit/src/lj_arch.h b/third_party/luajit/src/lj_arch.h
index ff4628df94b768451080c78423f6ff7a52b58328..50a6ef00bc7ef57ec66d0662f932acda282f1a12 100644
--- a/third_party/luajit/src/lj_arch.h
+++ b/third_party/luajit/src/lj_arch.h
@@ -95,6 +95,11 @@
 #define LJ_TARGET_POSIX		(LUAJIT_OS > LUAJIT_OS_WINDOWS)
 #define LJ_TARGET_DLOPEN	LJ_TARGET_POSIX
 
+#define LJ_NUMMODE_SINGLE	0	/* Single-number mode only. */
+#define LJ_NUMMODE_SINGLE_DUAL	1	/* Default to single-number mode. */
+#define LJ_NUMMODE_DUAL		2	/* Dual-number mode only. */
+#define LJ_NUMMODE_DUAL_SINGLE	3	/* Default to dual-number mode. */
+
 /* Set target architecture properties. */
 #if LUAJIT_TARGET == LUAJIT_ARCH_X86
 
@@ -108,7 +113,7 @@
 #define LJ_TARGET_EHRETREG	0
 #define LJ_TARGET_MASKSHIFT	1
 #define LJ_TARGET_MASKROT	1
-#define LJ_ARCH_DUALNUM		1
+#define LJ_ARCH_NUMMODE		LJ_NUMMODE_SINGLE_DUAL
 
 #elif LUAJIT_TARGET == LUAJIT_ARCH_X64
 
@@ -123,7 +128,7 @@
 #define LJ_TARGET_JUMPRANGE	31	/* +-2^31 = +-2GB */
 #define LJ_TARGET_MASKSHIFT	1
 #define LJ_TARGET_MASKROT	1
-#define LJ_ARCH_DUALNUM		1
+#define LJ_ARCH_NUMMODE		LJ_NUMMODE_SINGLE_DUAL
 
 #elif LUAJIT_TARGET == LUAJIT_ARCH_ARM
 
@@ -139,7 +144,7 @@
 #define LJ_TARGET_MASKSHIFT	0
 #define LJ_TARGET_MASKROT	1
 #define LJ_TARGET_UNIFYROT	2	/* Want only IR_BROR. */
-#define LJ_ARCH_DUALNUM		2
+#define LJ_ARCH_NUMMODE		LJ_NUMMODE_DUAL
 #if LJ_TARGET_OSX
 /* Runtime code generation is restricted on iOS. Complain to Apple, not me. */
 #define LJ_ARCH_NOJIT		1
@@ -147,7 +152,17 @@
 
 #elif LUAJIT_TARGET == LUAJIT_ARCH_PPC
 
-#error "No support for plain PowerPC CPUs (yet)"
+#define LJ_ARCH_NAME		"ppc"
+#define LJ_ARCH_BITS		32
+#define LJ_ARCH_ENDIAN		LUAJIT_BE
+#define LJ_ARCH_HASFPU		1
+#define LJ_TARGET_PPC		1
+#define LJ_TARGET_EHRETREG	3
+#define LJ_TARGET_JUMPRANGE	25	/* +-2^25 = +-32MB */
+#define LJ_TARGET_MASKSHIFT	0
+#define LJ_TARGET_MASKROT	1
+#define LJ_TARGET_UNIFYROT	1	/* Want only IR_BROL. */
+#define LJ_ARCH_NUMMODE		LJ_NUMMODE_DUAL_SINGLE
 
 #elif LUAJIT_TARGET == LUAJIT_ARCH_PPCSPE
 
@@ -157,14 +172,13 @@
 #define LJ_ARCH_HASFPU		1
 #define LJ_ABI_SOFTFP		1
 #define LJ_ABI_EABI		1
-#define LJ_TARGET_PPC		1
 #define LJ_TARGET_PPCSPE	1
 #define LJ_TARGET_EHRETREG	3
 #define LJ_TARGET_JUMPRANGE	25	/* +-2^25 = +-32MB */
 #define LJ_TARGET_MASKSHIFT	0
 #define LJ_TARGET_MASKROT	1
 #define LJ_TARGET_UNIFYROT	1	/* Want only IR_BROL. */
-#define LJ_ARCH_DUALNUM		0
+#define LJ_ARCH_NUMMODE		LJ_NUMMODE_SINGLE
 #define LJ_ARCH_NOFFI		1	/* NYI: comparisons, calls. */
 #define LJ_ARCH_NOJIT		1
 
@@ -203,10 +217,13 @@
 #if defined(__ARMEB__)
 #error "No support for big-endian ARM"
 #endif
+#if defined(__ARM_PCS_VFP)
+#error "No support for ARM hard-float ABI (yet)"
+#endif
 #if !(__ARM_EABI__ || LJ_TARGET_OSX)
 #error "Only ARM EABI or iOS 3.0+ ABI is supported"
 #endif
-#elif LJ_TARGET_PPC
+#elif LJ_TARGET_PPC || LJ_TARGET_PPCSPE
 #if defined(_SOFT_FLOAT) || defined(_SOFT_DOUBLE)
 #error "No support for PowerPC CPUs without double-precision FPU"
 #endif
@@ -219,9 +236,14 @@
 #endif
 #endif
 
-/* Enable or disable the dual-number VM. */
-#if LJ_ARCH_DUALNUM == 2 || \
-    (defined(LUAJIT_ENABLE_DUALNUM) && LJ_ARCH_DUALNUM == 1)
+/* Enable or disable the dual-number mode for the VM. */
+#if (LJ_ARCH_NUMMODE == LJ_NUMMODE_SINGLE && LUAJIT_NUMMODE == 2) || \
+    (LJ_ARCH_NUMMODE == LJ_NUMMODE_DUAL && LUAJIT_NUMMODE == 1)
+#error "No support for this number mode on this architecture"
+#endif
+#if LJ_ARCH_NUMMODE == LJ_NUMMODE_DUAL || \
+    (LJ_ARCH_NUMMODE == LJ_NUMMODE_DUAL_SINGLE && LUAJIT_NUMMODE != 1) || \
+    (LJ_ARCH_NUMMODE == LJ_NUMMODE_SINGLE_DUAL && LUAJIT_NUMMODE == 2)
 #define LJ_DUALNUM		1
 #else
 #define LJ_DUALNUM		0
@@ -263,4 +285,16 @@
 #define LJ_64			1
 #endif
 
+/* Various workarounds for embedded operating systems. */
+#if defined(__ANDROID__) || defined(__symbian__)
+#define LUAJIT_NO_LOG2
+#endif
+#if defined(__symbian__)
+#define LUAJIT_NO_EXP2
+#endif
+
+#if defined(__symbian__) || (LJ_TARGET_ARM && LJ_TARGET_OSX)
+#define LUAJIT_NO_UNWIND
+#endif
+
 #endif
diff --git a/third_party/luajit/src/lj_asm.c b/third_party/luajit/src/lj_asm.c
index b3fa7739793f786f507fffb0da8043abab223575..1103e99854aaedecf341158481c63e572f0ce2f4 100644
--- a/third_party/luajit/src/lj_asm.c
+++ b/third_party/luajit/src/lj_asm.c
@@ -147,20 +147,14 @@ IRFLDEF(FLOFS)
   0
 };
 
-/* Define this if you want to run LuaJIT with Valgrind. */
-#ifdef LUAJIT_USE_VALGRIND
-#include <valgrind/valgrind.h>
-#define VG_INVALIDATE(p, sz)	VALGRIND_DISCARD_TRANSLATIONS(p, sz)
-#else
-#define VG_INVALIDATE(p, sz)	((void)0)
-#endif
-
 /* -- Target-specific instruction emitter --------------------------------- */
 
 #if LJ_TARGET_X86ORX64
 #include "lj_emit_x86.h"
 #elif LJ_TARGET_ARM
 #include "lj_emit_arm.h"
+#elif LJ_TARGET_PPC
+#include "lj_emit_ppc.h"
 #else
 #error "Missing instruction emitter for target CPU"
 #endif
@@ -460,11 +454,24 @@ static void ra_evictset(ASMState *as, RegSet drop)
 /* Evict (rematerialize) all registers allocated to constants. */
 static void ra_evictk(ASMState *as)
 {
-  RegSet work = ~as->freeset & RSET_ALL;
+  RegSet work;
+#if !LJ_SOFTFP
+  work = ~as->freeset & RSET_FPR;
+  while (work) {
+    Reg r = rset_pickbot(work);
+    IRRef ref = regcost_ref(as->cost[r]);
+    if (emit_canremat(ref) && irref_isk(ref)) {
+      ra_rematk(as, ref);
+      checkmclim(as);
+    }
+    rset_clear(work, r);
+  }
+#endif
+  work = ~as->freeset & RSET_GPR;
   while (work) {
     Reg r = rset_pickbot(work);
     IRRef ref = regcost_ref(as->cost[r]);
-    if (irref_isk(ref)) {
+    if (emit_canremat(ref) && irref_isk(ref)) {
       ra_rematk(as, ref);
       checkmclim(as);
     }
@@ -483,7 +490,7 @@ static Reg ra_allock(ASMState *as, int32_t k, RegSet allow)
     IRRef ref;
     r = rset_pickbot(work);
     ref = regcost_ref(as->cost[r]);
-    if (emit_canremat(ref) &&
+    if (ref < ASMREF_L &&
 	k == (ra_iskref(ref) ? ra_krefk(as, ref) : IR(ref)->i))
       return r;
     rset_clear(work, r);
@@ -610,7 +617,7 @@ static Reg ra_dest(ASMState *as, IRIns *ir, RegSet allow)
     ra_free(as, dest);
     ra_modified(as, dest);
   } else {
-    if (ra_hashint(dest) && rset_test(as->freeset, ra_gethint(dest))) {
+    if (ra_hashint(dest) && rset_test((as->freeset&allow), ra_gethint(dest))) {
       dest = ra_gethint(dest);
       ra_modified(as, dest);
       RA_DBGX((as, "dest           $r", dest));
@@ -678,6 +685,76 @@ static void ra_left(ASMState *as, Reg dest, IRRef lref)
     }
   }
 }
+#else
+/* Similar to ra_left, except we override any hints. */
+static void ra_leftov(ASMState *as, Reg dest, IRRef lref)
+{
+  IRIns *ir = IR(lref);
+  Reg left = ir->r;
+  if (ra_noreg(left)) {
+    ra_sethint(ir->r, dest);  /* Propagate register hint. */
+    left = ra_allocref(as, lref,
+		       (LJ_SOFTFP || dest < RID_MAX_GPR) ? RSET_GPR : RSET_FPR);
+  }
+  ra_noweak(as, left);
+  if (dest != left) {
+    /* Use register renaming if dest is the PHI reg. */
+    if (irt_isphi(ir->t) && as->phireg[dest] == lref) {
+      ra_modified(as, left);
+      ra_rename(as, left, dest);
+    } else {
+      emit_movrr(as, ir, dest, left);
+    }
+  }
+}
+#endif
+
+#if !LJ_TARGET_X86ORX64
+/* Force a RID_RETLO/RID_RETHI destination register pair (marked as free). */
+static void ra_destpair(ASMState *as, IRIns *ir)
+{
+  Reg destlo = ir->r, desthi = (ir+1)->r;
+  /* First spill unrelated refs blocking the destination registers. */
+  if (!rset_test(as->freeset, RID_RETLO) &&
+      destlo != RID_RETLO && desthi != RID_RETLO)
+    ra_restore(as, regcost_ref(as->cost[RID_RETLO]));
+  if (!rset_test(as->freeset, RID_RETHI) &&
+      destlo != RID_RETHI && desthi != RID_RETHI)
+    ra_restore(as, regcost_ref(as->cost[RID_RETHI]));
+  /* Next free the destination registers (if any). */
+  if (ra_hasreg(destlo)) {
+    ra_free(as, destlo);
+    ra_modified(as, destlo);
+  } else {
+    destlo = RID_RETLO;
+  }
+  if (ra_hasreg(desthi)) {
+    ra_free(as, desthi);
+    ra_modified(as, desthi);
+  } else {
+    desthi = RID_RETHI;
+  }
+  /* Check for conflicts and shuffle the registers as needed. */
+  if (destlo == RID_RETHI) {
+    if (desthi == RID_RETLO) {
+      emit_movrr(as, ir, RID_RETHI, RID_TMP);
+      emit_movrr(as, ir, RID_RETLO, RID_RETHI);
+      emit_movrr(as, ir, RID_TMP, RID_RETLO);
+    } else {
+      emit_movrr(as, ir, RID_RETHI, RID_RETLO);
+      if (desthi != RID_RETHI) emit_movrr(as, ir, desthi, RID_RETHI);
+    }
+  } else if (desthi == RID_RETLO) {
+    emit_movrr(as, ir, RID_RETLO, RID_RETHI);
+    if (destlo != RID_RETLO) emit_movrr(as, ir, destlo, RID_RETLO);
+  } else {
+    if (desthi != RID_RETHI) emit_movrr(as, ir, desthi, RID_RETHI);
+    if (destlo != RID_RETLO) emit_movrr(as, ir, destlo, RID_RETLO);
+  }
+  /* Restore spill slots (if any). */
+  if (ra_hasspill((ir+1)->s)) ra_save(as, ir+1, RID_RETHI);
+  if (ra_hasspill(ir->s)) ra_save(as, ir, RID_RETLO);
+}
 #endif
 
 /* -- Snapshot handling --------- ----------------------------------------- */
@@ -724,8 +801,10 @@ static void asm_snap_alloc(ASMState *as)
     IRRef ref = snap_ref(sn);
     if (!irref_isk(ref)) {
       asm_snap_alloc1(as, ref);
-      if (LJ_SOFTFP && (sn & SNAP_SOFTFPNUM))
+      if (LJ_SOFTFP && (sn & SNAP_SOFTFPNUM)) {
+	lua_assert(irt_type(IR(ref+1)->t) == IRT_SOFTFP);
 	asm_snap_alloc1(as, ref+1);
+      }
     }
   }
 }
@@ -803,32 +882,17 @@ static uint32_t asm_callx_flags(ASMState *as, IRIns *ir)
     nargs++;
     while (ira->o == IR_CARG) { nargs++; ira = IR(ira->op1); }
   }
-  /* NYI: fastcall etc. */
-  return (nargs | (ir->t.irt << CCI_OTSHIFT));
-}
-
-/* Get extent of the stack for a snapshot. */
-static BCReg asm_stack_extent(ASMState *as, SnapShot *snap, BCReg *ptopslot)
-{
-  SnapEntry *map = &as->T->snapmap[snap->mapofs];
-  MSize n, nent = snap->nent;
-  BCReg baseslot = 0, topslot = 0;
-  /* Must check all frames to find topslot (outer can be larger than inner). */
-  for (n = 0; n < nent; n++) {
-    SnapEntry sn = map[n];
-    if ((sn & SNAP_FRAME)) {
-      IRIns *ir = IR(snap_ref(sn));
-      GCfunc *fn = ir_kfunc(ir);
-      if (isluafunc(fn)) {
-	BCReg s = snap_slot(sn);
-	BCReg fs = s + funcproto(fn)->framesize;
-	if (fs > topslot) topslot = fs;
-	baseslot = s;
-      }
-    }
+#if LJ_HASFFI
+  if (IR(ir->op2)->o == IR_CARG) {  /* Copy calling convention info. */
+    CTypeID id = (CTypeID)IR(IR(ir->op2)->op2)->i;
+    CType *ct = ctype_get(ctype_ctsG(J2G(as->J)), id);
+    nargs |= ((ct->info & CTF_VARARG) ? CCI_VARARG : 0);
+#if LJ_TARGET_X86
+    nargs |= (ctype_cconv(ct->info) << CCI_CC_SHIFT);
+#endif
   }
-  *ptopslot = topslot;
-  return baseslot;
+#endif
+  return (nargs | (ir->t.irt << CCI_OTSHIFT));
 }
 
 /* Calculate stack adjustment. */
@@ -859,21 +923,6 @@ static uint32_t ir_khash(IRIns *ir)
   return hashrot(lo, hi);
 }
 
-/* Flush instruction cache. */
-static void asm_cache_flush(MCode *start, MCode *end)
-{
-  VG_INVALIDATE(start, (char *)end-(char *)start);
-#if LJ_TARGET_X86ORX64
-  UNUSED(start); UNUSED(end);
-#else
-#if defined(__GNUC__)
-  __clear_cache(start, end);
-#else
-#error "Missing builtin to flush instruction cache"
-#endif
-#endif
-}
-
 /* -- Allocations --------------------------------------------------------- */
 
 static void asm_gencall(ASMState *as, const CCallInfo *ci, IRRef *args);
@@ -1102,8 +1151,10 @@ static void asm_loop(ASMState *as)
 #include "lj_asm_x86.h"
 #elif LJ_TARGET_ARM
 #include "lj_asm_arm.h"
+#elif LJ_TARGET_PPC
+#include "lj_asm_ppc.h"
 #else
-#error "Missing instruction emitter for target CPU"
+#error "Missing assembler for target CPU"
 #endif
 
 /* -- Head of trace ------------------------------------------------------- */
@@ -1283,25 +1334,48 @@ static void asm_head_side(ASMState *as)
   /* Inherit top stack slot already checked by parent trace. */
   as->T->topslot = as->parent->topslot;
   if (as->topslot > as->T->topslot) {  /* Need to check for higher slot? */
-    as->T->topslot = (uint8_t)as->topslot;  /* Remember for child traces. */
+#ifdef EXITSTATE_CHECKEXIT
+    /* Highest exit + 1 indicates stack check. */
+    ExitNo exitno = as->T->nsnap;
+#else
     /* Reuse the parent exit in the context of the parent trace. */
-    asm_stack_check(as, as->topslot, irp, allow & RSET_GPR, as->J->exitno);
+    ExitNo exitno = as->J->exitno;
+#endif
+    as->T->topslot = (uint8_t)as->topslot;  /* Remember for child traces. */
+    asm_stack_check(as, as->topslot, irp, allow & RSET_GPR, exitno);
   }
 }
 
 /* -- Tail of trace ------------------------------------------------------- */
 
+/* Get base slot for a snapshot. */
+static BCReg asm_baseslot(ASMState *as, SnapShot *snap, int *gotframe)
+{
+  SnapEntry *map = &as->T->snapmap[snap->mapofs];
+  MSize n;
+  for (n = snap->nent; n > 0; n--) {
+    SnapEntry sn = map[n-1];
+    if ((sn & SNAP_FRAME)) {
+      *gotframe = 1;
+      return snap_slot(sn);
+    }
+  }
+  return 0;
+}
+
 /* Link to another trace. */
 static void asm_tail_link(ASMState *as)
 {
   SnapNo snapno = as->T->nsnap-1;  /* Last snapshot. */
   SnapShot *snap = &as->T->snap[snapno];
-  BCReg baseslot = asm_stack_extent(as, snap, &as->topslot);
+  int gotframe = 0;
+  BCReg baseslot = asm_baseslot(as, snap, &gotframe);
 
+  as->topslot = snap->topslot;
   checkmclim(as);
   ra_allocref(as, REF_BASE, RID2RSET(RID_BASE));
 
-  if (as->T->link == TRACE_INTERP) {
+  if (as->T->link == 0) {
     /* Setup fixed registers for exit to interpreter. */
     const BCIns *pc = snap_pc(as->T->snapmap[snap->mapofs + snap->nent]);
     int32_t mres;
@@ -1330,8 +1404,8 @@ static void asm_tail_link(ASMState *as)
   /* Sync the interpreter state with the on-trace state. */
   asm_stack_restore(as, snap);
 
-  /* Root traces that grow the stack need to check the stack at the end. */
-  if (!as->parent && as->topslot)
+  /* Root traces that add frames need to check the stack at the end. */
+  if (!as->parent && gotframe)
     asm_stack_check(as, as->topslot, NULL, as->freeset & RSET_GPR, snapno);
 }
 
@@ -1441,10 +1515,21 @@ static void asm_setup_regsp(ASMState *as)
 	}
 #endif
 	break;
+#endif
+#if LJ_NEED_FP64
+      case IR_CONV:
+	if (irt_isfp((ir-1)->t)) {
+	  ir->prev = REGSP_HINT(RID_FPRET);
+	  continue;
+	}
+	/* fallthrough */
 #endif
       case IR_CALLN: case IR_CALLXS:
 #if LJ_SOFTFP
       case IR_MIN: case IR_MAX:
+#endif
+#if LJ_BE
+	(ir-1)->prev = REGSP_HINT(RID_RETLO);
 #endif
 	ir->prev = REGSP_HINT(RID_RETHI);
 	continue;
@@ -1471,6 +1556,9 @@ static void asm_setup_regsp(ASMState *as)
       if (inloop)
 	as->modset = RSET_SCRATCH;
       break;
+#if !LJ_TARGET_X86ORX64 && !LJ_SOFTFP
+    case IR_ATAN2: case IR_LDEXP:
+#endif
     case IR_POW:
       if (!LJ_SOFTFP && irt_isnum(ir->t)) {
 #if LJ_TARGET_X86ORX64
@@ -1486,14 +1574,12 @@ static void asm_setup_regsp(ASMState *as)
       }
       /* fallthrough for integer POW */
     case IR_DIV: case IR_MOD:
-#if LJ_64 && LJ_HASFFI
       if (!irt_isnum(ir->t)) {
 	ir->prev = REGSP_HINT(RID_RET);
 	if (inloop)
 	  as->modset |= (RSET_SCRATCH & RSET_GPR);
 	continue;
       }
-#endif
       break;
     case IR_FPMATH:
 #if LJ_TARGET_X86ORX64
@@ -1560,6 +1646,7 @@ void lj_asm_trace(jit_State *J, GCtrace *T)
 {
   ASMState as_;
   ASMState *as = &as_;
+  MCode *origtop;
 
   /* Ensure an initialized instruction beyond the last one for HIOP checks. */
   J->cur.nins = lj_ir_nextins(J);
@@ -1582,7 +1669,8 @@ void lj_asm_trace(jit_State *J, GCtrace *T)
   } else {
     as->parent = NULL;
   }
-  as->mctop = lj_mcode_reserve(J, &as->mcbot);  /* Reserve MCode memory. */
+  /* Reserve MCode memory. */
+  as->mctop = origtop = lj_mcode_reserve(J, &as->mcbot);
   as->mcp = as->mctop;
   as->mclim = as->mcbot + MCLIM_REDZONE;
   asm_setup_target(as);
@@ -1645,7 +1733,7 @@ void lj_asm_trace(jit_State *J, GCtrace *T)
   if (!as->loopref)
     asm_tail_fixup(as, T->link);  /* Note: this may change as->mctop! */
   T->szmcode = (MSize)((char *)as->mctop - (char *)as->mcp);
-  asm_cache_flush(T->mcode, as->mctop);
+  lj_mcode_sync(T->mcode, origtop);
 }
 
 #undef IR
diff --git a/third_party/luajit/src/lj_asm_arm.h b/third_party/luajit/src/lj_asm_arm.h
index 31b300bf726107b2dfdabadcad917f2f998467ea..087fc0fb2bd0def083d80f412aba97e5a31eaacf 100644
--- a/third_party/luajit/src/lj_asm_arm.h
+++ b/third_party/luajit/src/lj_asm_arm.h
@@ -18,27 +18,6 @@ static Reg ra_hintalloc(ASMState *as, IRRef ref, Reg hint, RegSet allow)
   return r;
 }
 
-/* Similar to ra_left, except we override any hints. */
-static void ra_leftov(ASMState *as, Reg dest, IRRef lref)
-{
-  IRIns *ir = IR(lref);
-  Reg left = ir->r;
-  if (ra_noreg(left)) {
-    ra_sethint(ir->r, dest);  /* Propagate register hint. */
-    left = ra_allocref(as, lref, RSET_GPR);
-  }
-  ra_noweak(as, left);
-  if (dest != left) {
-    /* Use register renaming if dest is the PHI reg. */
-    if (irt_isphi(ir->t) && as->phireg[dest] == lref) {
-      ra_modified(as, left);
-      ra_rename(as, left, dest);
-    } else {
-      emit_movrr(as, ir, dest, left);
-    }
-  }
-}
-
 /* Allocate a scratch register pair. */
 static Reg ra_scratchpair(ASMState *as, RegSet allow)
 {
@@ -69,52 +48,6 @@ static Reg ra_scratchpair(ASMState *as, RegSet allow)
   return r;
 }
 
-/* Force a RID_RET/RID_RETHI destination register pair (marked as free). */
-static void ra_destpair(ASMState *as, IRIns *ir)
-{
-  Reg destlo = ir->r, desthi = (ir+1)->r;
-  /* First spill unrelated refs blocking the destination registers. */
-  if (!rset_test(as->freeset, RID_RET) &&
-      destlo != RID_RET && desthi != RID_RET)
-    ra_restore(as, regcost_ref(as->cost[RID_RET]));
-  if (!rset_test(as->freeset, RID_RETHI) &&
-      destlo != RID_RETHI && desthi != RID_RETHI)
-    ra_restore(as, regcost_ref(as->cost[RID_RETHI]));
-  /* Next free the destination registers (if any). */
-  if (ra_hasreg(destlo)) {
-    ra_free(as, destlo);
-    ra_modified(as, destlo);
-  } else {
-    destlo = RID_RET;
-  }
-  if (ra_hasreg(desthi)) {
-    ra_free(as, desthi);
-    ra_modified(as, desthi);
-  } else {
-    desthi = RID_RETHI;
-  }
-  /* Check for conflicts and shuffle the registers as needed. */
-  if (destlo == RID_RETHI) {
-    if (desthi == RID_RET) {
-      emit_movrr(as, ir, RID_RETHI, RID_TMP);
-      emit_movrr(as, ir, RID_RET, RID_RETHI);
-      emit_movrr(as, ir, RID_TMP, RID_RET);
-    } else {
-      emit_movrr(as, ir, RID_RETHI, RID_RET);
-      if (desthi != RID_RETHI) emit_movrr(as, ir, desthi, RID_RETHI);
-    }
-  } else if (desthi == RID_RET) {
-    emit_movrr(as, ir, RID_RET, RID_RETHI);
-    if (destlo != RID_RET) emit_movrr(as, ir, destlo, RID_RET);
-  } else {
-    if (desthi != RID_RETHI) emit_movrr(as, ir, desthi, RID_RETHI);
-    if (destlo != RID_RET) emit_movrr(as, ir, destlo, RID_RET);
-  }
-  /* Restore spill slots (if any). */
-  if (ra_hasspill((ir+1)->s)) ra_save(as, ir+1, RID_RETHI);
-  if (ra_hasspill(ir->s)) ra_save(as, ir, RID_RET);
-}
-
 /* -- Guard handling ------------------------------------------------------ */
 
 /* Generate an exit stub group at the bottom of the reserved MCode memory. */
@@ -186,7 +119,7 @@ static int32_t asm_fuseabase(ASMState *as, IRRef ref)
 {
   IRIns *ir = IR(ref);
   if (ir->o == IR_TNEW && ir->op1 <= LJ_MAX_COLOSIZE &&
-      noconflict(as, ref, IR_NEWREF))
+      !neverfuse(as) && noconflict(as, ref, IR_NEWREF))
     return (int32_t)sizeof(GCtab);
   return 0;
 }
@@ -398,13 +331,17 @@ static void asm_callx(ASMState *as, IRIns *ir)
 {
   IRRef args[CCI_NARGS_MAX];
   CCallInfo ci;
+  IRRef func;
+  IRIns *irf;
   ci.flags = asm_callx_flags(as, ir);
   asm_collectargs(as, ir, &ci, args);
   asm_setupresult(as, ir, &ci);
-  if (irref_isk(ir->op2)) {  /* Call to constant address. */
-    ci.func = (ASMFunction)(void *)(IR(ir->op2)->i);
+  func = ir->op2; irf = IR(func);
+  if (irf->o == IR_CARG) { func = irf->op1; irf = IR(func); }
+  if (irref_isk(func)) {  /* Call to constant address. */
+    ci.func = (ASMFunction)(void *)(irf->i);
   } else {  /* Need a non-argument register for indirect calls. */
-    Reg freg = ra_alloc1(as, ir->op2, RSET_RANGE(RID_R4, RID_R12+1));
+    Reg freg = ra_alloc1(as, func, RSET_RANGE(RID_R4, RID_R12+1));
     emit_m(as, ARMI_BLXr, freg);
     ci.func = (ASMFunction)(void *)0;
   }
@@ -583,7 +520,7 @@ static void asm_href(ASMState *as, IRIns *ir, IROp merge)
   int destused = ra_used(ir);
   Reg dest = ra_dest(as, ir, allow);
   Reg tab = ra_alloc1(as, ir->op1, rset_clear(allow, dest));
-  Reg key = 0, keyhi = 0, keynumhi = RID_NONE, tmp = RID_LR;
+  Reg key = 0, keyhi = 0, keynumhi = RID_NONE, tmp = RID_TMP;
   IRRef refkey = ir->op2;
   IRIns *irkey = IR(refkey);
   IRType1 kt = irkey->t;
@@ -737,7 +674,7 @@ static void asm_hrefk(ASMState *as, IRIns *ir)
 	     (int32_t)ir_knum(irkey)->u32.hi, allow);
     emit_opk(as, ARMI_CMP, 0, key,
 	     (int32_t)ir_knum(irkey)->u32.lo, allow);
-  } if (ra_hasreg(key)) {
+  } else if (ra_hasreg(key)) {
     emit_n(as, ARMF_CC(ARMI_CMN, CC_EQ)|ARMI_K12|-irt_toitype(irkey->t), type);
     emit_opk(as, ARMI_CMP, 0, key, irkey->i, allow);
   } else {
@@ -914,7 +851,7 @@ static void asm_ahuvload(ASMState *as, IRIns *ir)
     rset_clear(allow, dest);
   }
   idx = asm_fuseahuref(as, ir->op1, &ofs, allow);
-  if (!hiop) {
+  if (!hiop || type == RID_NONE) {
     rset_clear(allow, idx);
     if (ofs < 256 && ra_hasreg(dest) && (dest & 1) == 0 &&
 	rset_test((as->freeset & allow), dest+1)) {
@@ -999,12 +936,18 @@ static void asm_cnew(ASMState *as, IRIns *ir)
   const CCallInfo *ci = &lj_ir_callinfo[IRCALL_lj_mem_newgco];
   IRRef args[2];
   RegSet allow = (RSET_GPR & ~RSET_SCRATCH);
+  RegSet drop = RSET_SCRATCH;
   lua_assert(sz != CTSIZE_INVALID);
 
   args[0] = ASMREF_L;     /* lua_State *L */
   args[1] = ASMREF_TMP1;  /* MSize size   */
   as->gcsteps++;
-  asm_setupresult(as, ir, ci);  /* GCcdata * */
+
+  if (ra_hasreg(ir->r))
+    rset_clear(drop, ir->r);  /* Dest reg handled below. */
+  ra_evictset(as, drop);
+  if (ra_used(ir))
+    ra_destreg(as, ir, RID_RET);  /* GCcdata * */
 
   /* Initialize immutable cdata object. */
   if (ir->o == IR_CNEWI) {
@@ -1280,7 +1223,7 @@ static void asm_fpmin_max(ASMState *as, IRIns *ir, int cc)
   ra_evictset(as, drop);
   ra_destpair(as, ir);
   emit_dm(as, ARMF_CC(ARMI_MOV, cc), RID_RETHI, RID_R3);
-  emit_dm(as, ARMF_CC(ARMI_MOV, cc), RID_RET, RID_R2);
+  emit_dm(as, ARMF_CC(ARMI_MOV, cc), RID_RETLO, RID_R2);
   emit_call(as, (void *)ci->func);
   for (r = RID_R0; r <= RID_R3; r++)
     ra_leftov(as, r, args[r-RID_R0]);
@@ -1427,42 +1370,28 @@ static void asm_hiop(ASMState *as, IRIns *ir)
       asm_fpcomp(as, ir-1);
     return;
   } else if ((ir-1)->o == IR_MIN || (ir-1)->o == IR_MAX) {
-    if (uselo || usehi || !(as->flags & JIT_F_OPT_DCE)) {
-      as->curins--;  /* Always skip the loword min/max. */
+    as->curins--;  /* Always skip the loword min/max. */
+    if (uselo || usehi)
       asm_fpmin_max(as, ir-1, (ir-1)->o == IR_MIN ? CC_HI : CC_LO);
-    }
     return;
   }
-  if (!usehi && (as->flags & JIT_F_OPT_DCE))
-    return;  /* Skip unused hiword op for all remaining ops. */
+  if (!usehi) return;  /* Skip unused hiword op for all remaining ops. */
   switch ((ir-1)->o) {
 #if LJ_HASFFI
   case IR_ADD:
-    if (uselo) {
-      as->curins--;
-      asm_intop(as, ir, ARMI_ADC);
-      asm_intop(as, ir-1, ARMI_ADD|ARMI_S);
-    } else {
-      asm_intop(as, ir, ARMI_ADD);
-    }
+    as->curins--;
+    asm_intop(as, ir, ARMI_ADC);
+    asm_intop(as, ir-1, ARMI_ADD|ARMI_S);
     break;
   case IR_SUB:
-    if (uselo) {
-      as->curins--;
-      asm_intop(as, ir, ARMI_SBC);
-      asm_intop(as, ir-1, ARMI_SUB|ARMI_S);
-    } else {
-      asm_intop(as, ir, ARMI_SUB);
-    }
+    as->curins--;
+    asm_intop(as, ir, ARMI_SBC);
+    asm_intop(as, ir-1, ARMI_SUB|ARMI_S);
     break;
   case IR_NEG:
-    if (uselo) {
-      as->curins--;
-      asm_intneg(as, ir, ARMI_RSC);
-      asm_intneg(as, ir-1, ARMI_RSB|ARMI_S);
-    } else {
-      asm_intneg(as, ir, ARMI_RSB);
-    }
+    as->curins--;
+    asm_intneg(as, ir, ARMI_RSC);
+    asm_intneg(as, ir-1, ARMI_RSB|ARMI_S);
     break;
 #endif
   case IR_SLOAD: case IR_ALOAD: case IR_HLOAD: case IR_ULOAD: case IR_VLOAD:
@@ -1474,7 +1403,7 @@ static void asm_hiop(ASMState *as, IRIns *ir)
   case IR_CALLS:
   case IR_CALLXS:
     if (!uselo)
-      ra_allocref(as, ir->op1, RID2RSET(RID_RET));  /* Mark lo op as used. */
+      ra_allocref(as, ir->op1, RID2RSET(RID_RETLO));  /* Mark lo op as used. */
     break;
   case IR_ASTORE: case IR_HSTORE: case IR_USTORE:
   case IR_TOSTR: case IR_CNEWI:
@@ -1493,9 +1422,9 @@ static void asm_stack_check(ASMState *as, BCReg topslot,
   Reg pbase;
   uint32_t k;
   if (irp) {
-    exitno = as->T->nsnap;  /* Highest exit + 1 indicates stack check. */
-    if (ra_hasreg(irp->r)) {
+    if (!ra_hasspill(irp->s)) {
       pbase = irp->r;
+      lua_assert(ra_hasreg(pbase));
     } else if (allow) {
       pbase = rset_pickbot(allow);
     } else {
@@ -1514,14 +1443,11 @@ static void asm_stack_check(ASMState *as, BCReg topslot,
 	   (int32_t)offsetof(lua_State, maxstack));
   if (irp) {  /* Must not spill arbitrary registers in head of side trace. */
     int32_t i = i32ptr(&J2G(as->J)->jit_L);
-    if (ra_noreg(irp->r)) {
-      lua_assert(ra_hasspill(irp->s));
-      emit_lso(as, ARMI_LDR, RID_RET, RID_SP, sps_scale(irp->s));
-    }
+    if (ra_hasspill(irp->s))
+      emit_lso(as, ARMI_LDR, pbase, RID_SP, sps_scale(irp->s));
     emit_lso(as, ARMI_LDR, RID_TMP, RID_TMP, (i & 4095));
-    if (ra_noreg(irp->r)) {
+    if (ra_hasspill(irp->s) && !allow)
       emit_lso(as, ARMI_STR, RID_RET, RID_SP, 0);  /* Save temp. register. */
-    }
     emit_loadi(as, RID_TMP, (i & ~4095));
   } else {
     emit_getgl(as, RID_TMP, jit_L);
@@ -1532,8 +1458,8 @@ static void asm_stack_check(ASMState *as, BCReg topslot,
 static void asm_stack_restore(ASMState *as, SnapShot *snap)
 {
   SnapEntry *map = &as->T->snapmap[snap->mapofs];
+  SnapEntry *flinks = &as->T->snapmap[snap_nextofs(as->T, snap)-1];
   MSize n, nent = snap->nent;
-  SnapEntry *flinks = map + nent + snap->depth;
   /* Store the value of all modified slots to the Lua stack. */
   for (n = 0; n < nent; n++) {
     SnapEntry sn = map[n];
@@ -1681,8 +1607,7 @@ static void asm_tail_fixup(ASMState *as, TraceNo lnk)
     p[-2] = (ARMI_ADD^k) | ARMF_D(RID_SP) | ARMF_N(RID_SP);
   }
   /* Patch exit branch. */
-  target = lnk == TRACE_INTERP ? (MCode *)lj_vm_exit_interp :
-				 traceref(as->J, lnk)->mcode;
+  target = lnk ? traceref(as->J, lnk)->mcode : (MCode *)lj_vm_exit_interp;
   p[-1] = ARMI_B|(((target-p)-1)&0x00ffffffu);
 }
 
@@ -1816,7 +1741,7 @@ static Reg asm_setup_call_slots(ASMState *as, IRIns *ir, const CCallInfo *ci)
   int nslots = 0, ngpr = REGARG_NUMGPR;
   asm_collectargs(as, ir, ci, args);
   for (i = 0; i < nargs; i++)
-    if (!LJ_SOFTFP && irt_isfp(IR(args[i])->t)) {
+    if (!LJ_SOFTFP && args[i] && irt_isnum(IR(args[i])->t)) {
       ngpr &= ~1;
       if (ngpr > 0) ngpr -= 2; else nslots += 2;
     } else {
@@ -1854,7 +1779,7 @@ void lj_asm_patchexit(jit_State *J, GCtrace *T, ExitNo exitno, MCode *target)
     }
   }
   lua_assert(cstart != NULL);
-  asm_cache_flush(cstart, cend);
+  lj_mcode_sync(cstart, cend);
   lj_mcode_patch(J, mcarea, 1);
 }
 
diff --git a/third_party/luajit/src/lj_asm_ppc.h b/third_party/luajit/src/lj_asm_ppc.h
new file mode 100644
index 0000000000000000000000000000000000000000..f3f9e2e0beb28fb9501854c1aae2210a747cac6c
--- /dev/null
+++ b/third_party/luajit/src/lj_asm_ppc.h
@@ -0,0 +1,2143 @@
+/*
+** PPC IR assembler (SSA IR -> machine code).
+** Copyright (C) 2005-2011 Mike Pall. See Copyright Notice in luajit.h
+*/
+
+/* -- Register allocator extensions --------------------------------------- */
+
+/* Allocate a register with a hint. */
+static Reg ra_hintalloc(ASMState *as, IRRef ref, Reg hint, RegSet allow)
+{
+  Reg r = IR(ref)->r;
+  if (ra_noreg(r)) {
+    if (!ra_hashint(r) && !iscrossref(as, ref))
+      ra_sethint(IR(ref)->r, hint);  /* Propagate register hint. */
+    r = ra_allocref(as, ref, allow);
+  }
+  ra_noweak(as, r);
+  return r;
+}
+
+/* Allocate two source registers for three-operand instructions. */
+static Reg ra_alloc2(ASMState *as, IRIns *ir, RegSet allow)
+{
+  IRIns *irl = IR(ir->op1), *irr = IR(ir->op2);
+  Reg left = irl->r, right = irr->r;
+  if (ra_hasreg(left)) {
+    ra_noweak(as, left);
+    if (ra_noreg(right))
+      right = ra_allocref(as, ir->op2, rset_exclude(allow, left));
+    else
+      ra_noweak(as, right);
+  } else if (ra_hasreg(right)) {
+    ra_noweak(as, right);
+    left = ra_allocref(as, ir->op1, rset_exclude(allow, right));
+  } else if (ra_hashint(right)) {
+    right = ra_allocref(as, ir->op2, allow);
+    left = ra_alloc1(as, ir->op1, rset_exclude(allow, right));
+  } else {
+    left = ra_allocref(as, ir->op1, allow);
+    right = ra_alloc1(as, ir->op2, rset_exclude(allow, left));
+  }
+  return left | (right << 8);
+}
+
+/* -- Guard handling ------------------------------------------------------ */
+
+/* Setup exit stubs after the end of each trace. */
+static void asm_exitstub_setup(ASMState *as, ExitNo nexits)
+{
+  ExitNo i;
+  MCode *mxp = as->mctop;
+  /* 1: mflr r0; bl ->vm_exit_handler; li r0, traceno; bl <1; bl <1; ... */
+  for (i = nexits-1; (int32_t)i >= 0; i--)
+    *--mxp = PPCI_BL|(((-3-i)&0x00ffffffu)<<2);
+  *--mxp = PPCI_LI|PPCF_T(RID_TMP)|as->T->traceno;  /* Read by exit handler. */
+  mxp--;
+  *mxp = PPCI_BL|((((MCode *)(void *)lj_vm_exit_handler-mxp)&0x00ffffffu)<<2);
+  *--mxp = PPCI_MFLR|PPCF_T(RID_TMP);
+  as->mctop = mxp;
+}
+
+static MCode *asm_exitstub_addr(ASMState *as, ExitNo exitno)
+{
+  /* Keep this in-sync with exitstub_trace_addr(). */
+  return as->mctop + exitno + 3;
+}
+
+/* Emit conditional branch to exit for guard. */
+static void asm_guardcc(ASMState *as, PPCCC cc)
+{
+  MCode *target = asm_exitstub_addr(as, as->snapno);
+  MCode *p = as->mcp;
+  if (LJ_UNLIKELY(p == as->invmcp)) {
+    as->loopinv = 1;
+    *p = PPCI_B | (((target-p) & 0x00ffffffu) << 2);
+    emit_condbranch(as, PPCI_BC, cc^4, p);
+    return;
+  }
+  emit_condbranch(as, PPCI_BC, cc, target);
+}
+
+/* -- Operand fusion ------------------------------------------------------ */
+
+/* Limit linear search to this distance. Avoids O(n^2) behavior. */
+#define CONFLICT_SEARCH_LIM	31
+
+/* Check if there's no conflicting instruction between curins and ref. */
+static int noconflict(ASMState *as, IRRef ref, IROp conflict)
+{
+  IRIns *ir = as->ir;
+  IRRef i = as->curins;
+  if (i > ref + CONFLICT_SEARCH_LIM)
+    return 0;  /* Give up, ref is too far away. */
+  while (--i > ref)
+    if (ir[i].o == conflict)
+      return 0;  /* Conflict found. */
+  return 1;  /* Ok, no conflict. */
+}
+
+/* Fuse the array base of colocated arrays. */
+static int32_t asm_fuseabase(ASMState *as, IRRef ref)
+{
+  IRIns *ir = IR(ref);
+  if (ir->o == IR_TNEW && ir->op1 <= LJ_MAX_COLOSIZE &&
+      !neverfuse(as) && noconflict(as, ref, IR_NEWREF))
+    return (int32_t)sizeof(GCtab);
+  return 0;
+}
+
+/* Indicates load/store indexed is ok. */
+#define AHUREF_LSX	((int32_t)0x80000000)
+
+/* Fuse array/hash/upvalue reference into register+offset operand. */
+static Reg asm_fuseahuref(ASMState *as, IRRef ref, int32_t *ofsp, RegSet allow)
+{
+  IRIns *ir = IR(ref);
+  if (ra_noreg(ir->r)) {
+    if (ir->o == IR_AREF) {
+      if (mayfuse(as, ref)) {
+	if (irref_isk(ir->op2)) {
+	  IRRef tab = IR(ir->op1)->op1;
+	  int32_t ofs = asm_fuseabase(as, tab);
+	  IRRef refa = ofs ? tab : ir->op1;
+	  ofs += 8*IR(ir->op2)->i;
+	  if (checki16(ofs)) {
+	    *ofsp = ofs;
+	    return ra_alloc1(as, refa, allow);
+	  }
+	}
+	if (*ofsp == AHUREF_LSX) {
+	  Reg base = ra_alloc1(as, ir->op1, allow);
+	  Reg idx = ra_alloc1(as, ir->op2, rset_exclude(RSET_GPR, base));
+	  return base | (idx << 8);
+	}
+      }
+    } else if (ir->o == IR_HREFK) {
+      if (mayfuse(as, ref)) {
+	int32_t ofs = (int32_t)(IR(ir->op2)->op2 * sizeof(Node));
+	if (checki16(ofs)) {
+	  *ofsp = ofs;
+	  return ra_alloc1(as, ir->op1, allow);
+	}
+      }
+    } else if (ir->o == IR_UREFC) {
+      if (irref_isk(ir->op1)) {
+	GCfunc *fn = ir_kfunc(IR(ir->op1));
+	int32_t ofs = i32ptr(&gcref(fn->l.uvptr[(ir->op2 >> 8)])->uv.tv);
+	int32_t jgl = (intptr_t)J2G(as->J);
+	if ((uint32_t)(ofs-jgl) < 65536) {
+	  *ofsp = ofs-jgl-32768;
+	  return RID_JGL;
+	} else {
+	  *ofsp = (int16_t)ofs;
+	  return ra_allock(as, ofs-(int16_t)ofs, allow);
+	}
+      }
+    }
+  }
+  *ofsp = 0;
+  return ra_alloc1(as, ref, allow);
+}
+
+/* Fuse XLOAD/XSTORE reference into load/store operand. */
+static void asm_fusexref(ASMState *as, PPCIns pi, Reg rt, IRRef ref,
+			 RegSet allow)
+{
+  IRIns *ir = IR(ref);
+  int32_t ofs = 0;
+  Reg base;
+  if (ra_noreg(ir->r) && mayfuse(as, ref)) {
+    if (ir->o == IR_ADD) {
+      if (irref_isk(ir->op2) && (ofs = IR(ir->op2)->i, checki16(ofs))) {
+	ref = ir->op1;
+      } else {
+	Reg right, left = ra_alloc2(as, ir, allow);
+	right = (left >> 8); left &= 255;
+	emit_fab(as, PPCI_LWZX | ((pi >> 20) & 0x780), rt, left, right);
+	return;
+      }
+    } else if (ir->o == IR_STRREF) {
+      ofs = (int32_t)sizeof(GCstr);
+      if (irref_isk(ir->op2)) {
+	ofs += IR(ir->op2)->i;
+	ref = ir->op1;
+      } else if (irref_isk(ir->op1)) {
+	ofs += IR(ir->op1)->i;
+	ref = ir->op2;
+      } else {
+	/* NYI: Fuse ADD with constant. */
+	Reg right, left = ra_alloc2(as, ir, allow);
+	right = (left >> 8); left &= 255;
+	emit_fai(as, pi, rt, rt, ofs);
+	emit_tab(as, PPCI_ADD, rt, left, right);
+	return;
+      }
+      if (!checki16(ofs)) {
+	Reg left = ra_alloc1(as, ref, allow);
+	Reg right = ra_allock(as, ofs, rset_exclude(allow, left));
+	emit_fab(as, PPCI_LWZX | ((pi >> 20) & 0x780), rt, left, right);
+	return;
+      }
+    }
+  }
+  base = ra_alloc1(as, ref, allow);
+  emit_fai(as, pi, rt, base, ofs);
+}
+
+/* Fuse XLOAD/XSTORE reference into indexed-only load/store operand. */
+static void asm_fusexrefx(ASMState *as, PPCIns pi, Reg rt, IRRef ref,
+			  RegSet allow)
+{
+  IRIns *ira = IR(ref);
+  Reg right, left;
+  if (mayfuse(as, ref) && ira->o == IR_ADD && ra_noreg(ira->r)) {
+    left = ra_alloc2(as, ira, allow);
+    right = (left >> 8); left &= 255;
+  } else {
+    right = ra_alloc1(as, ref, allow);
+    left = RID_R0;
+  }
+  emit_tab(as, pi, rt, left, right);
+}
+
+/* Fuse to multiply-add/sub instruction. */
+static int asm_fusemadd(ASMState *as, IRIns *ir, PPCIns pi, PPCIns pir)
+{
+  IRRef lref = ir->op1, rref = ir->op2;
+  IRIns *irm;
+  if (lref != rref &&
+      ((mayfuse(as, lref) && (irm = IR(lref), irm->o == IR_MUL) &&
+	ra_noreg(irm->r)) ||
+       (mayfuse(as, rref) && (irm = IR(rref), irm->o == IR_MUL) &&
+	(rref = lref, pi = pir, ra_noreg(irm->r))))) {
+    Reg dest = ra_dest(as, ir, RSET_FPR);
+    Reg add = ra_alloc1(as, rref, RSET_FPR);
+    Reg right, left = ra_alloc2(as, irm, rset_exclude(RSET_FPR, add));
+    right = (left >> 8); left &= 255;
+    emit_facb(as, pi, dest, left, right, add);
+    return 1;
+  }
+  return 0;
+}
+
+/* -- Calls --------------------------------------------------------------- */
+
+/* Generate a call to a C function. */
+static void asm_gencall(ASMState *as, const CCallInfo *ci, IRRef *args)
+{
+  uint32_t n, nargs = CCI_NARGS(ci);
+  int32_t ofs = 8;
+  Reg gpr = REGARG_FIRSTGPR, fpr = REGARG_FIRSTFPR;
+  if ((void *)ci->func)
+    emit_call(as, (void *)ci->func);
+  for (n = 0; n < nargs; n++) {  /* Setup args. */
+    IRRef ref = args[n];
+    if (ref) {
+      IRIns *ir = IR(ref);
+      if (irt_isfp(ir->t)) {
+	if (fpr <= REGARG_LASTFPR) {
+	  lua_assert(rset_test(as->freeset, fpr));  /* Already evicted. */
+	  ra_leftov(as, fpr, ref);
+	  fpr++;
+	} else {
+	  Reg r = ra_alloc1(as, ref, RSET_FPR);
+	  if (irt_isnum(ir->t)) ofs = (ofs + 4) & ~4;
+	  emit_spstore(as, ir, r, ofs);
+	  ofs += irt_isnum(ir->t) ? 8 : 4;
+	}
+      } else {
+	if (gpr <= REGARG_LASTGPR) {
+	  lua_assert(rset_test(as->freeset, gpr));  /* Already evicted. */
+	  ra_leftov(as, gpr, ref);
+	  gpr++;
+	} else {
+	  Reg r = ra_alloc1(as, ref, RSET_GPR);
+	  emit_spstore(as, ir, r, ofs);
+	  ofs += 4;
+	}
+      }
+    } else {
+      if (gpr <= REGARG_LASTGPR)
+	gpr++;
+      else
+	ofs += 4;
+    }
+  }
+  if ((ci->flags & CCI_VARARG))  /* Vararg calls need to know about FPR use. */
+    emit_tab(as, fpr == REGARG_FIRSTFPR ? PPCI_CRXOR : PPCI_CREQV, 6, 6, 6);
+}
+
+/* Setup result reg/sp for call. Evict scratch regs. */
+static void asm_setupresult(ASMState *as, IRIns *ir, const CCallInfo *ci)
+{
+  RegSet drop = RSET_SCRATCH;
+  int hiop = ((ir+1)->o == IR_HIOP);
+  if ((ci->flags & CCI_NOFPRCLOBBER))
+    drop &= ~RSET_FPR;
+  if (ra_hasreg(ir->r))
+    rset_clear(drop, ir->r);  /* Dest reg handled below. */
+  if (hiop && ra_hasreg((ir+1)->r))
+    rset_clear(drop, (ir+1)->r);  /* Dest reg handled below. */
+  ra_evictset(as, drop);  /* Evictions must be performed first. */
+  if (ra_used(ir)) {
+    lua_assert(!irt_ispri(ir->t));
+    if (irt_isfp(ir->t)) {
+      if ((ci->flags & CCI_CASTU64)) {
+	/* Use spill slot or temp slots. */
+	int32_t ofs = ir->s ? sps_scale(ir->s) : SPOFS_TMP;
+	Reg dest = ir->r;
+	if (ra_hasreg(dest)) {
+	  ra_free(as, dest);
+	  ra_modified(as, dest);
+	  emit_fai(as, PPCI_LFD, dest, RID_SP, ofs);
+	}
+	emit_tai(as, PPCI_STW, RID_RETHI, RID_SP, ofs);
+	emit_tai(as, PPCI_STW, RID_RETLO, RID_SP, ofs+4);
+      } else {
+	ra_destreg(as, ir, RID_FPRET);
+      }
+    } else if (hiop) {
+      ra_destpair(as, ir);
+    } else {
+      ra_destreg(as, ir, RID_RET);
+    }
+  }
+}
+
+static void asm_call(ASMState *as, IRIns *ir)
+{
+  IRRef args[CCI_NARGS_MAX];
+  const CCallInfo *ci = &lj_ir_callinfo[ir->op2];
+  asm_collectargs(as, ir, ci, args);
+  asm_setupresult(as, ir, ci);
+  asm_gencall(as, ci, args);
+}
+
+static void asm_callx(ASMState *as, IRIns *ir)
+{
+  IRRef args[CCI_NARGS_MAX];
+  CCallInfo ci;
+  IRRef func;
+  IRIns *irf;
+  ci.flags = asm_callx_flags(as, ir);
+  asm_collectargs(as, ir, &ci, args);
+  asm_setupresult(as, ir, &ci);
+  func = ir->op2; irf = IR(func);
+  if (irf->o == IR_CARG) { func = irf->op1; irf = IR(func); }
+  if (irref_isk(func)) {  /* Call to constant address. */
+    ci.func = (ASMFunction)(void *)(irf->i);
+  } else {  /* Need a non-argument register for indirect calls. */
+    RegSet allow = RSET_GPR & ~RSET_RANGE(RID_R0, REGARG_LASTGPR+1);
+    Reg freg = ra_alloc1(as, func, allow);
+    *--as->mcp = PPCI_BCTRL;
+    *--as->mcp = PPCI_MTCTR | PPCF_T(freg);
+    ci.func = (ASMFunction)(void *)0;
+  }
+  asm_gencall(as, &ci, args);
+}
+
+static void asm_callid(ASMState *as, IRIns *ir, IRCallID id)
+{
+  const CCallInfo *ci = &lj_ir_callinfo[id];
+  IRRef args[2];
+  args[0] = ir->op1;
+  args[1] = ir->op2;
+  asm_setupresult(as, ir, ci);
+  asm_gencall(as, ci, args);
+}
+
+/* -- Returns ------------------------------------------------------------- */
+
+/* Return to lower frame. Guard that it goes to the right spot. */
+static void asm_retf(ASMState *as, IRIns *ir)
+{
+  Reg base = ra_alloc1(as, REF_BASE, RSET_GPR);
+  void *pc = ir_kptr(IR(ir->op2));
+  int32_t delta = 1+bc_a(*((const BCIns *)pc - 1));
+  as->topslot -= (BCReg)delta;
+  if ((int32_t)as->topslot < 0) as->topslot = 0;
+  emit_setgl(as, base, jit_base);
+  emit_addptr(as, base, -8*delta);
+  asm_guardcc(as, CC_NE);
+  emit_ab(as, PPCI_CMPW, RID_TMP,
+	  ra_allock(as, i32ptr(pc), rset_exclude(RSET_GPR, base)));
+  emit_tai(as, PPCI_LWZ, RID_TMP, base, -8);
+}
+
+/* -- Type conversions ---------------------------------------------------- */
+
+static void asm_tointg(ASMState *as, IRIns *ir, Reg left)
+{
+  RegSet allow = RSET_FPR;
+  Reg tmp = ra_scratch(as, rset_clear(allow, left));
+  Reg fbias = ra_scratch(as, rset_clear(allow, tmp));
+  Reg dest = ra_dest(as, ir, RSET_GPR);
+  Reg hibias = ra_allock(as, 0x43300000, rset_exclude(RSET_GPR, dest));
+  asm_guardcc(as, CC_NE);
+  emit_fab(as, PPCI_FCMPU, 0, tmp, left);
+  emit_fab(as, PPCI_FSUB, tmp, tmp, fbias);
+  emit_fai(as, PPCI_LFD, tmp, RID_SP, SPOFS_TMP);
+  emit_tai(as, PPCI_STW, RID_TMP, RID_SP, SPOFS_TMPLO);
+  emit_tai(as, PPCI_STW, hibias, RID_SP, SPOFS_TMPHI);
+  emit_asi(as, PPCI_XORIS, RID_TMP, dest, 0x8000);
+  emit_tai(as, PPCI_LWZ, dest, RID_SP, SPOFS_TMPLO);
+  emit_lsptr(as, PPCI_LFS, (fbias & 31),
+	     (void *)lj_ir_k64_find(as->J, U64x(59800004,59800000)),
+	     RSET_GPR);
+  emit_fai(as, PPCI_STFD, tmp, RID_SP, SPOFS_TMP);
+  emit_fb(as, PPCI_FCTIWZ, tmp, left);
+}
+
+static void asm_tobit(ASMState *as, IRIns *ir)
+{
+  RegSet allow = RSET_FPR;
+  Reg dest = ra_dest(as, ir, RSET_GPR);
+  Reg left = ra_alloc1(as, ir->op1, allow);
+  Reg right = ra_alloc1(as, ir->op2, rset_clear(allow, left));
+  Reg tmp = ra_scratch(as, rset_clear(allow, right));
+  emit_tai(as, PPCI_LWZ, dest, RID_SP, SPOFS_TMPLO);
+  emit_fai(as, PPCI_STFD, tmp, RID_SP, SPOFS_TMP);
+  emit_fab(as, PPCI_FADD, tmp, left, right);
+}
+
+static void asm_conv(ASMState *as, IRIns *ir)
+{
+  IRType st = (IRType)(ir->op2 & IRCONV_SRCMASK);
+  int stfp = (st == IRT_NUM || st == IRT_FLOAT);
+  IRRef lref = ir->op1;
+  lua_assert(irt_type(ir->t) != st);
+  lua_assert(!(irt_isint64(ir->t) ||
+	       (st == IRT_I64 || st == IRT_U64))); /* Handled by SPLIT. */
+  if (irt_isfp(ir->t)) {
+    Reg dest = ra_dest(as, ir, RSET_FPR);
+    if (stfp) {  /* FP to FP conversion. */
+      if (st == IRT_NUM)  /* double -> float conversion. */
+	emit_fb(as, PPCI_FRSP, dest, ra_alloc1(as, lref, RSET_FPR));
+      else  /* float -> double conversion is a no-op on PPC. */
+	ra_leftov(as, dest, lref);  /* Do nothing, but may need to move regs. */
+    } else {  /* Integer to FP conversion. */
+      /* IRT_INT: Flip hibit, bias with 2^52, subtract 2^52+2^31. */
+      /* IRT_U32: Bias with 2^52, subtract 2^52. */
+      RegSet allow = RSET_GPR;
+      Reg left = ra_alloc1(as, lref, allow);
+      Reg hibias = ra_allock(as, 0x43300000, rset_clear(allow, left));
+      Reg fbias = ra_scratch(as, rset_exclude(RSET_FPR, dest));
+      const float *kbias;
+      if (irt_isfloat(ir->t)) emit_fb(as, PPCI_FRSP, dest, dest);
+      emit_fab(as, PPCI_FSUB, dest, dest, fbias);
+      emit_fai(as, PPCI_LFD, dest, RID_SP, SPOFS_TMP);
+      kbias = (const float *)lj_ir_k64_find(as->J, U64x(59800004,59800000));
+      if (st == IRT_U32) kbias++;
+      emit_lsptr(as, PPCI_LFS, (fbias & 31), (void *)kbias,
+		 rset_clear(allow, hibias));
+      emit_tai(as, PPCI_STW, st == IRT_U32 ? left : RID_TMP,
+	       RID_SP, SPOFS_TMPLO);
+      emit_tai(as, PPCI_STW, hibias, RID_SP, SPOFS_TMPHI);
+      if (st != IRT_U32) emit_asi(as, PPCI_XORIS, RID_TMP, left, 0x8000);
+    }
+  } else if (stfp) {  /* FP to integer conversion. */
+    if (irt_isguard(ir->t)) {
+      /* Checked conversions are only supported from number to int. */
+      lua_assert(irt_isint(ir->t) && st == IRT_NUM);
+      asm_tointg(as, ir, ra_alloc1(as, lref, RSET_FPR));
+    } else {
+      Reg dest = ra_dest(as, ir, RSET_GPR);
+      Reg left = ra_alloc1(as, lref, RSET_FPR);
+      Reg tmp = ra_scratch(as, rset_exclude(RSET_FPR, left));
+      if (irt_isu32(ir->t)) {
+	/* Convert both x and x-2^31 to int and merge results. */
+	Reg tmpi = ra_scratch(as, rset_exclude(RSET_GPR, dest));
+	emit_asb(as, PPCI_OR, dest, dest, tmpi);  /* Select with mask idiom. */
+	emit_asb(as, PPCI_AND, tmpi, tmpi, RID_TMP);
+	emit_asb(as, PPCI_ANDC, dest, dest, RID_TMP);
+	emit_tai(as, PPCI_LWZ, tmpi, RID_SP, SPOFS_TMPLO);  /* tmp = (int)(x) */
+	emit_tai(as, PPCI_ADDIS, dest, dest, 0x8000);  /* dest += 2^31 */
+	emit_asb(as, PPCI_SRAWI, RID_TMP, dest, 31);  /* mask = -(dest < 0) */
+	emit_fai(as, PPCI_STFD, tmp, RID_SP, SPOFS_TMP);
+	emit_tai(as, PPCI_LWZ, dest,
+		 RID_SP, SPOFS_TMPLO);  /* dest = (int)(x-2^31) */
+	emit_fb(as, PPCI_FCTIWZ, tmp, left);
+	emit_fai(as, PPCI_STFD, tmp, RID_SP, SPOFS_TMP);
+	emit_fb(as, PPCI_FCTIWZ, tmp, tmp);
+	emit_fab(as, PPCI_FSUB, tmp, left, tmp);
+	emit_lsptr(as, PPCI_LFS, (tmp & 31),
+		   (void *)lj_ir_k64_find(as->J, U64x(4f000000,00000000)),
+		   RSET_GPR);
+      } else {
+	emit_tai(as, PPCI_LWZ, dest, RID_SP, SPOFS_TMPLO);
+	emit_fai(as, PPCI_STFD, tmp, RID_SP, SPOFS_TMP);
+	emit_fb(as, PPCI_FCTIWZ, tmp, left);
+      }
+    }
+  } else {
+    Reg dest = ra_dest(as, ir, RSET_GPR);
+    if (st >= IRT_I8 && st <= IRT_U16) {  /* Extend to 32 bit integer. */
+      Reg left = ra_alloc1(as, ir->op1, RSET_GPR);
+      lua_assert(irt_isint(ir->t) || irt_isu32(ir->t));
+      if ((ir->op2 & IRCONV_SEXT))
+	emit_as(as, st == IRT_I8 ? PPCI_EXTSB : PPCI_EXTSH, dest, left);
+      else
+	emit_rot(as, PPCI_RLWINM, dest, left, 0, st == IRT_U8 ? 24 : 16, 31);
+    } else {  /* 32/64 bit integer conversions. */
+      /* Only need to handle 32/32 bit no-op (cast) on 32 bit archs. */
+      ra_leftov(as, dest, lref);  /* Do nothing, but may need to move regs. */
+    }
+  }
+}
+
+#if LJ_HASFFI
+static void asm_conv64(ASMState *as, IRIns *ir)
+{
+  IRType st = (IRType)((ir-1)->op2 & IRCONV_SRCMASK);
+  IRType dt = (((ir-1)->op2 & IRCONV_DSTMASK) >> IRCONV_DSH);
+  IRCallID id;
+  const CCallInfo *ci;
+  IRRef args[2];
+  args[0] = ir->op1;
+  args[1] = (ir-1)->op1;
+  if (st == IRT_NUM || st == IRT_FLOAT) {
+    id = IRCALL_fp64_d2l + ((st == IRT_FLOAT) ? 2 : 0) + (dt - IRT_I64);
+    ir--;
+  } else {
+    id = IRCALL_fp64_l2d + ((dt == IRT_FLOAT) ? 2 : 0) + (st - IRT_I64);
+  }
+  ci = &lj_ir_callinfo[id];
+  asm_setupresult(as, ir, ci);
+  asm_gencall(as, ci, args);
+}
+#endif
+
+static void asm_strto(ASMState *as, IRIns *ir)
+{
+  const CCallInfo *ci = &lj_ir_callinfo[IRCALL_lj_str_tonum];
+  IRRef args[2];
+  int32_t ofs;
+  RegSet drop = RSET_SCRATCH;
+  if (ra_hasreg(ir->r)) rset_set(drop, ir->r);  /* Spill dest reg (if any). */
+  ra_evictset(as, drop);
+  asm_guardcc(as, CC_EQ);
+  emit_ai(as, PPCI_CMPWI, RID_RET, 0);  /* Test return status. */
+  args[0] = ir->op1;      /* GCstr *str */
+  args[1] = ASMREF_TMP1;  /* TValue *n  */
+  asm_gencall(as, ci, args);
+  /* Store the result to the spill slot or temp slots. */
+  ofs = ir->s ? sps_scale(ir->s) : SPOFS_TMP;
+  emit_tai(as, PPCI_ADDI, ra_releasetmp(as, ASMREF_TMP1), RID_SP, ofs);
+}
+
+/* Get pointer to TValue. */
+static void asm_tvptr(ASMState *as, Reg dest, IRRef ref)
+{
+  IRIns *ir = IR(ref);
+  if (irt_isnum(ir->t)) {
+    if (irref_isk(ref))  /* Use the number constant itself as a TValue. */
+      ra_allockreg(as, i32ptr(ir_knum(ir)), dest);
+    else  /* Otherwise force a spill and use the spill slot. */
+      emit_tai(as, PPCI_ADDI, dest, RID_SP, ra_spill(as, ir));
+  } else {
+    /* Otherwise use g->tmptv to hold the TValue. */
+    RegSet allow = rset_exclude(RSET_GPR, dest);
+    Reg type;
+    emit_tai(as, PPCI_ADDI, dest, RID_JGL, offsetof(global_State, tmptv)-32768);
+    if (!irt_ispri(ir->t)) {
+      Reg src = ra_alloc1(as, ref, allow);
+      emit_setgl(as, src, tmptv.gcr);
+    }
+    type = ra_allock(as, irt_toitype(ir->t), allow);
+    emit_setgl(as, type, tmptv.it);
+  }
+}
+
+static void asm_tostr(ASMState *as, IRIns *ir)
+{
+  IRRef args[2];
+  args[0] = ASMREF_L;
+  as->gcsteps++;
+  if (irt_isnum(IR(ir->op1)->t) || (ir+1)->o == IR_HIOP) {
+    const CCallInfo *ci = &lj_ir_callinfo[IRCALL_lj_str_fromnum];
+    args[1] = ASMREF_TMP1;  /* const lua_Number * */
+    asm_setupresult(as, ir, ci);  /* GCstr * */
+    asm_gencall(as, ci, args);
+    asm_tvptr(as, ra_releasetmp(as, ASMREF_TMP1), ir->op1);
+  } else {
+    const CCallInfo *ci = &lj_ir_callinfo[IRCALL_lj_str_fromint];
+    args[1] = ir->op1;  /* int32_t k */
+    asm_setupresult(as, ir, ci);  /* GCstr * */
+    asm_gencall(as, ci, args);
+  }
+}
+
+/* -- Memory references --------------------------------------------------- */
+
+static void asm_aref(ASMState *as, IRIns *ir)
+{
+  Reg dest = ra_dest(as, ir, RSET_GPR);
+  Reg idx, base;
+  if (irref_isk(ir->op2)) {
+    IRRef tab = IR(ir->op1)->op1;
+    int32_t ofs = asm_fuseabase(as, tab);
+    IRRef refa = ofs ? tab : ir->op1;
+    ofs += 8*IR(ir->op2)->i;
+    if (checki16(ofs)) {
+      base = ra_alloc1(as, refa, RSET_GPR);
+      emit_tai(as, PPCI_ADDI, dest, base, ofs);
+      return;
+    }
+  }
+  base = ra_alloc1(as, ir->op1, RSET_GPR);
+  idx = ra_alloc1(as, ir->op2, rset_exclude(RSET_GPR, base));
+  emit_tab(as, PPCI_ADD, dest, RID_TMP, base);
+  emit_slwi(as, RID_TMP, idx, 3);
+}
+
+/* Inlined hash lookup. Specialized for key type and for const keys.
+** The equivalent C code is:
+**   Node *n = hashkey(t, key);
+**   do {
+**     if (lj_obj_equal(&n->key, key)) return &n->val;
+**   } while ((n = nextnode(n)));
+**   return niltv(L);
+*/
+static void asm_href(ASMState *as, IRIns *ir, IROp merge)
+{
+  RegSet allow = RSET_GPR;
+  int destused = ra_used(ir);
+  Reg dest = ra_dest(as, ir, allow);
+  Reg tab = ra_alloc1(as, ir->op1, rset_clear(allow, dest));
+  Reg key = RID_NONE, tmp1 = RID_TMP, tmp2;
+  Reg tisnum = RID_NONE, tmpnum = RID_NONE;
+  IRRef refkey = ir->op2;
+  IRIns *irkey = IR(refkey);
+  IRType1 kt = irkey->t;
+  uint32_t khash;
+  MCLabel l_end, l_loop, l_next;
+
+  rset_clear(allow, tab);
+  if (irt_isnum(kt)) {
+    key = ra_alloc1(as, refkey, RSET_FPR);
+    tmpnum = ra_scratch(as, rset_exclude(RSET_FPR, key));
+    tisnum = ra_allock(as, (int32_t)LJ_TISNUM, allow);
+    rset_clear(allow, tisnum);
+  } else if (!irt_ispri(kt)) {
+    key = ra_alloc1(as, refkey, allow);
+    rset_clear(allow, key);
+  }
+  tmp2 = ra_scratch(as, allow);
+  rset_clear(allow, tmp2);
+
+  /* Key not found in chain: jump to exit (if merged) or load niltv. */
+  l_end = emit_label(as);
+  as->invmcp = NULL;
+  if (merge == IR_NE)
+    asm_guardcc(as, CC_EQ);
+  else if (destused)
+    emit_loada(as, dest, niltvg(J2G(as->J)));
+
+  /* Follow hash chain until the end. */
+  l_loop = --as->mcp;
+  emit_ai(as, PPCI_CMPWI, dest, 0);
+  emit_tai(as, PPCI_LWZ, dest, dest, (int32_t)offsetof(Node, next));
+  l_next = emit_label(as);
+
+  /* Type and value comparison. */
+  if (merge == IR_EQ)
+    asm_guardcc(as, CC_EQ);
+  else
+    emit_condbranch(as, PPCI_BC|PPCF_Y, CC_EQ, l_end);
+  if (irt_isnum(kt)) {
+    emit_fab(as, PPCI_FCMPU, 0, tmpnum, key);
+    emit_condbranch(as, PPCI_BC, CC_GE, l_next);
+    emit_ab(as, PPCI_CMPLW, tmp1, tisnum);
+    emit_fai(as, PPCI_LFD, tmpnum, dest, (int32_t)offsetof(Node, key.n));
+  } else {
+    if (!irt_ispri(kt)) {
+      emit_ab(as, PPCI_CMPW, tmp2, key);
+      emit_condbranch(as, PPCI_BC, CC_NE, l_next);
+    }
+    emit_ai(as, PPCI_CMPWI, tmp1, irt_toitype(irkey->t));
+    if (!irt_ispri(kt))
+      emit_tai(as, PPCI_LWZ, tmp2, dest, (int32_t)offsetof(Node, key.gcr));
+  }
+  emit_tai(as, PPCI_LWZ, tmp1, dest, (int32_t)offsetof(Node, key.it));
+  *l_loop = PPCI_BC | PPCF_Y | PPCF_CC(CC_NE) |
+	    (((char *)as->mcp-(char *)l_loop) & 0xffffu);
+
+  /* Load main position relative to tab->node into dest. */
+  khash = irref_isk(refkey) ? ir_khash(irkey) : 1;
+  if (khash == 0) {
+    emit_tai(as, PPCI_LWZ, dest, tab, (int32_t)offsetof(GCtab, node));
+  } else {
+    Reg tmphash = tmp1;
+    if (irref_isk(refkey))
+      tmphash = ra_allock(as, khash, allow);
+    emit_tab(as, PPCI_ADD, dest, dest, tmp1);
+    emit_tai(as, PPCI_MULLI, tmp1, tmp1, sizeof(Node));
+    emit_asb(as, PPCI_AND, tmp1, tmp2, tmphash);
+    emit_tai(as, PPCI_LWZ, dest, tab, (int32_t)offsetof(GCtab, node));
+    emit_tai(as, PPCI_LWZ, tmp2, tab, (int32_t)offsetof(GCtab, hmask));
+    if (irref_isk(refkey)) {
+      /* Nothing to do. */
+    } else if (irt_isstr(kt)) {
+      emit_tai(as, PPCI_LWZ, tmp1, key, (int32_t)offsetof(GCstr, hash));
+    } else {  /* Must match with hash*() in lj_tab.c. */
+      emit_tab(as, PPCI_SUBF, tmp1, tmp2, tmp1);
+      emit_rotlwi(as, tmp2, tmp2, HASH_ROT3);
+      emit_asb(as, PPCI_XOR, tmp1, tmp1, tmp2);
+      emit_rotlwi(as, tmp1, tmp1, (HASH_ROT2+HASH_ROT1)&31);
+      emit_tab(as, PPCI_SUBF, tmp2, dest, tmp2);
+      if (irt_isnum(kt)) {
+	int32_t ofs = ra_spill(as, irkey);
+	emit_asb(as, PPCI_XOR, tmp2, tmp2, tmp1);
+	emit_rotlwi(as, dest, tmp1, HASH_ROT1);
+	emit_tab(as, PPCI_ADD, tmp1, tmp1, tmp1);
+	emit_tai(as, PPCI_LWZ, tmp2, RID_SP, ofs+4);
+	emit_tai(as, PPCI_LWZ, tmp1, RID_SP, ofs);
+      } else {
+	emit_asb(as, PPCI_XOR, tmp2, key, tmp1);
+	emit_rotlwi(as, dest, tmp1, HASH_ROT1);
+	emit_tai(as, PPCI_ADDI, tmp1, tmp2, HASH_BIAS);
+	emit_tai(as, PPCI_ADDIS, tmp2, key, (HASH_BIAS + 32768)>>16);
+      }
+    }
+  }
+}
+
+static void asm_hrefk(ASMState *as, IRIns *ir)
+{
+  IRIns *kslot = IR(ir->op2);
+  IRIns *irkey = IR(kslot->op1);
+  int32_t ofs = (int32_t)(kslot->op2 * sizeof(Node));
+  int32_t kofs = ofs + (int32_t)offsetof(Node, key);
+  Reg dest = (ra_used(ir)||ofs > 65535) ? ra_dest(as, ir, RSET_GPR) : RID_NONE;
+  Reg node = ra_alloc1(as, ir->op1, RSET_GPR);
+  Reg key = RID_NONE, type = RID_TMP, idx = node;
+  RegSet allow = rset_exclude(RSET_GPR, node);
+  lua_assert(ofs % sizeof(Node) == 0);
+  if (ofs > 65535) {
+    idx = dest;
+    rset_clear(allow, dest);
+    kofs = (int32_t)offsetof(Node, key);
+  } else if (ra_hasreg(dest)) {
+    emit_tai(as, PPCI_ADDI, dest, node, ofs);
+  }
+  asm_guardcc(as, CC_NE);
+  if (!irt_ispri(irkey->t)) {
+    key = ra_scratch(as, allow);
+    rset_clear(allow, key);
+  }
+  rset_clear(allow, type);
+  if (irt_isnum(irkey->t)) {
+    emit_cmpi(as, key, (int32_t)ir_knum(irkey)->u32.lo);
+    asm_guardcc(as, CC_NE);
+    emit_cmpi(as, type, (int32_t)ir_knum(irkey)->u32.hi);
+  } else {
+    if (ra_hasreg(key)) {
+      emit_cmpi(as, key, irkey->i);  /* May use RID_TMP, i.e. type. */
+      asm_guardcc(as, CC_NE);
+    }
+    emit_ai(as, PPCI_CMPWI, type, irt_toitype(irkey->t));
+  }
+  if (ra_hasreg(key)) emit_tai(as, PPCI_LWZ, key, idx, kofs+4);
+  emit_tai(as, PPCI_LWZ, type, idx, kofs);
+  if (ofs > 65535) {
+    emit_tai(as, PPCI_ADDIS, dest, dest, (ofs + 32768) >> 16);
+    emit_tai(as, PPCI_ADDI, dest, node, ofs);
+  }
+}
+
+static void asm_newref(ASMState *as, IRIns *ir)
+{
+  const CCallInfo *ci = &lj_ir_callinfo[IRCALL_lj_tab_newkey];
+  IRRef args[3];
+  args[0] = ASMREF_L;     /* lua_State *L */
+  args[1] = ir->op1;      /* GCtab *t     */
+  args[2] = ASMREF_TMP1;  /* cTValue *key */
+  asm_setupresult(as, ir, ci);  /* TValue * */
+  asm_gencall(as, ci, args);
+  asm_tvptr(as, ra_releasetmp(as, ASMREF_TMP1), ir->op2);
+}
+
+static void asm_uref(ASMState *as, IRIns *ir)
+{
+  /* NYI: Check that UREFO is still open and not aliasing a slot. */
+  Reg dest = ra_dest(as, ir, RSET_GPR);
+  if (irref_isk(ir->op1)) {
+    GCfunc *fn = ir_kfunc(IR(ir->op1));
+    MRef *v = &gcref(fn->l.uvptr[(ir->op2 >> 8)])->uv.v;
+    emit_lsptr(as, PPCI_LWZ, dest, v, RSET_GPR);
+  } else {
+    Reg uv = ra_scratch(as, RSET_GPR);
+    Reg func = ra_alloc1(as, ir->op1, RSET_GPR);
+    if (ir->o == IR_UREFC) {
+      asm_guardcc(as, CC_NE);
+      emit_ai(as, PPCI_CMPWI, RID_TMP, 1);
+      emit_tai(as, PPCI_ADDI, dest, uv, (int32_t)offsetof(GCupval, tv));
+      emit_tai(as, PPCI_LBZ, RID_TMP, uv, (int32_t)offsetof(GCupval, closed));
+    } else {
+      emit_tai(as, PPCI_LWZ, dest, uv, (int32_t)offsetof(GCupval, v));
+    }
+    emit_tai(as, PPCI_LWZ, uv, func,
+	     (int32_t)offsetof(GCfuncL, uvptr) + 4*(int32_t)(ir->op2 >> 8));
+  }
+}
+
+static void asm_fref(ASMState *as, IRIns *ir)
+{
+  UNUSED(as); UNUSED(ir);
+  lua_assert(!ra_used(ir));
+}
+
+static void asm_strref(ASMState *as, IRIns *ir)
+{
+  Reg dest = ra_dest(as, ir, RSET_GPR);
+  IRRef ref = ir->op2, refk = ir->op1;
+  int32_t ofs = (int32_t)sizeof(GCstr);
+  Reg r;
+  if (irref_isk(ref)) {
+    IRRef tmp = refk; refk = ref; ref = tmp;
+  } else if (!irref_isk(refk)) {
+    Reg right, left = ra_alloc1(as, ir->op1, RSET_GPR);
+    IRIns *irr = IR(ir->op2);
+    if (ra_hasreg(irr->r)) {
+      ra_noweak(as, irr->r);
+      right = irr->r;
+    } else if (mayfuse(as, irr->op2) &&
+	       irr->o == IR_ADD && irref_isk(irr->op2) &&
+	       checki16(ofs + IR(irr->op2)->i)) {
+      ofs += IR(irr->op2)->i;
+      right = ra_alloc1(as, irr->op1, rset_exclude(RSET_GPR, left));
+    } else {
+      right = ra_allocref(as, ir->op2, rset_exclude(RSET_GPR, left));
+    }
+    emit_tai(as, PPCI_ADDI, dest, dest, ofs);
+    emit_tab(as, PPCI_ADD, dest, left, right);
+    return;
+  }
+  r = ra_alloc1(as, ref, RSET_GPR);
+  ofs += IR(refk)->i;
+  if (checki16(ofs))
+    emit_tai(as, PPCI_ADDI, dest, r, ofs);
+  else
+    emit_tab(as, PPCI_ADD, dest, r,
+	     ra_allock(as, ofs, rset_exclude(RSET_GPR, r)));
+}
+
+/* -- Loads and stores ---------------------------------------------------- */
+
+static PPCIns asm_fxloadins(IRIns *ir)
+{
+  switch (irt_type(ir->t)) {
+  case IRT_I8: return PPCI_LBZ;  /* Needs sign-extension. */
+  case IRT_U8: return PPCI_LBZ;
+  case IRT_I16: return PPCI_LHA;
+  case IRT_U16: return PPCI_LHZ;
+  case IRT_NUM: return PPCI_LFD;
+  case IRT_FLOAT: return PPCI_LFS;
+  default: return PPCI_LWZ;
+  }
+}
+
+static PPCIns asm_fxstoreins(IRIns *ir)
+{
+  switch (irt_type(ir->t)) {
+  case IRT_I8: case IRT_U8: return PPCI_STB;
+  case IRT_I16: case IRT_U16: return PPCI_STH;
+  case IRT_NUM: return PPCI_STFD;
+  case IRT_FLOAT: return PPCI_STFS;
+  default: return PPCI_STW;
+  }
+}
+
+static void asm_fload(ASMState *as, IRIns *ir)
+{
+  Reg dest = ra_dest(as, ir, RSET_GPR);
+  Reg idx = ra_alloc1(as, ir->op1, RSET_GPR);
+  PPCIns pi = asm_fxloadins(ir);
+  int32_t ofs;
+  if (ir->op2 == IRFL_TAB_ARRAY) {
+    ofs = asm_fuseabase(as, ir->op1);
+    if (ofs) {  /* Turn the t->array load into an add for colocated arrays. */
+      emit_tai(as, PPCI_ADDI, dest, idx, ofs);
+      return;
+    }
+  }
+  ofs = field_ofs[ir->op2];
+  lua_assert(!irt_isi8(ir->t));
+  emit_tai(as, pi, dest, idx, ofs);
+}
+
+static void asm_fstore(ASMState *as, IRIns *ir)
+{
+  Reg src = ra_alloc1(as, ir->op2, RSET_GPR);
+  IRIns *irf = IR(ir->op1);
+  Reg idx = ra_alloc1(as, irf->op1, rset_exclude(RSET_GPR, src));
+  int32_t ofs = field_ofs[irf->op2];
+  PPCIns pi = asm_fxstoreins(ir);
+  emit_tai(as, pi, src, idx, ofs);
+}
+
+static void asm_xload(ASMState *as, IRIns *ir)
+{
+  Reg dest = ra_dest(as, ir, irt_isfp(ir->t) ? RSET_FPR : RSET_GPR);
+  lua_assert(!(ir->op2 & IRXLOAD_UNALIGNED));
+  if (irt_isi8(ir->t))
+    emit_as(as, PPCI_EXTSB, dest, dest);
+  asm_fusexref(as, asm_fxloadins(ir), dest, ir->op1, RSET_GPR);
+}
+
+static void asm_xstore(ASMState *as, IRIns *ir)
+{
+  IRIns *irb;
+  if (mayfuse(as, ir->op2) && (irb = IR(ir->op2))->o == IR_BSWAP &&
+      ra_noreg(irb->r) && (irt_isint(ir->t) || irt_isu32(ir->t))) {
+    /* Fuse BSWAP with XSTORE to stwbrx. */
+    Reg src = ra_alloc1(as, irb->op1, RSET_GPR);
+    asm_fusexrefx(as, PPCI_STWBRX, src, ir->op1, rset_exclude(RSET_GPR, src));
+  } else {
+    Reg src = ra_alloc1(as, ir->op2, irt_isfp(ir->t) ? RSET_FPR : RSET_GPR);
+    asm_fusexref(as, asm_fxstoreins(ir), src, ir->op1,
+		 rset_exclude(RSET_GPR, src));
+  }
+}
+
+static void asm_ahuvload(ASMState *as, IRIns *ir)
+{
+  IRType1 t = ir->t;
+  Reg dest = RID_NONE, type = RID_TMP, tmp = RID_TMP, idx;
+  RegSet allow = RSET_GPR;
+  int32_t ofs = AHUREF_LSX;
+  if (ra_used(ir)) {
+    lua_assert(irt_isnum(t) || irt_isint(t) || irt_isaddr(t));
+    if (!irt_isnum(t)) ofs = 0;
+    dest = ra_dest(as, ir, irt_isnum(t) ? RSET_FPR : RSET_GPR);
+    rset_clear(allow, dest);
+  }
+  idx = asm_fuseahuref(as, ir->op1, &ofs, allow);
+  if (irt_isnum(t)) {
+    Reg tisnum = ra_allock(as, (int32_t)LJ_TISNUM, rset_exclude(allow, idx));
+    asm_guardcc(as, CC_GE);
+    emit_ab(as, PPCI_CMPLW, type, tisnum);
+    if (ra_hasreg(dest)) {
+      if (ofs == AHUREF_LSX) {
+	tmp = ra_scratch(as, rset_exclude(rset_exclude(RSET_GPR,
+						       (idx&255)), (idx>>8)));
+	emit_fab(as, PPCI_LFDX, dest, (idx&255), tmp);
+      } else {
+	emit_fai(as, PPCI_LFD, dest, idx, ofs);
+      }
+    }
+  } else {
+    asm_guardcc(as, CC_NE);
+    emit_ai(as, PPCI_CMPWI, type, irt_toitype(t));
+    if (ra_hasreg(dest)) emit_tai(as, PPCI_LWZ, dest, idx, ofs+4);
+  }
+  if (ofs == AHUREF_LSX) {
+    emit_tab(as, PPCI_LWZX, type, (idx&255), tmp);
+    emit_slwi(as, tmp, (idx>>8), 3);
+  } else {
+    emit_tai(as, PPCI_LWZ, type, idx, ofs);
+  }
+}
+
+static void asm_ahustore(ASMState *as, IRIns *ir)
+{
+  RegSet allow = RSET_GPR;
+  Reg idx, src = RID_NONE, type = RID_NONE;
+  int32_t ofs = AHUREF_LSX;
+  if (irt_isnum(ir->t)) {
+    src = ra_alloc1(as, ir->op2, RSET_FPR);
+  } else {
+    if (!irt_ispri(ir->t)) {
+      src = ra_alloc1(as, ir->op2, allow);
+      rset_clear(allow, src);
+      ofs = 0;
+    }
+    type = ra_allock(as, (int32_t)irt_toitype(ir->t), allow);
+    rset_clear(allow, type);
+  }
+  idx = asm_fuseahuref(as, ir->op1, &ofs, allow);
+  if (irt_isnum(ir->t)) {
+    if (ofs == AHUREF_LSX) {
+      emit_fab(as, PPCI_STFDX, src, (idx&255), RID_TMP);
+      emit_slwi(as, RID_TMP, (idx>>8), 3);
+    } else {
+      emit_fai(as, PPCI_STFD, src, idx, ofs);
+    }
+  } else {
+    if (ra_hasreg(src))
+      emit_tai(as, PPCI_STW, src, idx, ofs+4);
+    if (ofs == AHUREF_LSX) {
+      emit_tab(as, PPCI_STWX, type, (idx&255), RID_TMP);
+      emit_slwi(as, RID_TMP, (idx>>8), 3);
+    } else {
+      emit_tai(as, PPCI_STW, type, idx, ofs);
+    }
+  }
+}
+
+static void asm_sload(ASMState *as, IRIns *ir)
+{
+  int32_t ofs = 8*((int32_t)ir->op1-1) + ((ir->op2 & IRSLOAD_FRAME) ? 0 : 4);
+  IRType1 t = ir->t;
+  Reg dest = RID_NONE, type = RID_NONE, base;
+  RegSet allow = RSET_GPR;
+  lua_assert(!(ir->op2 & IRSLOAD_PARENT));  /* Handled by asm_head_side(). */
+  lua_assert(irt_isguard(t) || !(ir->op2 & IRSLOAD_TYPECHECK));
+  lua_assert(LJ_DUALNUM ||
+	     !irt_isint(t) || (ir->op2 & (IRSLOAD_CONVERT|IRSLOAD_FRAME)));
+  if ((ir->op2 & IRSLOAD_CONVERT) && irt_isguard(t) && irt_isint(t)) {
+    dest = ra_scratch(as, RSET_FPR);
+    asm_tointg(as, ir, dest);
+    t.irt = IRT_NUM;  /* Continue with a regular number type check. */
+  } else if (ra_used(ir)) {
+    lua_assert(irt_isnum(t) || irt_isint(t) || irt_isaddr(t));
+    dest = ra_dest(as, ir, irt_isnum(t) ? RSET_FPR : RSET_GPR);
+    rset_clear(allow, dest);
+    base = ra_alloc1(as, REF_BASE, allow);
+    rset_clear(allow, base);
+    if ((ir->op2 & IRSLOAD_CONVERT)) {
+      if (irt_isint(t)) {
+	emit_tai(as, PPCI_LWZ, dest, RID_SP, SPOFS_TMPLO);
+	dest = ra_scratch(as, RSET_FPR);
+	emit_fai(as, PPCI_STFD, dest, RID_SP, SPOFS_TMP);
+	emit_fb(as, PPCI_FCTIWZ, dest, dest);
+	t.irt = IRT_NUM;  /* Check for original type. */
+      } else {
+	Reg tmp = ra_scratch(as, allow);
+	Reg hibias = ra_allock(as, 0x43300000, rset_clear(allow, tmp));
+	Reg fbias = ra_scratch(as, rset_exclude(RSET_FPR, dest));
+	emit_fab(as, PPCI_FSUB, dest, dest, fbias);
+	emit_fai(as, PPCI_LFD, dest, RID_SP, SPOFS_TMP);
+	emit_lsptr(as, PPCI_LFS, (fbias & 31),
+		   (void *)lj_ir_k64_find(as->J, U64x(59800004,59800000)),
+		   rset_clear(allow, hibias));
+	emit_tai(as, PPCI_STW, tmp, RID_SP, SPOFS_TMPLO);
+	emit_tai(as, PPCI_STW, hibias, RID_SP, SPOFS_TMPHI);
+	emit_asi(as, PPCI_XORIS, tmp, tmp, 0x8000);
+	dest = tmp;
+	t.irt = IRT_INT;  /* Check for original type. */
+      }
+    }
+    goto dotypecheck;
+  }
+  base = ra_alloc1(as, REF_BASE, allow);
+  rset_clear(allow, base);
+dotypecheck:
+  if (irt_isnum(t)) {
+    if ((ir->op2 & IRSLOAD_TYPECHECK)) {
+      Reg tisnum = ra_allock(as, (int32_t)LJ_TISNUM, allow);
+      asm_guardcc(as, CC_GE);
+      emit_ab(as, PPCI_CMPLW, RID_TMP, tisnum);
+      type = RID_TMP;
+    }
+    if (ra_hasreg(dest)) emit_fai(as, PPCI_LFD, dest, base, ofs-4);
+  } else {
+    if ((ir->op2 & IRSLOAD_TYPECHECK)) {
+      asm_guardcc(as, CC_NE);
+      emit_ai(as, PPCI_CMPWI, RID_TMP, irt_toitype(t));
+      type = RID_TMP;
+    }
+    if (ra_hasreg(dest)) emit_tai(as, PPCI_LWZ, dest, base, ofs);
+  }
+  if (ra_hasreg(type)) emit_tai(as, PPCI_LWZ, type, base, ofs-4);
+}
+
+/* -- Allocations --------------------------------------------------------- */
+
+#if LJ_HASFFI
+static void asm_cnew(ASMState *as, IRIns *ir)
+{
+  CTState *cts = ctype_ctsG(J2G(as->J));
+  CTypeID typeid = (CTypeID)IR(ir->op1)->i;
+  CTSize sz = (ir->o == IR_CNEWI || ir->op2 == REF_NIL) ?
+	      lj_ctype_size(cts, typeid) : (CTSize)IR(ir->op2)->i;
+  const CCallInfo *ci = &lj_ir_callinfo[IRCALL_lj_mem_newgco];
+  IRRef args[2];
+  RegSet allow = (RSET_GPR & ~RSET_SCRATCH);
+  RegSet drop = RSET_SCRATCH;
+  lua_assert(sz != CTSIZE_INVALID);
+
+  args[0] = ASMREF_L;     /* lua_State *L */
+  args[1] = ASMREF_TMP1;  /* MSize size   */
+  as->gcsteps++;
+
+  if (ra_hasreg(ir->r))
+    rset_clear(drop, ir->r);  /* Dest reg handled below. */
+  ra_evictset(as, drop);
+  if (ra_used(ir))
+    ra_destreg(as, ir, RID_RET);  /* GCcdata * */
+
+  /* Initialize immutable cdata object. */
+  if (ir->o == IR_CNEWI) {
+    int32_t ofs = sizeof(GCcdata);
+    lua_assert(sz == 4 || sz == 8);
+    if (sz == 8) {
+      ofs += 4;
+      lua_assert((ir+1)->o == IR_HIOP);
+    }
+    for (;;) {
+      Reg r = ra_alloc1(as, ir->op2, allow);
+      emit_tai(as, PPCI_STW, r, RID_RET, ofs);
+      rset_clear(allow, r);
+      if (ofs == sizeof(GCcdata)) break;
+      ofs -= 4; ir++;
+    }
+  }
+  /* Initialize gct and typeid. lj_mem_newgco() already sets marked. */
+  emit_tai(as, PPCI_STB, RID_RET+1, RID_RET, offsetof(GCcdata, gct));
+  emit_tai(as, PPCI_STH, RID_TMP, RID_RET, offsetof(GCcdata, typeid));
+  emit_ti(as, PPCI_LI, RID_RET+1, ~LJ_TCDATA);
+  emit_ti(as, PPCI_LI, RID_TMP, typeid);  /* Lower 16 bit used. Sign-ext ok. */
+  asm_gencall(as, ci, args);
+  ra_allockreg(as, (int32_t)(sz+sizeof(GCcdata)),
+	       ra_releasetmp(as, ASMREF_TMP1));
+}
+#else
+#define asm_cnew(as, ir)	((void)0)
+#endif
+
+/* -- Write barriers ------------------------------------------------------ */
+
+static void asm_tbar(ASMState *as, IRIns *ir)
+{
+  Reg tab = ra_alloc1(as, ir->op1, RSET_GPR);
+  Reg mark = ra_scratch(as, rset_exclude(RSET_GPR, tab));
+  Reg link = RID_TMP;
+  MCLabel l_end = emit_label(as);
+  emit_tai(as, PPCI_STW, link, tab, (int32_t)offsetof(GCtab, gclist));
+  emit_tai(as, PPCI_STB, mark, tab, (int32_t)offsetof(GCtab, marked));
+  emit_setgl(as, tab, gc.grayagain);
+  lua_assert(LJ_GC_BLACK == 0x04);
+  emit_rot(as, PPCI_RLWINM, mark, mark, 0, 30, 28);  /* Clear black bit. */
+  emit_getgl(as, link, gc.grayagain);
+  emit_condbranch(as, PPCI_BC|PPCF_Y, CC_EQ, l_end);
+  emit_asi(as, PPCI_ANDIDOT, RID_TMP, mark, LJ_GC_BLACK);
+  emit_tai(as, PPCI_LBZ, mark, tab, (int32_t)offsetof(GCtab, marked));
+}
+
+static void asm_obar(ASMState *as, IRIns *ir)
+{
+  const CCallInfo *ci = &lj_ir_callinfo[IRCALL_lj_gc_barrieruv];
+  IRRef args[2];
+  MCLabel l_end;
+  Reg obj, val, tmp;
+  /* No need for other object barriers (yet). */
+  lua_assert(IR(ir->op1)->o == IR_UREFC);
+  ra_evictset(as, RSET_SCRATCH);
+  l_end = emit_label(as);
+  args[0] = ASMREF_TMP1;  /* global_State *g */
+  args[1] = ir->op1;      /* TValue *tv      */
+  asm_gencall(as, ci, args);
+  emit_tai(as, PPCI_ADDI, ra_releasetmp(as, ASMREF_TMP1), RID_JGL, -32768);
+  obj = IR(ir->op1)->r;
+  tmp = ra_scratch(as, rset_exclude(RSET_GPR, obj));
+  emit_condbranch(as, PPCI_BC|PPCF_Y, CC_EQ, l_end);
+  emit_asi(as, PPCI_ANDIDOT, tmp, tmp, LJ_GC_BLACK);
+  emit_condbranch(as, PPCI_BC, CC_EQ, l_end);
+  emit_asi(as, PPCI_ANDIDOT, RID_TMP, RID_TMP, LJ_GC_WHITES);
+  val = ra_alloc1(as, ir->op2, rset_exclude(RSET_GPR, obj));
+  emit_tai(as, PPCI_LBZ, tmp, obj,
+	   (int32_t)offsetof(GCupval, marked)-(int32_t)offsetof(GCupval, tv));
+  emit_tai(as, PPCI_LBZ, RID_TMP, val, (int32_t)offsetof(GChead, marked));
+}
+
+/* -- Arithmetic and logic operations ------------------------------------- */
+
+static void asm_fparith(ASMState *as, IRIns *ir, PPCIns pi)
+{
+  Reg dest = ra_dest(as, ir, RSET_FPR);
+  Reg right, left = ra_alloc2(as, ir, RSET_FPR);
+  right = (left >> 8); left &= 255;
+  if (pi == PPCI_FMUL)
+    emit_fac(as, pi, dest, left, right);
+  else
+    emit_fab(as, pi, dest, left, right);
+}
+
+static void asm_fpunary(ASMState *as, IRIns *ir, PPCIns pi)
+{
+  Reg dest = ra_dest(as, ir, RSET_FPR);
+  Reg left = ra_hintalloc(as, ir->op1, dest, RSET_FPR);
+  emit_fb(as, pi, dest, left);
+}
+
+static int asm_fpjoin_pow(ASMState *as, IRIns *ir)
+{
+  IRIns *irp = IR(ir->op1);
+  if (irp == ir-1 && irp->o == IR_MUL && !ra_used(irp)) {
+    IRIns *irpp = IR(irp->op1);
+    if (irpp == ir-2 && irpp->o == IR_FPMATH &&
+	irpp->op2 == IRFPM_LOG2 && !ra_used(irpp)) {
+      const CCallInfo *ci = &lj_ir_callinfo[IRCALL_pow];
+      IRRef args[2];
+      args[0] = irpp->op1;
+      args[1] = irp->op2;
+      asm_setupresult(as, ir, ci);
+      asm_gencall(as, ci, args);
+      return 1;
+    }
+  }
+  return 0;
+}
+
+static void asm_add(ASMState *as, IRIns *ir)
+{
+  if (irt_isnum(ir->t)) {
+    if (!asm_fusemadd(as, ir, PPCI_FMADD, PPCI_FMADD))
+      asm_fparith(as, ir, PPCI_FADD);
+  } else {
+    Reg dest = ra_dest(as, ir, RSET_GPR);
+    Reg right, left = ra_hintalloc(as, ir->op1, dest, RSET_GPR);
+    PPCIns pi;
+    if (irref_isk(ir->op2)) {
+      int32_t k = IR(ir->op2)->i;
+      if (checki16(k)) {
+	pi = PPCI_ADDI;
+	/* May fail due to spills/restores above, but simplifies the logic. */
+	if (as->flagmcp == as->mcp) {
+	  as->flagmcp = NULL;
+	  as->mcp++;
+	  pi = PPCI_ADDICDOT;
+	}
+	emit_tai(as, pi, dest, left, k);
+	return;
+      } else if ((k & 0xffff) == 0) {
+	emit_tai(as, PPCI_ADDIS, dest, left, (k >> 16));
+	return;
+      } else if (!as->sectref) {
+	emit_tai(as, PPCI_ADDIS, dest, dest, (k + 32768) >> 16);
+	emit_tai(as, PPCI_ADDI, dest, left, k);
+	return;
+      }
+    }
+    pi = PPCI_ADD;
+    /* May fail due to spills/restores above, but simplifies the logic. */
+    if (as->flagmcp == as->mcp) {
+      as->flagmcp = NULL;
+      as->mcp++;
+      pi |= PPCF_DOT;
+    }
+    right = ra_alloc1(as, ir->op2, rset_exclude(RSET_GPR, left));
+    emit_tab(as, pi, dest, left, right);
+  }
+}
+
+static void asm_sub(ASMState *as, IRIns *ir)
+{
+  if (irt_isnum(ir->t)) {
+    if (!asm_fusemadd(as, ir, PPCI_FMSUB, PPCI_FNMSUB))
+      asm_fparith(as, ir, PPCI_FSUB);
+  } else {
+    PPCIns pi = PPCI_SUBF;
+    Reg dest = ra_dest(as, ir, RSET_GPR);
+    Reg left, right;
+    if (irref_isk(ir->op1)) {
+      int32_t k = IR(ir->op1)->i;
+      if (checki16(k)) {
+	right = ra_alloc1(as, ir->op2, RSET_GPR);
+	emit_tai(as, PPCI_SUBFIC, dest, right, k);
+	return;
+      }
+    }
+    /* May fail due to spills/restores above, but simplifies the logic. */
+    if (as->flagmcp == as->mcp) {
+      as->flagmcp = NULL;
+      as->mcp++;
+      pi |= PPCF_DOT;
+    }
+    left = ra_hintalloc(as, ir->op1, dest, RSET_GPR);
+    right = ra_alloc1(as, ir->op2, rset_exclude(RSET_GPR, left));
+    emit_tab(as, pi, dest, right, left);  /* Subtract right _from_ left. */
+  }
+}
+
+static void asm_mul(ASMState *as, IRIns *ir)
+{
+  if (irt_isnum(ir->t)) {
+    asm_fparith(as, ir, PPCI_FMUL);
+  } else {
+    PPCIns pi = PPCI_MULLW;
+    Reg dest = ra_dest(as, ir, RSET_GPR);
+    Reg right, left = ra_hintalloc(as, ir->op1, dest, RSET_GPR);
+    if (irref_isk(ir->op2)) {
+      int32_t k = IR(ir->op2)->i;
+      if (checki16(k)) {
+	emit_tai(as, PPCI_MULLI, dest, left, k);
+	return;
+      }
+    }
+    /* May fail due to spills/restores above, but simplifies the logic. */
+    if (as->flagmcp == as->mcp) {
+      as->flagmcp = NULL;
+      as->mcp++;
+      pi |= PPCF_DOT;
+    }
+    right = ra_alloc1(as, ir->op2, rset_exclude(RSET_GPR, left));
+    emit_tab(as, pi, dest, left, right);
+  }
+}
+
+static void asm_neg(ASMState *as, IRIns *ir)
+{
+  if (irt_isnum(ir->t)) {
+    asm_fpunary(as, ir, PPCI_FNEG);
+  } else {
+    Reg dest, left;
+    PPCIns pi = PPCI_NEG;
+    if (as->flagmcp == as->mcp) {
+      as->flagmcp = NULL;
+      as->mcp++;
+      pi |= PPCF_DOT;
+    }
+    dest = ra_dest(as, ir, RSET_GPR);
+    left = ra_hintalloc(as, ir->op1, dest, RSET_GPR);
+    emit_tab(as, pi, dest, left, 0);
+  }
+}
+
+static void asm_arithov(ASMState *as, IRIns *ir, PPCIns pi)
+{
+  Reg dest, left, right;
+  if (as->flagmcp == as->mcp) {
+    as->flagmcp = NULL;
+    as->mcp++;
+  }
+  asm_guardcc(as, CC_SO);
+  dest = ra_dest(as, ir, RSET_GPR);
+  left = ra_alloc2(as, ir, RSET_GPR);
+  right = (left >> 8); left &= 255;
+  if (pi == PPCI_SUBFO) { Reg tmp = left; left = right; right = tmp; }
+  emit_tab(as, pi|PPCF_DOT, dest, left, right);
+}
+
+#if LJ_HASFFI
+static void asm_add64(ASMState *as, IRIns *ir)
+{
+  Reg dest = ra_dest(as, ir, RSET_GPR);
+  Reg right, left = ra_alloc1(as, ir->op1, RSET_GPR);
+  PPCIns pi = PPCI_ADDE;
+  if (irref_isk(ir->op2)) {
+    int32_t k = IR(ir->op2)->i;
+    if (k == 0)
+      pi = PPCI_ADDZE;
+    else if (k == -1)
+      pi = PPCI_ADDME;
+    else
+      goto needright;
+    right = 0;
+  } else {
+  needright:
+    right = ra_alloc1(as, ir->op2, rset_exclude(RSET_GPR, left));
+  }
+  emit_tab(as, pi, dest, left, right);
+  ir--;
+  dest = ra_dest(as, ir, RSET_GPR);
+  left = ra_alloc1(as, ir->op1, RSET_GPR);
+  if (irref_isk(ir->op2)) {
+    int32_t k = IR(ir->op2)->i;
+    if (checki16(k)) {
+      emit_tai(as, PPCI_ADDIC, dest, left, k);
+      return;
+    }
+  }
+  right = ra_alloc1(as, ir->op2, rset_exclude(RSET_GPR, left));
+  emit_tab(as, PPCI_ADDC, dest, left, right);
+}
+
+static void asm_sub64(ASMState *as, IRIns *ir)
+{
+  Reg dest = ra_dest(as, ir, RSET_GPR);
+  Reg left, right = ra_alloc1(as, ir->op2, RSET_GPR);
+  PPCIns pi = PPCI_SUBFE;
+  if (irref_isk(ir->op1)) {
+    int32_t k = IR(ir->op1)->i;
+    if (k == 0)
+      pi = PPCI_SUBFZE;
+    else if (k == -1)
+      pi = PPCI_SUBFME;
+    else
+      goto needleft;
+    left = 0;
+  } else {
+  needleft:
+    left = ra_alloc1(as, ir->op1, rset_exclude(RSET_GPR, right));
+  }
+  emit_tab(as, pi, dest, right, left);  /* Subtract right _from_ left. */
+  ir--;
+  dest = ra_dest(as, ir, RSET_GPR);
+  right = ra_alloc1(as, ir->op2, RSET_GPR);
+  if (irref_isk(ir->op1)) {
+    int32_t k = IR(ir->op1)->i;
+    if (checki16(k)) {
+      emit_tai(as, PPCI_SUBFIC, dest, right, k);
+      return;
+    }
+  }
+  left = ra_alloc1(as, ir->op1, rset_exclude(RSET_GPR, right));
+  emit_tab(as, PPCI_SUBFC, dest, right, left);
+}
+
+static void asm_neg64(ASMState *as, IRIns *ir)
+{
+  Reg dest = ra_dest(as, ir, RSET_GPR);
+  Reg left = ra_alloc1(as, ir->op1, RSET_GPR);
+  emit_tab(as, PPCI_SUBFZE, dest, left, 0);
+  ir--;
+  dest = ra_dest(as, ir, RSET_GPR);
+  left = ra_alloc1(as, ir->op1, RSET_GPR);
+  emit_tai(as, PPCI_SUBFIC, dest, left, 0);
+}
+#endif
+
+static void asm_bitnot(ASMState *as, IRIns *ir)
+{
+  Reg dest, left, right;
+  PPCIns pi = PPCI_NOR;
+  if (as->flagmcp == as->mcp) {
+    as->flagmcp = NULL;
+    as->mcp++;
+    pi |= PPCF_DOT;
+  }
+  dest = ra_dest(as, ir, RSET_GPR);
+  if (mayfuse(as, ir->op1)) {
+    IRIns *irl = IR(ir->op1);
+    if (irl->o == IR_BAND)
+      pi ^= (PPCI_NOR ^ PPCI_NAND);
+    else if (irl->o == IR_BXOR)
+      pi ^= (PPCI_NOR ^ PPCI_EQV);
+    else if (irl->o != IR_BOR)
+      goto nofuse;
+    left = ra_hintalloc(as, irl->op1, dest, RSET_GPR);
+    right = ra_alloc1(as, irl->op2, rset_exclude(RSET_GPR, left));
+  } else {
+nofuse:
+    left = right = ra_hintalloc(as, ir->op1, dest, RSET_GPR);
+  }
+  emit_asb(as, pi, dest, left, right);
+}
+
+static void asm_bitswap(ASMState *as, IRIns *ir)
+{
+  Reg dest = ra_dest(as, ir, RSET_GPR);
+  IRIns *irx;
+  if (mayfuse(as, ir->op1) && (irx = IR(ir->op1))->o == IR_XLOAD &&
+      ra_noreg(irx->r) && (irt_isint(irx->t) || irt_isu32(irx->t))) {
+    /* Fuse BSWAP with XLOAD to lwbrx. */
+    asm_fusexrefx(as, PPCI_LWBRX, dest, irx->op1, RSET_GPR);
+  } else {
+    Reg left = ra_alloc1(as, ir->op1, RSET_GPR);
+    Reg tmp = dest;
+    if (tmp == left) {
+      tmp = RID_TMP;
+      emit_mr(as, dest, RID_TMP);
+    }
+    emit_rot(as, PPCI_RLWIMI, tmp, left, 24, 16, 23);
+    emit_rot(as, PPCI_RLWIMI, tmp, left, 24, 0, 7);
+    emit_rotlwi(as, tmp, left, 8);
+  }
+}
+
+static void asm_bitop(ASMState *as, IRIns *ir, PPCIns pi, PPCIns pik)
+{
+  Reg dest = ra_dest(as, ir, RSET_GPR);
+  Reg right, left = ra_hintalloc(as, ir->op1, dest, RSET_GPR);
+  if (irref_isk(ir->op2)) {
+    int32_t k = IR(ir->op2)->i;
+    Reg tmp = left;
+    if ((checku16(k) || (k & 0xffff) == 0) || (tmp = dest, !as->sectref)) {
+      if (!checku16(k)) {
+	emit_asi(as, pik ^ (PPCI_ORI ^ PPCI_ORIS), dest, tmp, (k >> 16));
+	if ((k & 0xffff) == 0) return;
+      }
+      emit_asi(as, pik, dest, left, k);
+      return;
+    }
+  }
+  /* May fail due to spills/restores above, but simplifies the logic. */
+  if (as->flagmcp == as->mcp) {
+    as->flagmcp = NULL;
+    as->mcp++;
+    pi |= PPCF_DOT;
+  }
+  right = ra_alloc1(as, ir->op2, rset_exclude(RSET_GPR, left));
+  emit_asb(as, pi, dest, left, right);
+}
+
+/* Fuse BAND with contiguous bitmask and a shift to rlwinm. */
+static void asm_fuseandsh(ASMState *as, PPCIns pi, int32_t mask, IRRef ref)
+{
+  IRIns *ir;
+  Reg left;
+  if (mayfuse(as, ref) && (ir = IR(ref), ra_noreg(ir->r)) &&
+      irref_isk(ir->op2) && ir->o >= IR_BSHL && ir->o <= IR_BROR) {
+    int32_t sh = (IR(ir->op2)->i & 31);
+    switch (ir->o) {
+    case IR_BSHL:
+      if ((mask & ((1u<<sh)-1))) goto nofuse;
+      break;
+    case IR_BSHR:
+      if ((mask & ~((~0u)>>sh))) goto nofuse;
+      sh = ((32-sh)&31);
+      break;
+    case IR_BROL:
+      break;
+    default:
+      goto nofuse;
+    }
+    left = ra_alloc1(as, ir->op1, RSET_GPR);
+    *--as->mcp = pi | PPCF_T(left) | PPCF_B(sh);
+    return;
+  }
+nofuse:
+  left = ra_alloc1(as, ref, RSET_GPR);
+  *--as->mcp = pi | PPCF_T(left);
+}
+
+static void asm_bitand(ASMState *as, IRIns *ir)
+{
+  Reg dest, left, right;
+  IRRef lref = ir->op1;
+  PPCIns dot = 0;
+  IRRef op2;
+  if (as->flagmcp == as->mcp) {
+    as->flagmcp = NULL;
+    as->mcp++;
+    dot = PPCF_DOT;
+  }
+  dest = ra_dest(as, ir, RSET_GPR);
+  if (irref_isk(ir->op2)) {
+    int32_t k = IR(ir->op2)->i;
+    if (k) {
+      /* First check for a contiguous bitmask as used by rlwinm. */
+      uint32_t s1 = lj_ffs((uint32_t)k);
+      uint32_t k1 = ((uint32_t)k >> s1);
+      if ((k1 & (k1+1)) == 0) {
+	asm_fuseandsh(as, PPCI_RLWINM|dot | PPCF_A(dest) |
+			  PPCF_MB(31-lj_fls((uint32_t)k)) | PPCF_ME(31-s1),
+			  k, lref);
+	return;
+      }
+      if (~(uint32_t)k) {
+	uint32_t s2 = lj_ffs(~(uint32_t)k);
+	uint32_t k2 = (~(uint32_t)k >> s2);
+	if ((k2 & (k2+1)) == 0) {
+	  asm_fuseandsh(as, PPCI_RLWINM|dot | PPCF_A(dest) |
+			    PPCF_MB(32-s2) | PPCF_ME(30-lj_fls(~(uint32_t)k)),
+			    k, lref);
+	  return;
+	}
+      }
+    }
+    if (checku16(k)) {
+      left = ra_alloc1(as, lref, RSET_GPR);
+      emit_asi(as, PPCI_ANDIDOT, dest, left, k);
+      return;
+    } else if ((k & 0xffff) == 0) {
+      left = ra_alloc1(as, lref, RSET_GPR);
+      emit_asi(as, PPCI_ANDISDOT, dest, left, (k >> 16));
+      return;
+    }
+  }
+  op2 = ir->op2;
+  if (mayfuse(as, op2) && IR(op2)->o == IR_BNOT && ra_noreg(IR(op2)->r)) {
+    dot ^= (PPCI_AND ^ PPCI_ANDC);
+    op2 = IR(op2)->op1;
+  }
+  left = ra_hintalloc(as, lref, dest, RSET_GPR);
+  right = ra_alloc1(as, op2, rset_exclude(RSET_GPR, left));
+  emit_asb(as, PPCI_AND ^ dot, dest, left, right);
+}
+
+static void asm_bitshift(ASMState *as, IRIns *ir, PPCIns pi, PPCIns pik)
+{
+  Reg dest, left;
+  Reg dot = 0;
+  if (as->flagmcp == as->mcp) {
+    as->flagmcp = NULL;
+    as->mcp++;
+    dot = PPCF_DOT;
+  }
+  dest = ra_dest(as, ir, RSET_GPR);
+  left = ra_alloc1(as, ir->op1, RSET_GPR);
+  if (irref_isk(ir->op2)) {  /* Constant shifts. */
+    int32_t shift = (IR(ir->op2)->i & 31);
+    if (pik == 0)  /* SLWI */
+      emit_rot(as, PPCI_RLWINM|dot, dest, left, shift, 0, 31-shift);
+    else if (pik == 1)  /* SRWI */
+      emit_rot(as, PPCI_RLWINM|dot, dest, left, (32-shift)&31, shift, 31);
+    else
+      emit_asb(as, pik|dot, dest, left, shift);
+  } else {
+    Reg right = ra_alloc1(as, ir->op2, rset_exclude(RSET_GPR, left));
+    emit_asb(as, pi|dot, dest, left, right);
+  }
+}
+
+static void asm_min_max(ASMState *as, IRIns *ir, int ismax)
+{
+  if (irt_isnum(ir->t)) {
+    Reg dest = ra_dest(as, ir, RSET_FPR);
+    Reg tmp = dest;
+    Reg right, left = ra_alloc2(as, ir, RSET_FPR);
+    right = (left >> 8); left &= 255;
+    if (tmp == left || tmp == right)
+      tmp = ra_scratch(as, rset_exclude(rset_exclude(rset_exclude(RSET_FPR,
+					dest), left), right));
+    emit_facb(as, PPCI_FSEL, dest, tmp,
+	      ismax ? left : right, ismax ? right : left);
+    emit_fab(as, PPCI_FSUB, tmp, left, right);
+  } else {
+    Reg dest = ra_dest(as, ir, RSET_GPR);
+    Reg tmp1 = RID_TMP, tmp2 = dest;
+    Reg right, left = ra_alloc2(as, ir, RSET_GPR);
+    right = (left >> 8); left &= 255;
+    if (tmp2 == left || tmp2 == right)
+      tmp2 = ra_scratch(as, rset_exclude(rset_exclude(rset_exclude(RSET_GPR,
+					 dest), left), right));
+    emit_tab(as, PPCI_ADD, dest, tmp2, right);
+    emit_asb(as, ismax ? PPCI_ANDC : PPCI_AND, tmp2, tmp2, tmp1);
+    emit_tab(as, PPCI_SUBFE, tmp1, tmp1, tmp1);
+    emit_tab(as, PPCI_SUBFC, tmp2, tmp2, tmp1);
+    emit_asi(as, PPCI_XORIS, tmp2, right, 0x8000);
+    emit_asi(as, PPCI_XORIS, tmp1, left, 0x8000);
+  }
+}
+
+/* -- Comparisons --------------------------------------------------------- */
+
+#define CC_UNSIGNED	0x08	/* Unsigned integer comparison. */
+#define CC_TWO		0x80	/* Check two flags for FP comparison. */
+
+/* Map of comparisons to flags. ORDER IR. */
+static const uint8_t asm_compmap[IR_ABC+1] = {
+  /* op     int cc                 FP cc */
+  /* LT  */ CC_GE               + (CC_GE<<4),
+  /* GE  */ CC_LT               + (CC_LE<<4) + CC_TWO,
+  /* LE  */ CC_GT               + (CC_GE<<4) + CC_TWO,
+  /* GT  */ CC_LE               + (CC_LE<<4),
+  /* ULT */ CC_GE + CC_UNSIGNED + (CC_GT<<4) + CC_TWO,
+  /* UGE */ CC_LT + CC_UNSIGNED + (CC_LT<<4),
+  /* ULE */ CC_GT + CC_UNSIGNED + (CC_GT<<4),
+  /* UGT */ CC_LE + CC_UNSIGNED + (CC_LT<<4) + CC_TWO,
+  /* EQ  */ CC_NE               + (CC_NE<<4),
+  /* NE  */ CC_EQ               + (CC_EQ<<4),
+  /* ABC */ CC_LE + CC_UNSIGNED + (CC_LT<<4) + CC_TWO  /* Same as UGT. */
+};
+
+static void asm_intcomp_(ASMState *as, IRRef lref, IRRef rref, Reg cr, PPCCC cc)
+{
+  Reg right, left = ra_alloc1(as, lref, RSET_GPR);
+  if (irref_isk(rref)) {
+    int32_t k = IR(rref)->i;
+    if ((cc & CC_UNSIGNED) == 0) {  /* Signed comparison with constant. */
+      if (checki16(k)) {
+	emit_tai(as, PPCI_CMPWI, cr, left, k);
+	/* Signed comparison with zero and referencing previous ins? */
+	if (k == 0 && lref == as->curins-1)
+	  as->flagmcp = as->mcp;  /* Allow elimination of the compare. */
+	return;
+      } else if ((cc & 3) == (CC_EQ & 3)) {  /* Use CMPLWI for EQ or NE. */
+	if (checku16(k)) {
+	  emit_tai(as, PPCI_CMPLWI, cr, left, k);
+	  return;
+	} else if (!as->sectref && ra_noreg(IR(rref)->r)) {
+	  emit_tai(as, PPCI_CMPLWI, cr, RID_TMP, k);
+	  emit_asi(as, PPCI_XORIS, RID_TMP, left, (k >> 16));
+	  return;
+	}
+      }
+    } else {  /* Unsigned comparison with constant. */
+      if (checku16(k)) {
+	emit_tai(as, PPCI_CMPLWI, cr, left, k);
+	return;
+      }
+    }
+  }
+  right = ra_alloc1(as, rref, rset_exclude(RSET_GPR, left));
+  emit_tab(as, (cc & CC_UNSIGNED) ? PPCI_CMPLW : PPCI_CMPW, cr, left, right);
+}
+
+static void asm_comp(ASMState *as, IRIns *ir)
+{
+  PPCCC cc = asm_compmap[ir->o];
+  if (irt_isnum(ir->t)) {
+    Reg right, left = ra_alloc2(as, ir, RSET_FPR);
+    right = (left >> 8); left &= 255;
+    asm_guardcc(as, (cc >> 4));
+    if ((cc & CC_TWO))
+      emit_tab(as, PPCI_CROR, ((cc>>4)&3), ((cc>>4)&3), (CC_EQ&3));
+    emit_fab(as, PPCI_FCMPU, 0, left, right);
+  } else {
+    IRRef lref = ir->op1, rref = ir->op2;
+    if (irref_isk(lref) && !irref_isk(rref)) {
+      /* Swap constants to the right (only for ABC). */
+      IRRef tmp = lref; lref = rref; rref = tmp;
+      if ((cc & 2) == 0) cc ^= 1;  /* LT <-> GT, LE <-> GE */
+    }
+    asm_guardcc(as, cc);
+    asm_intcomp_(as, lref, rref, 0, cc);
+  }
+}
+
+#if LJ_HASFFI
+/* 64 bit integer comparisons. */
+static void asm_comp64(ASMState *as, IRIns *ir)
+{
+  PPCCC cc = asm_compmap[(ir-1)->o];
+  if ((cc&3) == (CC_EQ&3)) {
+    asm_guardcc(as, cc);
+    emit_tab(as, (cc&4) ? PPCI_CRAND : PPCI_CROR,
+	     (CC_EQ&3), (CC_EQ&3), 4+(CC_EQ&3));
+  } else {
+    asm_guardcc(as, CC_EQ);
+    emit_tab(as, PPCI_CROR, (CC_EQ&3), (CC_EQ&3), ((cc^~(cc>>2))&1));
+    emit_tab(as, (cc&4) ? PPCI_CRAND : PPCI_CRANDC,
+	     (CC_EQ&3), (CC_EQ&3), 4+(cc&3));
+  }
+  /* Loword comparison sets cr1 and is unsigned, except for equality. */
+  asm_intcomp_(as, (ir-1)->op1, (ir-1)->op2, 4,
+	       cc | ((cc&3) == (CC_EQ&3) ? 0 : CC_UNSIGNED));
+  /* Hiword comparison sets cr0. */
+  asm_intcomp_(as, ir->op1, ir->op2, 0, cc);
+  as->flagmcp = NULL;  /* Doesn't work here. */
+}
+#endif
+
+/* -- Support for 64 bit ops in 32 bit mode ------------------------------- */
+
+/* Hiword op of a split 64 bit op. Previous op must be the loword op. */
+static void asm_hiop(ASMState *as, IRIns *ir)
+{
+#if LJ_HASFFI
+  /* HIOP is marked as a store because it needs its own DCE logic. */
+  int uselo = ra_used(ir-1), usehi = ra_used(ir);  /* Loword/hiword used? */
+  if (LJ_UNLIKELY(!(as->flags & JIT_F_OPT_DCE))) uselo = usehi = 1;
+  if ((ir-1)->o == IR_CONV) {  /* Conversions to/from 64 bit. */
+    as->curins--;  /* Always skip the CONV. */
+    if (usehi || uselo)
+      asm_conv64(as, ir);
+    return;
+  } else if ((ir-1)->o <= IR_NE) {  /* 64 bit integer comparisons. ORDER IR. */
+    as->curins--;  /* Always skip the loword comparison. */
+    asm_comp64(as, ir);
+    return;
+  }
+  if (!usehi) return;  /* Skip unused hiword op for all remaining ops. */
+  switch ((ir-1)->o) {
+  case IR_ADD: as->curins--; asm_add64(as, ir); break;
+  case IR_SUB: as->curins--; asm_sub64(as, ir); break;
+  case IR_NEG: as->curins--; asm_neg64(as, ir); break;
+  case IR_CALLN:
+  case IR_CALLXS:
+    if (!uselo)
+      ra_allocref(as, ir->op1, RID2RSET(RID_RETLO));  /* Mark lo op as used. */
+    break;
+  case IR_CNEWI:
+    /* Nothing to do here. Handled by lo op itself. */
+    break;
+  default: lua_assert(0); break;
+  }
+#else
+  UNUSED(as); UNUSED(ir); lua_assert(0);  /* Unused without FFI. */
+#endif
+}
+
+/* -- Stack handling ------------------------------------------------------ */
+
+/* Check Lua stack size for overflow. Use exit handler as fallback. */
+static void asm_stack_check(ASMState *as, BCReg topslot,
+			    IRIns *irp, RegSet allow, ExitNo exitno)
+{
+  /* Try to get an unused temp. register, otherwise spill/restore RID_RET*. */
+  Reg tmp, pbase = irp ? (ra_hasreg(irp->r) ? irp->r : RID_TMP) : RID_BASE;
+  rset_clear(allow, pbase);
+  tmp = allow ? rset_pickbot(allow) :
+		(pbase == RID_RETHI ? RID_RETLO : RID_RETHI);
+  emit_condbranch(as, PPCI_BC, CC_LT, asm_exitstub_addr(as, exitno));
+  if (allow == RSET_EMPTY)  /* Restore temp. register. */
+    emit_tai(as, PPCI_LWZ, tmp, RID_SP, SPOFS_TMPW);
+  else
+    ra_modified(as, tmp);
+  emit_ai(as, PPCI_CMPLWI, RID_TMP, (int32_t)(8*topslot));
+  emit_tab(as, PPCI_SUBF, RID_TMP, pbase, tmp);
+  emit_tai(as, PPCI_LWZ, tmp, tmp, offsetof(lua_State, maxstack));
+  if (pbase == RID_TMP)
+    emit_getgl(as, RID_TMP, jit_base);
+  emit_getgl(as, tmp, jit_L);
+  if (allow == RSET_EMPTY)  /* Spill temp. register. */
+    emit_tai(as, PPCI_STW, tmp, RID_SP, SPOFS_TMPW);
+}
+
+/* Restore Lua stack from on-trace state. */
+static void asm_stack_restore(ASMState *as, SnapShot *snap)
+{
+  SnapEntry *map = &as->T->snapmap[snap->mapofs];
+  SnapEntry *flinks = &as->T->snapmap[snap_nextofs(as->T, snap)-1];
+  MSize n, nent = snap->nent;
+  /* Store the value of all modified slots to the Lua stack. */
+  for (n = 0; n < nent; n++) {
+    SnapEntry sn = map[n];
+    BCReg s = snap_slot(sn);
+    int32_t ofs = 8*((int32_t)s-1);
+    IRRef ref = snap_ref(sn);
+    IRIns *ir = IR(ref);
+    if ((sn & SNAP_NORESTORE))
+      continue;
+    if (irt_isnum(ir->t)) {
+      Reg src = ra_alloc1(as, ref, RSET_FPR);
+      emit_fai(as, PPCI_STFD, src, RID_BASE, ofs);
+    } else {
+      Reg type;
+      RegSet allow = rset_exclude(RSET_GPR, RID_BASE);
+      lua_assert(irt_ispri(ir->t) || irt_isaddr(ir->t) || irt_isinteger(ir->t));
+      if (!irt_ispri(ir->t)) {
+	Reg src = ra_alloc1(as, ref, allow);
+	rset_clear(allow, src);
+	emit_tai(as, PPCI_STW, src, RID_BASE, ofs+4);
+      }
+      if ((sn & (SNAP_CONT|SNAP_FRAME))) {
+	if (s == 0) continue;  /* Do not overwrite link to previous frame. */
+	type = ra_allock(as, (int32_t)(*flinks--), allow);
+      } else {
+	type = ra_allock(as, (int32_t)irt_toitype(ir->t), allow);
+      }
+      emit_tai(as, PPCI_STW, type, RID_BASE, ofs);
+    }
+    checkmclim(as);
+  }
+  lua_assert(map + nent == flinks);
+}
+
+/* -- GC handling --------------------------------------------------------- */
+
+/* Check GC threshold and do one or more GC steps. */
+static void asm_gc_check(ASMState *as)
+{
+  const CCallInfo *ci = &lj_ir_callinfo[IRCALL_lj_gc_step_jit];
+  IRRef args[2];
+  MCLabel l_end;
+  Reg tmp;
+  ra_evictset(as, RSET_SCRATCH);
+  l_end = emit_label(as);
+  /* Exit trace if in GCSatomic or GCSfinalize. Avoids syncing GC objects. */
+  asm_guardcc(as, CC_NE);  /* Assumes asm_snap_prep() already done. */
+  emit_ai(as, PPCI_CMPWI, RID_RET, 0);
+  args[0] = ASMREF_TMP1;  /* global_State *g */
+  args[1] = ASMREF_TMP2;  /* MSize steps     */
+  asm_gencall(as, ci, args);
+  emit_tai(as, PPCI_ADDI, ra_releasetmp(as, ASMREF_TMP1), RID_JGL, -32768);
+  tmp = ra_releasetmp(as, ASMREF_TMP2);
+  emit_loadi(as, tmp, (int32_t)as->gcsteps);
+  /* Jump around GC step if GC total < GC threshold. */
+  emit_condbranch(as, PPCI_BC|PPCF_Y, CC_LT, l_end);
+  emit_ab(as, PPCI_CMPLW, RID_TMP, tmp);
+  emit_getgl(as, tmp, gc.threshold);
+  emit_getgl(as, RID_TMP, gc.total);
+  as->gcsteps = 0;
+  checkmclim(as);
+}
+
+/* -- Loop handling ------------------------------------------------------- */
+
+/* Fixup the loop branch. */
+static void asm_loop_fixup(ASMState *as)
+{
+  MCode *p = as->mctop;
+  MCode *target = as->mcp;
+  if (as->loopinv) {  /* Inverted loop branch? */
+    /* asm_guardcc already inverted the cond branch and patched the final b. */
+    p[-2] = (p[-2] & (0xffff0000u & ~PPCF_Y)) | (((target-p+2) & 0x3fffu) << 2);
+  } else {
+    p[-1] = PPCI_B|(((target-p+1)&0x00ffffffu)<<2);
+  }
+}
+
+/* -- Head of trace ------------------------------------------------------- */
+
+/* Coalesce BASE register for a root trace. */
+static void asm_head_root_base(ASMState *as)
+{
+  IRIns *ir = IR(REF_BASE);
+  Reg r = ir->r;
+  if (ra_hasreg(r)) {
+    ra_free(as, r);
+    if (rset_test(as->modset, r))
+      ir->r = RID_INIT;  /* No inheritance for modified BASE register. */
+    if (r != RID_BASE)
+      emit_mr(as, r, RID_BASE);
+  }
+}
+
+/* Coalesce BASE register for a side trace. */
+static RegSet asm_head_side_base(ASMState *as, IRIns *irp, RegSet allow)
+{
+  IRIns *ir = IR(REF_BASE);
+  Reg r = ir->r;
+  if (ra_hasreg(r)) {
+    ra_free(as, r);
+    if (rset_test(as->modset, r))
+      ir->r = RID_INIT;  /* No inheritance for modified BASE register. */
+    if (irp->r == r) {
+      rset_clear(allow, r);  /* Mark same BASE register as coalesced. */
+    } else if (ra_hasreg(irp->r) && rset_test(as->freeset, irp->r)) {
+      rset_clear(allow, irp->r);
+      emit_mr(as, r, irp->r);  /* Move from coalesced parent reg. */
+    } else {
+      emit_getgl(as, r, jit_base);  /* Otherwise reload BASE. */
+    }
+  }
+  return allow;
+}
+
+/* -- Tail of trace ------------------------------------------------------- */
+
+/* Fixup the tail code. */
+static void asm_tail_fixup(ASMState *as, TraceNo lnk)
+{
+  MCode *p = as->mctop;
+  MCode *target;
+  int32_t spadj = as->T->spadjust;
+  if (spadj == 0) {
+    *--p = PPCI_NOP;
+    *--p = PPCI_NOP;
+    as->mctop = p;
+  } else {
+    /* Patch stack adjustment. */
+    lua_assert(checki16(CFRAME_SIZE+spadj));
+    p[-3] = PPCI_ADDI | PPCF_T(RID_TMP) | PPCF_A(RID_SP) | (CFRAME_SIZE+spadj);
+    p[-2] = PPCI_STWU | PPCF_T(RID_TMP) | PPCF_A(RID_SP) | spadj;
+  }
+  /* Patch exit branch. */
+  target = lnk ? traceref(as->J, lnk)->mcode : (MCode *)lj_vm_exit_interp;
+  p[-1] = PPCI_B|(((target-p+1)&0x00ffffffu)<<2);
+}
+
+/* Prepare tail of code. */
+static void asm_tail_prep(ASMState *as)
+{
+  MCode *p = as->mctop - 1;  /* Leave room for exit branch. */
+  if (as->loopref) {
+    as->invmcp = as->mcp = p;
+  } else {
+    as->mcp = p-2;  /* Leave room for stack pointer adjustment. */
+    as->invmcp = NULL;
+  }
+}
+
+/* -- Instruction dispatch ------------------------------------------------ */
+
+/* Assemble a single instruction. */
+static void asm_ir(ASMState *as, IRIns *ir)
+{
+  switch ((IROp)ir->o) {
+  /* Miscellaneous ops. */
+  case IR_LOOP: asm_loop(as); break;
+  case IR_NOP: case IR_XBAR: lua_assert(!ra_used(ir)); break;
+  case IR_USE:
+    ra_alloc1(as, ir->op1, irt_isfp(ir->t) ? RSET_FPR : RSET_GPR); break;
+  case IR_PHI: asm_phi(as, ir); break;
+  case IR_HIOP: asm_hiop(as, ir); break;
+
+  /* Guarded assertions. */
+  case IR_EQ: case IR_NE:
+    if ((ir-1)->o == IR_HREF && ir->op1 == as->curins-1) {
+      as->curins--;
+      asm_href(as, ir-1, (IROp)ir->o);
+      break;
+    }
+    /* fallthrough */
+  case IR_LT: case IR_GE: case IR_LE: case IR_GT:
+  case IR_ULT: case IR_UGE: case IR_ULE: case IR_UGT:
+  case IR_ABC:
+    asm_comp(as, ir);
+    break;
+
+  case IR_RETF: asm_retf(as, ir); break;
+
+  /* Bit ops. */
+  case IR_BNOT: asm_bitnot(as, ir); break;
+  case IR_BSWAP: asm_bitswap(as, ir); break;
+
+  case IR_BAND: asm_bitand(as, ir); break;
+  case IR_BOR:  asm_bitop(as, ir, PPCI_OR, PPCI_ORI); break;
+  case IR_BXOR: asm_bitop(as, ir, PPCI_XOR, PPCI_XORI); break;
+
+  case IR_BSHL: asm_bitshift(as, ir, PPCI_SLW, 0); break;
+  case IR_BSHR: asm_bitshift(as, ir, PPCI_SRW, 1); break;
+  case IR_BSAR: asm_bitshift(as, ir, PPCI_SRAW, PPCI_SRAWI); break;
+  case IR_BROL: asm_bitshift(as, ir, PPCI_RLWNM|PPCF_MB(0)|PPCF_ME(31),
+			     PPCI_RLWINM|PPCF_MB(0)|PPCF_ME(31)); break;
+  case IR_BROR: lua_assert(0); break;
+
+  /* Arithmetic ops. */
+  case IR_ADD: asm_add(as, ir); break;
+  case IR_SUB: asm_sub(as, ir); break;
+  case IR_MUL: asm_mul(as, ir); break;
+  case IR_DIV: asm_fparith(as, ir, PPCI_FDIV); break;
+  case IR_MOD: asm_callid(as, ir, IRCALL_lj_vm_modi); break;
+  case IR_POW: asm_callid(as, ir, IRCALL_lj_vm_powi); break;
+  case IR_NEG: asm_neg(as, ir); break;
+
+  case IR_ABS: asm_fpunary(as, ir, PPCI_FABS); break;
+  case IR_ATAN2: asm_callid(as, ir, IRCALL_atan2); break;
+  case IR_LDEXP: asm_callid(as, ir, IRCALL_ldexp); break;
+  case IR_MIN: asm_min_max(as, ir, 0); break;
+  case IR_MAX: asm_min_max(as, ir, 1); break;
+  case IR_FPMATH:
+    if (ir->op2 == IRFPM_EXP2 && asm_fpjoin_pow(as, ir))
+      break;
+    asm_callid(as, ir, IRCALL_lj_vm_floor + ir->op2);
+    break;
+
+  /* Overflow-checking arithmetic ops. */
+  case IR_ADDOV: asm_arithov(as, ir, PPCI_ADDO); break;
+  case IR_SUBOV: asm_arithov(as, ir, PPCI_SUBFO); break;
+  case IR_MULOV: asm_arithov(as, ir, PPCI_MULLWO); break;
+
+  /* Memory references. */
+  case IR_AREF: asm_aref(as, ir); break;
+  case IR_HREF: asm_href(as, ir, 0); break;
+  case IR_HREFK: asm_hrefk(as, ir); break;
+  case IR_NEWREF: asm_newref(as, ir); break;
+  case IR_UREFO: case IR_UREFC: asm_uref(as, ir); break;
+  case IR_FREF: asm_fref(as, ir); break;
+  case IR_STRREF: asm_strref(as, ir); break;
+
+  /* Loads and stores. */
+  case IR_ALOAD: case IR_HLOAD: case IR_ULOAD: case IR_VLOAD:
+    asm_ahuvload(as, ir);
+    break;
+  case IR_FLOAD: asm_fload(as, ir); break;
+  case IR_XLOAD: asm_xload(as, ir); break;
+  case IR_SLOAD: asm_sload(as, ir); break;
+
+  case IR_ASTORE: case IR_HSTORE: case IR_USTORE: asm_ahustore(as, ir); break;
+  case IR_FSTORE: asm_fstore(as, ir); break;
+  case IR_XSTORE: asm_xstore(as, ir); break;
+
+  /* Allocations. */
+  case IR_SNEW: case IR_XSNEW: asm_snew(as, ir); break;
+  case IR_TNEW: asm_tnew(as, ir); break;
+  case IR_TDUP: asm_tdup(as, ir); break;
+  case IR_CNEW: case IR_CNEWI: asm_cnew(as, ir); break;
+
+  /* Write barriers. */
+  case IR_TBAR: asm_tbar(as, ir); break;
+  case IR_OBAR: asm_obar(as, ir); break;
+
+  /* Type conversions. */
+  case IR_CONV: asm_conv(as, ir); break;
+  case IR_TOBIT: asm_tobit(as, ir); break;
+  case IR_TOSTR: asm_tostr(as, ir); break;
+  case IR_STRTO: asm_strto(as, ir); break;
+
+  /* Calls. */
+  case IR_CALLN: case IR_CALLL: case IR_CALLS: asm_call(as, ir); break;
+  case IR_CALLXS: asm_callx(as, ir); break;
+  case IR_CARG: break;
+
+  default:
+    setintV(&as->J->errinfo, ir->o);
+    lj_trace_err_info(as->J, LJ_TRERR_NYIIR);
+    break;
+  }
+}
+
+/* -- Trace setup --------------------------------------------------------- */
+
+/* Ensure there are enough stack slots for call arguments. */
+static Reg asm_setup_call_slots(ASMState *as, IRIns *ir, const CCallInfo *ci)
+{
+  IRRef args[CCI_NARGS_MAX];
+  uint32_t i, nargs = (int)CCI_NARGS(ci);
+  int nslots = 2, ngpr = REGARG_NUMGPR, nfpr = REGARG_NUMFPR;
+  asm_collectargs(as, ir, ci, args);
+  for (i = 0; i < nargs; i++)
+    if (args[i] && irt_isfp(IR(args[i])->t)) {
+      if (nfpr > 0) nfpr--; else nslots = (nslots+3) & ~1;
+    } else {
+      if (ngpr > 0) ngpr--; else nslots++;
+    }
+  if (nslots > as->evenspill)  /* Leave room for args in stack slots. */
+    as->evenspill = nslots;
+  return irt_isfp(ir->t) ? REGSP_HINT(RID_FPRET) : REGSP_HINT(RID_RET);
+}
+
+static void asm_setup_target(ASMState *as)
+{
+  asm_exitstub_setup(as, as->T->nsnap + (as->parent ? 1 : 0));
+}
+
+/* -- Trace patching ------------------------------------------------------ */
+
+/* Patch exit jumps of existing machine code to a new target. */
+void lj_asm_patchexit(jit_State *J, GCtrace *T, ExitNo exitno, MCode *target)
+{
+  MCode *p = T->mcode;
+  MCode *pe = (MCode *)((char *)p + T->szmcode);
+  MCode *px = exitstub_trace_addr(T, exitno);
+  MCode *cstart = NULL;
+  MCode *mcarea = lj_mcode_patch(J, p, 0);
+  int clearso = 0;
+  for (; p < pe; p++) {
+    /* Look for exitstub branch, try to replace with branch to target. */
+    uint32_t ins = *p;
+    if ((ins & 0xfc000000u) == 0x40000000u &&
+	((ins ^ ((char *)px-(char *)p)) & 0xffffu) == 0) {
+      ptrdiff_t delta = (char *)target - (char *)p;
+      if (((ins >> 16) & 3) == (CC_SO&3)) {
+	clearso = sizeof(MCode);
+	delta -= sizeof(MCode);
+      }
+      /* Many, but not all short-range branches can be patched directly. */
+      if (((delta + 0x8000) >> 16) == 0) {
+	*p = (ins & 0xffdf0000u) | ((uint32_t)delta & 0xffffu) |
+	     ((delta & 0x8000) * (PPCF_Y/0x8000));
+	if (!cstart) cstart = p;
+      }
+    } else if ((ins & 0xfc000000u) == PPCI_B &&
+	       ((ins ^ ((char *)px-(char *)p)) & 0x03ffffffu) == 0) {
+      ptrdiff_t delta = (char *)target - (char *)p;
+      lua_assert(((delta + 0x02000000) >> 26) == 0);
+      *p = PPCI_B | ((uint32_t)delta & 0x03ffffffu);
+      if (!cstart) cstart = p;
+    }
+  }
+  {  /* Always patch long-range branch in exit stub itself. */
+    ptrdiff_t delta = (char *)target - (char *)px - clearso;
+    lua_assert(((delta + 0x02000000) >> 26) == 0);
+    *px = PPCI_B | ((uint32_t)delta & 0x03ffffffu);
+  }
+  if (!cstart) cstart = px;
+  lj_mcode_sync(cstart, px+1);
+  if (clearso) {  /* Extend the current trace. Ugly workaround. */
+    MCode *pp = J->cur.mcode;
+    J->cur.szmcode += sizeof(MCode);
+    *--pp = PPCI_MCRXR;  /* Clear SO flag. */
+    J->cur.mcode = pp;
+    lj_mcode_sync(pp, pp+1);
+  }
+  lj_mcode_patch(J, mcarea, 1);
+}
+
diff --git a/third_party/luajit/src/lj_asm_x86.h b/third_party/luajit/src/lj_asm_x86.h
index 141957c709174c93e6283135765bb96f7c7be0b2..1170b6635f4162c8866e7bee831bf6d78ec5e8f8 100644
--- a/third_party/luajit/src/lj_asm_x86.h
+++ b/third_party/luajit/src/lj_asm_x86.h
@@ -118,7 +118,7 @@ static IRRef asm_fuseabase(ASMState *as, IRRef ref)
     lua_assert(irb->op2 == IRFL_TAB_ARRAY);
     /* We can avoid the FLOAD of t->array for colocated arrays. */
     if (ira->o == IR_TNEW && ira->op1 <= LJ_MAX_COLOSIZE &&
-	noconflict(as, irb->op1, IR_NEWREF, 1)) {
+	!neverfuse(as) && noconflict(as, irb->op1, IR_NEWREF, 1)) {
       as->mrm.ofs = (int32_t)sizeof(GCtab);  /* Ofs to colocated array. */
       return irb->op1;  /* Table obj. */
     }
@@ -369,18 +369,76 @@ static Reg asm_fuseload(ASMState *as, IRRef ref, RegSet allow)
 
 /* -- Calls --------------------------------------------------------------- */
 
+/* Count the required number of stack slots for a call. */
+static int asm_count_call_slots(ASMState *as, const CCallInfo *ci, IRRef *args)
+{
+  uint32_t i, nargs = CCI_NARGS(ci);
+  int nslots = 0;
+#if LJ_64
+  if (LJ_ABI_WIN) {
+    nslots = (int)(nargs*2);  /* Only matters for more than four args. */
+  } else {
+    int ngpr = REGARG_NUMGPR, nfpr = REGARG_NUMFPR;
+    for (i = 0; i < nargs; i++)
+      if (args[i] && irt_isfp(IR(args[i])->t)) {
+	if (nfpr > 0) nfpr--; else nslots += 2;
+      } else {
+	if (ngpr > 0) ngpr--; else nslots += 2;
+      }
+  }
+#else
+  int ngpr = 0;
+  if ((ci->flags & CCI_CC_MASK) == CCI_CC_FASTCALL)
+    ngpr = 2;
+  else if ((ci->flags & CCI_CC_MASK) == CCI_CC_THISCALL)
+    ngpr = 1;
+  for (i = 0; i < nargs; i++)
+    if (args[i] && irt_isfp(IR(args[i])->t)) {
+      nslots += irt_isnum(IR(args[i])->t) ? 2 : 1;
+    } else {
+      if (ngpr > 0) ngpr--; else nslots++;
+    }
+#endif
+  return nslots;
+}
+
 /* Generate a call to a C function. */
 static void asm_gencall(ASMState *as, const CCallInfo *ci, IRRef *args)
 {
   uint32_t n, nargs = CCI_NARGS(ci);
   int32_t ofs = STACKARG_OFS;
-  uint32_t gprs = REGARG_GPRS;
 #if LJ_64
+  uint32_t gprs = REGARG_GPRS;
   Reg fpr = REGARG_FIRSTFPR;
+#if !LJ_ABI_WIN
+  MCode *patchnfpr = NULL;
+#endif
+#else
+  uint32_t gprs = 0;
+  if ((ci->flags & CCI_CC_MASK) != CCI_CC_CDECL) {
+    if ((ci->flags & CCI_CC_MASK) == CCI_CC_THISCALL)
+      gprs = (REGARG_GPRS & 31);
+    else if ((ci->flags & CCI_CC_MASK) == CCI_CC_FASTCALL)
+      gprs = REGARG_GPRS;
+  }
 #endif
-  lua_assert(!(nargs > 2 && (ci->flags&CCI_FASTCALL)));  /* Avoid stack adj. */
   if ((void *)ci->func)
     emit_call(as, ci->func);
+#if LJ_64
+  if ((ci->flags & CCI_VARARG)) {  /* Special handling for vararg calls. */
+#if LJ_ABI_WIN
+    for (n = 0; n < 4 && n < nargs; n++) {
+      IRIns *ir = IR(args[n]);
+      if (irt_isfp(ir->t))  /* Duplicate FPRs in GPRs. */
+	emit_rr(as, XO_MOVDto, (irt_isnum(ir->t) ? REX_64 : 0) | (fpr+n),
+		((gprs >> (n*5)) & 31));  /* Either MOVD or MOVQ. */
+    }
+#else
+    patchnfpr = --as->mcp;  /* Indicate number of used FPRs in register al. */
+    *--as->mcp = XI_MOVrib | RID_EAX;
+#endif
+  }
+#endif
   for (n = 0; n < nargs; n++) {  /* Setup args. */
     IRRef ref = args[n];
     IRIns *ir = IR(ref);
@@ -392,15 +450,16 @@ static void asm_gencall(ASMState *as, const CCallInfo *ci, IRRef *args)
 #elif LJ_64
     /* POSIX/x64 argument registers are used in order of appearance. */
     if (irt_isfp(ir->t)) {
-      r = fpr <= REGARG_LASTFPR ? fpr : 0; fpr++;
+      r = fpr <= REGARG_LASTFPR ? fpr++ : 0;
     } else {
       r = gprs & 31; gprs >>= 5;
     }
 #else
-    if (irt_isfp(ir->t) || !(ci->flags & CCI_FASTCALL)) {
+    if (ref && irt_isfp(ir->t)) {
       r = 0;
     } else {
       r = gprs & 31; gprs >>= 5;
+      if (!ref) continue;
     }
 #endif
     if (r) {  /* Argument is in a register. */
@@ -437,11 +496,14 @@ static void asm_gencall(ASMState *as, const CCallInfo *ci, IRRef *args)
 	emit_movmroi(as, RID_ESP, ofs, ir->i);
       } else {
 	r = ra_alloc1(as, ref, RSET_GPR);
-	emit_movtomro(as, REX_64IR(ir, r), RID_ESP, ofs);
+	emit_movtomro(as, REX_64 + r, RID_ESP, ofs);
       }
       ofs += sizeof(intptr_t);
     }
   }
+#if LJ_64 && !LJ_ABI_WIN
+  if (patchnfpr) *patchnfpr = fpr - REGARG_FIRSTFPR;
+#endif
 }
 
 /* Setup result reg/sp for call. Evict scratch regs. */
@@ -463,9 +525,8 @@ static void asm_setupresult(ASMState *as, IRIns *ir, const CCallInfo *ci)
 	  ra_free(as, dest);
 	  ra_modified(as, dest);
 	  emit_rr(as, XO_MOVD, dest|REX_64, RID_RET);  /* Really MOVQ. */
-	} else {
-	  emit_movtomro(as, RID_RET|REX_64, RID_ESP, ofs);
 	}
+	if (ofs) emit_movtomro(as, RID_RET|REX_64, RID_ESP, ofs);
       } else {
 	ra_destreg(as, ir, RID_FPRET);
       }
@@ -479,7 +540,7 @@ static void asm_setupresult(ASMState *as, IRIns *ir, const CCallInfo *ci)
 		  dest, RID_ESP, ofs);
       }
       if ((ci->flags & CCI_CASTU64)) {
-	emit_movtomro(as, RID_RET, RID_ESP, ofs);
+	emit_movtomro(as, RID_RETLO, RID_ESP, ofs);
 	emit_movtomro(as, RID_RETHI, RID_ESP, ofs+4);
       } else {
 	emit_rmro(as, irt_isnum(ir->t) ? XO_FSTPq : XO_FSTPd,
@@ -504,23 +565,54 @@ static void asm_call(ASMState *as, IRIns *ir)
   asm_gencall(as, ci, args);
 }
 
+/* Return a constant function pointer or NULL for indirect calls. */
+static void *asm_callx_func(ASMState *as, IRIns *irf, IRRef func)
+{
+#if LJ_32
+  UNUSED(as);
+  if (irref_isk(func))
+    return (void *)irf->i;
+#else
+  if (irref_isk(func)) {
+    MCode *p;
+    if (irf->o == IR_KINT64)
+      p = (MCode *)(void *)ir_k64(irf)->u64;
+    else
+      p = (MCode *)(void *)(uintptr_t)(uint32_t)irf->i;
+    if (p - as->mcp == (int32_t)(p - as->mcp))
+      return p;  /* Call target is still in +-2GB range. */
+    /* Avoid the indirect case of emit_call(). Try to hoist func addr. */
+  }
+#endif
+  return NULL;
+}
+
 static void asm_callx(ASMState *as, IRIns *ir)
 {
   IRRef args[CCI_NARGS_MAX];
   CCallInfo ci;
+  IRRef func;
   IRIns *irf;
+  int32_t spadj = 0;
   ci.flags = asm_callx_flags(as, ir);
   asm_collectargs(as, ir, &ci, args);
   asm_setupresult(as, ir, &ci);
-  irf = IR(ir->op2);
-  if (LJ_32 && irref_isk(ir->op2)) {  /* Call to constant address on x86. */
-    ci.func = (ASMFunction)(void *)(uintptr_t)(uint32_t)irf->i;
-  } else {
-    /* Prefer a non-argument register or RID_RET for indirect calls. */
-    RegSet allow = (RSET_GPR & ~RSET_SCRATCH)|RID2RSET(RID_RET);
-    Reg r = ra_alloc1(as, ir->op2, allow);
+#if LJ_32
+  /* Have to readjust stack after non-cdecl calls due to callee cleanup. */
+  if ((ci.flags & CCI_CC_MASK) != CCI_CC_CDECL)
+    spadj = 4 * asm_count_call_slots(as, &ci, args);
+#endif
+  func = ir->op2; irf = IR(func);
+  if (irf->o == IR_CARG) { func = irf->op1; irf = IR(func); }
+  ci.func = (ASMFunction)asm_callx_func(as, irf, func);
+  if (!(void *)ci.func) {
+    /* Use a (hoistable) non-scratch register for indirect calls. */
+    RegSet allow = (RSET_GPR & ~RSET_SCRATCH);
+    Reg r = ra_alloc1(as, func, allow);
+    if (LJ_32) emit_spsub(as, spadj);  /* Above code may cause restores! */
     emit_rr(as, XO_GROUP5, XOg_CALL, r);
-    ci.func = (ASMFunction)(void *)0;
+  } else if (LJ_32) {
+    emit_spsub(as, spadj);
   }
   asm_gencall(as, &ci, args);
 }
@@ -620,33 +712,23 @@ static void asm_conv(ASMState *as, IRIns *ir)
       x86Op op = st == IRT_NUM ?
 		 ((ir->op2 & IRCONV_TRUNC) ? XO_CVTTSD2SI : XO_CVTSD2SI) :
 		 ((ir->op2 & IRCONV_TRUNC) ? XO_CVTTSS2SI : XO_CVTSS2SI);
-      if (LJ_32 && irt_isu32(ir->t)) {  /* FP to U32 conversion on x86. */
-	/* u32 = (int32_t)(number - 2^31) + 2^31 */
-	Reg tmp = ra_noreg(IR(lref)->r) ? ra_alloc1(as, lref, RSET_FPR) :
-					  ra_scratch(as, RSET_FPR);
-	emit_gri(as, XG_ARITHi(XOg_ADD), dest, (int32_t)0x80000000);
-	emit_rr(as, op, dest, tmp);
-	if (st == IRT_NUM)
-	  emit_rma(as, XO_ADDSD, tmp,
-		   lj_ir_k64_find(as->J, U64x(c1e00000,00000000)));
-	else
-	  emit_rma(as, XO_ADDSS, tmp,
-		   lj_ir_k64_find(as->J, U64x(00000000,cf000000)));
-	ra_left(as, tmp, lref);
-      } else if (LJ_64 && irt_isu64(ir->t)) {
-	/* For inputs in [2^63,2^64-1] add -2^64 and convert again. */
+      if (LJ_64 ? irt_isu64(ir->t) : irt_isu32(ir->t)) {
+	/* LJ_64: For inputs >= 2^63 add -2^64, convert again. */
+	/* LJ_32: For inputs >= 2^31 add -2^31, convert again and add 2^31. */
 	Reg tmp = ra_noreg(IR(lref)->r) ? ra_alloc1(as, lref, RSET_FPR) :
 					  ra_scratch(as, RSET_FPR);
 	MCLabel l_end = emit_label(as);
+	if (LJ_32)
+	  emit_gri(as, XG_ARITHi(XOg_ADD), dest, (int32_t)0x80000000);
 	emit_rr(as, op, dest|REX_64, tmp);
 	if (st == IRT_NUM)
-	  emit_rma(as, XO_ADDSD, tmp,
-		   lj_ir_k64_find(as->J, U64x(c3f00000,00000000)));
+	  emit_rma(as, XO_ADDSD, tmp, lj_ir_k64_find(as->J,
+		   LJ_64 ? U64x(c3f00000,00000000) : U64x(c1e00000,00000000)));
 	else
-	  emit_rma(as, XO_ADDSS, tmp,
-		   lj_ir_k64_find(as->J, U64x(00000000,df800000)));
+	  emit_rma(as, XO_ADDSS, tmp, lj_ir_k64_find(as->J,
+		   LJ_64 ? U64x(00000000,df800000) : U64x(00000000,cf000000)));
 	emit_sjcc(as, CC_NS, l_end);
-	emit_rr(as, XO_TEST, dest|REX_64, dest);  /* Check if dest < 2^63. */
+	emit_rr(as, XO_TEST, dest|REX_64, dest);  /* Check if dest negative. */
 	emit_rr(as, op, dest|REX_64, tmp);
 	ra_left(as, tmp, lref);
       } else {
@@ -1147,13 +1229,13 @@ static void asm_strref(ASMState *as, IRIns *ir)
 
 static void asm_fxload(ASMState *as, IRIns *ir)
 {
-  Reg dest = ra_dest(as, ir, irt_isnum(ir->t) ? RSET_FPR : RSET_GPR);
+  Reg dest = ra_dest(as, ir, irt_isfp(ir->t) ? RSET_FPR : RSET_GPR);
   x86Op xo;
   if (ir->o == IR_FLOAD)
     asm_fusefref(as, ir, RSET_GPR);
   else
     asm_fusexref(as, ir->op1, RSET_GPR);
-    /* ir->op2 is ignored -- unaligned loads are ok on x86. */
+  /* ir->op2 is ignored -- unaligned loads are ok on x86. */
   switch (irt_type(ir->t)) {
   case IRT_I8: xo = XO_MOVSXb; break;
   case IRT_U8: xo = XO_MOVZXb; break;
@@ -1860,7 +1942,7 @@ static void asm_bitswap(ASMState *as, IRIns *ir)
 {
   Reg dest = ra_dest(as, ir, RSET_GPR);
   as->mcp = emit_op(XO_BSWAP + ((dest&7) << 24),
-		    REX_64IR(ir, dest), 0, 0, as->mcp, 1);
+		    REX_64IR(ir, 0), dest, 0, as->mcp, 1);
   ra_left(as, dest, ir->op1);
 }
 
@@ -2171,26 +2253,32 @@ static void asm_hiop(ASMState *as, IRIns *ir)
   if (!usehi) return;  /* Skip unused hiword op for all remaining ops. */
   switch ((ir-1)->o) {
   case IR_ADD:
-    asm_intarith(as, ir, uselo ? XOg_ADC : XOg_ADD);
+    as->flagmcp = NULL;
+    as->curins--;
+    asm_intarith(as, ir, XOg_ADC);
+    asm_intarith(as, ir-1, XOg_ADD);
     break;
   case IR_SUB:
-    asm_intarith(as, ir, uselo ? XOg_SBB : XOg_SUB);
+    as->flagmcp = NULL;
+    as->curins--;
+    asm_intarith(as, ir, XOg_SBB);
+    asm_intarith(as, ir-1, XOg_SUB);
     break;
   case IR_NEG: {
     Reg dest = ra_dest(as, ir, RSET_GPR);
     emit_rr(as, XO_GROUP3, XOg_NEG, dest);
-    if (uselo) {
-      emit_i8(as, 0);
-      emit_rr(as, XO_ARITHi8, XOg_ADC, dest);
-    }
+    emit_i8(as, 0);
+    emit_rr(as, XO_ARITHi8, XOg_ADC, dest);
     ra_left(as, dest, ir->op1);
+    as->curins--;
+    asm_neg_not(as, ir-1, XOg_NEG);
     break;
     }
   case IR_CALLN:
   case IR_CALLXS:
     ra_destreg(as, ir, RID_RETHI);
     if (!uselo)
-      ra_allocref(as, ir->op1, RID2RSET(RID_RET));  /* Mark call as used. */
+      ra_allocref(as, ir->op1, RID2RSET(RID_RETLO));  /* Mark call as used. */
     break;
   case IR_CNEWI:
     /* Nothing to do here. Handled by CNEWI itself. */
@@ -2232,8 +2320,8 @@ static void asm_stack_check(ASMState *as, BCReg topslot,
 static void asm_stack_restore(ASMState *as, SnapShot *snap)
 {
   SnapEntry *map = &as->T->snapmap[snap->mapofs];
+  SnapEntry *flinks = &as->T->snapmap[snap_nextofs(as->T, snap)-1];
   MSize n, nent = snap->nent;
-  SnapEntry *flinks = map + nent + snap->depth;
   /* Store the value of all modified slots to the Lua stack. */
   for (n = 0; n < nent; n++) {
     SnapEntry sn = map[n];
@@ -2418,8 +2506,7 @@ static void asm_tail_fixup(ASMState *as, TraceNo lnk)
     }
   }
   /* Patch exit branch. */
-  target = lnk == TRACE_INTERP ? (MCode *)lj_vm_exit_interp :
-				 traceref(as->J, lnk)->mcode;
+  target = lnk ? traceref(as->J, lnk)->mcode : (MCode *)lj_vm_exit_interp;
   *(int32_t *)(p-4) = jmprel(p, target);
   p[-5] = XI_JMP;
   /* Drop unused mcode tail. Fill with NOPs to make the prefetcher happy. */
@@ -2614,35 +2701,14 @@ static void asm_ir(ASMState *as, IRIns *ir)
 static Reg asm_setup_call_slots(ASMState *as, IRIns *ir, const CCallInfo *ci)
 {
   IRRef args[CCI_NARGS_MAX];
-  uint32_t nargs = (int)CCI_NARGS(ci);
-  int nslots = 0;
+  int nslots;
   asm_collectargs(as, ir, ci, args);
-#if LJ_64
-  if (LJ_ABI_WIN) {
-    nslots = (int)(nargs*2);  /* Only matters for more than four args. */
-  } else {
-    uint32_t i;
-    int ngpr = 6, nfpr = 8;
-    for (i = 0; i < nargs; i++)
-      if (irt_isfp(IR(args[i])->t)) {
-	if (nfpr > 0) nfpr--; else nslots += 2;
-      } else {
-	if (ngpr > 0) ngpr--; else nslots += 2;
-      }
-  }
+  nslots = asm_count_call_slots(as, ci, args);
   if (nslots > as->evenspill)  /* Leave room for args in stack slots. */
     as->evenspill = nslots;
+#if LJ_64
   return irt_isfp(ir->t) ? REGSP_HINT(RID_FPRET) : REGSP_HINT(RID_RET);
 #else
-  if ((ci->flags & CCI_FASTCALL)) {
-    lua_assert(nargs <= 2);
-  } else {
-    uint32_t i;
-    for (i = 0; i < nargs; i++)
-      nslots += irt_isnum(IR(args[i])->t) ? 2 : 1;
-    if (nslots > as->evenspill)  /* Leave room for args. */
-      as->evenspill = nslots;
-  }
   return irt_isfp(ir->t) ? REGSP_INIT : REGSP_HINT(RID_RET);
 #endif
 }
@@ -2679,7 +2745,7 @@ void lj_asm_patchexit(jit_State *J, GCtrace *T, ExitNo exitno, MCode *target)
       p += 5;
     }
   }
+  lj_mcode_sync(T->mcode, T->mcode + T->szmcode);
   lj_mcode_patch(J, mcarea, 1);
-  VG_INVALIDATE(T->mcode, T->szmcode);
 }
 
diff --git a/third_party/luajit/src/lj_bcread.c b/third_party/luajit/src/lj_bcread.c
index c5d4cd9d764174d7a433e69c2ca6b72636567acd..30479230d3149a789285617152a1a7907edbbf88 100644
--- a/third_party/luajit/src/lj_bcread.c
+++ b/third_party/luajit/src/lj_bcread.c
@@ -457,7 +457,7 @@ GCproto *lj_bcread(LexState *ls)
     setprotoV(L, L->top, pt);
     incr_top(L);
   }
-  if (ls->n != 0 || L->top-1 != bcread_oldtop(L, ls))
+  if ((int32_t)ls->n > 0 || L->top-1 != bcread_oldtop(L, ls))
     bcread_error(ls, LJ_ERR_BCBAD);
   /* Pop off last prototype. */
   L->top--;
diff --git a/third_party/luajit/src/lj_bcwrite.c b/third_party/luajit/src/lj_bcwrite.c
index de9b4cf29ea70fdc4285ec090a97c84cd7febddb..198541c5f6406ef625da2c705bd5e88f377306d1 100644
--- a/third_party/luajit/src/lj_bcwrite.c
+++ b/third_party/luajit/src/lj_bcwrite.c
@@ -219,13 +219,19 @@ static void bcwrite_knum(BCWriteCtx *ctx, GCproto *pt)
 	k = lj_num2int(num);
 	if (num == (lua_Number)k) {  /* -0 is never a constant. */
 	save_int:
-	  bcwrite_uleb128(ctx, 2*(uint32_t)k);
-	  if (k < 0) ctx->sb.buf[ctx->sb.n-1] |= 0x10;
+	  bcwrite_uleb128(ctx, 2*(uint32_t)k | ((uint32_t)k & 0x80000000u));
+	  if (k < 0) {
+	    char *p = &ctx->sb.buf[ctx->sb.n-1];
+	    *p = (*p & 7) | ((k>>27) & 0x18);
+	  }
 	  continue;
 	}
       }
-      bcwrite_uleb128(ctx, 1+2*o->u32.lo);
-      if (o->u32.lo >= 0x80000000u) ctx->sb.buf[ctx->sb.n-1] |= 0x10;
+      bcwrite_uleb128(ctx, 1+(2*o->u32.lo | (o->u32.lo & 0x80000000u)));
+      if (o->u32.lo >= 0x80000000u) {
+	char *p = &ctx->sb.buf[ctx->sb.n-1];
+	*p = (*p & 7) | ((o->u32.lo>>27) & 0x18);
+      }
       bcwrite_uleb128(ctx, o->u32.hi);
     }
   }
diff --git a/third_party/luajit/src/lj_carith.c b/third_party/luajit/src/lj_carith.c
index 8f644d8358e3cbe5513f7b28acae250c5c6059a0..b0f4c65aa6f4b9d44103f5d1092a527594ec65a4 100644
--- a/third_party/luajit/src/lj_carith.c
+++ b/third_party/luajit/src/lj_carith.c
@@ -35,11 +35,16 @@ static int carith_checkarg(lua_State *L, CTState *cts, CDArith *ca)
   for (i = 0; i < 2; i++, o++) {
     if (tviscdata(o)) {
       GCcdata *cd = cdataV(o);
-      CType *ct = ctype_raw(cts, (CTypeID)cd->typeid);
+      CTypeID id = (CTypeID)cd->typeid;
+      CType *ct = ctype_raw(cts, id);
       uint8_t *p = (uint8_t *)cdataptr(cd);
       if (ctype_isptr(ct->info)) {
 	p = (uint8_t *)cdata_getptr(p, ct->size);
 	if (ctype_isref(ct->info)) ct = ctype_rawchild(cts, ct);
+      } else if (ctype_isfunc(ct->info)) {
+	p = (uint8_t *)*(void **)p;
+	ct = ctype_get(cts,
+	  lj_ctype_intern(cts, CTINFO(CT_PTR, CTALIGN_PTR|id), CTSIZE_PTR));
       }
       ca->ct[i] = ct;
       ca->p[i] = p;
diff --git a/third_party/luajit/src/lj_ccall.c b/third_party/luajit/src/lj_ccall.c
index 6a163b0e47e28702897a1642579071be16e9263a..5ed1bf5b2f88f9f9a77fc6bd50275e149d849dce 100644
--- a/third_party/luajit/src/lj_ccall.c
+++ b/third_party/luajit/src/lj_ccall.c
@@ -10,6 +10,7 @@
 #include "lj_gc.h"
 #include "lj_err.h"
 #include "lj_str.h"
+#include "lj_tab.h"
 #include "lj_ctype.h"
 #include "lj_cconv.h"
 #include "lj_cdata.h"
@@ -205,6 +206,54 @@
     goto done; \
   }
 
+#elif LJ_TARGET_PPC
+/* -- PPC calling conventions --------------------------------------------- */
+
+#define CCALL_HANDLE_STRUCTRET \
+  cc->retref = 1;  /* Return all structs by reference. */ \
+  cc->gpr[ngpr++] = (GPRArg)dp;
+
+#define CCALL_HANDLE_COMPLEXRET \
+  /* Complex values are returned in 2 or 4 GPRs. */ \
+  cc->retref = 0;
+
+#define CCALL_HANDLE_COMPLEXRET2 \
+  memcpy(dp, sp, ctr->size);  /* Copy complex from GPRs. */
+
+#define CCALL_HANDLE_STRUCTARG \
+  rp = cdataptr(lj_cdata_new(cts, did, sz)); \
+  sz = CTSIZE_PTR;  /* Pass all structs by reference. */
+
+#define CCALL_HANDLE_COMPLEXARG \
+  /* Pass complex by value in 2 or 4 GPRs. */
+
+#define CCALL_HANDLE_REGARG \
+  if (isfp) {  /* Try to pass argument in FPRs. */ \
+    if (nfpr + 1 <= CCALL_NARG_FPR) { \
+      dp = &cc->fpr[nfpr]; \
+      nfpr += 1; \
+      d = ctype_get(cts, CTID_DOUBLE);  /* FPRs always hold doubles. */ \
+      goto done; \
+    } \
+  } else {  /* Try to pass argument in GPRs. */ \
+    if (n > 1) { \
+      lua_assert(n == 2 || n == 4);  /* int64_t or complex (float). */ \
+      if (ctype_isinteger(d->info)) \
+	ngpr = (ngpr + 1u) & ~1u;  /* Align int64_t to regpair. */ \
+      else if (ngpr + n > maxgpr) \
+	ngpr = maxgpr;  /* Prevent reordering. */ \
+    } \
+    if (ngpr + n <= maxgpr) { \
+      dp = &cc->gpr[ngpr]; \
+      ngpr += n; \
+      goto done; \
+    } \
+  }
+
+#define CCALL_HANDLE_RET \
+  if (ctype_isfp(ctr->info) && ctr->size == sizeof(float)) \
+    ctr = ctype_get(cts, CTID_DOUBLE);  /* FPRs always hold doubles. */
+
 #elif LJ_TARGET_PPCSPE
 /* -- PPC/SPE calling conventions ----------------------------------------- */
 
@@ -242,7 +291,7 @@
   }
 
 #else
-#error "missing calling convention definitions for this architecture"
+#error "Missing calling convention definitions for this architecture"
 #endif
 
 #ifndef CCALL_HANDLE_STRUCTRET2
@@ -325,7 +374,7 @@ static int ccall_struct_arg(CCallState *cc, CTState *cts, CType *d, int *rcl,
   dp[0] = dp[1] = 0;
   /* Convert to temp. struct. */
   lj_cconv_ct_tv(cts, d, (uint8_t *)dp, o, CCF_ARG(narg));
-  if (!ccall_struct_reg(cc, dp, rcl)) {  /* Register overflow? Pass on stack. */
+  if (ccall_struct_reg(cc, dp, rcl)) {  /* Register overflow? Pass on stack. */
     MSize nsp = cc->nsp, n = rcl[1] ? 2 : 1;
     if (nsp + n > CCALL_MAXSTACK) return 1;  /* Too many arguments. */
     cc->nsp = nsp + n;
@@ -354,7 +403,7 @@ static void ccall_struct_ret(CCallState *cc, int *rcl, uint8_t *dp, CTSize sz)
 /* -- Common C call handling ---------------------------------------------- */
 
 /* Infer the destination CTypeID for a vararg argument. */
-static CTypeID ccall_ctid_vararg(CTState *cts, cTValue *o)
+CTypeID lj_ccall_ctid_vararg(CTState *cts, cTValue *o)
 {
   if (tvisnumber(o)) {
     return CTID_DOUBLE;
@@ -367,7 +416,7 @@ static CTypeID ccall_ctid_vararg(CTState *cts, cTValue *o)
     } else if (ctype_isstruct(s->info) || ctype_isfunc(s->info)) {
       /* NYI: how to pass a struct by value in a vararg argument? */
       return lj_ctype_intern(cts, CTINFO(CT_PTR, CTALIGN_PTR|id), CTSIZE_PTR);
-    } if (ctype_isfp(s->info) && s->size == sizeof(float)) {
+    } else if (ctype_isfp(s->info) && s->size == sizeof(float)) {
       return CTID_DOUBLE;
     } else {
       return id;
@@ -458,7 +507,7 @@ static int ccall_set_args(lua_State *L, CTState *cts, CType *ct,
     } else {
       if (!(ct->info & CTF_VARARG))
 	lj_err_caller(L, LJ_ERR_FFI_NUMARG);  /* Too many arguments. */
-      did = ccall_ctid_vararg(cts, o);  /* Infer vararg type. */
+      did = lj_ccall_ctid_vararg(cts, o);  /* Infer vararg type. */
       isva = 1;
     }
     d = ctype_raw(cts, did);
@@ -467,11 +516,8 @@ static int ccall_set_args(lua_State *L, CTState *cts, CType *ct,
     /* Find out how (by value/ref) and where (GPR/FPR) to pass an argument. */
     if (ctype_isnum(d->info)) {
       if (sz > 8) goto err_nyi;
-      if ((d->info & CTF_FP)) {
+      if ((d->info & CTF_FP))
 	isfp = 1;
-      } else if (sz < CTSIZE_PTR) {
-	d = ctype_get(cts, CTID_INT_PSZ);
-      }
     } else if (ctype_isvector(d->info)) {
       if (CCALL_VECTOR_REG && (sz == 8 || sz == 16))
 	isfp = 1;
@@ -509,6 +555,15 @@ static int ccall_set_args(lua_State *L, CTState *cts, CType *ct,
       dp = rp;
     }
     lj_cconv_ct_tv(cts, d, (uint8_t *)dp, o, CCF_ARG(narg));
+    /* Extend passed integers to 32 bits at least. */
+    if (ctype_isinteger_or_bool(d->info) && d->size < 4) {
+      if (d->info & CTF_UNSIGNED)
+	*(uint32_t *)dp = d->size == 1 ? (uint32_t)*(uint8_t *)dp :
+					 (uint32_t)*(uint16_t *)dp;
+      else
+	*(int32_t *)dp = d->size == 1 ? (int32_t)*(int8_t *)dp :
+					(int32_t)*(int16_t *)dp;
+    }
 #if LJ_TARGET_X64 && LJ_ABI_WIN
     if (isva) {  /* Windows/x64 mirrors varargs in both register sets. */
       if (nfpr == ngpr)
@@ -530,7 +585,7 @@ static int ccall_set_args(lua_State *L, CTState *cts, CType *ct,
   }
   if (fid) lj_err_caller(L, LJ_ERR_FFI_NUMARG);  /* Too few arguments. */
 
-#if LJ_TARGET_X64
+#if LJ_TARGET_X64 || LJ_TARGET_PPC
   cc->nfpr = nfpr;  /* Required for vararg functions. */
 #endif
   cc->nsp = nsp;
@@ -545,7 +600,7 @@ static int ccall_get_results(lua_State *L, CTState *cts, CType *ct,
 			     CCallState *cc, int *ret)
 {
   CType *ctr = ctype_rawchild(cts, ct);
-  void *sp = &cc->gpr[0];
+  uint8_t *sp = (uint8_t *)&cc->gpr[0];
   if (ctype_isvoid(ctr->info)) {
     *ret = 0;  /* Zero results. */
     return 0;  /* No additional GC step. */
@@ -565,14 +620,19 @@ static int ccall_get_results(lua_State *L, CTState *cts, CType *ct,
     CCALL_HANDLE_COMPLEXRET2
     return 1;  /* One GC step. */
   }
+  if (LJ_BE && ctype_isinteger_or_bool(ctr->info) && ctr->size < CTSIZE_PTR)
+    sp += (CTSIZE_PTR - ctr->size);
+#ifdef CCALL_HANDLE_RET
+  CCALL_HANDLE_RET
+#endif
 #if CCALL_NUM_FPR
   if (ctype_isfp(ctr->info) || ctype_isvector(ctr->info))
-    sp = &cc->fpr[0];
+    sp = (uint8_t *)&cc->fpr[0];
 #endif
   /* No reference types end up here, so there's no need for the CTypeID. */
   lua_assert(!(ctype_isrefarray(ctr->info) || ctype_isstruct(ctr->info)));
   if (ctype_isenum(ctr->info)) ctr = ctype_child(cts, ctr);
-  return lj_cconv_tv_ct(cts, ctr, 0, L->top-1, (uint8_t *)sp);
+  return lj_cconv_tv_ct(cts, ctr, 0, L->top-1, sp);
 }
 
 /* Call C function. */
@@ -590,7 +650,13 @@ int lj_ccall_func(lua_State *L, GCcdata *cd)
     int gcsteps, ret;
     cc.func = (void (*)(void))cdata_getptr(cdataptr(cd), sz);
     gcsteps = ccall_set_args(L, cts, ct, &cc);
+    cts->cb.slot = ~0u;
     lj_vm_ffi_call(&cc);
+    if (cts->cb.slot != ~0u) {  /* Blacklist function that called a callback. */
+      TValue tv;
+      setlightudV(&tv, (void *)cc.func);
+      setboolV(lj_tab_set(L, cts->miscmap, &tv), 1);
+    }
     gcsteps += ccall_get_results(L, cts, ct, &cc, &ret);
 #if LJ_TARGET_X86 && LJ_ABI_WIN
     /* Automatically detect __stdcall and fix up C function declaration. */
diff --git a/third_party/luajit/src/lj_ccall.h b/third_party/luajit/src/lj_ccall.h
index d097978109991c83ff1f8344d9749530f4dcd3e4..0641625f3395ea0ec235a56ae22d030af150edf1 100644
--- a/third_party/luajit/src/lj_ccall.h
+++ b/third_party/luajit/src/lj_ccall.h
@@ -7,6 +7,7 @@
 #define _LJ_CCALL_H
 
 #include "lj_obj.h"
+#include "lj_ctype.h"
 
 #if LJ_HASFFI
 
@@ -53,10 +54,22 @@ typedef intptr_t GPRArg;
 #define CCALL_NARG_FPR		0
 #define CCALL_NRET_GPR		2	/* For softfp double. */
 #define CCALL_NRET_FPR		0
-#define CCALL_SPS_FREE		0	/* NYI */
+#define CCALL_SPS_FREE		0
 
 typedef intptr_t GPRArg;
 
+#elif LJ_TARGET_PPC
+
+#define CCALL_NARG_GPR		8
+#define CCALL_NARG_FPR		8
+#define CCALL_NRET_GPR		4	/* For complex double. */
+#define CCALL_NRET_FPR		1
+#define CCALL_SPS_EXTRA		4
+#define CCALL_SPS_FREE		0
+
+typedef intptr_t GPRArg;
+typedef double FPRArg;
+
 #elif LJ_TARGET_PPCSPE
 
 #define CCALL_NARG_GPR		8
@@ -68,7 +81,7 @@ typedef intptr_t GPRArg;
 typedef intptr_t GPRArg;
 
 #else
-#error "missing calling convention definitions for this architecture"
+#error "Missing calling convention definitions for this architecture"
 #endif
 
 #ifndef CCALL_SPS_EXTRA
@@ -86,6 +99,10 @@ typedef intptr_t GPRArg;
 #define CCALL_NUM_FPR \
   (CCALL_NARG_FPR > CCALL_NRET_FPR ? CCALL_NARG_FPR : CCALL_NRET_FPR)
 
+/* Check against constants in lj_ctype.h. */
+LJ_STATIC_ASSERT(CCALL_NUM_GPR <= CCALL_MAX_GPR);
+LJ_STATIC_ASSERT(CCALL_NUM_FPR <= CCALL_MAX_FPR);
+
 #define CCALL_MAXSTACK		32
 
 /* -- C call state -------------------------------------------------------- */
@@ -100,8 +117,13 @@ typedef struct CCallState {
   uint8_t nfpr;			/* Number of arguments in FPRs. */
 #elif LJ_TARGET_X86
   uint8_t resx87;		/* Result on x87 stack: 1:float, 2:double. */
+#elif LJ_TARGET_PPC
+  uint8_t nfpr;			/* Number of arguments in FPRs. */
 #endif
 #if CCALL_NUM_FPR
+#if LJ_32
+  int32_t align1;
+#endif
   FPRArg fpr[CCALL_NUM_FPR];	/* Arguments/results in FPRs. */
 #endif
   GPRArg gpr[CCALL_NUM_GPR];	/* Arguments/results in GPRs. */
@@ -112,6 +134,8 @@ typedef struct CCallState {
 
 /* Really belongs to lj_vm.h. */
 LJ_ASMF void LJ_FASTCALL lj_vm_ffi_call(CCallState *cc);
+
+LJ_FUNC CTypeID lj_ccall_ctid_vararg(CTState *cts, cTValue *o);
 LJ_FUNC int lj_ccall_func(lua_State *L, GCcdata *cd);
 
 #endif
diff --git a/third_party/luajit/src/lj_ccallback.c b/third_party/luajit/src/lj_ccallback.c
new file mode 100644
index 0000000000000000000000000000000000000000..f3474588b763a2f1075567635d77ba34ab15d179
--- /dev/null
+++ b/third_party/luajit/src/lj_ccallback.c
@@ -0,0 +1,544 @@
+/*
+** FFI C callback handling.
+** Copyright (C) 2005-2011 Mike Pall. See Copyright Notice in luajit.h
+*/
+
+#include "lj_obj.h"
+
+#if LJ_HASFFI
+
+#include "lj_gc.h"
+#include "lj_err.h"
+#include "lj_tab.h"
+#include "lj_state.h"
+#include "lj_frame.h"
+#include "lj_ctype.h"
+#include "lj_cconv.h"
+#include "lj_ccall.h"
+#include "lj_ccallback.h"
+#include "lj_target.h"
+#include "lj_mcode.h"
+#include "lj_vm.h"
+
+/* -- Target-specific handling of callback slots -------------------------- */
+
+#define CALLBACK_MCODE_SIZE	(LJ_PAGESIZE * LJ_NUM_CBPAGE)
+
+#if LJ_TARGET_X86ORX64
+
+#define CALLBACK_MCODE_HEAD	(LJ_64 ? 8 : 0)
+#define CALLBACK_MCODE_GROUP	(-2+1+2+5+(LJ_64 ? 6 : 5))
+
+#define CALLBACK_SLOT2OFS(slot) \
+  (CALLBACK_MCODE_HEAD + CALLBACK_MCODE_GROUP*((slot)/32) + 4*(slot))
+
+static MSize CALLBACK_OFS2SLOT(MSize ofs)
+{
+  MSize group;
+  ofs -= CALLBACK_MCODE_HEAD;
+  group = ofs / (32*4 + CALLBACK_MCODE_GROUP);
+  return (ofs % (32*4 + CALLBACK_MCODE_GROUP))/4 + group*32;
+}
+
+#define CALLBACK_MAX_SLOT \
+  (((CALLBACK_MCODE_SIZE-CALLBACK_MCODE_HEAD)/(CALLBACK_MCODE_GROUP+4*32))*32)
+
+#elif LJ_TARGET_ARM
+
+#define CALLBACK_MCODE_HEAD		32
+#define CALLBACK_SLOT2OFS(slot)		(CALLBACK_MCODE_HEAD + 8*(slot))
+#define CALLBACK_OFS2SLOT(ofs)		(((ofs)-CALLBACK_MCODE_HEAD)/8)
+#define CALLBACK_MAX_SLOT		(CALLBACK_OFS2SLOT(CALLBACK_MCODE_SIZE))
+
+#elif LJ_TARGET_PPC
+
+#define CALLBACK_MCODE_HEAD		24
+#define CALLBACK_SLOT2OFS(slot)		(CALLBACK_MCODE_HEAD + 8*(slot))
+#define CALLBACK_OFS2SLOT(ofs)		(((ofs)-CALLBACK_MCODE_HEAD)/8)
+#define CALLBACK_MAX_SLOT		(CALLBACK_OFS2SLOT(CALLBACK_MCODE_SIZE))
+
+#else
+
+/* Missing support for this architecture. */
+#define CALLBACK_SLOT2OFS(slot)	(0*(slot))
+#define CALLBACK_OFS2SLOT(ofs)	(0*(ofs))
+#define CALLBACK_MAX_SLOT	0
+
+#endif
+
+/* Convert callback slot number to callback function pointer. */
+static void *callback_slot2ptr(CTState *cts, MSize slot)
+{
+  return (uint8_t *)cts->cb.mcode + CALLBACK_SLOT2OFS(slot);
+}
+
+/* Convert callback function pointer to slot number. */
+MSize lj_ccallback_ptr2slot(CTState *cts, void *p)
+{
+  uintptr_t ofs = (uintptr_t)((uint8_t *)p -(uint8_t *)cts->cb.mcode);
+  if (ofs < CALLBACK_MCODE_SIZE) {
+    MSize slot = CALLBACK_OFS2SLOT((MSize)ofs);
+    if (CALLBACK_SLOT2OFS(slot) == (MSize)ofs)
+      return slot;
+  }
+  return ~0u;  /* Not a known callback function pointer. */
+}
+
+/* Initialize machine code for callback function pointers. */
+#if LJ_TARGET_X86ORX64
+static void callback_mcode_init(global_State *g, uint8_t *page)
+{
+  uint8_t *p = page;
+  uint8_t *target = (uint8_t *)(void *)lj_vm_ffi_callback;
+  MSize slot;
+#if LJ_64
+  *(void **)p = target; p += 8;
+#endif
+  for (slot = 0; slot < CALLBACK_MAX_SLOT; slot++) {
+    /* mov al, slot; jmp group */
+    *p++ = XI_MOVrib | RID_EAX; *p++ = (uint8_t)slot;
+    if ((slot & 31) == 31 || slot == CALLBACK_MAX_SLOT-1) {
+      /* push ebp/rbp; mov ah, slot>>8; mov ebp, &g. */
+      *p++ = XI_PUSH + RID_EBP;
+      *p++ = XI_MOVrib | (RID_EAX+4); *p++ = (uint8_t)(slot >> 8);
+      *p++ = XI_MOVri | RID_EBP;
+      *(int32_t *)p = i32ptr(g); p += 4;
+#if LJ_64
+      /* jmp [rip-pageofs] where lj_vm_ffi_callback is stored. */
+      *p++ = XI_GROUP5; *p++ = XM_OFS0 + (XOg_JMP<<3) + RID_EBP;
+      *(int32_t *)p = (int32_t)(page-(p+4)); p += 4;
+#else
+      /* jmp lj_vm_ffi_callback. */
+      *p++ = XI_JMP; *(int32_t *)p = target-(p+4); p += 4;
+#endif
+    } else {
+      *p++ = XI_JMPs; *p++ = (uint8_t)((2+2)*(31-(slot&31)) - 2);
+    }
+  }
+  lua_assert(p - page <= CALLBACK_MCODE_SIZE);
+}
+#elif LJ_TARGET_ARM
+static void callback_mcode_init(global_State *g, uint32_t *page)
+{
+  uint32_t *p = page;
+  void *target = (void *)lj_vm_ffi_callback;
+  MSize slot;
+  /* This must match with the saveregs macro in buildvm_arm.dasc. */
+  *p++ = ARMI_SUB|ARMF_D(RID_R12)|ARMF_N(RID_R12)|ARMF_M(RID_PC);
+  *p++ = ARMI_PUSH|ARMF_N(RID_SP)|RSET_RANGE(RID_R4,RID_R11+1)|RID2RSET(RID_LR);
+  *p++ = ARMI_SUB|ARMI_K12|ARMF_D(RID_R12)|ARMF_N(RID_R12)|CALLBACK_MCODE_HEAD;
+  *p++ = ARMI_STR|ARMI_LS_P|ARMI_LS_W|ARMF_D(RID_R12)|ARMF_N(RID_SP)|(CFRAME_SIZE-4*9);
+  *p++ = ARMI_LDR|ARMI_LS_P|ARMI_LS_U|ARMF_D(RID_R12)|ARMF_N(RID_PC);
+  *p++ = ARMI_LDR|ARMI_LS_P|ARMI_LS_U|ARMF_D(RID_PC)|ARMF_N(RID_PC);
+  *p++ = u32ptr(g);
+  *p++ = u32ptr(target);
+  for (slot = 0; slot < CALLBACK_MAX_SLOT; slot++) {
+    *p++ = ARMI_MOV|ARMF_D(RID_R12)|ARMF_M(RID_PC);
+    *p = ARMI_B | ((page-p-2) & 0x00ffffffu);
+    p++;
+  }
+  lua_assert(p - page <= CALLBACK_MCODE_SIZE);
+}
+#elif LJ_TARGET_PPC
+static void callback_mcode_init(global_State *g, uint32_t *page)
+{
+  uint32_t *p = page;
+  void *target = (void *)lj_vm_ffi_callback;
+  MSize slot;
+  *p++ = PPCI_LIS | PPCF_T(RID_TMP) | (u32ptr(target) >> 16);
+  *p++ = PPCI_LIS | PPCF_T(RID_R12) | (u32ptr(g) >> 16);
+  *p++ = PPCI_ORI | PPCF_A(RID_TMP)|PPCF_T(RID_TMP) | (u32ptr(target) & 0xffff);
+  *p++ = PPCI_ORI | PPCF_A(RID_R12)|PPCF_T(RID_R12) | (u32ptr(g) & 0xffff);
+  *p++ = PPCI_MTCTR | PPCF_T(RID_TMP);
+  *p++ = PPCI_BCTR;
+  for (slot = 0; slot < CALLBACK_MAX_SLOT; slot++) {
+    *p++ = PPCI_LI | PPCF_T(RID_R11) | slot;
+    *p = PPCI_B | (((page-p) & 0x00ffffffu) << 2);
+    p++;
+  }
+  lua_assert(p - page <= CALLBACK_MCODE_SIZE);
+}
+#else
+/* Missing support for this architecture. */
+#define callback_mcode_init(g, p)	UNUSED(p)
+#endif
+
+/* -- Machine code management --------------------------------------------- */
+
+#if LJ_TARGET_WINDOWS
+
+#define WIN32_LEAN_AND_MEAN
+#include <windows.h>
+
+#elif LJ_TARGET_POSIX
+
+#include <sys/mman.h>
+#ifndef MAP_ANONYMOUS
+#define MAP_ANONYMOUS   MAP_ANON
+#endif
+
+#endif
+
+/* Allocate and initialize area for callback function pointers. */
+static void callback_mcode_new(CTState *cts)
+{
+  size_t sz = (size_t)CALLBACK_MCODE_SIZE;
+  void *p;
+  if (CALLBACK_MAX_SLOT == 0)
+    lj_err_caller(cts->L, LJ_ERR_FFI_CBACKOV);
+#if LJ_TARGET_WINDOWS
+  p = VirtualAlloc(NULL, sz, MEM_RESERVE|MEM_COMMIT, PAGE_READWRITE);
+  if (!p)
+    lj_err_caller(cts->L, LJ_ERR_FFI_CBACKOV);
+#elif LJ_TARGET_POSIX
+  p = mmap(NULL, sz, (PROT_READ|PROT_WRITE), MAP_PRIVATE|MAP_ANONYMOUS,
+	   -1, 0);
+  if (p == MAP_FAILED)
+    lj_err_caller(cts->L, LJ_ERR_FFI_CBACKOV);
+#else
+  /* Fallback allocator. Fails if memory is not executable by default. */
+  p = lj_mem_new(cts->L, sz);
+#endif
+  cts->cb.mcode = p;
+  callback_mcode_init(cts->g, p);
+  lj_mcode_sync(p, (char *)p + sz);
+#if LJ_TARGET_WINDOWS
+  {
+    DWORD oprot;
+    VirtualProtect(p, sz, PAGE_EXECUTE_READ, &oprot);
+  }
+#elif LJ_TARGET_POSIX
+  mprotect(p, sz, (PROT_READ|PROT_EXEC));
+#endif
+}
+
+/* Free area for callback function pointers. */
+void lj_ccallback_mcode_free(CTState *cts)
+{
+  size_t sz = (size_t)CALLBACK_MCODE_SIZE;
+  void *p = cts->cb.mcode;
+  if (p == NULL) return;
+#if LJ_TARGET_WINDOWS
+  VirtualFree(p, 0, MEM_RELEASE);
+  UNUSED(sz);
+#elif LJ_TARGET_POSIX
+  munmap(p, sz);
+#else
+  lj_mem_free(cts->g, p, sz);
+#endif
+}
+
+/* -- C callback entry ---------------------------------------------------- */
+
+/* Target-specific handling of register arguments. Similar to lj_ccall.c. */
+#if LJ_TARGET_X86
+
+#define CALLBACK_HANDLE_REGARG \
+  if (!isfp) {  /* Only non-FP values may be passed in registers. */ \
+    if (n > 1) {  /* Anything > 32 bit is passed on the stack. */ \
+      if (!LJ_ABI_WIN) ngpr = maxgpr;  /* Prevent reordering. */ \
+    } else if (ngpr + 1 <= maxgpr) { \
+      sp = &cts->cb.gpr[ngpr]; \
+      ngpr += n; \
+      goto done; \
+    } \
+  }
+
+#elif LJ_TARGET_X64 && LJ_ABI_WIN
+
+/* Windows/x64 argument registers are strictly positional (use ngpr). */
+#define CALLBACK_HANDLE_REGARG \
+  if (isfp) { \
+    if (ngpr < 4) { sp = &cts->cb.fpr[ngpr++]; nfpr = ngpr; goto done; } \
+  } else { \
+    if (ngpr < 4) { sp = &cts->cb.gpr[ngpr++]; goto done; } \
+  }
+
+#elif LJ_TARGET_X64
+
+#define CALLBACK_HANDLE_REGARG \
+  if (isfp) { \
+    if (nfpr + n <= CCALL_NARG_FPR) { \
+      sp = &cts->cb.fpr[nfpr]; \
+      nfpr += n; \
+      goto done; \
+    } \
+  } else { \
+    if (ngpr + n <= maxgpr) { \
+      sp = &cts->cb.gpr[ngpr]; \
+      ngpr += n; \
+      goto done; \
+    } \
+  }
+
+#elif LJ_TARGET_ARM
+
+#define CALLBACK_HANDLE_REGARG \
+  if (n > 1) ngpr = (ngpr + 1u) & ~1u;  /* Align to regpair. */ \
+  if (ngpr + n <= maxgpr) { \
+    sp = &cts->cb.gpr[ngpr]; \
+    ngpr += n; \
+    goto done; \
+  }
+
+#elif LJ_TARGET_PPC
+
+#define CALLBACK_HANDLE_REGARG \
+  if (isfp) { \
+    if (nfpr + 1 <= CCALL_NARG_FPR) { \
+      sp = &cts->cb.fpr[nfpr]; \
+      nfpr += 1; \
+      cta = ctype_get(cts, CTID_DOUBLE);  /* FPRs always hold doubles. */ \
+      goto done; \
+    } \
+  } else {  /* Try to pass argument in GPRs. */ \
+    if (n > 1) { \
+      lua_assert(ctype_isinteger(cta->info) && n == 2);  /* int64_t. */ \
+      ngpr = (ngpr + 1u) & ~1u;  /* Align int64_t to regpair. */ \
+    } \
+    if (ngpr + n <= maxgpr) { \
+      sp = &cts->cb.gpr[ngpr]; \
+      ngpr += n; \
+      goto done; \
+    } \
+  }
+
+#define CALLBACK_HANDLE_RET \
+  if (ctype_isfp(ctr->info) && ctr->size == sizeof(float)) \
+    *(double *)dp = *(float *)dp;  /* FPRs always hold doubles. */
+
+#else
+#error "Missing calling convention definitions for this architecture"
+#endif
+
+/* Convert and push callback arguments to Lua stack. */
+static void callback_conv_args(CTState *cts, lua_State *L)
+{
+  TValue *o = L->top;
+  intptr_t *stack = cts->cb.stack;
+  MSize slot = cts->cb.slot;
+  CTypeID id = 0, rid, fid;
+  CType *ct;
+  GCfunc *fn;
+  MSize ngpr = 0, nsp = 0, maxgpr = CCALL_NARG_GPR;
+#if CCALL_NARG_FPR
+  MSize nfpr = 0;
+#endif
+
+  if (slot < cts->cb.sizeid && (id = cts->cb.cbid[slot]) != 0) {
+    ct = ctype_get(cts, id);
+    rid = ctype_cid(ct->info);
+    fn = funcV(lj_tab_getint(cts->miscmap, (int32_t)slot));
+  } else {  /* Must set up frame first, before throwing the error. */
+    ct = NULL;
+    rid = 0;
+    fn = (GCfunc *)L;
+  }
+  o->u32.lo = LJ_CONT_FFI_CALLBACK;  /* Continuation returns from callback. */
+  o->u32.hi = rid;  /* Return type. x86: +(spadj<<16). */
+  o++;
+  setframe_gc(o, obj2gco(fn));
+  setframe_ftsz(o, (int)((char *)(o+1) - (char *)L->base) + FRAME_CONT);
+  L->top = L->base = ++o;
+  if (!ct)
+    lj_err_caller(cts->L, LJ_ERR_FFI_BADCBACK);
+  if (isluafunc(fn))
+    setcframe_pc(L->cframe, proto_bc(funcproto(fn))+1);
+  lj_state_checkstack(L, LUA_MINSTACK);  /* May throw. */
+  o = L->base;  /* Might have been reallocated. */
+
+#if LJ_TARGET_X86
+  /* x86 has several different calling conventions. */
+  switch (ctype_cconv(ct->info)) {
+  case CTCC_FASTCALL: maxgpr = 2; break;
+  case CTCC_THISCALL: maxgpr = 1; break;
+  default: maxgpr = 0; break;
+  }
+#endif
+
+  fid = ct->sib;
+  while (fid) {
+    CType *ctf = ctype_get(cts, fid);
+    if (!ctype_isattrib(ctf->info)) {
+      CType *cta;
+      void *sp;
+      CTSize sz;
+      int isfp;
+      MSize n;
+      lua_assert(ctype_isfield(ctf->info));
+      cta = ctype_rawchild(cts, ctf);
+      if (ctype_isenum(cta->info)) cta = ctype_child(cts, cta);
+      isfp = ctype_isfp(cta->info);
+      sz = (cta->size + CTSIZE_PTR-1) & ~(CTSIZE_PTR-1);
+      n = sz / CTSIZE_PTR;  /* Number of GPRs or stack slots needed. */
+
+      CALLBACK_HANDLE_REGARG  /* Handle register arguments. */
+
+      /* Otherwise pass argument on stack. */
+      if (CCALL_ALIGN_STACKARG && LJ_32 && sz == 8)
+	nsp = (nsp + 1) & ~1u;  /* Align 64 bit argument on stack. */
+      sp = &stack[nsp];
+      nsp += n;
+
+    done:
+      if (LJ_BE && cta->size < CTSIZE_PTR)
+	sp = (void *)((uint8_t *)sp + CTSIZE_PTR-cta->size);
+      lj_cconv_tv_ct(cts, cta, 0, o++, sp);
+    }
+    fid = ctf->sib;
+  }
+  L->top = o;
+#if LJ_TARGET_X86
+  /* Store stack adjustment for returns from fastcall/stdcall callbacks. */
+  switch (ctype_cconv(ct->info)) {
+  case CTCC_FASTCALL: case CTCC_STDCALL:
+    (L->base-2)->u32.hi |= (nsp << (16+2));
+    break;
+  }
+#endif
+}
+
+/* Convert Lua object to callback result. */
+static void callback_conv_result(CTState *cts, lua_State *L, TValue *o)
+{
+  CType *ctr = ctype_raw(cts, (uint16_t)(L->base-2)->u32.hi);
+#if LJ_TARGET_X86
+  cts->cb.gpr[2] = 0;
+#endif
+  if (!ctype_isvoid(ctr->info)) {
+    uint8_t *dp = (uint8_t *)&cts->cb.gpr[0];
+#if CCALL_NUM_FPR
+    if (ctype_isfp(ctr->info))
+      dp = (uint8_t *)&cts->cb.fpr[0];
+#endif
+    lj_cconv_ct_tv(cts, ctr, dp, o, 0);
+#ifdef CALLBACK_HANDLE_RET
+    CALLBACK_HANDLE_RET
+#endif
+    /* Extend returned integers to (at least) 32 bits. */
+    if (ctype_isinteger_or_bool(ctr->info) && ctr->size < 4) {
+      if (ctr->info & CTF_UNSIGNED)
+	*(uint32_t *)dp = ctr->size == 1 ? (uint32_t)*(uint8_t *)dp :
+					   (uint32_t)*(uint16_t *)dp;
+      else
+	*(int32_t *)dp = ctr->size == 1 ? (int32_t)*(int8_t *)dp :
+					  (int32_t)*(int16_t *)dp;
+    }
+#if LJ_TARGET_X86
+    if (ctype_isfp(ctr->info))
+      cts->cb.gpr[2] = ctr->size == sizeof(float) ? 1 : 2;
+#endif
+  }
+}
+
+/* Enter callback. */
+lua_State * LJ_FASTCALL lj_ccallback_enter(CTState *cts, void *cf)
+{
+  lua_State *L = cts->L;
+  lua_assert(L != NULL);
+  if (gcref(cts->g->jit_L))
+    lj_err_caller(gco2th(gcref(cts->g->jit_L)), LJ_ERR_FFI_BADCBACK);
+  /* Setup C frame. */
+  cframe_prev(cf) = L->cframe;
+  setcframe_L(cf, L);
+  cframe_errfunc(cf) = -1;
+  cframe_nres(cf) = 0;
+  L->cframe = cf;
+  callback_conv_args(cts, L);
+  return L;  /* Now call the function on this stack. */
+}
+
+/* Leave callback. */
+void LJ_FASTCALL lj_ccallback_leave(CTState *cts, TValue *o)
+{
+  lua_State *L = cts->L;
+  GCfunc *fn;
+  TValue *obase = L->base;
+  L->base = L->top;  /* Keep continuation frame for throwing errors. */
+  /* PC of RET* is lost. Point to last line for result conv. errors. */
+  fn = curr_func(L);
+  if (isluafunc(fn)) {
+    GCproto *pt = funcproto(fn);
+    setcframe_pc(L->cframe, proto_bc(pt)+pt->sizebc+1);
+  }
+  callback_conv_result(cts, L, o);
+  /* Finally drop C frame and continuation frame. */
+  L->cframe = cframe_prev(L->cframe);
+  L->top -= 2;
+  L->base = obase;
+}
+
+/* -- C callback management ----------------------------------------------- */
+
+/* Get an unused slot in the callback slot table. */
+static MSize callback_slot_new(CTState *cts, CType *ct)
+{
+  CTypeID id = ctype_typeid(cts, ct);
+  CTypeID1 *cbid = cts->cb.cbid;
+  MSize top;
+  for (top = cts->cb.topid; top < cts->cb.sizeid; top++)
+    if (LJ_LIKELY(cbid[top] == 0))
+      goto found;
+#if CALLBACK_MAX_SLOT
+  if (top >= CALLBACK_MAX_SLOT)
+#endif
+    lj_err_caller(cts->L, LJ_ERR_FFI_CBACKOV);
+  if (!cts->cb.mcode)
+    callback_mcode_new(cts);
+  lj_mem_growvec(cts->L, cbid, cts->cb.sizeid, CALLBACK_MAX_SLOT, CTypeID1);
+  cts->cb.cbid = cbid;
+  memset(cbid+top, 0, (cts->cb.sizeid-top)*sizeof(CTypeID1));
+found:
+  cbid[top] = id;
+  cts->cb.topid = top+1;
+  return top;
+}
+
+/* Check for function pointer and supported argument/result types. */
+static CType *callback_checkfunc(CTState *cts, CType *ct)
+{
+  int narg = 0;
+  if (!ctype_isptr(ct->info) || (LJ_64 && ct->size != CTSIZE_PTR))
+    return NULL;
+  ct = ctype_rawchild(cts, ct);
+  if (ctype_isfunc(ct->info)) {
+    CType *ctr = ctype_rawchild(cts, ct);
+    CTypeID fid = ct->sib;
+    if (!(ctype_isvoid(ctr->info) || ctype_isenum(ctr->info) ||
+	  ctype_isptr(ctr->info) || (ctype_isnum(ctr->info) && ctr->size <= 8)))
+      return NULL;
+    if ((ct->info & CTF_VARARG))
+      return NULL;
+    while (fid) {
+      CType *ctf = ctype_get(cts, fid);
+      if (!ctype_isattrib(ctf->info)) {
+	CType *cta;
+	lua_assert(ctype_isfield(ctf->info));
+	cta = ctype_rawchild(cts, ctf);
+	if (!(ctype_isenum(cta->info) || ctype_isptr(cta->info) ||
+	      (ctype_isnum(cta->info) && cta->size <= 8)) ||
+	    ++narg >= LUA_MINSTACK-3)
+	  return NULL;
+      }
+      fid = ctf->sib;
+    }
+    return ct;
+  }
+  return NULL;
+}
+
+/* Create a new callback and return the callback function pointer. */
+void *lj_ccallback_new(CTState *cts, CType *ct, GCfunc *fn)
+{
+  ct = callback_checkfunc(cts, ct);
+  if (ct) {
+    MSize slot = callback_slot_new(cts, ct);
+    GCtab *t = cts->miscmap;
+    setfuncV(cts->L, lj_tab_setint(cts->L, t, (int32_t)slot), fn);
+    lj_gc_anybarriert(cts->L, t);
+    return callback_slot2ptr(cts, slot);
+  }
+  return NULL;  /* Bad conversion. */
+}
+
+#endif
diff --git a/third_party/luajit/src/lj_ccallback.h b/third_party/luajit/src/lj_ccallback.h
new file mode 100644
index 0000000000000000000000000000000000000000..cbdc1e89061d487c2869805074875d9b97b52b78
--- /dev/null
+++ b/third_party/luajit/src/lj_ccallback.h
@@ -0,0 +1,25 @@
+/*
+** FFI C callback handling.
+** Copyright (C) 2005-2011 Mike Pall. See Copyright Notice in luajit.h
+*/
+
+#ifndef _LJ_CCALLBACK_H
+#define _LJ_CCALLBACK_H
+
+#include "lj_obj.h"
+#include "lj_ctype.h"
+
+#if LJ_HASFFI
+
+/* Really belongs to lj_vm.h. */
+LJ_ASMF void lj_vm_ffi_callback(void);
+
+LJ_FUNC MSize lj_ccallback_ptr2slot(CTState *cts, void *p);
+LJ_FUNCA lua_State * LJ_FASTCALL lj_ccallback_enter(CTState *cts, void *cf);
+LJ_FUNCA void LJ_FASTCALL lj_ccallback_leave(CTState *cts, TValue *o);
+LJ_FUNC void *lj_ccallback_new(CTState *cts, CType *ct, GCfunc *fn);
+LJ_FUNC void lj_ccallback_mcode_free(CTState *cts);
+
+#endif
+
+#endif
diff --git a/third_party/luajit/src/lj_cconv.c b/third_party/luajit/src/lj_cconv.c
index 884edef1a6429f2146d7892c2ca7d06f7c3dea04..9d4783553f9958a1236c2f54d2ceba12c2e2be9b 100644
--- a/third_party/luajit/src/lj_cconv.c
+++ b/third_party/luajit/src/lj_cconv.c
@@ -12,6 +12,7 @@
 #include "lj_ctype.h"
 #include "lj_cdata.h"
 #include "lj_cconv.h"
+#include "lj_ccallback.h"
 
 /* -- Conversion errors --------------------------------------------------- */
 
@@ -390,7 +391,7 @@ int lj_cconv_tv_ct(CTState *cts, CType *s, CTypeID sid,
 	lua_assert(tvisnum(o));
       }
     } else {
-      uint32_t b = ((*sp) & 1);
+      uint32_t b = (*sp != 0);
       setboolV(o, b);
       setboolV(&cts->g->tmptv2, b);  /* Remember for trace recorder. */
     }
@@ -603,6 +604,13 @@ void lj_cconv_ct_tv(CTState *cts, CType *d,
     tmpptr = uddata(udataV(o));
   } else if (tvislightud(o)) {
     tmpptr = lightudV(o);
+  } else if (tvisfunc(o)) {
+    void *p = lj_ccallback_new(cts, d, funcV(o));
+    if (p) {
+      *(void **)dp = p;
+      return;
+    }
+    goto err_conv;
   } else {
   err_conv:
     cconv_err_convtv(cts, d, o, flags);
diff --git a/third_party/luajit/src/lj_clib.c b/third_party/luajit/src/lj_clib.c
index 7b9b6c1a2910de300e5c56d4d78a71f21ae41162..68398cf5f6bad5f59c26b010c8a8a49d57e9fb00 100644
--- a/third_party/luajit/src/lj_clib.c
+++ b/third_party/luajit/src/lj_clib.c
@@ -27,7 +27,7 @@
 #if defined(RTLD_DEFAULT)
 #define CLIB_DEFHANDLE	RTLD_DEFAULT
 #elif LJ_TARGET_OSX || LJ_TARGET_BSD
-#define CLIB_DEFHANDLE	((void *)-2)
+#define CLIB_DEFHANDLE	((void *)(intptr_t)-2)
 #else
 #define CLIB_DEFHANDLE	NULL
 #endif
@@ -60,25 +60,39 @@ static const char *clib_extname(lua_State *L, const char *name)
   return name;
 }
 
+/* Check for a recognized ld script line. */
+static const char *clib_check_lds(lua_State *L, const char *buf)
+{
+  char *p, *e;
+  if ((!strncmp(buf, "GROUP", 5) || !strncmp(buf, "INPUT", 5)) &&
+      (p = strchr(buf, '('))) {
+    while (*++p == ' ') ;
+    for (e = p; *e && *e != ' ' && *e != ')'; e++) ;
+    return strdata(lj_str_new(L, p, e-p));
+  }
+  return NULL;
+}
+
 /* Quick and dirty solution to resolve shared library name from ld script. */
 static const char *clib_resolve_lds(lua_State *L, const char *name)
 {
   FILE *fp = fopen(name, "r");
+  const char *p = NULL;
   if (fp) {
-    char *p, *e, buf[256];
-    if (fgets(buf, sizeof(buf), fp) && !strncmp(buf, "/* GNU ld script", 16)) {
-      while (fgets(buf, sizeof(buf), fp)) {
-	if (!strncmp(buf, "GROUP", 5) && (p = strchr(buf, '('))) {
-	  while (*++p == ' ') ;
-	  for (e = p; *e && *e != ' ' && *e != ')'; e++) ;
-	  fclose(fp);
-	  return strdata(lj_str_new(L, p, e-p));
+    char buf[256];
+    if (fgets(buf, sizeof(buf), fp)) {
+      if (!strncmp(buf, "/* GNU ld script", 16)) {  /* ld script magic? */
+	while (fgets(buf, sizeof(buf), fp)) {  /* Check all lines. */
+	  p = clib_check_lds(L, buf);
+	  if (p) break;
 	}
+      } else {  /* Otherwise check only the first line. */
+	p = clib_check_lds(L, buf);
       }
     }
     fclose(fp);
   }
-  return NULL;
+  return p;
 }
 
 static void *clib_loadlib(lua_State *L, const char *name, int global)
@@ -120,6 +134,7 @@ static void *clib_getsym(CLibrary *cl, const char *name)
 
 #ifndef GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS
 #define GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS	4
+#define GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT	2
 BOOL WINAPI GetModuleHandleExA(DWORD, LPCSTR, HMODULE*);
 #endif
 
@@ -169,8 +184,10 @@ static const char *clib_extname(lua_State *L, const char *name)
 
 static void *clib_loadlib(lua_State *L, const char *name, int global)
 {
+  DWORD oldwerr = GetLastError();
   void *h = (void *)LoadLibraryA(clib_extname(L, name));
   if (!h) clib_error(L, "cannot load module " LUA_QS ": %s", name);
+  SetLastError(oldwerr);
   UNUSED(global);
   return h;
 }
@@ -194,19 +211,20 @@ static void clib_unloadlib(CLibrary *cl)
 static void *clib_getsym(CLibrary *cl, const char *name)
 {
   void *p = NULL;
+  DWORD oldwerr = GetLastError();
   if (cl->handle == CLIB_DEFHANDLE) {  /* Search default libraries. */
     MSize i;
     for (i = 0; i < CLIB_HANDLE_MAX; i++) {
       HINSTANCE h = (HINSTANCE)clib_def_handle[i];
       if (!(void *)h) {  /* Resolve default library handles (once). */
 	switch (i) {
-	case CLIB_HANDLE_EXE: GetModuleHandleExA(0, NULL, &h); break;
+	case CLIB_HANDLE_EXE: GetModuleHandleExA(GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT, NULL, &h); break;
 	case CLIB_HANDLE_DLL:
-	  GetModuleHandleExA(GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS,
+	  GetModuleHandleExA(GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS|GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT,
 			     (const char *)clib_def_handle, &h);
 	  break;
 	case CLIB_HANDLE_CRT:
-	  GetModuleHandleExA(GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS,
+	  GetModuleHandleExA(GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS|GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT,
 			     (const char *)&_fmode, &h);
 	  break;
 	case CLIB_HANDLE_KERNEL32: h = LoadLibraryA("kernel32.dll"); break;
@@ -222,6 +240,7 @@ static void *clib_getsym(CLibrary *cl, const char *name)
   } else {
     p = (void *)GetProcAddress((HINSTANCE)cl->handle, name);
   }
+  SetLastError(oldwerr);
   return p;
 }
 
diff --git a/third_party/luajit/src/lj_cparse.c b/third_party/luajit/src/lj_cparse.c
index 523e51462e0f54716ef9bbde2877e5183223b1d0..118de1e09d884bf8cca5fedce0b9004c28515caf 100644
--- a/third_party/luajit/src/lj_cparse.c
+++ b/third_party/luajit/src/lj_cparse.c
@@ -264,7 +264,11 @@ static CPToken cp_string(CPState *cp)
 static void cp_comment_c(CPState *cp)
 {
   do {
-    if (cp_get(cp) == '*' && cp_get(cp) == '/') { cp_get(cp); break; }
+    if (cp_get(cp) == '*') {
+      do {
+	if (cp_get(cp) == '/') { cp_get(cp); return; }
+      } while (cp->c == '*');
+    }
     if (cp_iseol(cp->c)) cp_newline(cp);
   } while (cp->c != '\0');
 }
diff --git a/third_party/luajit/src/lj_crecord.c b/third_party/luajit/src/lj_crecord.c
index 743137de1cbc82e140aa1bf016e7210416c13beb..27001f675463caf5898b21f57df2b6842035eb51 100644
--- a/third_party/luajit/src/lj_crecord.c
+++ b/third_party/luajit/src/lj_crecord.c
@@ -15,9 +15,11 @@
 #include "lj_tab.h"
 #include "lj_frame.h"
 #include "lj_ctype.h"
+#include "lj_cdata.h"
 #include "lj_cparse.h"
 #include "lj_cconv.h"
 #include "lj_clib.h"
+#include "lj_ccall.h"
 #include "lj_ir.h"
 #include "lj_jit.h"
 #include "lj_ircall.h"
@@ -25,6 +27,7 @@
 #include "lj_trace.h"
 #include "lj_record.h"
 #include "lj_ffrecord.h"
+#include "lj_snap.h"
 #include "lj_crecord.h"
 #include "lj_dispatch.h"
 
@@ -364,7 +367,7 @@ static TRef crec_tv_ct(jit_State *J, CType *s, CTypeID sid, TRef sp)
 
 /* -- Convert TValue to C type (store) ------------------------------------ */
 
-static TRef crec_ct_tv(jit_State *J, CType *d, TRef dp, TRef sp, TValue *sval)
+static TRef crec_ct_tv(jit_State *J, CType *d, TRef dp, TRef sp, cTValue *sval)
 {
   CTState *cts = ctype_ctsG(J2G(J));
   CTypeID sid = CTID_P_VOID;
@@ -526,9 +529,13 @@ void LJ_FASTCALL recff_cdata_index(jit_State *J, RecordFFData *rd)
 	idx = emitir(IRT(IR_BAND, IRT_INTP), idx, lj_ir_kintp(J, 1));
       sz = lj_ctype_size(cts, (sid = ctype_cid(ct->info)));
       idx = crec_reassoc_ofs(J, idx, &ofs, sz);
+#if LJ_TARGET_ARM || LJ_TARGET_PPC
+      /* Hoist base add to allow fusion of index/shift into operands. */
+      if (LJ_LIKELY(J->flags & JIT_F_OPT_LOOP) && ofs
 #if LJ_TARGET_ARM
-      /* Hoist base add to allow fusion of shifts into operands. */
-      if (LJ_LIKELY(J->flags & JIT_F_OPT_LOOP) && ofs && (sz == 1 || sz == 4)) {
+	  && (sz == 1 || sz == 4)
+#endif
+	  ) {
 	ptr = emitir(IRT(IR_ADD, IRT_PTR), ptr, lj_ir_kintp(J, ofs));
 	ofs = 0;
       }
@@ -743,23 +750,89 @@ static TRef crec_call_args(jit_State *J, RecordFFData *rd,
 			   CTState *cts, CType *ct)
 {
   TRef args[CCI_NARGS_MAX];
+  CTypeID fid;
   MSize i, n;
-  TRef tr;
+  TRef tr, *base;
+  cTValue *o;
+#if LJ_TARGET_X86
+#if LJ_ABI_WIN
+  TRef *arg0 = NULL, *arg1 = NULL;
+#endif
+  int ngpr = 0;
+  if (ctype_cconv(ct->info) == CTCC_THISCALL)
+    ngpr = 1;
+  else if (ctype_cconv(ct->info) == CTCC_FASTCALL)
+    ngpr = 2;
+#endif
+
+  /* Skip initial attributes. */
+  fid = ct->sib;
+  while (fid) {
+    CType *ctf = ctype_get(cts, fid);
+    if (!ctype_isattrib(ctf->info)) break;
+    fid = ctf->sib;
+  }
   args[0] = TREF_NIL;
-  for (n = 0; J->base[n+1]; n++) {
+  for (n = 0, base = J->base+1, o = rd->argv+1; *base; n++, base++, o++) {
+    CTypeID did;
     CType *d;
-    do {
-      if (!ct->sib || n >= CCI_NARGS_MAX)
-	lj_trace_err(J, LJ_TRERR_NYICALL);
-      ct = ctype_get(cts, ct->sib);
-    } while (ctype_isattrib(ct->info));
-    if (!ctype_isfield(ct->info))
+
+    if (n >= CCI_NARGS_MAX)
       lj_trace_err(J, LJ_TRERR_NYICALL);
-    d = ctype_rawchild(cts, ct);
+
+    if (fid) {  /* Get argument type from field. */
+      CType *ctf = ctype_get(cts, fid);
+      fid = ctf->sib;
+      lua_assert(ctype_isfield(ctf->info));
+      did = ctype_cid(ctf->info);
+    } else {
+      if (!(ct->info & CTF_VARARG))
+	lj_trace_err(J, LJ_TRERR_NYICALL);  /* Too many arguments. */
+      did = lj_ccall_ctid_vararg(cts, o);  /* Infer vararg type. */
+    }
+    d = ctype_raw(cts, did);
     if (!(ctype_isnum(d->info) || ctype_isptr(d->info) ||
 	  ctype_isenum(d->info)))
       lj_trace_err(J, LJ_TRERR_NYICALL);
-    args[n] = crec_ct_tv(J, d, 0, J->base[n+1], &rd->argv[n+1]);
+    tr = crec_ct_tv(J, d, 0, *base, o);
+    if (ctype_isinteger_or_bool(d->info)) {
+      if (d->size < 4) {
+	if ((d->info & CTF_UNSIGNED))
+	  tr = emitconv(tr, IRT_INT, d->size==1 ? IRT_U8 : IRT_U16, 0);
+	else
+	  tr = emitconv(tr, IRT_INT, d->size==1 ? IRT_I8 : IRT_I16,IRCONV_SEXT);
+      }
+    }
+#if LJ_TARGET_X86
+    /* 64 bit args must not end up in registers for fastcall/thiscall. */
+#if LJ_ABI_WIN
+    if (!ctype_isfp(d->info)) {
+      /* Sigh, the Windows/x86 ABI allows reordering across 64 bit args. */
+      if (tref_typerange(tr, IRT_I64, IRT_U64)) {
+	if (ngpr) {
+	  arg0 = &args[n]; args[n++] = TREF_NIL; ngpr--;
+	  if (ngpr) {
+	    arg1 = &args[n]; args[n++] = TREF_NIL; ngpr--;
+	  }
+	}
+      } else {
+	if (arg0) { *arg0 = tr; arg0 = NULL; n--; continue; }
+	if (arg1) { *arg1 = tr; arg1 = NULL; n--; continue; }
+	if (ngpr) ngpr--;
+      }
+    }
+#else
+    if (!ctype_isfp(d->info) && ngpr) {
+      if (tref_typerange(tr, IRT_I64, IRT_U64)) {
+	/* No reordering for other x86 ABIs. Simply add alignment args. */
+	do { args[n++] = TREF_NIL; } while (--ngpr);
+      } else {
+	ngpr--;
+      }
+    }
+#endif
+#endif
+    args[n] = tr;
   }
   tr = args[0];
   for (i = 1; i < n; i++)
@@ -767,6 +840,28 @@ static TRef crec_call_args(jit_State *J, RecordFFData *rd,
   return tr;
 }
 
+/* Create a snapshot for the caller, simulating a 'false' return value. */
+static void crec_snap_caller(jit_State *J)
+{
+  lua_State *L = J->L;
+  TValue *base = L->base, *top = L->top;
+  const BCIns *pc = J->pc;
+  TRef ftr = J->base[-1];
+  ptrdiff_t delta;
+  if (!frame_islua(base-1))
+    lj_trace_err(J, LJ_TRERR_NYICALL);
+  J->pc = frame_pc(base-1); delta = 1+bc_a(J->pc[-1]);
+  L->top = base; L->base = base - delta;
+  J->base[-1] = TREF_FALSE;
+  J->base -= delta; J->baseslot -= (BCReg)delta;
+  J->maxslot = (BCReg)delta; J->framedepth--;
+  lj_snap_add(J);
+  L->base = base; L->top = top;
+  J->framedepth++; J->maxslot = 1;
+  J->base += delta; J->baseslot += (BCReg)delta;
+  J->base[-1] = ftr; J->pc = pc;
+}
+
 /* Record function call. */
 static int crec_call(jit_State *J, RecordFFData *rd, GCcdata *cd)
 {
@@ -782,6 +877,12 @@ static int crec_call(jit_State *J, RecordFFData *rd, GCcdata *cd)
     CType *ctr = ctype_rawchild(cts, ct);
     IRType t = crec_ct2irt(ctr);
     TRef tr;
+    TValue tv;
+    /* Check for blacklisted C functions that might call a callback. */
+    setlightudV(&tv,
+		cdata_getptr(cdataptr(cd), (LJ_64 && tp == IRT_P64) ? 8 : 4));
+    if (tvistrue(lj_tab_get(J->L, cts->miscmap, &tv)))
+      lj_trace_err(J, LJ_TRERR_BLACKL);
     if (ctype_isvoid(ctr->info)) {
       t = IRT_NIL;
       rd->nres = 0;
@@ -789,16 +890,27 @@ static int crec_call(jit_State *J, RecordFFData *rd, GCcdata *cd)
       ctr = ctype_child(cts, ctr);
     }
     if (!(ctype_isnum(ctr->info) || ctype_isptr(ctr->info) ||
-	  ctype_isvoid(ctr->info)) ||
-	ctype_isbool(ctr->info) || (ct->info & CTF_VARARG) ||
+	  ctype_isvoid(ctr->info)) || t == IRT_CDATA)
+      lj_trace_err(J, LJ_TRERR_NYICALL);
+    if ((ct->info & CTF_VARARG)
 #if LJ_TARGET_X86
-	ctype_cconv(ct->info) != CTCC_CDECL ||
+	|| ctype_cconv(ct->info) != CTCC_CDECL
 #endif
-	t == IRT_CDATA)
-      lj_trace_err(J, LJ_TRERR_NYICALL);
+	)
+      func = emitir(IRT(IR_CARG, IRT_NIL), func,
+		    lj_ir_kint(J, ctype_typeid(cts, ct)));
     tr = emitir(IRT(IR_CALLXS, t), crec_call_args(J, rd, cts, ct), func);
-    if (t == IRT_FLOAT || t == IRT_U32) {
+    if (ctype_isbool(ctr->info)) {
+      crec_snap_caller(J);
+      lj_ir_set(J, IRTGI(IR_NE), tr, lj_ir_kint(J, 0));
+      J->postproc = LJ_POST_FIXGUARDSNAP;
+      tr = TREF_TRUE;
+    } else if (t == IRT_FLOAT || t == IRT_U32) {
       tr = emitconv(tr, IRT_NUM, t, 0);
+    } else if (t == IRT_I8 || t == IRT_I16) {
+      tr = emitconv(tr, IRT_INT, t, IRCONV_SEXT);
+    } else if (t == IRT_U8 || t == IRT_U16) {
+      tr = emitconv(tr, IRT_INT, t, 0);
     } else if (t == IRT_PTR || (LJ_64 && t == IRT_P32) ||
 	       (t == IRT_I64 || t == IRT_U64)) {
       TRef trid = lj_ir_kint(J, ctype_cid(ct->info));
@@ -812,13 +924,30 @@ static int crec_call(jit_State *J, RecordFFData *rd, GCcdata *cd)
   return 0;
 }
 
+/* Record ctype call metamethod. */
+static void crec_call_meta(jit_State *J, RecordFFData *rd, CTypeID id)
+{
+  CTState *cts = ctype_ctsG(J2G(J));
+  CType *ct = ctype_raw(cts, id);
+  cTValue *tv;
+  if (ctype_isptr(ct->info)) id = ctype_cid(ct->info);
+  tv = lj_ctype_meta(cts, id, MM_call);
+  if (tv && tvisfunc(tv)) {
+    J->base[-1] = lj_ir_kfunc(J, funcV(tv)) | TREF_FRAME;
+    rd->nres = -1;  /* Pending tailcall. */
+  } else {
+    /* NYI: non-function metamethods. */
+    lj_trace_err(J, LJ_TRERR_BADTYPE);
+  }
+}
+
 void LJ_FASTCALL recff_cdata_call(jit_State *J, RecordFFData *rd)
 {
   GCcdata *cd = argv2cdata(J, J->base[0], &rd->argv[0]);
   if (cd->typeid == CTID_CTYPEID)
     crec_alloc(J, rd, crec_constructor(J, cd, J->base[0]));
   else if (!crec_call(J, rd, cd))
-    lj_trace_err(J, LJ_TRERR_BADTYPE);
+    crec_call_meta(J, rd, cd->typeid);
 }
 
 static TRef crec_arith_int64(jit_State *J, TRef *sp, CType **s, MMS mm)
@@ -969,6 +1098,10 @@ void LJ_FASTCALL recff_cdata_arith(jit_State *J, RecordFFData *rd)
 	tr = emitir(IRT(IR_FLOAD, t), tr, IRFL_CDATA_INT64);
 	lj_needsplit(J);
 	goto ok;
+      } else if (ctype_isfunc(ct->info)) {
+	tr = emitir(IRT(IR_FLOAD, IRT_PTR), tr, IRFL_CDATA_PTR);
+	ct = ctype_get(cts,
+	  lj_ctype_intern(cts, CTINFO(CT_PTR, CTALIGN_PTR|id), CTSIZE_PTR));
       } else {
 	tr = emitir(IRT(IR_ADD, IRT_PTR), tr, lj_ir_kintp(J, sizeof(GCcdata)));
       }
@@ -999,7 +1132,8 @@ void LJ_FASTCALL recff_cdata_arith(jit_State *J, RecordFFData *rd)
 	(tr = crec_arith_ptr(J, sp, s, (MMS)rd->data))) {
       J->base[0] = tr;
       /* Fixup cdata comparisons, too. Avoids some cdata escapes. */
-      if (J->postproc == LJ_POST_FIXGUARD && frame_iscont(J->L->base-1)) {
+      if (J->postproc == LJ_POST_FIXGUARD && frame_iscont(J->L->base-1) &&
+	  !irt_isguard(J->guardemit)) {
 	const BCIns *pc = frame_contpc(J->L->base-1) - 1;
 	if (bc_op(*pc) <= BC_ISNEP) {
 	  setframe_pc(&J2G(J)->tmptv, pc);
@@ -1026,7 +1160,8 @@ void LJ_FASTCALL recff_clib_index(jit_State *J, RecordFFData *rd)
     CType *ct;
     CTypeID id = lj_ctype_getname(cts, &ct, name, CLNS_INDEX);
     cTValue *tv = lj_tab_getstr(cl->cache, name);
-    if (id && tv && tviscdata(tv)) {
+    rd->nres = rd->data;
+    if (id && tv && !tvisnil(tv)) {
       /* Specialize to the symbol name and make the result a constant. */
       emitir(IRTG(IR_EQ, IRT_STR), J->base[1], lj_ir_kstr(J, name));
       if (ctype_isconstval(ct->info)) {
@@ -1036,7 +1171,21 @@ void LJ_FASTCALL recff_clib_index(jit_State *J, RecordFFData *rd)
 	else
 	  J->base[0] = lj_ir_kint(J, (int32_t)ct->size);
       } else if (ctype_isextern(ct->info)) {
-	lj_trace_err(J, LJ_TRERR_BADTYPE);  /* NYI: access extern variables. */
+	CTypeID sid = ctype_cid(ct->info);
+	void *sp = *(void **)cdataptr(cdataV(tv));
+	TRef ptr;
+	ct = ctype_raw(cts, sid);
+	if (rd->data && ctype_isenum(ct->info)) ct = ctype_child(cts, ct);
+	if (LJ_64 && !checkptr32(sp))
+	  ptr = lj_ir_kintp(J, (uintptr_t)sp);
+	else
+	  ptr = lj_ir_kptr(J, sp);
+	if (rd->data) {
+	  J->base[0] = crec_tv_ct(J, ct, sid, ptr);
+	} else {
+	  J->needsnap = 1;
+	  crec_ct_tv(J, ct, ptr, J->base[2], &rd->argv[2]);
+	}
       } else {
 	J->base[0] = lj_ir_kgc(J, obj2gco(cdataV(tv)), IRT_CDATA);
       }
@@ -1058,6 +1207,14 @@ void LJ_FASTCALL recff_ffi_new(jit_State *J, RecordFFData *rd)
   crec_alloc(J, rd, argv2ctype(J, J->base[0], &rd->argv[0]));
 }
 
+void LJ_FASTCALL recff_ffi_errno(jit_State *J, RecordFFData *rd)
+{
+  UNUSED(rd);
+  if (J->base[0])
+    lj_trace_err(J, LJ_TRERR_NYICALL);
+  J->base[0] = lj_ir_call(J, IRCALL_lj_vm_errno);
+}
+
 void LJ_FASTCALL recff_ffi_string(jit_State *J, RecordFFData *rd)
 {
   CTState *cts = ctype_ctsG(J2G(J));
diff --git a/third_party/luajit/src/lj_crecord.h b/third_party/luajit/src/lj_crecord.h
index fce45afed4e56e866839dadf8f5a9a1bbba89c00..fb042c56cea14879651e735d77f7ce6d3a97b71a 100644
--- a/third_party/luajit/src/lj_crecord.h
+++ b/third_party/luajit/src/lj_crecord.h
@@ -16,6 +16,7 @@ LJ_FUNC void LJ_FASTCALL recff_cdata_call(jit_State *J, RecordFFData *rd);
 LJ_FUNC void LJ_FASTCALL recff_cdata_arith(jit_State *J, RecordFFData *rd);
 LJ_FUNC void LJ_FASTCALL recff_clib_index(jit_State *J, RecordFFData *rd);
 LJ_FUNC void LJ_FASTCALL recff_ffi_new(jit_State *J, RecordFFData *rd);
+LJ_FUNC void LJ_FASTCALL recff_ffi_errno(jit_State *J, RecordFFData *rd);
 LJ_FUNC void LJ_FASTCALL recff_ffi_string(jit_State *J, RecordFFData *rd);
 LJ_FUNC void LJ_FASTCALL recff_ffi_copy(jit_State *J, RecordFFData *rd);
 LJ_FUNC void LJ_FASTCALL recff_ffi_fill(jit_State *J, RecordFFData *rd);
@@ -28,6 +29,7 @@ LJ_FUNC void LJ_FASTCALL lj_crecord_tonumber(jit_State *J, RecordFFData *rd);
 #define recff_cdata_arith	recff_nyi
 #define recff_clib_index	recff_nyi
 #define recff_ffi_new		recff_nyi
+#define recff_ffi_errno		recff_nyi
 #define recff_ffi_string	recff_nyi
 #define recff_ffi_copy		recff_nyi
 #define recff_ffi_fill		recff_nyi
diff --git a/third_party/luajit/src/lj_ctype.c b/third_party/luajit/src/lj_ctype.c
index 85e9a0ba33f5fc3409754dd13ccc321ff4a9807b..7187d6ff6dac3796990cda835ce81cbd28e38e98 100644
--- a/third_party/luajit/src/lj_ctype.c
+++ b/third_party/luajit/src/lj_ctype.c
@@ -12,6 +12,7 @@
 #include "lj_str.h"
 #include "lj_tab.h"
 #include "lj_ctype.h"
+#include "lj_ccallback.h"
 
 /* -- C type definitions -------------------------------------------------- */
 
@@ -315,7 +316,11 @@ cTValue *lj_ctype_meta(CTState *cts, CTypeID id, MMS mm)
     id = ctype_cid(ct->info);
     ct = ctype_get(cts, id);
   }
-  tv = lj_tab_getint(cts->metatype, (int32_t)id);
+  if (ctype_isptr(ct->info) &&
+      ctype_isfunc(ctype_get(cts, ctype_cid(ct->info))->info))
+    tv = lj_tab_getstr(cts->miscmap, &cts->g->strempty);
+  else
+    tv = lj_tab_getinth(cts->miscmap, -(int32_t)id);
   if (tv && tvistab(tv) &&
       (tv = lj_tab_getstr(tabV(tv), mmname_str(cts->g, mm))) && !tvisnil(tv))
     return tv;
@@ -592,7 +597,9 @@ void lj_ctype_freestate(global_State *g)
 {
   CTState *cts = ctype_ctsG(g);
   if (cts) {
+    lj_ccallback_mcode_free(cts);
     lj_mem_freevec(g, cts->tab, cts->sizetab, CType);
+    lj_mem_freevec(g, cts->cb.cbid, cts->cb.sizeid, CTypeID1);
     lj_mem_freet(g, cts);
   }
 }
diff --git a/third_party/luajit/src/lj_ctype.h b/third_party/luajit/src/lj_ctype.h
index f7a7121b6c697fd695dc7421bcdbfe6ece0ad56e..da3138513c0b73ab21f75a367e5c24f02e42a61f 100644
--- a/third_party/luajit/src/lj_ctype.h
+++ b/third_party/luajit/src/lj_ctype.h
@@ -117,7 +117,7 @@ LJ_STATIC_ASSERT(((int)CT_STRUCT & (int)CT_ARRAY) == CT_STRUCT);
   info = (info & ~(CTMASK_##field<<CTSHIFT_##field)) | \
 	  (((CTSize)(val) & CTMASK_##field) << CTSHIFT_##field)
 
-/* Calling conventions. */
+/* Calling conventions. ORDER CC */
 enum { CTCC_CDECL, CTCC_THISCALL, CTCC_FASTCALL, CTCC_STDCALL };
 
 /* Attribute numbers. */
@@ -151,6 +151,25 @@ typedef struct CType {
 #define CTHASH_SIZE	128	/* Number of hash anchors. */
 #define CTHASH_MASK	(CTHASH_SIZE-1)
 
+/* Simplify target-specific configuration. Checked in lj_ccall.h. */
+#define CCALL_MAX_GPR		8
+#define CCALL_MAX_FPR		8
+
+typedef LJ_ALIGN(8) union FPRCBArg { double d; float f; } FPRCBArg;
+
+/* C callback state. Defined here, to avoid dragging in lj_ccall.h. */
+
+typedef LJ_ALIGN(8) struct CCallback {
+  FPRCBArg fpr[CCALL_MAX_FPR];	/* Arguments/results in FPRs. */
+  intptr_t gpr[CCALL_MAX_GPR];	/* Arguments/results in GPRs. */
+  intptr_t *stack;		/* Pointer to arguments on stack. */
+  void *mcode;			/* Machine code for callback func. pointers. */
+  CTypeID1 *cbid;		/* Callback type table. */
+  MSize sizeid;			/* Size of callback type table. */
+  MSize topid;			/* Highest unused callback type table slot. */
+  MSize slot;			/* Current callback slot. */
+} CCallback;
+
 /* C type state. */
 typedef struct CTState {
   CType *tab;		/* C type table. */
@@ -159,7 +178,8 @@ typedef struct CTState {
   lua_State *L;		/* Lua state (needed for errors and allocations). */
   global_State *g;	/* Global state. */
   GCtab *finalizer;	/* Map of cdata to finalizer. */
-  GCtab *metatype;	/* Map of CTypeID to metatable. */
+  GCtab *miscmap;	/* Map of -CTypeID to metatable and cb slot to func. */
+  CCallback cb;		/* Temporary callback state. */
   CTypeID1 hash[CTHASH_SIZE];  /* Hash anchors for C type table. */
 } CTState;
 
@@ -243,7 +263,7 @@ typedef struct CTState {
 /* -- Predefined types ---------------------------------------------------- */
 
 /* Target-dependent types. */
-#if LJ_TARGET_PPC
+#if LJ_TARGET_PPC || LJ_TARGET_PPCSPE
 #define CTTYDEFP(_) \
   _(LINT32,		4,	CT_NUM, CTF_LONG|CTALIGN(2))
 #else
diff --git a/third_party/luajit/src/lj_debug.c b/third_party/luajit/src/lj_debug.c
index 1c4bac43b6a5742dc634b64407d3674b2decbaae..89434aaf8db31a5719bcc1f6446858673d1dcbdd 100644
--- a/third_party/luajit/src/lj_debug.c
+++ b/third_party/luajit/src/lj_debug.c
@@ -14,6 +14,9 @@
 #include "lj_state.h"
 #include "lj_frame.h"
 #include "lj_bc.h"
+#if LJ_HASJIT
+#include "lj_jit.h"
+#endif
 
 /* -- Frames -------------------------------------------------------------- */
 
@@ -49,6 +52,8 @@ cTValue *lj_debug_frame(lua_State *L, int level, int *size)
 static BCPos debug_framepc(lua_State *L, GCfunc *fn, cTValue *nextframe)
 {
   const BCIns *ins;
+  GCproto *pt;
+  BCPos pos;
   lua_assert(fn->c.gct == ~LJ_TFUNC || fn->c.gct == ~LJ_TTHREAD);
   if (!isluafunc(fn)) {  /* Cannot derive a PC for non-Lua functions. */
     return NO_BCPOS;
@@ -82,7 +87,16 @@ static BCPos debug_framepc(lua_State *L, GCfunc *fn, cTValue *nextframe)
       ins = cframe_pc(cf);
     }
   }
-  return proto_bcpos(funcproto(fn), ins) - 1;
+  pt = funcproto(fn);
+  pos = proto_bcpos(pt, ins) - 1;
+#if LJ_HASJIT
+  if (pos > pt->sizebc) {  /* Undo the effects of lj_trace_exit for JLOOP. */
+    GCtrace *T = (GCtrace *)((char *)(ins-1) - offsetof(GCtrace, startins));
+    lua_assert(bc_isret(bc_op(ins[-1])));
+    pos = proto_bcpos(pt, mref(T->startpc, const BCIns));
+  }
+#endif
+  return pos;
 }
 
 /* -- Line numbers -------------------------------------------------------- */
@@ -91,8 +105,9 @@ static BCPos debug_framepc(lua_State *L, GCfunc *fn, cTValue *nextframe)
 BCLine LJ_FASTCALL lj_debug_line(GCproto *pt, BCPos pc)
 {
   const void *lineinfo = proto_lineinfo(pt);
-  if (pc < pt->sizebc && lineinfo) {
+  if (pc <= pt->sizebc && lineinfo) {
     BCLine first = pt->firstline;
+    if (pc == pt->sizebc) return first + pt->numline;
     if (pc-- == 0) return first;
     if (pt->numline < 256)
       return first + (BCLine)((const uint8_t *)lineinfo)[pc];
@@ -110,7 +125,7 @@ static BCLine debug_frameline(lua_State *L, GCfunc *fn, cTValue *nextframe)
   BCPos pc = debug_framepc(L, fn, nextframe);
   if (pc != NO_BCPOS) {
     GCproto *pt = funcproto(fn);
-    lua_assert(pc < pt->sizebc);
+    lua_assert(pc <= pt->sizebc);
     return lj_debug_line(pt, pc);
   }
   return -1;
diff --git a/third_party/luajit/src/lj_def.h b/third_party/luajit/src/lj_def.h
index 78d988ea279105304c044b0bb97811a58766606b..5d21d584b862570c209336c6a3e466f67957b821 100644
--- a/third_party/luajit/src/lj_def.h
+++ b/third_party/luajit/src/lj_def.h
@@ -67,6 +67,8 @@ typedef unsigned int uintptr_t;
 #define LJ_MAX_IDXCHAIN	100		/* __index/__newindex chain limit. */
 #define LJ_STACK_EXTRA	5		/* Extra stack space (metamethods). */
 
+#define LJ_NUM_CBPAGE	1		/* Number of FFI callback pages. */
+
 /* Minimum table/buffer sizes. */
 #define LJ_MIN_GLOBAL	6		/* Min. global table size (hbits). */
 #define LJ_MIN_REGISTRY	2		/* Min. registry size (hbits). */
@@ -79,7 +81,7 @@ typedef unsigned int uintptr_t;
 /* JIT compiler limits. */
 #define LJ_MAX_JSLOTS	250		/* Max. # of stack slots for a trace. */
 #define LJ_MAX_PHI	32		/* Max. # of PHIs for a loop. */
-#define LJ_MAX_EXITSTUBGR	8	/* Max. # of exit stub groups. */
+#define LJ_MAX_EXITSTUBGR	16	/* Max. # of exit stub groups. */
 
 /* Various macros. */
 #ifndef UNUSED
diff --git a/third_party/luajit/src/lj_dispatch.c b/third_party/luajit/src/lj_dispatch.c
index c29cad46f394d3fd9c7ec0d49fe2c9d49f6c831f..38fd1709619ce82a0d26d1dcf5ec3acd3432f57d 100644
--- a/third_party/luajit/src/lj_dispatch.c
+++ b/third_party/luajit/src/lj_dispatch.c
@@ -50,7 +50,8 @@ void lj_dispatch_init(GG_State *GG)
 /* Initialize hotcount table. */
 void lj_dispatch_init_hotcount(global_State *g)
 {
-  HotCount start = (HotCount)G2J(g)->param[JIT_P_hotloop];
+  int32_t hotloop = G2J(g)->param[JIT_P_hotloop];
+  HotCount start = (HotCount)(hotloop*HOTCOUNT_LOOP - 1);
   HotCount *hotcount = G2GG(g)->hotcount;
   uint32_t i;
   for (i = 0; i < HOTCOUNT_SIZE; i++)
@@ -430,8 +431,12 @@ ASMFunction LJ_FASTCALL lj_dispatch_call(lua_State *L, const BCIns *pc)
     goto out;
   } else if (J->state != LJ_TRACE_IDLE &&
 	     !(g->hookmask & (HOOK_GC|HOOK_VMEVENT))) {
+#ifdef LUA_USE_ASSERT
+    ptrdiff_t delta = L->top - L->base;
+#endif
     /* Record the FUNC* bytecodes, too. */
     lj_trace_ins(J, pc-1);  /* The interpreter bytecode PC is offset by 1. */
+    lua_assert(L->top - L->base == delta);
   }
 #endif
   if ((g->hookmask & LUA_MASKCALL)) {
diff --git a/third_party/luajit/src/lj_dispatch.h b/third_party/luajit/src/lj_dispatch.h
index dd4f68fe26fcdf8182df139d3ea78063efa35cba..c50d33ac9f06ba916a61fb7e6f35c5f902eebc69 100644
--- a/third_party/luajit/src/lj_dispatch.h
+++ b/third_party/luajit/src/lj_dispatch.h
@@ -20,6 +20,10 @@ typedef uint16_t HotCount;
 #define HOTCOUNT_SIZE		64
 #define HOTCOUNT_PCMASK		((HOTCOUNT_SIZE-1)*sizeof(HotCount))
 
+/* Hotcount decrements. */
+#define HOTCOUNT_LOOP		2
+#define HOTCOUNT_CALL		1
+
 /* This solves a circular dependency problem -- bump as needed. Sigh. */
 #define GG_NUM_ASMFF	62
 
diff --git a/third_party/luajit/src/lj_emit_ppc.h b/third_party/luajit/src/lj_emit_ppc.h
new file mode 100644
index 0000000000000000000000000000000000000000..e44221cd80ed60cd74a19605c97dd6fa369caded
--- /dev/null
+++ b/third_party/luajit/src/lj_emit_ppc.h
@@ -0,0 +1,232 @@
+/*
+** PPC instruction emitter.
+** Copyright (C) 2005-2011 Mike Pall. See Copyright Notice in luajit.h
+*/
+
+/* -- Emit basic instructions --------------------------------------------- */
+
+static void emit_tab(ASMState *as, PPCIns pi, Reg rt, Reg ra, Reg rb)
+{
+  *--as->mcp = pi | PPCF_T(rt) | PPCF_A(ra) | PPCF_B(rb);
+}
+
+#define emit_asb(as, pi, ra, rs, rb)	emit_tab(as, (pi), (rs), (ra), (rb))
+#define emit_as(as, pi, ra, rs)		emit_tab(as, (pi), (rs), (ra), 0)
+#define emit_ab(as, pi, ra, rb)		emit_tab(as, (pi), 0, (ra), (rb))
+
+static void emit_tai(ASMState *as, PPCIns pi, Reg rt, Reg ra, int32_t i)
+{
+  *--as->mcp = pi | PPCF_T(rt) | PPCF_A(ra) | (i & 0xffff);
+}
+
+#define emit_ti(as, pi, rt, i)		emit_tai(as, (pi), (rt), 0, (i))
+#define emit_ai(as, pi, ra, i)		emit_tai(as, (pi), 0, (ra), (i))
+#define emit_asi(as, pi, ra, rs, i)	emit_tai(as, (pi), (rs), (ra), (i))
+
+#define emit_fab(as, pi, rf, ra, rb) \
+  emit_tab(as, (pi), (rf)&31, (ra)&31, (rb)&31)
+#define emit_fb(as, pi, rf, rb)		emit_tab(as, (pi), (rf)&31, 0, (rb)&31)
+#define emit_fac(as, pi, rf, ra, rc) \
+  emit_tab(as, (pi) | PPCF_C((rc) & 31), (rf)&31, (ra)&31, 0)
+#define emit_facb(as, pi, rf, ra, rc, rb) \
+  emit_tab(as, (pi) | PPCF_C((rc) & 31), (rf)&31, (ra)&31, (rb)&31)
+#define emit_fai(as, pi, rf, ra, i)	emit_tai(as, (pi), (rf)&31, (ra), (i))
+
+static void emit_rot(ASMState *as, PPCIns pi, Reg ra, Reg rs,
+		     int32_t n, int32_t b, int32_t e)
+{
+  *--as->mcp = pi | PPCF_T(rs) | PPCF_A(ra) | PPCF_B(n) |
+	       PPCF_MB(b) | PPCF_ME(e);
+}
+
+static void emit_slwi(ASMState *as, Reg ra, Reg rs, int32_t n)
+{
+  lua_assert(n >= 0 && n < 32);
+  emit_rot(as, PPCI_RLWINM, ra, rs, n, 0, 31-n);
+}
+
+static void emit_rotlwi(ASMState *as, Reg ra, Reg rs, int32_t n)
+{
+  lua_assert(n >= 0 && n < 32);
+  emit_rot(as, PPCI_RLWINM, ra, rs, n, 0, 31);
+}
+
+/* -- Emit loads/stores --------------------------------------------------- */
+
+/* Prefer rematerialization of BASE/L from global_State over spills. */
+#define emit_canremat(ref)	((ref) <= REF_BASE)
+
+/* Try to find a one step delta relative to another constant. */
+static int emit_kdelta1(ASMState *as, Reg t, int32_t i)
+{
+  RegSet work = ~as->freeset & RSET_GPR;
+  while (work) {
+    Reg r = rset_picktop(work);
+    IRRef ref = regcost_ref(as->cost[r]);
+    lua_assert(r != t);
+    if (ref < ASMREF_L) {
+      int32_t delta = i - (ra_iskref(ref) ? ra_krefk(as, ref) : IR(ref)->i);
+      if (checki16(delta)) {
+	emit_tai(as, PPCI_ADDI, t, r, delta);
+	return 1;
+      }
+    }
+    rset_clear(work, r);
+  }
+  return 0;  /* Failed. */
+}
+
+/* Load a 32 bit constant into a GPR. */
+static void emit_loadi(ASMState *as, Reg r, int32_t i)
+{
+  if (checki16(i)) {
+    emit_ti(as, PPCI_LI, r, i);
+  } else {
+    if ((i & 0xffff)) {
+      int32_t jgl = i32ptr(J2G(as->J));
+      if ((uint32_t)(i-jgl) < 65536) {
+	emit_tai(as, PPCI_ADDI, r, RID_JGL, i-jgl-32768);
+	return;
+      } else if (emit_kdelta1(as, r, i)) {
+	return;
+      }
+      emit_asi(as, PPCI_ORI, r, r, i);
+    }
+    emit_ti(as, PPCI_LIS, r, (i >> 16));
+  }
+}
+
+#define emit_loada(as, r, addr)		emit_loadi(as, (r), i32ptr((addr)))
+
+static Reg ra_allock(ASMState *as, int32_t k, RegSet allow);
+
+/* Get/set from constant pointer. */
+static void emit_lsptr(ASMState *as, PPCIns pi, Reg r, void *p, RegSet allow)
+{
+  int32_t jgl = i32ptr(J2G(as->J));
+  int32_t i = i32ptr(p);
+  Reg base;
+  if ((uint32_t)(i-jgl) < 65536) {
+    i = i-jgl-32768;
+    base = RID_JGL;
+  } else {
+    base = ra_allock(as, i-(int16_t)i, allow);
+  }
+  emit_tai(as, pi, r, base, i);
+}
+
+#define emit_loadn(as, r, tv) \
+  emit_lsptr(as, PPCI_LFD, ((r) & 31), (void *)(tv), RSET_GPR)
+
+/* Get/set global_State fields. */
+static void emit_lsglptr(ASMState *as, PPCIns pi, Reg r, int32_t ofs)
+{
+  emit_tai(as, pi, r, RID_JGL, ofs-32768);
+}
+
+#define emit_getgl(as, r, field) \
+  emit_lsglptr(as, PPCI_LWZ, (r), (int32_t)offsetof(global_State, field))
+#define emit_setgl(as, r, field) \
+  emit_lsglptr(as, PPCI_STW, (r), (int32_t)offsetof(global_State, field))
+
+/* Trace number is determined from per-trace exit stubs. */
+#define emit_setvmstate(as, i)		UNUSED(i)
+
+/* -- Emit control-flow instructions -------------------------------------- */
+
+/* Label for internal jumps. */
+typedef MCode *MCLabel;
+
+/* Return label pointing to current PC. */
+#define emit_label(as)		((as)->mcp)
+
+static void emit_condbranch(ASMState *as, PPCIns pi, PPCCC cc, MCode *target)
+{
+  MCode *p = as->mcp;
+  ptrdiff_t delta = ((char *)target - (char *)p) + 4;
+  lua_assert(((delta + 0x8000) >> 16) == 0);
+  pi ^= (delta & 0x8000) * (PPCF_Y/0x8000);
+  *--p = pi | PPCF_CC(cc) | ((uint32_t)delta & 0xffffu);
+  as->mcp = p;
+}
+
+static void emit_call(ASMState *as, void *target)
+{
+  MCode *p = --as->mcp;
+  ptrdiff_t delta = (char *)target - (char *)p;
+  if ((((delta>>2) + 0x00800000) >> 24) == 0) {
+    *p = PPCI_BL | (delta & 0x03fffffcu);
+  } else {  /* Target out of range: need indirect call. Don't use arg reg. */
+    RegSet allow = RSET_GPR & ~RSET_RANGE(RID_R0, REGARG_LASTGPR+1);
+    Reg r = ra_allock(as, i32ptr(target), allow);
+    *p = PPCI_BCTRL;
+    p[-1] = PPCI_MTCTR | PPCF_T(r);
+    as->mcp = p-1;
+  }
+}
+
+/* -- Emit generic operations --------------------------------------------- */
+
+#define emit_mr(as, dst, src) \
+  emit_asb(as, PPCI_MR, (dst), (src), (src))
+
+/* Generic move between two regs. */
+static void emit_movrr(ASMState *as, IRIns *ir, Reg dst, Reg src)
+{
+  UNUSED(ir);
+  if (dst < RID_MAX_GPR)
+    emit_mr(as, dst, src);
+  else
+    emit_fb(as, PPCI_FMR, dst, src);
+}
+
+/* Generic load of register from stack slot. */
+static void emit_spload(ASMState *as, IRIns *ir, Reg r, int32_t ofs)
+{
+  if (r < RID_MAX_GPR)
+    emit_tai(as, PPCI_LWZ, r, RID_SP, ofs);
+  else
+    emit_fai(as, irt_isnum(ir->t) ? PPCI_LFD : PPCI_LFS, r, RID_SP, ofs);
+}
+
+/* Generic store of register to stack slot. */
+static void emit_spstore(ASMState *as, IRIns *ir, Reg r, int32_t ofs)
+{
+  if (r < RID_MAX_GPR)
+    emit_tai(as, PPCI_STW, r, RID_SP, ofs);
+  else
+    emit_fai(as, irt_isnum(ir->t) ? PPCI_STFD : PPCI_STFS, r, RID_SP, ofs);
+}
+
+/* Emit a compare (for equality) with a constant operand. */
+static void emit_cmpi(ASMState *as, Reg r, int32_t k)
+{
+  if (checki16(k)) {
+    emit_ai(as, PPCI_CMPWI, r, k);
+  } else if (checku16(k)) {
+    emit_ai(as, PPCI_CMPLWI, r, k);
+  } else {
+    emit_ai(as, PPCI_CMPLWI, RID_TMP, k);
+    emit_asi(as, PPCI_XORIS, RID_TMP, r, (k >> 16));
+  }
+}
+
+/* Add offset to pointer. */
+static void emit_addptr(ASMState *as, Reg r, int32_t ofs)
+{
+  if (ofs) {
+    emit_tai(as, PPCI_ADDI, r, r, ofs);
+    if (!checki16(ofs))
+      emit_tai(as, PPCI_ADDIS, r, r, (ofs + 32768) >> 16);
+  }
+}
+
+static void emit_spsub(ASMState *as, int32_t ofs)
+{
+  if (ofs) {
+    emit_tai(as, PPCI_STWU, RID_TMP, RID_SP, -ofs);
+    emit_tai(as, PPCI_ADDI, RID_TMP, RID_SP,
+	     CFRAME_SIZE + (as->parent ? as->parent->spadjust : 0));
+  }
+}
+
diff --git a/third_party/luajit/src/lj_err.c b/third_party/luajit/src/lj_err.c
index 42bb87fc66beee7c057a1db09b053e1d577d8637..b0f3e5c7e4c3cdd92bdacbf9863ca7e3deeb45d5 100644
--- a/third_party/luajit/src/lj_err.c
+++ b/third_party/luajit/src/lj_err.c
@@ -113,6 +113,9 @@ static void *err_unwind(lua_State *L, void *stopcf, int errcode)
       frame = frame_prevl(frame);
       break;
     case FRAME_C:  /* C frame. */
+#if LJ_HASFFI
+    unwind_c:
+#endif
 #if LJ_UNWIND_EXT
       if (errcode) {
 	L->cframe = cframe_prev(cf);
@@ -145,6 +148,10 @@ static void *err_unwind(lua_State *L, void *stopcf, int errcode)
       }
       return cf;
     case FRAME_CONT:  /* Continuation frame. */
+#if LJ_HASFFI
+      if ((frame-1)->u32.lo == LJ_CONT_FFI_CALLBACK)
+	goto unwind_c;
+#endif
     case FRAME_VARG:  /* Vararg frame. */
       frame = frame_prevd(frame);
       break;
@@ -178,7 +185,7 @@ static void *err_unwind(lua_State *L, void *stopcf, int errcode)
 
 /* -- External frame unwinding -------------------------------------------- */
 
-#if defined(__GNUC__) && !defined(__symbian__)
+#if defined(__GNUC__) && !defined(LUAJIT_NO_UNWIND)
 
 #ifdef __clang__
 /* http://llvm.org/bugs/show_bug.cgi?id=8703 */
@@ -190,13 +197,13 @@ static void *err_unwind(lua_State *L, void *stopcf, int errcode)
 #if !LJ_TARGET_ARM
 
 #define LJ_UEXCLASS		0x4c55414a49543200ULL	/* LUAJIT2\0 */
-#define LJ_UEXCLASS_MAKE(c)	(LJ_UEXCLASS | (_Unwind_Exception_Class)(c))
+#define LJ_UEXCLASS_MAKE(c)	(LJ_UEXCLASS | (uint64_t)(c))
 #define LJ_UEXCLASS_CHECK(cl)	(((cl) ^ LJ_UEXCLASS) <= 0xff)
 #define LJ_UEXCLASS_ERRCODE(cl)	((int)((cl) & 0xff))
 
 /* DWARF2 personality handler referenced from interpreter .eh_frame. */
 LJ_FUNCA int lj_err_unwind_dwarf(int version, _Unwind_Action actions,
-  _Unwind_Exception_Class uexclass, struct _Unwind_Exception *uex,
+  uint64_t uexclass, struct _Unwind_Exception *uex,
   struct _Unwind_Context *ctx)
 {
   void *cf;
@@ -227,11 +234,13 @@ LJ_FUNCA int lj_err_unwind_dwarf(int version, _Unwind_Action actions,
     }
 #if LJ_UNWIND_EXT
     cf = err_unwind(L, cf, errcode);
-    if (cf) {
+    if ((actions & _UA_FORCE_UNWIND)) {
+      return _URC_CONTINUE_UNWIND;
+    } else if (cf) {
       _Unwind_SetGR(ctx, LJ_TARGET_EHRETREG, errcode);
-      _Unwind_SetIP(ctx, (_Unwind_Ptr)(cframe_unwind_ff(cf) ?
-				       lj_vm_unwind_ff_eh :
-				       lj_vm_unwind_c_eh));
+      _Unwind_SetIP(ctx, (uintptr_t)(cframe_unwind_ff(cf) ?
+				     lj_vm_unwind_ff_eh :
+				     lj_vm_unwind_c_eh));
       return _URC_INSTALL_CONTEXT;
     }
 #if LJ_TARGET_X86ORX64
@@ -240,7 +249,7 @@ LJ_FUNCA int lj_err_unwind_dwarf(int version, _Unwind_Action actions,
       ** Real fix: http://gcc.gnu.org/viewcvs/trunk/gcc/unwind-dw2.c?r1=121165&r2=124837&pathrev=153877&diff_format=h
       */
       _Unwind_SetGR(ctx, LJ_TARGET_EHRETREG, errcode);
-      _Unwind_SetIP(ctx, (_Unwind_Ptr)lj_vm_unwind_rethrow);
+      _Unwind_SetIP(ctx, (uintptr_t)lj_vm_unwind_rethrow);
       return _URC_INSTALL_CONTEXT;
     }
 #endif
@@ -255,8 +264,12 @@ LJ_FUNCA int lj_err_unwind_dwarf(int version, _Unwind_Action actions,
 }
 
 #if LJ_UNWIND_EXT
-/* NYI: this is not thread-safe. */
+#if LJ_TARGET_OSX
+/* Sorry, no thread safety for OSX. Complain to Apple, not me. */
 static struct _Unwind_Exception static_uex;
+#else
+static __thread struct _Unwind_Exception static_uex;
+#endif
 
 /* Raise DWARF2 exception. */
 static void err_raise_ext(int errcode)
@@ -280,7 +293,7 @@ LJ_FUNCA _Unwind_Reason_Code lj_err_unwind_arm(_Unwind_State state,
     setstrV(L, L->top++, lj_err_str(L, LJ_ERR_ERRCPP));
     return _URC_HANDLER_FOUND;
   }
-  if ((state & _US_ACTION_MASK) == _US_UNWIND_FRAME_STARTING) {
+  if ((state&(_US_ACTION_MASK|_US_FORCE_UNWIND)) == _US_UNWIND_FRAME_STARTING) {
     _Unwind_DeleteException(ucb);
     _Unwind_SetGR(ctx, 15, (_Unwind_Word)(void *)lj_err_throw);
     _Unwind_SetGR(ctx, 0, (_Unwind_Word)L);
@@ -458,6 +471,10 @@ static ptrdiff_t finderrfunc(lua_State *L)
       cf = cframe_prev(cf);
       /* fallthrough */
     case FRAME_CONT:
+#if LJ_HASFFI
+      if ((frame-1)->u32.lo == LJ_CONT_FFI_CALLBACK)
+	cf = cframe_prev(cf);
+#endif
     case FRAME_VARG:
       frame = frame_prevd(frame);
       break;
@@ -585,15 +602,23 @@ LJ_NOINLINE void lj_err_callermsg(lua_State *L, const char *msg)
   if (frame_islua(frame)) {
     pframe = frame_prevl(frame);
   } else if (frame_iscont(frame)) {
-    pframe = frame_prevd(frame);
 #if LJ_HASFFI
-    /* Remove frame for FFI metamethods. */
-    if (frame_func(frame)->c.ffid >= FF_ffi_meta___index &&
-	frame_func(frame)->c.ffid <= FF_ffi_meta___tostring) {
-      L->base = pframe+1;
-      L->top = frame;
-    }
+    if ((frame-1)->u32.lo == LJ_CONT_FFI_CALLBACK) {
+      pframe = frame;
+      frame = NULL;
+    } else
 #endif
+    {
+      pframe = frame_prevd(frame);
+#if LJ_HASFFI
+      /* Remove frame for FFI metamethods. */
+      if (frame_func(frame)->c.ffid >= FF_ffi_meta___index &&
+	  frame_func(frame)->c.ffid <= FF_ffi_meta___tostring) {
+	L->base = pframe+1;
+	L->top = frame;
+      }
+#endif
+    }
   }
   lj_debug_addloc(L, msg, pframe, frame);
   lj_err_run(L);
diff --git a/third_party/luajit/src/lj_errmsg.h b/third_party/luajit/src/lj_errmsg.h
index dc015ef2c024b18dfe882db1a897faca6ff39bc3..10c8395d0f8aaf4415f2de4693e0b99ec7d8cffe 100644
--- a/third_party/luajit/src/lj_errmsg.h
+++ b/third_party/luajit/src/lj_errmsg.h
@@ -160,6 +160,8 @@ ERRDEF(FFI_BADMEMBER,	LUA_QS " has no member named " LUA_QS)
 ERRDEF(FFI_BADIDX,	LUA_QS " cannot be indexed")
 ERRDEF(FFI_WRCONST,	"attempt to write to constant location")
 ERRDEF(FFI_NODECL,	"missing declaration for symbol " LUA_QS)
+ERRDEF(FFI_BADCBACK,	"bad callback")
+ERRDEF(FFI_CBACKOV,	"too many callbacks")
 ERRDEF(FFI_NYIPACKBIT,	"NYI: packed bit fields")
 ERRDEF(FFI_NYICALL,	"NYI: cannot call this C function (yet)")
 #endif
diff --git a/third_party/luajit/src/lj_ffrecord.c b/third_party/luajit/src/lj_ffrecord.c
index 067f66cff2f2c389af7f2e21c0d5864a7d62b5cb..6cdd79a9a6707921f4c57c0ad78afa09fad7200a 100644
--- a/third_party/luajit/src/lj_ffrecord.c
+++ b/third_party/luajit/src/lj_ffrecord.c
@@ -297,15 +297,17 @@ static int recff_metacall(jit_State *J, RecordFFData *rd, MMS mm)
   copyTV(J->L, &ix.tabv, &rd->argv[0]);
   if (lj_record_mm_lookup(J, &ix, mm)) {  /* Has metamethod? */
     int errcode;
+    TValue argv0;
     /* Temporarily insert metamethod below object. */
     J->base[1] = J->base[0];
     J->base[0] = ix.mobj;
+    copyTV(J->L, &argv0, &rd->argv[0]);
     copyTV(J->L, &rd->argv[1], &rd->argv[0]);
     copyTV(J->L, &rd->argv[0], &ix.mobjv);
     /* Need to protect lj_record_tailcall because it may throw. */
     errcode = lj_vm_cpcall(J->L, NULL, J, recff_metacall_cp);
     /* Always undo Lua stack changes to avoid confusing the interpreter. */
-    copyTV(J->L, &rd->argv[0], &rd->argv[1]);
+    copyTV(J->L, &rd->argv[0], &argv0);
     if (errcode)
       lj_err_throw(J->L, errcode);  /* Propagate errors. */
     rd->nres = -1;  /* Pending call. */
diff --git a/third_party/luajit/src/lj_frame.h b/third_party/luajit/src/lj_frame.h
index 4a2a767afa798744660a34f1eb70d81075f8e2dc..3497671b5f8ba8da40ff188fe84ddcd2c3baad3f 100644
--- a/third_party/luajit/src/lj_frame.h
+++ b/third_party/luajit/src/lj_frame.h
@@ -67,7 +67,6 @@ enum {
 #define CFRAME_OFS_PC		(6*4)
 #define CFRAME_OFS_MULTRES	(5*4)
 #define CFRAME_SIZE		(12*4)
-#define CFRAME_SIZE_JIT		CFRAME_SIZE
 #define CFRAME_SHIFT_MULTRES	0
 #elif LJ_TARGET_X64
 #if LJ_ABI_WIN
@@ -99,7 +98,15 @@ enum {
 #define CFRAME_OFS_PC		8
 #define CFRAME_OFS_MULTRES	4
 #define CFRAME_SIZE		64
-#define CFRAME_SIZE_JIT		CFRAME_SIZE
+#define CFRAME_SHIFT_MULTRES	3
+#elif LJ_TARGET_PPC
+#define CFRAME_OFS_ERRF		48
+#define CFRAME_OFS_NRES		44
+#define CFRAME_OFS_PREV		40
+#define CFRAME_OFS_L		36
+#define CFRAME_OFS_PC		32
+#define CFRAME_OFS_MULTRES	28
+#define CFRAME_SIZE		272
 #define CFRAME_SHIFT_MULTRES	3
 #elif LJ_TARGET_PPCSPE
 #define CFRAME_OFS_ERRF		28
@@ -108,13 +115,16 @@ enum {
 #define CFRAME_OFS_L		16
 #define CFRAME_OFS_PC		12
 #define CFRAME_OFS_MULTRES	8
-#define CFRAME_SIZE		176
-#define CFRAME_SIZE_JIT		CFRAME_SIZE
+#define CFRAME_SIZE		184
 #define CFRAME_SHIFT_MULTRES	3
 #else
 #error "Missing CFRAME_* definitions for this architecture"
 #endif
 
+#ifndef CFRAME_SIZE_JIT
+#define CFRAME_SIZE_JIT		CFRAME_SIZE
+#endif
+
 #define CFRAME_RESUME		1
 #define CFRAME_UNWIND_FF	2  /* Only used in unwinder. */
 #define CFRAME_RAWMASK		(~(intptr_t)(CFRAME_RESUME|CFRAME_UNWIND_FF))
@@ -128,6 +138,8 @@ enum {
   (&gcref(*(GCRef *)(((char *)(cf))+CFRAME_OFS_L))->th)
 #define cframe_pc(cf) \
   (mref(*(MRef *)(((char *)(cf))+CFRAME_OFS_PC), const BCIns))
+#define setcframe_L(cf, L) \
+  (setmref(*(MRef *)(((char *)(cf))+CFRAME_OFS_L), (L)))
 #define setcframe_pc(cf, pc) \
   (setmref(*(MRef *)(((char *)(cf))+CFRAME_OFS_PC), (pc)))
 #define cframe_canyield(cf)	((intptr_t)(cf) & CFRAME_RESUME)
diff --git a/third_party/luajit/src/lj_func.c b/third_party/luajit/src/lj_func.c
index 334ba4c8509a49d88448634d6b229e51ec9396df..97be0a2aae809a8a19262e17b9b1bcb9292e766f 100644
--- a/third_party/luajit/src/lj_func.c
+++ b/third_party/luajit/src/lj_func.c
@@ -118,6 +118,7 @@ GCfunc *lj_func_newC(lua_State *L, MSize nelems, GCtab *env)
 
 static GCfunc *func_newL(lua_State *L, GCproto *pt, GCtab *env)
 {
+  uint32_t count;
   GCfunc *fn = (GCfunc *)lj_mem_newgco(L, sizeLfunc((MSize)pt->sizeuv));
   fn->l.gct = ~LJ_TFUNC;
   fn->l.ffid = FF_LUA;
@@ -125,6 +126,9 @@ static GCfunc *func_newL(lua_State *L, GCproto *pt, GCtab *env)
   /* NOBARRIER: Really a setgcref. But the GCfunc is new (marked white). */
   setmref(fn->l.pc, proto_bc(pt));
   setgcref(fn->l.env, obj2gco(env));
+  /* Saturating 3 bit counter (0..7) for created closures. */
+  count = (uint32_t)pt->flags + PROTO_CLCOUNT;
+  pt->flags = (uint8_t)(count - ((count >> PROTO_CLC_BITS) & PROTO_CLCOUNT));
   return fn;
 }
 
diff --git a/third_party/luajit/src/lj_gdbjit.c b/third_party/luajit/src/lj_gdbjit.c
index acbe429ab98b9542e99677dc088a862265579444..130ab99164f721ded70cd54fb55aa108eac2a509 100644
--- a/third_party/luajit/src/lj_gdbjit.c
+++ b/third_party/luajit/src/lj_gdbjit.c
@@ -232,8 +232,10 @@ enum {
 
 enum {
   DW_CFA_nop = 0x0,
+  DW_CFA_offset_extended = 0x5,
   DW_CFA_def_cfa = 0xc,
   DW_CFA_def_cfa_offset = 0xe,
+  DW_CFA_offset_extended_sf = 0x11,
   DW_CFA_advance_loc = 0x40,
   DW_CFA_offset = 0x80
 };
@@ -292,6 +294,10 @@ enum {
 #elif LJ_TARGET_ARM
   DW_REG_SP = 13,
   DW_REG_RA = 14,
+#elif LJ_TARGET_PPC
+  DW_REG_SP = 1,
+  DW_REG_RA = 65,
+  DW_REG_CR = 70,
 #else
 #error "Unsupported target architecture"
 #endif
@@ -361,6 +367,8 @@ static const ELFheader elfhdr_template = {
   .machine = 62,
 #elif LJ_TARGET_ARM
   .machine = 40,
+#elif LJ_TARGET_PPC
+  .machine = 20,
 #else
 #error "Unsupported target architecture"
 #endif
@@ -523,7 +531,11 @@ static void LJ_FASTCALL gdbjit_ehframe(GDBJITctx *ctx)
     DB(DW_REG_RA);		/* Return address register. */
     DB(1); DB(DW_EH_PE_textrel|DW_EH_PE_udata4);  /* Augmentation data. */
     DB(DW_CFA_def_cfa); DUV(DW_REG_SP); DUV(sizeof(uintptr_t));
+#if LJ_TARGET_PPC
+    DB(DW_CFA_offset_extended_sf); DB(DW_REG_RA); DSV(-1);
+#else
     DB(DW_CFA_offset|DW_REG_RA); DUV(1);
+#endif
     DALIGNNOP(sizeof(uintptr_t));
   )
 
@@ -550,10 +562,19 @@ static void LJ_FASTCALL gdbjit_ehframe(GDBJITctx *ctx)
 #elif LJ_TARGET_ARM
     {
       int i;
+      DB(DW_CFA_offset_extended); DB(DW_REG_CR); DUV(55);
       for (i = 11; i >= 4; i--) {  /* R4-R11. */
 	DB(DW_CFA_offset|i); DUV(2+(11-i));
       }
     }
+#elif LJ_TARGET_PPC
+    {
+      int i;
+      for (i = 14; i <= 31; i++) {
+	DB(DW_CFA_offset|i); DUV(37+(31-i));
+	DB(DW_CFA_offset|32|i); DUV(2+2*(31-i));
+      }
+    }
 #else
 #error "Unsupported target architecture"
 #endif
diff --git a/third_party/luajit/src/lj_ir.c b/third_party/luajit/src/lj_ir.c
index 8f22e085385402054ccdd2f85d10c4cc9292adf5..457d918768da54a79aa8e2c7cc658fabe4fb2427 100644
--- a/third_party/luajit/src/lj_ir.c
+++ b/third_party/luajit/src/lj_ir.c
@@ -47,8 +47,8 @@ IRDEF(IRMODE)
 
 /* C call info for CALL* instructions. */
 LJ_DATADEF const CCallInfo lj_ir_callinfo[] = {
-#define IRCALLCI(name, nargs, kind, type, flags) \
-  { (ASMFunction)name, \
+#define IRCALLCI(cond, name, nargs, kind, type, flags) \
+  { (ASMFunction)IRCALLCOND_##cond(name), \
     (nargs)|(CCI_CALL_##kind)|(IRT_##type<<CCI_OTSHIFT)|(flags) },
 IRCALLDEF(IRCALLCI)
 #undef IRCALLCI
diff --git a/third_party/luajit/src/lj_ir.h b/third_party/luajit/src/lj_ir.h
index aac34350d107acec6931009266ac247524ed1458..8cf8129f1f18e516cacd12bfa5c42ac28e48ff60 100644
--- a/third_party/luajit/src/lj_ir.h
+++ b/third_party/luajit/src/lj_ir.h
@@ -183,6 +183,7 @@ IRFPMDEF(FPMENUM)
 #define IRFLDEF(_) \
   _(STR_LEN,	offsetof(GCstr, len)) \
   _(FUNC_ENV,	offsetof(GCfunc, l.env)) \
+  _(FUNC_PC,	offsetof(GCfunc, l.pc)) \
   _(TAB_META,	offsetof(GCtab, metatable)) \
   _(TAB_ARRAY,	offsetof(GCtab, array)) \
   _(TAB_NODE,	offsetof(GCtab, node)) \
@@ -195,7 +196,7 @@ IRFPMDEF(FPMENUM)
   _(CDATA_TYPEID, offsetof(GCcdata, typeid)) \
   _(CDATA_PTR,	sizeof(GCcdata)) \
   _(CDATA_INT64, sizeof(GCcdata)) \
-  _(CDATA_INT64HI, sizeof(GCcdata) + 4)
+  _(CDATA_INT64_4, sizeof(GCcdata) + 4)
 
 typedef enum {
 #define FLENUM(name, ofs)	IRFL_##name,
@@ -354,6 +355,7 @@ typedef struct IRType1 { uint8_t irt; } IRType1;
 #endif
 
 #define irt_is64(t)		((IRT_IS64 >> irt_type(t)) & 1)
+#define irt_is64orfp(t)		(((IRT_IS64|(1u<<IRT_FLOAT))>>irt_type(t)) & 1)
 
 static LJ_AINLINE IRType itype2irt(const TValue *tv)
 {
diff --git a/third_party/luajit/src/lj_ircall.h b/third_party/luajit/src/lj_ircall.h
index 3b0a54b6f4c62068a7dcbd7093a9b8e4589ca0c1..1a9599afe4b99d8c9e6677d7403bd109ca40f457 100644
--- a/third_party/luajit/src/lj_ircall.h
+++ b/third_party/luajit/src/lj_ircall.h
@@ -27,137 +27,157 @@ typedef struct CCallInfo {
 #define CCI_CALL_N		(IR_CALLN << CCI_OPSHIFT)
 #define CCI_CALL_L		(IR_CALLL << CCI_OPSHIFT)
 #define CCI_CALL_S		(IR_CALLS << CCI_OPSHIFT)
-#define CCI_CALL_FN		(CCI_CALL_N|CCI_FASTCALL)
-#define CCI_CALL_FL		(CCI_CALL_L|CCI_FASTCALL)
-#define CCI_CALL_FS		(CCI_CALL_S|CCI_FASTCALL)
+#define CCI_CALL_FN		(CCI_CALL_N|CCI_CC_FASTCALL)
+#define CCI_CALL_FL		(CCI_CALL_L|CCI_CC_FASTCALL)
+#define CCI_CALL_FS		(CCI_CALL_S|CCI_CC_FASTCALL)
 
 /* C call info flags. */
 #define CCI_L			0x0100	/* Implicit L arg. */
 #define CCI_CASTU64		0x0200	/* Cast u64 result to number. */
 #define CCI_NOFPRCLOBBER	0x0400	/* Does not clobber any FPRs. */
-#define CCI_FASTCALL		0x0800	/* Fastcall convention. */
+#define CCI_VARARG		0x0800	/* Vararg function. */
+
+#define CCI_CC_MASK		0x3000	/* Calling convention mask. */
+#define CCI_CC_SHIFT		12
+/* ORDER CC */
+#define CCI_CC_CDECL		0x0000	/* Default cdecl calling convention. */
+#define CCI_CC_THISCALL		0x1000	/* Thiscall calling convention. */
+#define CCI_CC_FASTCALL		0x2000	/* Fastcall calling convention. */
+#define CCI_CC_STDCALL		0x3000	/* Stdcall calling convention. */
+
+/* Helpers for conditional function definitions. */
+#define IRCALLCOND_ANY(x)		x
+
+#if LJ_TARGET_X86ORX64
+#define IRCALLCOND_FPMATH(x)		NULL
+#else
+#define IRCALLCOND_FPMATH(x)		x
+#endif
 
-/* Function definitions for CALL* instructions. */
 #if LJ_SOFTFP
+#define IRCALLCOND_SOFTFP(x)		x
 #if LJ_HASFFI
-#define IRCALLDEF_SOFTFP_FFI(_) \
-  _(softfp_ui2d,	1,   N, NUM, 0) \
-  _(softfp_l2d,		2,   N, NUM, 0) \
-  _(softfp_ul2d,	2,   N, NUM, 0) \
-  _(softfp_f2d,		1,   N, NUM, 0) \
-  _(softfp_d2ui,	2,   N, INT, 0) \
-  _(softfp_d2l,		2,   N, I64, 0) \
-  _(softfp_d2ul,	2,   N, U64, 0) \
-  _(softfp_d2f,		2,   N, FLOAT, 0) \
-  _(softfp_i2f,		1,   N, FLOAT, 0) \
-  _(softfp_ui2f,	1,   N, FLOAT, 0) \
-  _(softfp_l2f,		2,   N, FLOAT, 0) \
-  _(softfp_ul2f,	2,   N, FLOAT, 0) \
-  _(softfp_f2i,		1,   N, INT, 0) \
-  _(softfp_f2ui,	1,   N, INT, 0) \
-  _(softfp_f2l,		1,   N, I64, 0) \
-  _(softfp_f2ul,	1,   N, U64, 0)
+#define IRCALLCOND_SOFTFP_FFI(x)	x
 #else
-#define IRCALLDEF_SOFTFP_FFI(_)
-#endif
-#define IRCALLDEF_SOFTFP(_) \
-  _(lj_vm_tobit,	2,   N, INT, 0) \
-  _(softfp_add,		4,   N, NUM, 0) \
-  _(softfp_sub,		4,   N, NUM, 0) \
-  _(softfp_mul,		4,   N, NUM, 0) \
-  _(softfp_div,		4,   N, NUM, 0) \
-  _(softfp_cmp,		4,   N, NIL, 0) \
-  _(softfp_i2d,		1,   N, NUM, 0) \
-  _(softfp_d2i,		2,   N, INT, 0) \
-  IRCALLDEF_SOFTFP_FFI(_)
+#define IRCALLCOND_SOFTFP_FFI(x)	NULL
+#endif
 #else
-#define IRCALLDEF_SOFTFP(_)
+#define IRCALLCOND_SOFTFP(x)		NULL
+#define IRCALLCOND_SOFTFP_FFI(x)	NULL
 #endif
 
-#if LJ_TARGET_X86ORX64
-/* Use lj_vm_* helpers and x87 ops. */
-#define IRCALLDEF_FPMATH(_)
+#define LJ_NEED_FP64			LJ_TARGET_PPC
+
+#if LJ_HASFFI && (LJ_SOFTFP || LJ_NEED_FP64)
+#define IRCALLCOND_FP64_FFI(x)		x
 #else
-/* Use standard math library calls. */
+#define IRCALLCOND_FP64_FFI(x)		NULL
+#endif
+
+#if LJ_HASFFI
+#define IRCALLCOND_FFI(x)		x
+#if LJ_32
+#define IRCALLCOND_FFI32(x)		x
+#else
+#define IRCALLCOND_FFI32(x)		NULL
+#endif
+#else
+#define IRCALLCOND_FFI(x)		NULL
+#define IRCALLCOND_FFI32(x)		NULL
+#endif
+
 #if LJ_SOFTFP
 #define ARG1_FP		2	/* Treat as 2 32 bit arguments. */
 #else
 #define ARG1_FP		1
 #endif
-/* ORDER FPM */
-#define IRCALLDEF_FPMATH(_) \
-  _(lj_vm_floor,	ARG1_FP,   N, NUM, 0) \
-  _(lj_vm_ceil,		ARG1_FP,   N, NUM, 0) \
-  _(lj_vm_trunc,	ARG1_FP,   N, NUM, 0) \
-  _(sqrt,		ARG1_FP,   N, NUM, 0) \
-  _(exp,		ARG1_FP,   N, NUM, 0) \
-  _(lj_vm_exp2,		ARG1_FP,   N, NUM, 0) \
-  _(log,		ARG1_FP,   N, NUM, 0) \
-  _(lj_vm_log2,		ARG1_FP,   N, NUM, 0) \
-  _(log10,		ARG1_FP,   N, NUM, 0) \
-  _(sin,		ARG1_FP,   N, NUM, 0) \
-  _(cos,		ARG1_FP,   N, NUM, 0) \
-  _(tan,		ARG1_FP,   N, NUM, 0) \
-  _(lj_vm_powi,		ARG1_FP+1, N, NUM, 0) \
-  _(pow,		ARG1_FP*2, N, NUM, 0) \
-  _(atan2,		ARG1_FP*2, N, NUM, 0) \
-  _(ldexp,		ARG1_FP+1, N, NUM, 0)
-#endif
 
-#if LJ_HASFFI
 #if LJ_32
 #define ARG2_64		4	/* Treat as 4 32 bit arguments. */
-#define IRCALLDEF_FFI32(_) \
-  _(lj_carith_mul64,	ARG2_64,   N, I64, CCI_NOFPRCLOBBER)
 #else
 #define ARG2_64		2
-#define IRCALLDEF_FFI32(_)
-#endif
-#define IRCALLDEF_FFI(_) \
-  IRCALLDEF_FFI32(_) \
-  _(lj_carith_divi64,	ARG2_64,   N, I64, CCI_NOFPRCLOBBER) \
-  _(lj_carith_divu64,	ARG2_64,   N, U64, CCI_NOFPRCLOBBER) \
-  _(lj_carith_modi64,	ARG2_64,   N, I64, CCI_NOFPRCLOBBER) \
-  _(lj_carith_modu64,	ARG2_64,   N, U64, CCI_NOFPRCLOBBER) \
-  _(lj_carith_powi64,	ARG2_64,   N, I64, CCI_NOFPRCLOBBER) \
-  _(lj_carith_powu64,	ARG2_64,   N, U64, CCI_NOFPRCLOBBER) \
-  _(lj_cdata_setfin,	2,        FN, P32, CCI_L) \
-  _(strlen,		1,         N, INTP, 0) \
-  _(memcpy,		3,         S, PTR, 0) \
-  _(memset,		3,         S, PTR, 0)
-#else
-#define IRCALLDEF_FFI(_)
 #endif
 
+/* Function definitions for CALL* instructions. */
 #define IRCALLDEF(_) \
-  _(lj_str_cmp,		2,  FN, INT, CCI_NOFPRCLOBBER) \
-  _(lj_str_new,		3,   S, STR, CCI_L) \
-  _(lj_str_tonum,	2,  FN, INT, 0) \
-  _(lj_str_fromint,	2,  FN, STR, CCI_L) \
-  _(lj_str_fromnum,	2,  FN, STR, CCI_L) \
-  _(lj_tab_new1,	2,  FS, TAB, CCI_L) \
-  _(lj_tab_dup,		2,  FS, TAB, CCI_L) \
-  _(lj_tab_newkey,	3,   S, P32, CCI_L) \
-  _(lj_tab_len,		1,  FL, INT, 0) \
-  _(lj_gc_step_jit,	2,  FS, NIL, CCI_L) \
-  _(lj_gc_barrieruv,	2,  FS, NIL, 0) \
-  _(lj_mem_newgco,	2,  FS, P32, CCI_L) \
-  _(lj_math_random_step, 1, FS, NUM, CCI_CASTU64|CCI_NOFPRCLOBBER) \
-  _(lj_vm_modi,		2,  FN, INT, 0) \
-  IRCALLDEF_SOFTFP(_) \
-  IRCALLDEF_FPMATH(_) \
-  IRCALLDEF_FFI(_) \
-  _(sinh,		1,  N, NUM, 0) \
-  _(cosh,		1,  N, NUM, 0) \
-  _(tanh,		1,  N, NUM, 0) \
-  _(fputc,		2,  S, INT, 0) \
-  _(fwrite,		4,  S, INT, 0) \
-  _(fflush,		1,  S, INT, 0) \
+  _(ANY,	lj_str_cmp,		2,  FN, INT, CCI_NOFPRCLOBBER) \
+  _(ANY,	lj_str_new,		3,   S, STR, CCI_L) \
+  _(ANY,	lj_str_tonum,		2,  FN, INT, 0) \
+  _(ANY,	lj_str_fromint,		2,  FN, STR, CCI_L) \
+  _(ANY,	lj_str_fromnum,		2,  FN, STR, CCI_L) \
+  _(ANY,	lj_tab_new1,		2,  FS, TAB, CCI_L) \
+  _(ANY,	lj_tab_dup,		2,  FS, TAB, CCI_L) \
+  _(ANY,	lj_tab_newkey,		3,   S, P32, CCI_L) \
+  _(ANY,	lj_tab_len,		1,  FL, INT, 0) \
+  _(ANY,	lj_gc_step_jit,		2,  FS, NIL, CCI_L) \
+  _(ANY,	lj_gc_barrieruv,	2,  FS, NIL, 0) \
+  _(ANY,	lj_mem_newgco,		2,  FS, P32, CCI_L) \
+  _(ANY,	lj_math_random_step, 1, FS, NUM, CCI_CASTU64|CCI_NOFPRCLOBBER) \
+  _(ANY,	lj_vm_modi,		2,  FN, INT, 0) \
+  _(ANY,	sinh,			1,  N, NUM, 0) \
+  _(ANY,	cosh,			1,  N, NUM, 0) \
+  _(ANY,	tanh,			1,  N, NUM, 0) \
+  _(ANY,	fputc,			2,  S, INT, 0) \
+  _(ANY,	fwrite,			4,  S, INT, 0) \
+  _(ANY,	fflush,			1,  S, INT, 0) \
+  /* ORDER FPM */ \
+  _(FPMATH,	lj_vm_floor,		ARG1_FP,   N, NUM, 0) \
+  _(FPMATH,	lj_vm_ceil,		ARG1_FP,   N, NUM, 0) \
+  _(FPMATH,	lj_vm_trunc,		ARG1_FP,   N, NUM, 0) \
+  _(FPMATH,	sqrt,			ARG1_FP,   N, NUM, 0) \
+  _(FPMATH,	exp,			ARG1_FP,   N, NUM, 0) \
+  _(FPMATH,	lj_vm_exp2,		ARG1_FP,   N, NUM, 0) \
+  _(FPMATH,	log,			ARG1_FP,   N, NUM, 0) \
+  _(FPMATH,	lj_vm_log2,		ARG1_FP,   N, NUM, 0) \
+  _(FPMATH,	log10,			ARG1_FP,   N, NUM, 0) \
+  _(FPMATH,	sin,			ARG1_FP,   N, NUM, 0) \
+  _(FPMATH,	cos,			ARG1_FP,   N, NUM, 0) \
+  _(FPMATH,	tan,			ARG1_FP,   N, NUM, 0) \
+  _(FPMATH,	lj_vm_powi,		ARG1_FP+1, N, NUM, 0) \
+  _(FPMATH,	pow,			ARG1_FP*2, N, NUM, 0) \
+  _(FPMATH,	atan2,			ARG1_FP*2, N, NUM, 0) \
+  _(FPMATH,	ldexp,			ARG1_FP+1, N, NUM, 0) \
+  _(SOFTFP,	lj_vm_tobit,		2,   N, INT, 0) \
+  _(SOFTFP,	softfp_add,		4,   N, NUM, 0) \
+  _(SOFTFP,	softfp_sub,		4,   N, NUM, 0) \
+  _(SOFTFP,	softfp_mul,		4,   N, NUM, 0) \
+  _(SOFTFP,	softfp_div,		4,   N, NUM, 0) \
+  _(SOFTFP,	softfp_cmp,		4,   N, NIL, 0) \
+  _(SOFTFP,	softfp_i2d,		1,   N, NUM, 0) \
+  _(SOFTFP,	softfp_d2i,		2,   N, INT, 0) \
+  _(SOFTFP_FFI,	softfp_ui2d,		1,   N, NUM, 0) \
+  _(SOFTFP_FFI,	softfp_f2d,		1,   N, NUM, 0) \
+  _(SOFTFP_FFI,	softfp_d2ui,		2,   N, INT, 0) \
+  _(SOFTFP_FFI,	softfp_d2f,		2,   N, FLOAT, 0) \
+  _(SOFTFP_FFI,	softfp_i2f,		1,   N, FLOAT, 0) \
+  _(SOFTFP_FFI,	softfp_ui2f,		1,   N, FLOAT, 0) \
+  _(SOFTFP_FFI,	softfp_f2i,		1,   N, INT, 0) \
+  _(SOFTFP_FFI,	softfp_f2ui,		1,   N, INT, 0) \
+  _(FP64_FFI,	fp64_l2d,		2,   N, NUM, 0) \
+  _(FP64_FFI,	fp64_ul2d,		2,   N, NUM, 0) \
+  _(FP64_FFI,	fp64_l2f,		2,   N, FLOAT, 0) \
+  _(FP64_FFI,	fp64_ul2f,		2,   N, FLOAT, 0) \
+  _(FP64_FFI,	fp64_d2l,		2,   N, I64, 0) \
+  _(FP64_FFI,	fp64_d2ul,		2,   N, U64, 0) \
+  _(FP64_FFI,	fp64_f2l,		1,   N, I64, 0) \
+  _(FP64_FFI,	fp64_f2ul,		1,   N, U64, 0) \
+  _(FFI,	lj_carith_divi64,	ARG2_64,   N, I64, CCI_NOFPRCLOBBER) \
+  _(FFI,	lj_carith_divu64,	ARG2_64,   N, U64, CCI_NOFPRCLOBBER) \
+  _(FFI,	lj_carith_modi64,	ARG2_64,   N, I64, CCI_NOFPRCLOBBER) \
+  _(FFI,	lj_carith_modu64,	ARG2_64,   N, U64, CCI_NOFPRCLOBBER) \
+  _(FFI,	lj_carith_powi64,	ARG2_64,   N, I64, CCI_NOFPRCLOBBER) \
+  _(FFI,	lj_carith_powu64,	ARG2_64,   N, U64, CCI_NOFPRCLOBBER) \
+  _(FFI,	lj_cdata_setfin,	2,        FN, P32, CCI_L) \
+  _(FFI,	strlen,			1,         L, INTP, 0) \
+  _(FFI,	memcpy,			3,         S, PTR, 0) \
+  _(FFI,	memset,			3,         S, PTR, 0) \
+  _(FFI,	lj_vm_errno,		0,         S, INT, CCI_NOFPRCLOBBER) \
+  _(FFI32,	lj_carith_mul64,	ARG2_64,   N, I64, CCI_NOFPRCLOBBER)
   \
   /* End of list. */
 
 typedef enum {
-#define IRCALLENUM(name, nargs, kind, type, flags)	IRCALL_##name,
+#define IRCALLENUM(cond, name, nargs, kind, type, flags)	IRCALL_##name,
 IRCALLDEF(IRCALLENUM)
 #undef IRCALLENUM
   IRCALL__MAX
@@ -176,23 +196,30 @@ LJ_DATA const CCallInfo lj_ir_callinfo[IRCALL__MAX+1];
 #define softfp_div __aeabi_ddiv
 #define softfp_cmp __aeabi_cdcmple
 #define softfp_i2d __aeabi_i2d
+#define softfp_d2i __aeabi_d2iz
 #define softfp_ui2d __aeabi_ui2d
-#define softfp_l2d __aeabi_l2d
-#define softfp_ul2d __aeabi_ul2d
 #define softfp_f2d __aeabi_f2d
-#define softfp_d2i __aeabi_d2iz
 #define softfp_d2ui __aeabi_d2uiz
-#define softfp_d2l __aeabi_d2lz
-#define softfp_d2ul __aeabi_d2ulz
 #define softfp_d2f __aeabi_d2f
 #define softfp_i2f __aeabi_i2f
 #define softfp_ui2f __aeabi_ui2f
-#define softfp_l2f __aeabi_l2f
-#define softfp_ul2f __aeabi_ul2f
 #define softfp_f2i __aeabi_f2iz
 #define softfp_f2ui __aeabi_f2uiz
-#define softfp_f2l __aeabi_f2lz
-#define softfp_f2ul __aeabi_f2ulz
+#define fp64_l2d __aeabi_l2d
+#define fp64_ul2d __aeabi_ul2d
+#define fp64_l2f __aeabi_l2f
+#define fp64_ul2f __aeabi_ul2f
+#if LJ_TARGET_OSX
+#define fp64_d2l __fixdfdi
+#define fp64_d2ul __fixunsdfdi
+#define fp64_f2l __fixsfdi
+#define fp64_f2ul __fixunssfdi
+#else
+#define fp64_d2l __aeabi_d2lz
+#define fp64_d2ul __aeabi_d2ulz
+#define fp64_f2l __aeabi_f2lz
+#define fp64_f2ul __aeabi_f2ulz
+#endif
 #else
 #error "Missing soft-float definitions for target architecture"
 #endif
@@ -202,23 +229,43 @@ extern double softfp_mul(double a, double b);
 extern double softfp_div(double a, double b);
 extern void softfp_cmp(double a, double b);
 extern double softfp_i2d(int32_t a);
+extern int32_t softfp_d2i(double a);
+#if LJ_HASFFI
 extern double softfp_ui2d(uint32_t a);
-extern double softfp_l2d(int64_t a);
-extern double softfp_ul2d(uint64_t a);
 extern double softfp_f2d(float a);
-extern int32_t softfp_d2i(double a);
 extern uint32_t softfp_d2ui(double a);
-extern int64_t softfp_d2l(double a);
-extern uint64_t softfp_d2ul(double a);
 extern float softfp_d2f(double a);
 extern float softfp_i2f(int32_t a);
 extern float softfp_ui2f(uint32_t a);
-extern float softfp_l2f(int64_t a);
-extern float softfp_ul2f(uint64_t a);
 extern int32_t softfp_f2i(float a);
 extern uint32_t softfp_f2ui(float a);
-extern int64_t softfp_f2l(float a);
-extern uint64_t softfp_f2ul(float a);
+#endif
+#endif
+
+#if LJ_HASFFI && LJ_NEED_FP64
+#ifdef __GNUC__
+#define fp64_l2d __floatdidf
+#define fp64_ul2d __floatundidf
+#define fp64_l2f __floatdisf
+#define fp64_ul2f __floatundisf
+#define fp64_d2l __fixdfdi
+#define fp64_d2ul __fixunsdfdi
+#define fp64_f2l __fixsfdi
+#define fp64_f2ul __fixunssfdi
+#else
+#error "Missing fp64 helper definitions for this compiler"
+#endif
+#endif
+
+#if LJ_HASFFI && (LJ_SOFTFP || LJ_NEED_FP64)
+extern double fp64_l2d(int64_t a);
+extern double fp64_ul2d(uint64_t a);
+extern float fp64_l2f(int64_t a);
+extern float fp64_ul2f(uint64_t a);
+extern int64_t fp64_d2l(double a);
+extern uint64_t fp64_d2ul(double a);
+extern int64_t fp64_f2l(float a);
+extern uint64_t fp64_f2ul(float a);
 #endif
 
 #endif
diff --git a/third_party/luajit/src/lj_jit.h b/third_party/luajit/src/lj_jit.h
index ea2dd4adaf0c6e4dd28ead54cc23615eb5404068..8a4c04c808ef2b5a6a42d65baee7c43d1fdc094c 100644
--- a/third_party/luajit/src/lj_jit.h
+++ b/third_party/luajit/src/lj_jit.h
@@ -122,6 +122,7 @@ typedef enum {
   LJ_POST_NONE,		/* No action. */
   LJ_POST_FIXCOMP,	/* Fixup comparison and emit pending guard. */
   LJ_POST_FIXGUARD,	/* Fixup and emit pending guard. */
+  LJ_POST_FIXGUARDSNAP,	/* Fixup and emit pending guard and snapshot. */
   LJ_POST_FIXBOOL,	/* Fixup boolean result. */
   LJ_POST_FFRETRY	/* Suppress recording of retried fast functions. */
 } PostProc;
@@ -138,8 +139,8 @@ typedef struct SnapShot {
   uint16_t mapofs;	/* Offset into snapshot map. */
   IRRef1 ref;		/* First IR ref for this snapshot. */
   uint8_t nslots;	/* Number of valid slots. */
+  uint8_t topslot;	/* Maximum frame extent. */
   uint8_t nent;		/* Number of compressed entries. */
-  uint8_t depth;	/* Number of frame links. */
   uint8_t count;	/* Count of taken exits for this snapshot. */
 } SnapShot;
 
@@ -174,13 +175,23 @@ typedef uint32_t ExitNo;
 typedef uint32_t TraceNo;	/* Used to pass around trace numbers. */
 typedef uint16_t TraceNo1;	/* Stored trace number. */
 
-#define TRACE_INTERP	0	/* Fallback to interpreter. */
+/* Type of link. ORDER LJ_TRLINK */
+typedef enum {
+  LJ_TRLINK_NONE,		/* Incomplete trace. No link, yet. */
+  LJ_TRLINK_ROOT,		/* Link to other root trace. */
+  LJ_TRLINK_LOOP,		/* Loop to same trace. */
+  LJ_TRLINK_TAILREC,		/* Tail-recursion. */
+  LJ_TRLINK_UPREC,		/* Up-recursion. */
+  LJ_TRLINK_DOWNREC,		/* Down-recursion. */
+  LJ_TRLINK_INTERP,		/* Fallback to interpreter. */
+  LJ_TRLINK_RETURN		/* Return to interpreter. */
+} TraceLink;
 
 /* Trace object. */
 typedef struct GCtrace {
   GCHeader;
   uint8_t topslot;	/* Top stack slot already checked to be allocated. */
-  uint8_t unused1;
+  uint8_t linktype;	/* Type of link. */
   IRRef nins;		/* Next IR instruction. Biased with REF_BIAS. */
   GCRef gclist;
   IRIns *ir;		/* IR instructions/constants. Biased with REF_BIAS. */
@@ -214,6 +225,14 @@ typedef struct GCtrace {
 
 LJ_STATIC_ASSERT(offsetof(GChead, gclist) == offsetof(GCtrace, gclist));
 
+static LJ_AINLINE MSize snap_nextofs(GCtrace *T, SnapShot *snap)
+{
+  if (snap+1 == &T->snap[T->nsnap])
+    return T->nsnapmap;
+  else
+    return (snap+1)->mapofs;
+}
+
 /* Round-robin penalty cache for bytecodes leading to aborted traces. */
 typedef struct HotPenalty {
   MRef pc;		/* Starting bytecode PC. */
@@ -222,7 +241,7 @@ typedef struct HotPenalty {
 } HotPenalty;
 
 #define PENALTY_SLOTS	64	/* Penalty cache slot. Must be a power of 2. */
-#define PENALTY_MIN	36	/* Minimum penalty value. */
+#define PENALTY_MIN	(36*2)	/* Minimum penalty value. */
 #define PENALTY_MAX	60000	/* Maximum penalty value. */
 #define PENALTY_RNDBITS	4	/* # of random bits to add to penalty value. */
 
@@ -358,7 +377,11 @@ typedef struct jit_State {
   size_t szallmcarea;	/* Total size of all allocated mcode areas. */
 
   TValue errinfo;	/* Additional info element for trace errors. */
-} LJ_ALIGN(16) jit_State;
+}
+#if LJ_TARGET_ARM
+LJ_ALIGN(16)		/* For DISPATCH-relative addresses in assembler part. */
+#endif
+jit_State;
 
 /* Trivial PRNG e.g. used for penalty randomization. */
 static LJ_AINLINE uint32_t LJ_PRNG_BITS(jit_State *J, int bits)
diff --git a/third_party/luajit/src/lj_lex.c b/third_party/luajit/src/lj_lex.c
index 01e0c641a711f63142fd880575f954100be079cc..59d82259269bc9d42679e937e635a38763673f98 100644
--- a/third_party/luajit/src/lj_lex.c
+++ b/third_party/luajit/src/lj_lex.c
@@ -137,14 +137,17 @@ static int lex_number64(LexState *ls, TValue *tv)
 /* Parse a number literal. */
 static void lex_number(LexState *ls, TValue *tv)
 {
-  int c;
+  int c, xp = 'E';
   lua_assert(lj_char_isdigit(ls->current));
-  do {
+  if ((c = ls->current) == '0') {
+    save_and_next(ls);
+    if ((ls->current & ~0x20) == 'X') xp = 'P';
+  }
+  while (lj_char_isident(ls->current) || ls->current == '.' ||
+	 ((ls->current == '-' || ls->current == '+') && (c & ~0x20) == xp)) {
     c = ls->current;
     save_and_next(ls);
-  } while (lj_char_isident(ls->current) || ls->current == '.' ||
-	   ((ls->current == '-' || ls->current == '+') &&
-	    ((c & ~0x20) == 'E' || (c & ~0x20) == 'P')));
+  }
 #if LJ_HASFFI
   c &= ~0x20;
   if ((c == 'I' || c == 'L' || c == 'U') && !ctype_ctsG(G(ls->L)))
@@ -238,9 +241,8 @@ static void read_string(LexState *ls, int delim, TValue *tv)
       lj_lex_error(ls, TK_string, LJ_ERR_XSTR);
       continue;
     case '\\': {
-      int c;
-      next(ls);  /* Skip the '\\'. */
-      switch (ls->current) {
+      int c = next(ls);  /* Skip the '\\'. */
+      switch (c) {
       case 'a': c = '\a'; break;
       case 'b': c = '\b'; break;
       case 'f': c = '\f'; break;
@@ -260,31 +262,30 @@ static void read_string(LexState *ls, int delim, TValue *tv)
 	  c += 9;
 	}
 	break;
-      case '*':  /* Skip whitespace. */
+      case 'z':  /* Skip whitespace. */
 	next(ls);
 	while (lj_char_isspace(ls->current))
 	  if (currIsNewline(ls)) inclinenumber(ls); else next(ls);
 	continue;
       case '\n': case '\r': save(ls, '\n'); inclinenumber(ls); continue;
+      case '\\': case '\"': case '\'': break;
       case END_OF_STREAM: continue;
       default:
-	if (!lj_char_isdigit(ls->current)) {
-	  save_and_next(ls);  /* Handles '\\', '\"' and "\'". */
-	} else {  /* Decimal escape '\ddd'. */
-	  c = (ls->current - '0');
+	if (!lj_char_isdigit(c))
+	  goto err_xesc;
+	c -= '0';  /* Decimal escape '\ddd'. */
+	if (lj_char_isdigit(next(ls))) {
+	  c = c*10 + (ls->current - '0');
 	  if (lj_char_isdigit(next(ls))) {
 	    c = c*10 + (ls->current - '0');
-	    if (lj_char_isdigit(next(ls))) {
-	      c = c*10 + (ls->current - '0');
-	      if (c > 255) {
-	      err_xesc:
-		lj_lex_error(ls, TK_string, LJ_ERR_XESC);
-	      }
-	      next(ls);
+	    if (c > 255) {
+	    err_xesc:
+	      lj_lex_error(ls, TK_string, LJ_ERR_XESC);
 	    }
+	    next(ls);
 	  }
-	  save(ls, c);
 	}
+	save(ls, c);
 	continue;
       }
       save(ls, c);
diff --git a/third_party/luajit/src/lj_mcode.c b/third_party/luajit/src/lj_mcode.c
index 279854f87b5d20ab7502174569b84827d175e217..90ac34fcb0de0393c84681201950b4f181b10dbe 100644
--- a/third_party/luajit/src/lj_mcode.c
+++ b/third_party/luajit/src/lj_mcode.c
@@ -7,18 +7,65 @@
 #define LUA_CORE
 
 #include "lj_obj.h"
-
 #if LJ_HASJIT
-
 #include "lj_gc.h"
 #include "lj_jit.h"
 #include "lj_mcode.h"
 #include "lj_trace.h"
 #include "lj_dispatch.h"
 #include "lj_vm.h"
+#endif
 
 /* -- OS-specific functions ----------------------------------------------- */
 
+#if LJ_HASJIT || LJ_HASFFI
+
+/* Define this if you want to run LuaJIT with Valgrind. */
+#ifdef LUAJIT_USE_VALGRIND
+#include <valgrind/valgrind.h>
+#endif
+
+#if !LJ_TARGET_X86ORX64 && LJ_TARGET_OSX
+void sys_icache_invalidate(void *start, size_t len);
+#endif
+
+#if LJ_TARGET_LINUX && LJ_TARGET_PPC
+#include <dlfcn.h>
+static void (*mcode_sync_ppc)(void *start, void *end);
+static void mcode_sync_dummy(void *start, void *end)
+{
+    UNUSED(start); UNUSED(end);
+}
+#endif
+
+/* Synchronize data/instruction cache. */
+void lj_mcode_sync(void *start, void *end)
+{
+#ifdef LUAJIT_USE_VALGRIND
+  VALGRIND_DISCARD_TRANSLATIONS(start, (char *)end-(char *)start);
+#endif
+#if LJ_TARGET_X86ORX64
+  UNUSED(start); UNUSED(end);
+#elif LJ_TARGET_OSX
+  sys_icache_invalidate(start, (char *)end-(char *)start);
+#elif LJ_TARGET_LINUX && LJ_TARGET_PPC
+  if (!mcode_sync_ppc) {
+    void *vdso = dlopen("linux-vdso32.so.1", RTLD_LAZY);
+    if (!vdso || !(mcode_sync_ppc = dlsym(vdso, "__kernel_sync_dicache")))
+      mcode_sync_ppc = mcode_sync_dummy;
+  }
+  mcode_sync_ppc(start, end);
+#elif defined(__GNUC__) && !LJ_TARGET_PPC
+  __clear_cache(start, end);
+#else
+#error "Missing builtin to flush instruction cache"
+#endif
+}
+
+#endif
+
+#if LJ_HASJIT
+
 #if LJ_TARGET_WINDOWS
 
 #define WIN32_LEAN_AND_MEAN
diff --git a/third_party/luajit/src/lj_mcode.h b/third_party/luajit/src/lj_mcode.h
index be1bdb5aa37b30461e334e986c0f829448e09d02..d11b668223e16c6094795fa4df4e5b72bb0e4529 100644
--- a/third_party/luajit/src/lj_mcode.h
+++ b/third_party/luajit/src/lj_mcode.h
@@ -6,9 +6,16 @@
 #ifndef _LJ_MCODE_H
 #define _LJ_MCODE_H
 
-#include "lj_jit.h"
+#include "lj_obj.h"
+
+#if LJ_HASJIT || LJ_HASFFI
+LJ_FUNC void lj_mcode_sync(void *start, void *end);
+#endif
 
 #if LJ_HASJIT
+
+#include "lj_jit.h"
+
 LJ_FUNC void lj_mcode_free(jit_State *J);
 LJ_FUNC MCode *lj_mcode_reserve(jit_State *J, MCode **lim);
 LJ_FUNC void lj_mcode_commit(jit_State *J, MCode *m);
diff --git a/third_party/luajit/src/lj_meta.c b/third_party/luajit/src/lj_meta.c
index 278d2d34b94e6eed512c2fc83b44fc9b71e1503a..f258e3e1c0d2e59522e38787d2c1075e90db0515 100644
--- a/third_party/luajit/src/lj_meta.c
+++ b/third_party/luajit/src/lj_meta.c
@@ -77,7 +77,7 @@ int lj_meta_tailcall(lua_State *L, cTValue *tv)
   TValue *top = L->top;
   const BCIns *pc = frame_pc(base-1);  /* Preserve old PC from frame. */
   copyTV(L, base-1, tv);  /* Replace frame with new object. */
-  top->u64 = 0;
+  top->u32.lo = LJ_CONT_TAILCALL;
   setframe_pc(top, pc);
   setframe_gc(top+1, obj2gco(L));  /* Dummy frame object. */
   setframe_ftsz(top+1, (int)((char *)(top+2) - (char *)base) + FRAME_CONT);
diff --git a/third_party/luajit/src/lj_obj.h b/third_party/luajit/src/lj_obj.h
index afb29d0f7b7c32ed7790d918328b0dbae11e32b0..4a360df6196e2f17984922e88e23c355403a381a 100644
--- a/third_party/luajit/src/lj_obj.h
+++ b/third_party/luajit/src/lj_obj.h
@@ -318,6 +318,9 @@ typedef struct GCproto {
 /* Only used during parsing. */
 #define PROTO_HAS_RETURN	0x20	/* Already emitted a return. */
 #define PROTO_FIXUP_RETURN	0x40	/* Need to fixup emitted returns. */
+/* Top bits used for counting created closures. */
+#define PROTO_CLCOUNT		0x20	/* Base of saturating 3 bit counter. */
+#define PROTO_CLC_BITS		3
 
 #define proto_kgc(pt, idx) \
   check_exp((uintptr_t)(intptr_t)(idx) >= (uintptr_t)-(intptr_t)(pt)->sizekgc, \
diff --git a/third_party/luajit/src/lj_opt_dce.c b/third_party/luajit/src/lj_opt_dce.c
index 253fe3d21378312bf6741fe1faf7a142b08f9cb9..0587262d75816e9cf9376d9b1c8a675c929e1acb 100644
--- a/third_party/luajit/src/lj_opt_dce.c
+++ b/third_party/luajit/src/lj_opt_dce.c
@@ -47,17 +47,15 @@ static void dce_propagate(jit_State *J)
       pchain[ir->o] = &ir->prev;
     } else if (!ir_sideeff(ir)) {
       *pchain[ir->o] = ir->prev;  /* Reroute original instruction chain. */
-      *pchain[IR_NOP] = (IRRef1)ins;
       ir->t.irt = IRT_NIL;
       ir->o = IR_NOP;  /* Replace instruction with NOP. */
       ir->op1 = ir->op2 = 0;
-      pchain[IR_NOP] = &ir->prev;
+      ir->prev = 0;
       continue;
     }
     if (ir->op1 >= REF_FIRST) irt_setmark(IR(ir->op1)->t);
     if (ir->op2 >= REF_FIRST) irt_setmark(IR(ir->op2)->t);
   }
-  *pchain[IR_NOP] = 0;  /* Terminate NOP chain. */
 }
 
 /* Dead Code Elimination.
diff --git a/third_party/luajit/src/lj_opt_fold.c b/third_party/luajit/src/lj_opt_fold.c
index 2ecac2d95cd5188a8c9f382840cda7486cd2e3ac..e7d4f9cd7273f6dae06360f98e09005771e8247c 100644
--- a/third_party/luajit/src/lj_opt_fold.c
+++ b/third_party/luajit/src/lj_opt_fold.c
@@ -232,6 +232,7 @@ static int32_t kfold_intop(int32_t k1, int32_t k2, IROp op)
   case IR_SUB: k1 -= k2; break;
   case IR_MUL: k1 *= k2; break;
   case IR_MOD: k1 = lj_vm_modi(k1, k2); break;
+  case IR_NEG: k1 = -k1; break;
   case IR_BAND: k1 &= k2; break;
   case IR_BOR: k1 |= k2; break;
   case IR_BXOR: k1 ^= k2; break;
@@ -251,6 +252,7 @@ LJFOLD(ADD KINT KINT)
 LJFOLD(SUB KINT KINT)
 LJFOLD(MUL KINT KINT)
 LJFOLD(MOD KINT KINT)
+LJFOLD(NEG KINT KINT)
 LJFOLD(BAND KINT KINT)
 LJFOLD(BOR KINT KINT)
 LJFOLD(BXOR KINT KINT)
@@ -929,11 +931,11 @@ LJFOLDF(simplify_conv_int_i64)
   return NEXTFOLD;
 }
 
-LJFOLD(CONV CONV IRCONV_NUM_FLOAT)  /* _NUM */
+LJFOLD(CONV CONV IRCONV_FLOAT_NUM)  /* _FLOAT */
 LJFOLDF(simplify_conv_flt_num)
 {
   PHIBARRIER(fleft);
-  if ((fleft->op2 & IRCONV_SRCMASK) == IRT_NUM)
+  if ((fleft->op2 & IRCONV_SRCMASK) == IRT_FLOAT)
     return fleft->op1;
   return NEXTFOLD;
 }
@@ -965,6 +967,7 @@ LJFOLDF(simplify_floor_conv)
 
 /* Strength reduction of widening. */
 LJFOLD(CONV any IRCONV_I64_INT)
+LJFOLD(CONV any IRCONV_U64_INT)
 LJFOLDF(simplify_conv_sext)
 {
   IRRef ref = fins->op1;
@@ -1399,6 +1402,36 @@ LJFOLDF(simplify_shift2_ki)
   return NEXTFOLD;
 }
 
+LJFOLD(BSHL BAND KINT)
+LJFOLD(BSHR BAND KINT)
+LJFOLD(BROL BAND KINT)
+LJFOLD(BROR BAND KINT)
+LJFOLDF(simplify_shiftk_andk)
+{
+  IRIns *irk = IR(fleft->op2);
+  PHIBARRIER(fleft);
+  if (irk->o == IR_KINT) {  /* (i & k1) o k2 ==> (i o k2) & (k1 o k2) */
+    int32_t k = kfold_intop(irk->i, fright->i, (IROp)fins->o);
+    fins->op1 = fleft->op1;
+    fins->op1 = (IRRef1)lj_opt_fold(J);
+    fins->op2 = (IRRef1)lj_ir_kint(J, k);
+    fins->ot = IRTI(IR_BAND);
+    return RETRYFOLD;
+  }
+  return NEXTFOLD;
+}
+
+LJFOLD(BAND BSHL KINT)
+LJFOLD(BAND BSHR KINT)
+LJFOLDF(simplify_andk_shiftk)
+{
+  IRIns *irk = IR(fleft->op2);
+  if (irk->o == IR_KINT &&
+      kfold_intop(-1, irk->i, (IROp)fleft->o) == fright->i)
+    return LEFTFOLD;  /* (i o k1) & k2 ==> i, if (-1 o k1) == k2 */
+  return NEXTFOLD;
+}
+
 /* -- Reassociation ------------------------------------------------------- */
 
 LJFOLD(ADD ADD KINT)
@@ -1450,7 +1483,6 @@ LJFOLD(BAND BAND any)
 LJFOLD(BOR BOR any)
 LJFOLDF(reassoc_dup)
 {
-  PHIBARRIER(fleft);
   if (fins->op2 == fleft->op1 || fins->op2 == fleft->op2)
     return LEFTFOLD;  /* (a o b) o a ==> a o b; (a o b) o b ==> a o b */
   return NEXTFOLD;
diff --git a/third_party/luajit/src/lj_opt_loop.c b/third_party/luajit/src/lj_opt_loop.c
index 6dd06636c6d8e8cf9b9fab0ac20a3199044ec01d..460297b6463ed6931c7af5dd4ae629c630f0cadd 100644
--- a/third_party/luajit/src/lj_opt_loop.c
+++ b/third_party/luajit/src/lj_opt_loop.c
@@ -104,7 +104,7 @@
 static void loop_emit_phi(jit_State *J, IRRef1 *subst, IRRef1 *phi, IRRef nphi,
 			  SnapNo onsnap)
 {
-  int pass2 = 0;
+  int passx = 0;
   IRRef i, nslots;
   IRRef invar = J->chain[IR_LOOP];
   /* Pass #1: mark redundant and potentially redundant PHIs. */
@@ -116,16 +116,28 @@ static void loop_emit_phi(jit_State *J, IRRef1 *subst, IRRef1 *phi, IRRef nphi,
     } else if (!(IR(rref)->op1 == lref || IR(rref)->op2 == lref)) {
       /* Quick check for simple recurrences failed, need pass2. */
       irt_setmark(IR(lref)->t);
-      pass2 = 1;
+      passx = 1;
     }
   }
   /* Pass #2: traverse variant part and clear marks of non-redundant PHIs. */
-  if (pass2) {
+  if (passx) {
     SnapNo s;
     for (i = J->cur.nins-1; i > invar; i--) {
       IRIns *ir = IR(i);
-      if (!irref_isk(ir->op1)) irt_clearmark(IR(ir->op1)->t);
       if (!irref_isk(ir->op2)) irt_clearmark(IR(ir->op2)->t);
+      if (!irref_isk(ir->op1)) {
+	irt_clearmark(IR(ir->op1)->t);
+	if (ir->op1 < invar &&
+	    ir->o >= IR_CALLN && ir->o <= IR_CARG) {  /* ORDER IR */
+	  ir = IR(ir->op1);
+	  while (ir->o == IR_CARG) {
+	    if (!irref_isk(ir->op2)) irt_clearmark(IR(ir->op2)->t);
+	    if (irref_isk(ir->op1)) break;
+	    ir = IR(ir->op1);
+	    irt_clearmark(ir->t);
+	  }
+	}
+      }
     }
     for (s = J->cur.nsnap-1; s >= onsnap; s--) {
       SnapShot *snap = &J->cur.snap[s];
@@ -155,7 +167,27 @@ static void loop_emit_phi(jit_State *J, IRRef1 *subst, IRRef1 *phi, IRRef nphi,
 	break;
     }
   }
-  /* Pass #4: emit PHI instructions or eliminate PHIs. */
+  /* Pass #4: propagate non-redundant PHIs. */
+  while (passx) {
+    passx = 0;
+    for (i = 0; i < nphi; i++) {
+      IRRef lref = phi[i];
+      IRIns *ir = IR(lref);
+      if (!irt_ismarked(ir->t)) {  /* Propagate only from unmarked PHIs. */
+	IRRef rref = subst[lref];
+	if (lref == rref) {  /* Mark redundant PHI. */
+	  irt_setmark(ir->t);
+	} else {
+	  IRIns *irr = IR(rref);
+	  if (irt_ismarked(irr->t)) {  /* Right ref points to other PHI? */
+	    irt_clearmark(irr->t);  /* Mark that PHI as non-redundant. */
+	    passx = 1;  /* Retry. */
+	  }
+	}
+      }
+    }
+  }
+  /* Pass #5: emit PHI instructions or eliminate PHIs. */
   for (i = 0; i < nphi; i++) {
     IRRef lref = phi[i];
     IRIns *ir = IR(lref);
@@ -178,7 +210,8 @@ static void loop_subst_snap(jit_State *J, SnapShot *osnap,
 			    SnapEntry *loopmap, IRRef1 *subst)
 {
   SnapEntry *nmap, *omap = &J->cur.snapmap[osnap->mapofs];
-  MSize nmapofs, depth;
+  SnapEntry *nextmap = &J->cur.snapmap[snap_nextofs(&J->cur, osnap)];
+  MSize nmapofs;
   MSize on, ln, nn, onent = osnap->nent;
   BCReg nslots = osnap->nslots;
   SnapShot *snap = &J->cur.snap[J->cur.nsnap];
@@ -190,12 +223,11 @@ static void loop_subst_snap(jit_State *J, SnapShot *osnap,
     nmapofs = snap->mapofs;
   }
   J->guardemit.irt = 0;
-  depth = osnap->depth;
   /* Setup new snapshot. */
   snap->mapofs = (uint16_t)nmapofs;
   snap->ref = (IRRef1)J->cur.nins;
-  snap->depth = (uint8_t)depth;
   snap->nslots = nslots;
+  snap->topslot = osnap->topslot;
   snap->count = 0;
   nmap = &J->cur.snapmap[nmapofs];
   /* Substitute snapshot slots. */
@@ -216,11 +248,11 @@ static void loop_subst_snap(jit_State *J, SnapShot *osnap,
   while (snap_slot(loopmap[ln]) < nslots)  /* Copy remaining loop slots. */
     nmap[nn++] = loopmap[ln++];
   snap->nent = (uint8_t)nn;
-  J->cur.nsnapmap = (uint16_t)(nmapofs + nn + 1 + depth);
   omap += onent;
   nmap += nn;
-  for (nn = 0; nn <= depth; nn++)  /* Copy PC + frame links. */
-    nmap[nn] = omap[nn];
+  while (omap < nextmap)  /* Copy PC + frame links. */
+    *nmap++ = *omap++;
+  J->cur.nsnapmap = (uint16_t)(nmap - J->cur.snapmap);
 }
 
 /* Unroll loop. */
@@ -300,13 +332,24 @@ static void loop_unroll(jit_State *J)
 	}
 	/* Check all loop-carried dependencies for type instability. */
 	if (!irt_sametype(t, irr->t)) {
-	  if (irt_isnum(t) && irt_isinteger(irr->t))  /* Fix int->num. */
-	    subst[ins] = tref_ref(emitir(IRTN(IR_CONV), ref, IRCONV_NUM_INT));
+	  if (irt_isinteger(t) && irt_isinteger(irr->t))
+	    continue;
+	  else if (irt_isnum(t) && irt_isinteger(irr->t))  /* Fix int->num. */
+	    ref = tref_ref(emitir(IRTN(IR_CONV), ref, IRCONV_NUM_INT));
 	  else if (irt_isnum(irr->t) && irt_isinteger(t))  /* Fix num->int. */
-	    subst[ins] = tref_ref(emitir(IRTGI(IR_CONV), ref,
-					 IRCONV_INT_NUM|IRCONV_CHECK));
-	  else if (!(irt_isinteger(t) && irt_isinteger(irr->t)))
+	    ref = tref_ref(emitir(IRTGI(IR_CONV), ref,
+				  IRCONV_INT_NUM|IRCONV_CHECK));
+	  else
 	    lj_trace_err(J, LJ_TRERR_TYPEINS);
+	  subst[ins] = (IRRef1)ref;
+	  /* May need a PHI for the CONV, too. */
+	  irr = IR(ref);
+	  if (ref < invar && !irref_isk(ref) && !irt_isphi(irr->t)) {
+	    irt_setphi(irr->t);
+	    if (nphi >= LJ_MAX_PHI)
+	      lj_trace_err(J, LJ_TRERR_PHIOV);
+	    phi[nphi++] = (IRRef1)ref;
+	  }
 	}
       }
     }
@@ -320,13 +363,13 @@ static void loop_unroll(jit_State *J)
 }
 
 /* Undo any partial changes made by the loop optimization. */
-static void loop_undo(jit_State *J, IRRef ins, SnapNo nsnap)
+static void loop_undo(jit_State *J, IRRef ins, SnapNo nsnap, MSize nsnapmap)
 {
   ptrdiff_t i;
   SnapShot *snap = &J->cur.snap[nsnap-1];
   SnapEntry *map = J->cur.snapmap;
   map[snap->mapofs + snap->nent] = map[J->cur.snap[0].nent];  /* Restore PC. */
-  J->cur.nsnapmap = (uint16_t)(snap->mapofs + snap->nent + 1 + snap->depth);
+  J->cur.nsnapmap = (uint16_t)nsnapmap;
   J->cur.nsnap = nsnap;
   J->guardemit.irt = 0;
   lj_ir_rollback(J, ins);
@@ -355,6 +398,7 @@ int lj_opt_loop(jit_State *J)
 {
   IRRef nins = J->cur.nins;
   SnapNo nsnap = J->cur.nsnap;
+  MSize nsnapmap = J->cur.nsnapmap;
   int errcode = lj_vm_cpcall(J->L, NULL, J, cploop_opt);
   if (LJ_UNLIKELY(errcode)) {
     lua_State *L = J->L;
@@ -367,7 +411,7 @@ int lj_opt_loop(jit_State *J)
 	if (--J->instunroll < 0)  /* But do not unroll forever. */
 	  break;
 	L->top--;  /* Remove error object. */
-	loop_undo(J, nins, nsnap);
+	loop_undo(J, nins, nsnap, nsnapmap);
 	return 1;  /* Loop optimization failed, continue recording. */
       default:
 	break;
diff --git a/third_party/luajit/src/lj_opt_mem.c b/third_party/luajit/src/lj_opt_mem.c
index 400646397a1a29aab22276018f874da9cbf6ccda..a90d0979e5fceaba54929c8a7ca3ab9dfa9d68e7 100644
--- a/third_party/luajit/src/lj_opt_mem.c
+++ b/third_party/luajit/src/lj_opt_mem.c
@@ -323,7 +323,7 @@ TRef LJ_FASTCALL lj_opt_dse_ahstore(jit_State *J)
 	    goto doemit;  /* No elimination possible. */
 	/* Remove redundant store from chain and replace with NOP. */
 	*refp = store->prev;
-	store->o = IR_NOP;  /* Unchained NOP -- does anybody care? */
+	store->o = IR_NOP;
 	store->t.irt = IRT_NIL;
 	store->op1 = store->op2 = 0;
 	store->prev = 0;
@@ -418,7 +418,7 @@ TRef LJ_FASTCALL lj_opt_dse_ustore(jit_State *J)
 	    goto doemit;  /* No elimination possible. */
 	/* Remove redundant store from chain and replace with NOP. */
 	*refp = store->prev;
-	store->o = IR_NOP;  /* Unchained NOP -- does anybody care? */
+	store->o = IR_NOP;
 	store->t.irt = IRT_NIL;
 	store->op1 = store->op2 = 0;
 	store->prev = 0;
@@ -511,7 +511,7 @@ TRef LJ_FASTCALL lj_opt_dse_fstore(jit_State *J)
 	    goto doemit;  /* No elimination possible. */
 	/* Remove redundant store from chain and replace with NOP. */
 	*refp = store->prev;
-	store->o = IR_NOP;  /* Unchained NOP -- does anybody care? */
+	store->o = IR_NOP;
 	store->t.irt = IRT_NIL;
 	store->op1 = store->op2 = 0;
 	store->prev = 0;
@@ -761,7 +761,7 @@ TRef LJ_FASTCALL lj_opt_dse_xstore(jit_State *J)
 	    goto doemit;  /* No elimination possible. */
 	/* Remove redundant store from chain and replace with NOP. */
 	*refp = store->prev;
-	store->o = IR_NOP;  /* Unchained NOP -- does anybody care? */
+	store->o = IR_NOP;
 	store->t.irt = IRT_NIL;
 	store->op1 = store->op2 = 0;
 	store->prev = 0;
diff --git a/third_party/luajit/src/lj_opt_narrow.c b/third_party/luajit/src/lj_opt_narrow.c
index 40696c02e42f9f144a155cd7b751fd930747047d..d9d1e2babc2d239ffcdf98beb1cf6da2e022c854 100644
--- a/third_party/luajit/src/lj_opt_narrow.c
+++ b/third_party/luajit/src/lj_opt_narrow.c
@@ -284,7 +284,8 @@ static int narrow_conv_backprop(NarrowConv *nc, IRRef ref, int depth)
       }
     } else {
       int32_t k = lj_num2int(n);
-      if (n == (lua_Number)k) {  /* Only if constant is really an integer. */
+      /* Only if constant is a small integer. */
+      if (checki16(k) && n == (lua_Number)k) {
 	*nc->sp++ = NARROWINS(NARROW_INT, 0);
 	*nc->sp++ = (NarrowIns)k;
 	return 0;
@@ -495,7 +496,7 @@ TRef LJ_FASTCALL lj_opt_narrow_cindex(jit_State *J, TRef tr)
 {
   lua_assert(tref_isnumber(tr));
   if (tref_isnum(tr))
-    return emitir(IRTI(IR_CONV), tr,
+    return emitir(IRT(IR_CONV, IRT_INTP), tr,
 		  (IRT_INTP<<5)|IRT_NUM|IRCONV_TRUNC|IRCONV_ANY);
   /* Undefined overflow semantics allow stripping of ADDOV, SUBOV and MULOV. */
   return narrow_stripov(J, tr, IR_MULOV,
diff --git a/third_party/luajit/src/lj_opt_split.c b/third_party/luajit/src/lj_opt_split.c
index 0a1d87cbae84c4e022a184fa0b7603de7a282f99..913a7a0a1d877e3e395064b66ba2cb449a756e24 100644
--- a/third_party/luajit/src/lj_opt_split.c
+++ b/third_party/luajit/src/lj_opt_split.c
@@ -313,13 +313,21 @@ static void split_ir(jit_State *J)
       case IR_STRTO:
 	hi = split_emit(J, IRT(IR_HIOP, IRT_SOFTFP), nref, nref);
 	break;
-      case IR_XLOAD:
-	hi = split_emit(J, IRT(IR_XLOAD, IRT_SOFTFP),
-			split_ptr(J, oir, ir->op1), ir->op2);
-#if LJ_BE
+      case IR_XLOAD: {
+	IRIns inslo = *nir;  /* Save/undo the emit of the lo XLOAD. */
+	J->cur.nins--;
+	hi = split_ptr(J, oir, ir->op1);  /* Insert the hiref ADD. */
+	nref = lj_ir_nextins(J);
+	nir = IR(nref);
+	*nir = inslo;  /* Re-emit lo XLOAD immediately before hi XLOAD. */
+	hi = split_emit(J, IRT(IR_XLOAD, IRT_SOFTFP), hi, ir->op2);
+#if LJ_LE
+	ir->prev = nref;
+#else
 	ir->prev = hi; hi = nref;
 #endif
 	break;
+	}
       case IR_ASTORE: case IR_HSTORE: case IR_USTORE:
 	split_emit(J, IRT(IR_HIOP, IRT_SOFTFP), nir->op1, hisubst[ir->op2]);
 	break;
@@ -335,10 +343,11 @@ static void split_ir(jit_State *J)
 	}
       case IR_CONV: {  /* Conversion to number. Others handled below. */
 	IRType st = (IRType)(ir->op2 & IRCONV_SRCMASK);
+	UNUSED(st);
 #if LJ_32 && LJ_HASFFI
 	if (st == IRT_I64 || st == IRT_U64) {
 	  hi = split_call_l(J, hisubst, oir, ir,
-		 st == IRT_I64 ? IRCALL_softfp_l2d : IRCALL_softfp_ul2d);
+		 st == IRT_I64 ? IRCALL_fp64_l2d : IRCALL_fp64_ul2d);
 	  break;
 	}
 #endif
@@ -411,7 +420,7 @@ static void split_ir(jit_State *J)
 	break;
       case IR_FLOAD:
 	lua_assert(ir->op2 == IRFL_CDATA_INT64);
-	hi = split_emit(J, IRTI(IR_FLOAD), nir->op1, IRFL_CDATA_INT64HI);
+	hi = split_emit(J, IRTI(IR_FLOAD), nir->op1, IRFL_CDATA_INT64_4);
 #if LJ_BE
 	ir->prev = hi; hi = nref;
 #endif
@@ -435,10 +444,10 @@ static void split_ir(jit_State *J)
 #if LJ_SOFTFP
 	if (st == IRT_NUM) {  /* NUM to 64 bit int conv. */
 	  hi = split_call_l(J, hisubst, oir, ir,
-		 irt_isi64(ir->t) ? IRCALL_softfp_d2l : IRCALL_softfp_d2ul);
+		 irt_isi64(ir->t) ? IRCALL_fp64_d2l : IRCALL_fp64_d2ul);
 	} else if (st == IRT_FLOAT) {  /* FLOAT to 64 bit int conv. */
 	  nir->o = IR_CALLN;
-	  nir->op2 = irt_isi64(ir->t) ? IRCALL_softfp_f2l : IRCALL_softfp_f2ul;
+	  nir->op2 = irt_isi64(ir->t) ? IRCALL_fp64_f2l : IRCALL_fp64_f2ul;
 	  hi = split_emit(J, IRTI(IR_HIOP), nref, nref);
 	}
 #else
@@ -518,7 +527,7 @@ static void split_ir(jit_State *J)
 #if LJ_SOFTFP
 	if (irt_isfloat(ir->t)) {
 	  split_call_l(J, hisubst, oir, ir,
-		       st == IRT_I64 ? IRCALL_softfp_l2f : IRCALL_softfp_ul2f);
+		       st == IRT_I64 ? IRCALL_fp64_l2f : IRCALL_fp64_ul2f);
 	  J->cur.nins--;  /* Drop unused HIOP. */
 	}
 #else
@@ -672,18 +681,19 @@ static int split_needsplit(jit_State *J)
   IRIns *ir, *irend;
   IRRef ref;
   for (ir = IR(REF_FIRST), irend = IR(J->cur.nins); ir < irend; ir++)
-    if (LJ_SOFTFP ? irt_is64(ir->t) : irt_isint64(ir->t))
+    if (LJ_SOFTFP ? irt_is64orfp(ir->t) : irt_isint64(ir->t))
       return 1;
   if (LJ_SOFTFP) {
     for (ref = J->chain[IR_SLOAD]; ref; ref = IR(ref)->prev)
       if ((IR(ref)->op2 & IRSLOAD_CONVERT))
 	return 1;
   }
-  for (ref = J->chain[IR_CONV]; ref; ref = IR(ref)->prev)
-    if ((LJ_SOFTFP && (IR(ref)->op2 & IRCONV_SRCMASK) == IRT_NUM) ||
-	(IR(ref)->op2 & IRCONV_SRCMASK) == IRT_I64 ||
-	(IR(ref)->op2 & IRCONV_SRCMASK) == IRT_U64)
+  for (ref = J->chain[IR_CONV]; ref; ref = IR(ref)->prev) {
+    IRType st = (IR(ref)->op2 & IRCONV_SRCMASK);
+    if ((LJ_SOFTFP && (st == IRT_NUM || st == IRT_FLOAT)) ||
+	st == IRT_I64 || st == IRT_U64)
       return 1;
+  }
   return 0;  /* Nope. */
 }
 #endif
diff --git a/third_party/luajit/src/lj_parse.c b/third_party/luajit/src/lj_parse.c
index f0bb44199b5fbcfafb4987fbae702f484a9ca8ba..4b8a8e6ff20a2a5d7ed95190d8ae83bd9b6ef904 100644
--- a/third_party/luajit/src/lj_parse.c
+++ b/third_party/luajit/src/lj_parse.c
@@ -1392,7 +1392,7 @@ static GCproto *fs_finish(LexState *ls, BCLine line)
   pt->gct = ~LJ_TPROTO;
   pt->sizept = (MSize)sizept;
   pt->trace = 0;
-  pt->flags = fs->flags;
+  pt->flags = (uint8_t)(fs->flags & ~(PROTO_HAS_RETURN|PROTO_FIXUP_RETURN));
   pt->numparams = fs->numparams;
   pt->framesize = fs->framesize;
   setgcref(pt->chunkname, obj2gco(ls->chunkname));
diff --git a/third_party/luajit/src/lj_record.c b/third_party/luajit/src/lj_record.c
index 63d5e4c1ea881d65c1531b112fec6c75ad7d19c4..2c27a718fcbb398c4fc34ef8390e5075ad5f7011 100644
--- a/third_party/luajit/src/lj_record.c
+++ b/third_party/luajit/src/lj_record.c
@@ -67,7 +67,7 @@ static void rec_check_ir(jit_State *J)
     if (ir->prev) {
       lua_assert(ir->prev >= nk);
       lua_assert(i >= REF_BIAS ? ir->prev < i : ir->prev > i);
-      lua_assert(IR(ir->prev)->o == ir->o);
+      lua_assert(ir->o == IR_NOP || IR(ir->prev)->o == ir->o);
     }
   }
 }
@@ -212,9 +212,10 @@ static void canonicalize_slots(jit_State *J)
 }
 
 /* Stop recording. */
-static void rec_stop(jit_State *J, TraceNo lnk)
+static void rec_stop(jit_State *J, TraceLink linktype, TraceNo lnk)
 {
   lj_trace_end(J);
+  J->cur.linktype = (uint8_t)linktype;
   J->cur.link = (uint16_t)lnk;
   /* Looping back at the same stack level? */
   if (lnk == J->cur.traceno && J->framedepth + J->retdepth == 0) {
@@ -434,6 +435,7 @@ static LoopEvent rec_for(jit_State *J, const BCIns *fori, int isforl)
     t = (LJ_DUALNUM || tref_isint(tr[FORL_IDX])) ? lj_opt_narrow_forl(J, tv) :
 						   IRT_NUM;
     for (i = FORL_IDX; i <= FORL_STEP; i++) {
+      if (!tr[i]) sload(J, ra+i);
       lua_assert(tref_isnumber_str(tr[i]));
       if (tref_isstr(tr[i]))
 	tr[i] = emitir(IRTG(IR_STRTO, IRT_NUM), tr[i], 0);
@@ -522,7 +524,7 @@ static void rec_loop_interp(jit_State *J, const BCIns *pc, LoopEvent ev)
       /* Same loop? */
       if (ev == LOOPEV_LEAVE)  /* Must loop back to form a root trace. */
 	lj_trace_err(J, LJ_TRERR_LLEAVE);
-      rec_stop(J, J->cur.traceno);  /* Root trace forms a loop. */
+      rec_stop(J, LJ_TRLINK_LOOP, J->cur.traceno);  /* Looping root trace. */
     } else if (ev != LOOPEV_LEAVE) {  /* Entering inner loop? */
       /* It's usually better to abort here and wait until the inner loop
       ** is traced. But if the inner loop repeatedly didn't loop back,
@@ -553,19 +555,40 @@ static void rec_loop_jit(jit_State *J, TraceNo lnk, LoopEvent ev)
   } else if (ev != LOOPEV_LEAVE) {  /* Side trace enters a compiled loop. */
     J->instunroll = 0;  /* Cannot continue across a compiled loop op. */
     if (J->pc == J->startpc && J->framedepth + J->retdepth == 0)
-      lnk = J->cur.traceno;  /* Can form an extra loop. */
-    rec_stop(J, lnk);  /* Link to the loop. */
+      rec_stop(J, LJ_TRLINK_LOOP, J->cur.traceno);  /* Form an extra loop. */
+    else
+      rec_stop(J, LJ_TRLINK_ROOT, lnk);  /* Link to the loop. */
   }  /* Side trace continues across a loop that's left or not entered. */
 }
 
 /* -- Record calls and returns -------------------------------------------- */
 
+/* Specialize to the runtime value of the called function or its prototype. */
+static TRef rec_call_specialize(jit_State *J, GCfunc *fn, TRef tr)
+{
+  TRef kfunc;
+  if (isluafunc(fn)) {
+    GCproto *pt = funcproto(fn);
+    /* 3 or more closures created? Probably not a monomorphic function. */
+    if (pt->flags >= 3*PROTO_CLCOUNT) {  /* Specialize to prototype instead. */
+      TRef trpt = emitir(IRT(IR_FLOAD, IRT_P32), tr, IRFL_FUNC_PC);
+      emitir(IRTG(IR_EQ, IRT_P32), trpt, lj_ir_kptr(J, proto_bc(pt)));
+      (void)lj_ir_kgc(J, obj2gco(pt), IRT_PROTO);  /* Prevent GC of proto. */
+      return tr;
+    }
+  }
+  /* Otherwise specialize to the function (closure) value itself. */
+  kfunc = lj_ir_kfunc(J, fn);
+  emitir(IRTG(IR_EQ, IRT_FUNC), tr, kfunc);
+  return kfunc;
+}
+
 /* Record call setup. */
 static void rec_call_setup(jit_State *J, BCReg func, ptrdiff_t nargs)
 {
   RecordIndex ix;
   TValue *functv = &J->L->base[func];
-  TRef trfunc, *fbase = &J->base[func];
+  TRef *fbase = &J->base[func];
   ptrdiff_t i;
   for (i = 0; i <= nargs; i++)
     (void)getslot(J, func+i);  /* Ensure func and all args have a reference. */
@@ -579,11 +602,7 @@ static void rec_call_setup(jit_State *J, BCReg func, ptrdiff_t nargs)
     fbase[0] = ix.mobj;  /* Replace function. */
     functv = &ix.mobjv;
   }
-
-  /* Specialize to the runtime value of the called function. */
-  trfunc = lj_ir_kfunc(J, funcV(functv));
-  emitir(IRTG(IR_EQ, IRT_FUNC), fbase[0], trfunc);
-  fbase[0] = trfunc | TREF_FRAME;
+  fbase[0] = TREF_FRAME | rec_call_specialize(J, funcV(functv), fbase[0]);
   J->maxslot = (BCReg)nargs;
 }
 
@@ -659,6 +678,17 @@ void lj_record_ret(jit_State *J, BCReg rbase, ptrdiff_t gotresults)
     J->base[--rbase] = TREF_TRUE;  /* Prepend true to results. */
     frame = frame_prevd(frame);
   }
+  /* Return to lower frame via interpreter for unhandled cases. */
+  if (J->framedepth == 0 && J->pt && bc_isret(bc_op(*J->pc)) &&
+       (!frame_islua(frame) ||
+	(J->parent == 0 && !bc_isret(bc_op(J->cur.startins))))) {
+    /* NYI: specialize to frame type and return directly, not via RET*. */
+    for (i = -1; i < (ptrdiff_t)rbase; i++)
+      J->base[i] = 0;  /* Purge dead slots. */
+    J->maxslot = rbase + (BCReg)gotresults;
+    rec_stop(J, LJ_TRLINK_RETURN, 0);  /* Return to interpreter. */
+    return;
+  }
   if (frame_isvarg(frame)) {
     BCReg cbase = (BCReg)frame_delta(frame);
     if (--J->framedepth < 0)  /* NYI: return of vararg func to lower frame. */
@@ -678,7 +708,7 @@ void lj_record_ret(jit_State *J, BCReg rbase, ptrdiff_t gotresults)
       if (check_downrec_unroll(J, pt)) {
 	J->maxslot = (BCReg)(rbase + gotresults);
 	lj_snap_purge(J);
-	rec_stop(J, J->cur.traceno);  /* Down-recursion. */
+	rec_stop(J, LJ_TRLINK_DOWNREC, J->cur.traceno);  /* Down-recursion. */
 	return;
       }
       lj_snap_add(J);
@@ -1281,22 +1311,35 @@ static TRef rec_upvalue(jit_State *J, uint32_t uv, TRef val)
 /* -- Record calls to Lua functions --------------------------------------- */
 
 /* Check unroll limits for calls. */
-static void check_call_unroll(jit_State *J)
+static void check_call_unroll(jit_State *J, TraceNo lnk)
 {
-  IRRef fref = tref_ref(J->base[-1]);
+  cTValue *frame = J->L->base - 1;
+  void *pc = mref(frame_func(frame)->l.pc, void);
+  int32_t depth = J->framedepth;
   int32_t count = 0;
-  BCReg s;
-  for (s = J->baseslot - 1; s > 0; s--)
-    if ((J->slot[s] & TREF_FRAME) && tref_ref(J->slot[s]) == fref)
+  if ((J->pt->flags & PROTO_VARARG)) depth--;  /* Vararg frame still missing. */
+  for (; depth > 0; depth--) {  /* Count frames with same prototype. */
+    frame = frame_prev(frame);
+    if (mref(frame_func(frame)->l.pc, void) == pc)
       count++;
+  }
   if (J->pc == J->startpc) {
     if (count + J->tailcalled > J->param[JIT_P_recunroll]) {
       J->pc++;
-      rec_stop(J, J->cur.traceno);  /* Up-recursion or tail-recursion. */
+      if (J->framedepth + J->retdepth == 0)
+	rec_stop(J, LJ_TRLINK_TAILREC, J->cur.traceno);  /* Tail-recursion. */
+      else
+	rec_stop(J, LJ_TRLINK_UPREC, J->cur.traceno);  /* Up-recursion. */
     }
   } else {
-    if (count > J->param[JIT_P_callunroll])
+    if (count > J->param[JIT_P_callunroll]) {
+      if (lnk) {  /* Possible tail- or up-recursion. */
+	lj_trace_flush(J, lnk);  /* Flush trace that only returns. */
+	/* Set a small, pseudo-random hotcount for a quick retry of JFUNC*. */
+	hotcount_set(J2GG(J), J->pc+1, LJ_PRNG_BITS(J, 4));
+      }
       lj_trace_err(J, LJ_TRERR_CUNROLL);
+    }
   }
 }
 
@@ -1341,17 +1384,28 @@ static void rec_func_vararg(jit_State *J)
 static void rec_func_lua(jit_State *J)
 {
   rec_func_setup(J);
-  check_call_unroll(J);
+  check_call_unroll(J, 0);
 }
 
 /* Record entry to an already compiled function. */
 static void rec_func_jit(jit_State *J, TraceNo lnk)
 {
+  GCtrace *T;
   rec_func_setup(J);
+  T = traceref(J, lnk);
+  if (T->linktype == LJ_TRLINK_RETURN) {  /* Trace returns to interpreter? */
+    check_call_unroll(J, lnk);
+    /* Temporarily unpatch JFUNC* to continue recording across function. */
+    J->patchins = *J->pc;
+    J->patchpc = (BCIns *)J->pc;
+    *J->patchpc = T->startins;
+    return;
+  }
   J->instunroll = 0;  /* Cannot continue across a compiled function. */
   if (J->pc == J->startpc && J->framedepth + J->retdepth == 0)
-    lnk = J->cur.traceno;  /* Can form an extra tail-recursive loop. */
-  rec_stop(J, lnk);  /* Link to the function. */
+    rec_stop(J, LJ_TRLINK_TAILREC, J->cur.traceno);  /* Extra tail-recursion. */
+  else
+    rec_stop(J, LJ_TRLINK_ROOT, lnk);  /* Link to the function. */
 }
 
 /* -- Vararg handling ----------------------------------------------------- */
@@ -1519,8 +1573,14 @@ void lj_record_ins(jit_State *J)
       rec_comp_fixup(J, pc, (!tvistruecond(&J2G(J)->tmptv2) ^ (bc_op(*pc)&1)));
       /* fallthrough */
     case LJ_POST_FIXGUARD:  /* Fixup and emit pending guard. */
-      if (!tvistruecond(&J2G(J)->tmptv2))
+    case LJ_POST_FIXGUARDSNAP:  /* Fixup and emit pending guard and snapshot. */
+      if (!tvistruecond(&J2G(J)->tmptv2)) {
 	J->fold.ins.o ^= 1;  /* Flip guard to opposite. */
+	if (J->postproc == LJ_POST_FIXGUARDSNAP) {
+	  SnapShot *snap = &J->cur.snap[J->cur.nsnap-1];
+	  J->cur.snapmap[snap->mapofs+snap->nent-1]--;  /* False -> true. */
+	}
+      }
       lj_opt_fold(J);  /* Emit pending guard. */
       /* fallthrough */
     case LJ_POST_FIXBOOL:
@@ -1863,7 +1923,7 @@ void lj_record_ins(jit_State *J)
   case BC_JFORI:
     lua_assert(bc_op(pc[(ptrdiff_t)rc-BCBIAS_J]) == BC_JFORL);
     if (rec_for(J, pc, 0) != LOOPEV_LEAVE)  /* Link to existing loop. */
-      rec_stop(J, bc_d(pc[(ptrdiff_t)rc-BCBIAS_J]));
+      rec_stop(J, LJ_TRLINK_ROOT, bc_d(pc[(ptrdiff_t)rc-BCBIAS_J]));
     /* Continue tracing if the loop is not entered. */
     break;
 
@@ -2013,6 +2073,7 @@ static void rec_setup_side(jit_State *J, GCtrace *T)
   SnapEntry *map = &T->snapmap[snap->mapofs];
   MSize n, nent = snap->nent;
   BloomFilter seen = 0;
+  J->framedepth = 0;
   /* Emit IR for slots inherited from parent snapshot. */
   for (n = 0; n < nent; n++) {
     SnapEntry sn = map[n];
@@ -2053,12 +2114,12 @@ static void rec_setup_side(jit_State *J, GCtrace *T)
     }
   setslot:
     J->slot[s] = tr | (sn&(SNAP_CONT|SNAP_FRAME));  /* Same as TREF_* flags. */
+    J->framedepth += ((sn & (SNAP_CONT|SNAP_FRAME)) && s);
     if ((sn & SNAP_FRAME))
       J->baseslot = s+1;
   }
   J->base = J->slot + J->baseslot;
   J->maxslot = snap->nslots - J->baseslot;
-  J->framedepth = snap->depth;
   lj_snap_add(J);
 }
 
@@ -2121,8 +2182,9 @@ void lj_record_setup(jit_State *J)
   sidecheck:
     if (traceref(J, J->cur.root)->nchild >= J->param[JIT_P_maxside] ||
 	T->snap[J->exitno].count >= J->param[JIT_P_hotexit] +
-				    J->param[JIT_P_tryside])
-      rec_stop(J, TRACE_INTERP);
+				    J->param[JIT_P_tryside]) {
+      rec_stop(J, LJ_TRLINK_INTERP, 0);
+    }
   } else {  /* Root trace. */
     J->cur.root = 0;
     J->cur.startins = *J->pc;
diff --git a/third_party/luajit/src/lj_snap.c b/third_party/luajit/src/lj_snap.c
index 9124b7896bbc4076665f09b7bc4509e5be72a47c..10fd6af728d895bb8fe1c6cde55667227073a40a 100644
--- a/third_party/luajit/src/lj_snap.c
+++ b/third_party/luajit/src/lj_snap.c
@@ -63,7 +63,8 @@ static MSize snapshot_slots(jit_State *J, SnapEntry *map, BCReg nslots)
     if (ref) {
       SnapEntry sn = SNAP_TR(s, tr);
       IRIns *ir = IR(ref);
-      if (ir->o == IR_SLOAD && ir->op1 == s && ref > retf) {
+      if (!(sn & (SNAP_CONT|SNAP_FRAME)) &&
+	  ir->o == IR_SLOAD && ir->op1 == s && ref > retf) {
 	/* No need to snapshot unmodified non-inherited slots. */
 	if (!(ir->op2 & IRSLOAD_INHERIT))
 	  continue;
@@ -81,16 +82,19 @@ static MSize snapshot_slots(jit_State *J, SnapEntry *map, BCReg nslots)
 }
 
 /* Add frame links at the end of the snapshot. */
-static void snapshot_framelinks(jit_State *J, SnapEntry *map)
+static BCReg snapshot_framelinks(jit_State *J, SnapEntry *map)
 {
   cTValue *frame = J->L->base - 1;
   cTValue *lim = J->L->base - J->baseslot;
+  cTValue *ftop = frame + funcproto(frame_func(frame))->framesize;
   MSize f = 0;
   map[f++] = SNAP_MKPC(J->pc);  /* The current PC is always the first entry. */
   while (frame > lim) {  /* Backwards traversal of all frames above base. */
     if (frame_islua(frame)) {
       map[f++] = SNAP_MKPC(frame_pc(frame));
       frame = frame_prevl(frame);
+      if (frame + funcproto(frame_func(frame))->framesize > ftop)
+	ftop = frame + funcproto(frame_func(frame))->framesize;
     } else if (frame_iscont(frame)) {
       map[f++] = SNAP_MKFTSZ(frame_ftsz(frame));
       map[f++] = SNAP_MKPC(frame_contpc(frame));
@@ -102,6 +106,7 @@ static void snapshot_framelinks(jit_State *J, SnapEntry *map)
     }
   }
   lua_assert(f == (MSize)(1 + J->framedepth));
+  return (BCReg)(ftop - lim);
 }
 
 /* Take a snapshot of the current stack. */
@@ -114,11 +119,10 @@ static void snapshot_stack(jit_State *J, SnapShot *snap, MSize nsnapmap)
   lj_snap_grow_map(J, nsnapmap + nslots + (MSize)J->framedepth+1);
   p = &J->cur.snapmap[nsnapmap];
   nent = snapshot_slots(J, p, nslots);
-  snapshot_framelinks(J, p + nent);
+  snap->topslot = (uint8_t)snapshot_framelinks(J, p + nent);
   snap->mapofs = (uint16_t)nsnapmap;
   snap->ref = (IRRef1)J->cur.nins;
   snap->nent = (uint8_t)nent;
-  snap->depth = (uint8_t)J->framedepth;
   snap->nslots = (uint8_t)nslots;
   snap->count = 0;
   J->cur.nsnapmap = (uint16_t)(nsnapmap + nent + 1 + J->framedepth);
@@ -192,7 +196,7 @@ static BCReg snap_usedef(jit_State *J, uint8_t *udf,
     handle_jump: {
       BCReg minslot = bc_a(ins);
       if (op >= BC_FORI && op <= BC_JFORL) minslot += FORL_EXT;
-      else if (op >= BC_ITERL && op <= BC_JITERL) minslot += bc_b(pc[-1])-1;
+      else if (op >= BC_ITERL && op <= BC_JITERL) minslot += bc_b(pc[-2])-1;
       else if (op == BC_UCLO) { pc += bc_j(ins); break; }
       for (s = minslot; s < maxslot; s++) DEF_SLOT(s);
       return minslot < maxslot ? minslot : maxslot;
@@ -274,7 +278,7 @@ void lj_snap_shrink(jit_State *J)
       map[m++] = map[n];  /* Only copy used slots. */
   }
   snap->nent = (uint8_t)m;
-  nlim = nent + snap->depth;
+  nlim = J->cur.nsnapmap - snap->mapofs - 1;
   while (n <= nlim) map[m++] = map[n++];  /* Move PC + frame links down. */
   J->cur.nsnapmap = (uint16_t)(snap->mapofs + m);  /* Free up space in map. */
 }
@@ -337,9 +341,8 @@ const BCIns *lj_snap_restore(jit_State *J, void *exptr)
   SnapShot *snap = &T->snap[snapno];
   MSize n, nent = snap->nent;
   SnapEntry *map = &T->snapmap[snap->mapofs];
-  SnapEntry *flinks = map + nent + snap->depth;
+  SnapEntry *flinks = &T->snapmap[snap_nextofs(T, snap)-1];
   int32_t ftsz0;
-  BCReg nslots = snap->nslots;
   TValue *frame;
   BloomFilter rfilt = snap_renamefilter(T, snapno);
   const BCIns *pc = snap_pc(map[nent]);
@@ -349,9 +352,9 @@ const BCIns *lj_snap_restore(jit_State *J, void *exptr)
   setcframe_pc(cframe_raw(L->cframe), pc+1);
 
   /* Make sure the stack is big enough for the slots from the snapshot. */
-  if (LJ_UNLIKELY(L->base + nslots > tvref(L->maxstack))) {
+  if (LJ_UNLIKELY(L->base + snap->topslot >= tvref(L->maxstack))) {
     L->top = curr_topL(L);
-    lj_state_growstack(L, nslots - curr_proto(L)->framesize);
+    lj_state_growstack(L, snap->topslot - curr_proto(L)->framesize);
   }
 
   /* Fill stack slots with data from the registers and spill slots. */
@@ -365,27 +368,9 @@ const BCIns *lj_snap_restore(jit_State *J, void *exptr)
     IRIns *ir = &T->ir[ref];
     if (irref_isk(ref)) {  /* Restore constant slot. */
       lj_ir_kvalue(L, o, ir);
-      if ((sn & (SNAP_CONT|SNAP_FRAME))) {
-	/* Overwrite tag with frame link. */
-	o->fr.tp.ftsz = s != 0 ? (int32_t)*flinks-- : ftsz0;
-	if ((sn & SNAP_FRAME)) {
-	  GCfunc *fn = ir_kfunc(ir);
-	  if (isluafunc(fn)) {
-	    MSize framesize = funcproto(fn)->framesize;
-	    L->base = ++o;
-	    if (LJ_UNLIKELY(o + framesize > tvref(L->maxstack))) {
-	      ptrdiff_t fsave = savestack(L, frame);
-	      L->top = o;
-	      lj_state_growstack(L, framesize);  /* Grow again. */
-	      frame = restorestack(L, fsave);
-	    }
-	  }
-	}
-      }
     } else if (!(sn & SNAP_NORESTORE)) {
       IRType1 t = ir->t;
       RegSP rs = ir->prev;
-      lua_assert(!(sn & (SNAP_CONT|SNAP_FRAME)));
       if (LJ_UNLIKELY(bloomtest(rfilt, ref)))
 	rs = snap_renameref(T, snapno, ref, rs);
       if (ra_hasspill(regsp_spill(rs))) {  /* Restore from spill slot. */
@@ -439,10 +424,14 @@ const BCIns *lj_snap_restore(jit_State *J, void *exptr)
 	    (uint32_t)ex->gpr[regsp_reg(rs)-RID_MIN_GPR];
       }
     }
+    if ((sn & (SNAP_CONT|SNAP_FRAME))) {  /* Overwrite tag with frame link. */
+      o->fr.tp.ftsz = s != 0 ? (int32_t)*flinks-- : ftsz0;
+      L->base = o+1;
+    }
   }
   switch (bc_op(*pc)) {
   case BC_CALLM: case BC_CALLMT: case BC_RETM: case BC_TSETM:
-    L->top = frame + nslots;
+    L->top = frame + snap->nslots;
     break;
   default:
     L->top = curr_topL(L);
diff --git a/third_party/luajit/src/lj_state.h b/third_party/luajit/src/lj_state.h
index d8d6104e42fac99d83b015a2e4af32d501133e2e..75b8dc851c75ab0192a57f30b33b04fd5a52b773 100644
--- a/third_party/luajit/src/lj_state.h
+++ b/third_party/luajit/src/lj_state.h
@@ -21,8 +21,8 @@ LJ_FUNC void LJ_FASTCALL lj_state_growstack1(lua_State *L);
 
 static LJ_AINLINE void lj_state_checkstack(lua_State *L, MSize need)
 {
-  if ((MSize)(mref(L->maxstack, char) - (char *)L->top) <=
-      need*(MSize)sizeof(TValue))
+  if ((mref(L->maxstack, char) - (char *)L->top) <=
+      (ptrdiff_t)need*(ptrdiff_t)sizeof(TValue))
     lj_state_growstack(L, need);
 }
 
diff --git a/third_party/luajit/src/lj_target.h b/third_party/luajit/src/lj_target.h
index 410ad0a0fc27a082e01e9a48af444d4bb1b4fce9..c302d30199915d3c22f3391a44bad48e66547996 100644
--- a/third_party/luajit/src/lj_target.h
+++ b/third_party/luajit/src/lj_target.h
@@ -50,21 +50,30 @@ typedef uint32_t RegSP;
 
 /* -- Register sets ------------------------------------------------------- */
 
-/* Bitset for registers. 32 registers suffice right now.
+/* Bitset for registers. 32 registers suffice for most architectures.
 ** Note that one set holds bits for both GPRs and FPRs.
 */
+#if LJ_TARGET_PPC
+typedef uint64_t RegSet;
+#else
 typedef uint32_t RegSet;
+#endif
 
 #define RID2RSET(r)		(((RegSet)1) << (r))
-#define RSET_EMPTY		0
+#define RSET_EMPTY		((RegSet)0)
 #define RSET_RANGE(lo, hi)	((RID2RSET((hi)-(lo))-1) << (lo))
 
 #define rset_test(rs, r)	(((rs) >> (r)) & 1)
 #define rset_set(rs, r)		(rs |= RID2RSET(r))
 #define rset_clear(rs, r)	(rs &= ~RID2RSET(r))
 #define rset_exclude(rs, r)	(rs & ~RID2RSET(r))
+#if LJ_TARGET_PPC
+#define rset_picktop(rs)	((Reg)(__builtin_clzll(rs)^63))
+#define rset_pickbot(rs)	((Reg)__builtin_ctzll(rs))
+#else
 #define rset_picktop(rs)	((Reg)lj_fls(rs))
 #define rset_pickbot(rs)	((Reg)lj_ffs(rs))
+#endif
 
 /* -- Register allocation cost -------------------------------------------- */
 
@@ -127,16 +136,23 @@ typedef uint32_t RegCost;
 #include "lj_target_x86.h"
 #elif LJ_TARGET_ARM
 #include "lj_target_arm.h"
+#elif LJ_TARGET_PPC
+#include "lj_target_ppc.h"
 #else
 #error "Missing include for target CPU"
 #endif
 
+#ifdef EXITSTUBS_PER_GROUP
 /* Return the address of an exit stub. */
-static LJ_AINLINE MCode *exitstub_addr(jit_State *J, ExitNo exitno)
+static LJ_AINLINE char *exitstub_addr_(char **group, uint32_t exitno)
 {
-  lua_assert(J->exitstubgroup[exitno / EXITSTUBS_PER_GROUP] != NULL);
-  return (MCode *)((char *)J->exitstubgroup[exitno / EXITSTUBS_PER_GROUP] +
-		   EXITSTUB_SPACING*(exitno % EXITSTUBS_PER_GROUP));
+  lua_assert(group[exitno / EXITSTUBS_PER_GROUP] != NULL);
+  return (char *)group[exitno / EXITSTUBS_PER_GROUP] +
+	 EXITSTUB_SPACING*(exitno % EXITSTUBS_PER_GROUP);
 }
+/* Avoid dependence on lj_jit.h if only including lj_target.h. */
+#define exitstub_addr(J, exitno) \
+  ((MCode *)exitstub_addr_((char **)((J)->exitstubgroup), (exitno)))
+#endif
 
 #endif
diff --git a/third_party/luajit/src/lj_target_arm.h b/third_party/luajit/src/lj_target_arm.h
index 78a5679d61fec6d705036b3e83879406e8b8e5cd..b4b26d4d2f718e1e39db7bbf8d76cc9061d363c6 100644
--- a/third_party/luajit/src/lj_target_arm.h
+++ b/third_party/luajit/src/lj_target_arm.h
@@ -28,6 +28,7 @@ enum {
 
   /* Calling conventions. */
   RID_RET = RID_R0,
+  RID_RETLO = RID_R0,
   RID_RETHI = RID_R1,
   RID_FPRET = RID_R0,
 
@@ -116,6 +117,8 @@ typedef struct {
 
 /* PC after instruction that caused an exit. Used to find the trace number. */
 #define EXITSTATE_PCREG		RID_PC
+/* Highest exit + 1 indicates stack check. */
+#define EXITSTATE_CHECKEXIT	1
 
 #define EXITSTUB_SPACING        4
 #define EXITSTUBS_PER_GROUP     32
@@ -136,6 +139,7 @@ typedef enum ARMIns {
   ARMI_S = 0x000100000,
   ARMI_K12 = 0x02000000,
   ARMI_KNEG = 0x00200000,
+  ARMI_LS_W = 0x00200000,
   ARMI_LS_U = 0x00800000,
   ARMI_LS_P = 0x01000000,
   ARMI_LS_R = 0x02000000,
@@ -173,6 +177,7 @@ typedef enum ARMIns {
   ARMI_STRB = 0xe4400000,
   ARMI_STRH = 0xe00000b0,
   ARMI_STRD = 0xe00000f0,
+  ARMI_PUSH = 0xe92d0000,
 
   ARMI_B = 0xea000000,
   ARMI_BL = 0xeb000000,
diff --git a/third_party/luajit/src/lj_target_ppc.h b/third_party/luajit/src/lj_target_ppc.h
new file mode 100644
index 0000000000000000000000000000000000000000..d8fbea6ddfa790efe8828ebc0c704e5e77b5895b
--- /dev/null
+++ b/third_party/luajit/src/lj_target_ppc.h
@@ -0,0 +1,279 @@
+/*
+** Definitions for PPC CPUs.
+** Copyright (C) 2005-2011 Mike Pall. See Copyright Notice in luajit.h
+*/
+
+#ifndef _LJ_TARGET_PPC_H
+#define _LJ_TARGET_PPC_H
+
+/* -- Registers IDs ------------------------------------------------------- */
+
+#define GPRDEF(_) \
+  _(R0) _(SP) _(SYS1) _(R3) _(R4) _(R5) _(R6) _(R7) \
+  _(R8) _(R9) _(R10) _(R11) _(R12) _(SYS2) _(R14) _(R15) \
+  _(R16) _(R17) _(R18) _(R19) _(R20) _(R21) _(R22) _(R23) \
+  _(R24) _(R25) _(R26) _(R27) _(R28) _(R29) _(R30) _(R31)
+#define FPRDEF(_) \
+  _(F0) _(F1) _(F2) _(F3) _(F4) _(F5) _(F6) _(F7) \
+  _(F8) _(F9) _(F10) _(F11) _(F12) _(F13) _(F14) _(F15) \
+  _(F16) _(F17) _(F18) _(F19) _(F20) _(F21) _(F22) _(F23) \
+  _(F24) _(F25) _(F26) _(F27) _(F28) _(F29) _(F30) _(F31)
+#define VRIDDEF(_)
+
+#define RIDENUM(name)	RID_##name,
+
+enum {
+  GPRDEF(RIDENUM)		/* General-purpose registers (GPRs). */
+  FPRDEF(RIDENUM)		/* Floating-point registers (FPRs). */
+  RID_MAX,
+  RID_TMP = RID_R0,
+
+  /* Calling conventions. */
+  RID_RET = RID_R3,
+  RID_RETHI = RID_R3,
+  RID_RETLO = RID_R4,
+  RID_FPRET = RID_F1,
+
+  /* These definitions must match with the *.dasc file(s): */
+  RID_BASE = RID_R14,		/* Interpreter BASE. */
+  RID_LPC = RID_R16,		/* Interpreter PC. */
+  RID_DISPATCH = RID_R17,	/* Interpreter DISPATCH table. */
+  RID_LREG = RID_R18,		/* Interpreter L. */
+  RID_JGL = RID_R31,		/* On-trace: global_State + 32768. */
+
+  /* Register ranges [min, max) and number of registers. */
+  RID_MIN_GPR = RID_R0,
+  RID_MAX_GPR = RID_R31+1,
+  RID_MIN_FPR = RID_F0,
+  RID_MAX_FPR = RID_F31+1,
+  RID_NUM_GPR = RID_MAX_GPR - RID_MIN_GPR,
+  RID_NUM_FPR = RID_MAX_FPR - RID_MIN_FPR
+};
+
+#define RID_NUM_KREF		RID_NUM_GPR
+#define RID_MIN_KREF		RID_R0
+
+/* -- Register sets ------------------------------------------------------- */
+
+/* Make use of all registers, except TMP, SP, SYS1, SYS2 and JGL. */
+#define RSET_FIXED \
+  (RID2RSET(RID_TMP)|RID2RSET(RID_SP)|RID2RSET(RID_SYS1)|\
+   RID2RSET(RID_SYS2)|RID2RSET(RID_JGL))
+#define RSET_GPR	(RSET_RANGE(RID_MIN_GPR, RID_MAX_GPR) - RSET_FIXED)
+#define RSET_FPR	RSET_RANGE(RID_MIN_FPR, RID_MAX_FPR)
+#define RSET_ALL	(RSET_GPR|RSET_FPR)
+#define RSET_INIT	RSET_ALL
+
+#define RSET_SCRATCH_GPR	(RSET_RANGE(RID_R3, RID_R12+1))
+#define RSET_SCRATCH_FPR	(RSET_RANGE(RID_F0, RID_F13+1))
+#define RSET_SCRATCH		(RSET_SCRATCH_GPR|RSET_SCRATCH_FPR)
+#define REGARG_FIRSTGPR		RID_R3
+#define REGARG_LASTGPR		RID_R10
+#define REGARG_NUMGPR		8
+#define REGARG_FIRSTFPR		RID_F1
+#define REGARG_LASTFPR		RID_F8
+#define REGARG_NUMFPR		8
+
+/* -- Spill slots --------------------------------------------------------- */
+
+/* Spill slots are 32 bit wide. An even/odd pair is used for FPRs.
+**
+** SPS_FIXED: Available fixed spill slots in interpreter frame.
+** This definition must match with the *.dasc file(s).
+**
+** SPS_FIRST: First spill slot for general use.
+** [sp+12] tmplo word \
+** [sp+ 8] tmphi word / tmp dword, parameter area for callee
+** [sp+ 4] tmpw, LR of callee
+** [sp+ 0] stack chain
+*/
+#define SPS_FIXED	7
+#define SPS_FIRST	4
+
+/* Stack offsets for temporary slots. Used for FP<->int conversions etc. */
+#define SPOFS_TMPW	4
+#define SPOFS_TMP	8
+#define SPOFS_TMPHI	8
+#define SPOFS_TMPLO	12
+
+#define sps_scale(slot)		(4 * (int32_t)(slot))
+#define sps_align(slot)		(((slot) - SPS_FIXED + 3) & ~3)
+
+/* -- Exit state ---------------------------------------------------------- */
+
+/* This definition must match with the *.dasc file(s). */
+typedef struct {
+  lua_Number fpr[RID_NUM_FPR];	/* Floating-point registers. */
+  int32_t gpr[RID_NUM_GPR];	/* General-purpose registers. */
+  int32_t spill[256];		/* Spill slots. */
+} ExitState;
+
+/* Highest exit + 1 indicates stack check. */
+#define EXITSTATE_CHECKEXIT	1
+
+/* Return the address of a per-trace exit stub. */
+static LJ_AINLINE uint32_t *exitstub_trace_addr_(uint32_t *p, uint32_t exitno)
+{
+  while (*p == 0x60000000) p++;  /* Skip PPCI_NOP. */
+  return p + 3 + exitno;
+}
+/* Avoid dependence on lj_jit.h if only including lj_target.h. */
+#define exitstub_trace_addr(T, exitno) \
+  exitstub_trace_addr_((MCode *)((char *)(T)->mcode + (T)->szmcode), (exitno))
+
+/* -- Instructions -------------------------------------------------------- */
+
+/* Instruction fields. */
+#define PPCF_CC(cc)	((((cc) & 3) << 16) | (((cc) & 4) << 22))
+#define PPCF_T(r)	((r) << 21)
+#define PPCF_A(r)	((r) << 16)
+#define PPCF_B(r)	((r) << 11)
+#define PPCF_C(r)	((r) << 6)
+#define PPCF_MB(n)	((n) << 6)
+#define PPCF_ME(n)	((n) << 1)
+#define PPCF_Y		0x00200000
+#define PPCF_DOT	0x00000001
+
+typedef enum PPCIns {
+  /* Integer instructions. */
+  PPCI_MR = 0x7c000378,
+  PPCI_NOP = 0x60000000,
+
+  PPCI_LI = 0x38000000,
+  PPCI_LIS = 0x3c000000,
+
+  PPCI_ADD = 0x7c000214,
+  PPCI_ADDC = 0x7c000014,
+  PPCI_ADDO = 0x7c000614,
+  PPCI_ADDE = 0x7c000114,
+  PPCI_ADDZE = 0x7c000194,
+  PPCI_ADDME = 0x7c0001d4,
+  PPCI_ADDI = 0x38000000,
+  PPCI_ADDIS = 0x3c000000,
+  PPCI_ADDIC = 0x30000000,
+  PPCI_ADDICDOT = 0x34000000,
+
+  PPCI_SUBF = 0x7c000050,
+  PPCI_SUBFC = 0x7c000010,
+  PPCI_SUBFO = 0x7c000450,
+  PPCI_SUBFE = 0x7c000110,
+  PPCI_SUBFZE = 0x7c000190,
+  PPCI_SUBFME = 0x7c0001d0,
+  PPCI_SUBFIC = 0x20000000,
+
+  PPCI_NEG = 0x7c0000d0,
+
+  PPCI_AND = 0x7c000038,
+  PPCI_ANDC = 0x7c000078,
+  PPCI_NAND = 0x7c0003b8,
+  PPCI_ANDIDOT = 0x70000000,
+  PPCI_ANDISDOT = 0x74000000,
+
+  PPCI_OR = 0x7c000378,
+  PPCI_NOR = 0x7c0000f8,
+  PPCI_ORI = 0x60000000,
+  PPCI_ORIS = 0x64000000,
+
+  PPCI_XOR = 0x7c000278,
+  PPCI_EQV = 0x7c000238,
+  PPCI_XORI = 0x68000000,
+  PPCI_XORIS = 0x6c000000,
+
+  PPCI_CMPW = 0x7c000000,
+  PPCI_CMPLW = 0x7c000040,
+  PPCI_CMPWI = 0x2c000000,
+  PPCI_CMPLWI = 0x28000000,
+
+  PPCI_MULLW = 0x7c0001d6,
+  PPCI_MULLI = 0x1c000000,
+  PPCI_MULLWO = 0x7c0005d6,
+
+  PPCI_EXTSB = 0x7c000774,
+  PPCI_EXTSH = 0x7c000734,
+
+  PPCI_SLW = 0x7c000030,
+  PPCI_SRW = 0x7c000430,
+  PPCI_SRAW = 0x7c000630,
+  PPCI_SRAWI = 0x7c000670,
+
+  PPCI_RLWNM = 0x5c000000,
+  PPCI_RLWINM = 0x54000000,
+  PPCI_RLWIMI = 0x50000000,
+
+  PPCI_B = 0x48000000,
+  PPCI_BL = 0x48000001,
+  PPCI_BC = 0x40800000,
+  PPCI_BCL = 0x40800001,
+  PPCI_BCTR = 0x4e800420,
+  PPCI_BCTRL = 0x4e800421,
+
+  PPCI_CRANDC = 0x4c000102,
+  PPCI_CRXOR = 0x4c000182,
+  PPCI_CRAND = 0x4c000202,
+  PPCI_CREQV = 0x4c000242,
+  PPCI_CRORC = 0x4c000342,
+  PPCI_CROR = 0x4c000382,
+
+  PPCI_MFLR = 0x7c0802a6,
+  PPCI_MTCTR = 0x7c0903a6,
+
+  PPCI_MCRXR = 0x7c000400,
+
+  /* Load/store instructions. */
+  PPCI_LWZ = 0x80000000,
+  PPCI_LBZ = 0x88000000,
+  PPCI_STW = 0x90000000,
+  PPCI_STB = 0x98000000,
+  PPCI_LHZ = 0xa0000000,
+  PPCI_LHA = 0xa8000000,
+  PPCI_STH = 0xb0000000,
+
+  PPCI_STWU = 0x94000000,
+
+  PPCI_LFS = 0xc0000000,
+  PPCI_LFD = 0xc8000000,
+  PPCI_STFS = 0xd0000000,
+  PPCI_STFD = 0xd8000000,
+
+  PPCI_LWZX = 0x7c00002e,
+  PPCI_LBZX = 0x7c0000ae,
+  PPCI_STWX = 0x7c00012e,
+  PPCI_STBX = 0x7c0001ae,
+  PPCI_LHZX = 0x7c00022e,
+  PPCI_LHAX = 0x7c0002ae,
+  PPCI_STHX = 0x7c00032e,
+
+  PPCI_LWBRX = 0x7c00042c,
+  PPCI_STWBRX = 0x7c00052c,
+
+  PPCI_LFSX = 0x7c00042e,
+  PPCI_LFDX = 0x7c0004ae,
+  PPCI_STFSX = 0x7c00052e,
+  PPCI_STFDX = 0x7c0005ae,
+
+  /* FP instructions. */
+  PPCI_FMR = 0xfc000090,
+  PPCI_FNEG = 0xfc000050,
+  PPCI_FABS = 0xfc000210,
+
+  PPCI_FRSP = 0xfc000018,
+  PPCI_FCTIWZ = 0xfc00001e,
+
+  PPCI_FADD = 0xfc00002a,
+  PPCI_FSUB = 0xfc000028,
+  PPCI_FMUL = 0xfc000032,
+  PPCI_FDIV = 0xfc000024,
+
+  PPCI_FMADD = 0xfc00003a,
+  PPCI_FMSUB = 0xfc000038,
+  PPCI_FNMSUB = 0xfc00003c,
+
+  PPCI_FCMPU = 0xfc000000,
+  PPCI_FSEL = 0xfc00002e,
+} PPCIns;
+
+typedef enum PPCCC {
+  CC_GE, CC_LE, CC_NE, CC_NS, CC_LT, CC_GT, CC_EQ, CC_SO
+} PPCCC;
+
+#endif
diff --git a/third_party/luajit/src/lj_target_x86.h b/third_party/luajit/src/lj_target_x86.h
index 34b247d4c9effd6aa477940a81d40d5f3b2dd6c0..593e7b009601ea001d183fda47e5b4251d6020f7 100644
--- a/third_party/luajit/src/lj_target_x86.h
+++ b/third_party/luajit/src/lj_target_x86.h
@@ -37,6 +37,7 @@ enum {
 #if LJ_64
   RID_FPRET = RID_XMM0,
 #else
+  RID_RETLO = RID_EAX,
   RID_RETHI = RID_EDX,
 #endif
 
@@ -84,6 +85,7 @@ enum {
 #define REGARG_GPRS \
   (RID_ECX|((RID_EDX|((RID_R8D|(RID_R9D<<5))<<5))<<5))
 #define REGARG_NUMGPR	4
+#define REGARG_NUMFPR	4
 #define REGARG_FIRSTFPR	RID_XMM0
 #define REGARG_LASTFPR	RID_XMM3
 #define STACKARG_OFS	(4*8)
@@ -95,6 +97,7 @@ enum {
   (RID_EDI|((RID_ESI|((RID_EDX|((RID_ECX|((RID_R8D|(RID_R9D \
    <<5))<<5))<<5))<<5))<<5))
 #define REGARG_NUMGPR	6
+#define REGARG_NUMFPR	8
 #define REGARG_FIRSTFPR	RID_XMM0
 #define REGARG_LASTFPR	RID_XMM7
 #define STACKARG_OFS	0
@@ -104,6 +107,7 @@ enum {
 #define RSET_SCRATCH	(RSET_ACD|RSET_FPR)
 #define REGARG_GPRS	(RID_ECX|(RID_EDX<<5))  /* Fastcall only. */
 #define REGARG_NUMGPR	2  /* Fastcall only. */
+#define REGARG_NUMFPR	0
 #define STACKARG_OFS	0
 #endif
 
@@ -188,9 +192,11 @@ typedef enum {
   XI_CALL =	0xe8,
   XI_JMP =	0xe9,
   XI_JMPs =	0xeb,
+  XI_PUSH =	0x50, /* Really 50+r. */
   XI_JCCs =	0x70, /* Really 7x. */
   XI_JCCn =	0x80, /* Really 0f8x. */
   XI_LEA =	0x8d,
+  XI_MOVrib =	0xb0, /* Really b0+r. */
   XI_MOVri =	0xb8, /* Really b8+r. */
   XI_ARITHib =	0x80,
   XI_ARITHi =	0x81,
@@ -198,6 +204,7 @@ typedef enum {
   XI_PUSHi8 =	0x6a,
   XI_TEST =	0x85,
   XI_MOVmi =	0xc7,
+  XI_GROUP5 =	0xff,
 
   /* Note: little-endian byte-order! */
   XI_FLDZ =	0xeed9,
diff --git a/third_party/luajit/src/lj_trace.c b/third_party/luajit/src/lj_trace.c
index 2bb2075d88df559612429c83869e8f73a0dd44dc..9645ecbafdb321fde87ce2020823bf83fc9c7008 100644
--- a/third_party/luajit/src/lj_trace.c
+++ b/third_party/luajit/src/lj_trace.c
@@ -497,6 +497,7 @@ static int trace_abort(jit_State *J)
   if (tvisnumber(L->top-1))
     e = (TraceError)numberVint(L->top-1);
   if (e == LJ_TRERR_MCODELM) {
+    L->top--;  /* Remove error object */
     J->state = LJ_TRACE_ASM;
     return 1;  /* Retry ASM with new MCode area. */
   }
@@ -509,6 +510,7 @@ static int trace_abort(jit_State *J)
   if (traceno) {
     ptrdiff_t errobj = savestack(L, L->top-1);  /* Stack may be resized. */
     J->cur.link = 0;
+    J->cur.linktype = LJ_TRLINK_NONE;
     lj_vmevent_send(L, TRACE,
       TValue *frame;
       const BCIns *pc;
@@ -545,9 +547,13 @@ static int trace_abort(jit_State *J)
 /* Perform pending re-patch of a bytecode instruction. */
 static LJ_AINLINE void trace_pendpatch(jit_State *J, int force)
 {
-  if (LJ_UNLIKELY(J->patchpc) && (force || J->chain[IR_RETF])) {
-    *J->patchpc = J->patchins;
-    J->patchpc = NULL;
+  if (LJ_UNLIKELY(J->patchpc)) {
+    if (force || J->bcskip == 0) {
+      *J->patchpc = J->patchins;
+      J->patchpc = NULL;
+    } else {
+      J->bcskip = 0;
+    }
   }
 }
 
@@ -568,11 +574,17 @@ static TValue *trace_state(lua_State *L, lua_CFunction dummy, void *ud)
     case LJ_TRACE_RECORD:
       trace_pendpatch(J, 0);
       setvmstate(J2G(J), RECORD);
-      lj_vmevent_send(L, RECORD,
+      lj_vmevent_send_(L, RECORD,
+	/* Save/restore tmptv state for trace recorder. */
+	TValue savetv = J2G(J)->tmptv;
+	TValue savetv2 = J2G(J)->tmptv2;
 	setintV(L->top++, J->cur.traceno);
 	setfuncV(L, L->top++, J->fn);
 	setintV(L->top++, J->pt ? (int32_t)proto_bcpos(J->pt, J->pc) : -1);
 	setintV(L->top++, J->framedepth);
+      ,
+	J2G(J)->tmptv = savetv;
+	J2G(J)->tmptv2 = savetv2;
       );
       lj_record_ins(J);
       break;
@@ -586,6 +598,7 @@ static TValue *trace_state(lua_State *L, lua_CFunction dummy, void *ud)
 	lj_opt_dce(J);
 	if (lj_opt_loop(J)) {  /* Loop optimization failed? */
 	  J->cur.link = 0;
+	  J->cur.linktype = LJ_TRLINK_NONE;
 	  J->loopref = J->cur.nins;
 	  J->state = LJ_TRACE_RECORD;  /* Try to continue recording. */
 	  break;
@@ -637,9 +650,10 @@ void lj_trace_ins(jit_State *J, const BCIns *pc)
 /* A hotcount triggered. Start recording a root trace. */
 void LJ_FASTCALL lj_trace_hot(jit_State *J, const BCIns *pc)
 {
-  ERRNO_SAVE
   /* Note: pc is the interpreter bytecode PC here. It's offset by 1. */
-  hotcount_set(J2GG(J), pc, J->param[JIT_P_hotloop]+1);  /* Reset hotcount. */
+  ERRNO_SAVE
+  /* Reset hotcount. */
+  hotcount_set(J2GG(J), pc, J->param[JIT_P_hotloop]*HOTCOUNT_LOOP);
   /* Only start a new trace if not recording or inside __gc call or vmevent. */
   if (J->state == LJ_TRACE_IDLE &&
       !(J2G(J)->hookmask & (HOOK_GC|HOOK_VMEVENT))) {
@@ -713,14 +727,8 @@ static TraceNo trace_exit_find(jit_State *J, MCode *pc)
   TraceNo traceno;
   for (traceno = 1; traceno < J->sizetrace; traceno++) {
     GCtrace *T = traceref(J, traceno);
-    if (T && pc >= T->mcode && pc < (MCode *)((char *)T->mcode + T->szmcode)) {
-      if (J->exitno == T->nsnap) {  /* Treat stack check like a parent exit. */
-	lua_assert(T->root != 0);
-	traceno = T->ir[REF_BASE].op1;
-	J->exitno = T->ir[REF_BASE].op2;
-      }
+    if (T && pc >= T->mcode && pc < (MCode *)((char *)T->mcode + T->szmcode))
       return traceno;
-    }
   }
   lua_assert(0);
   return 0;
@@ -737,11 +745,20 @@ int LJ_FASTCALL lj_trace_exit(jit_State *J, void *exptr)
   int errcode;
   const BCIns *pc;
   void *cf;
+  GCtrace *T;
 #ifdef EXITSTATE_PCREG
   J->parent = trace_exit_find(J, (MCode *)(intptr_t)ex->gpr[EXITSTATE_PCREG]);
 #endif
-  lua_assert(traceref(J, J->parent) != NULL &&
-	     J->exitno < traceref(J, J->parent)->nsnap);
+  T = traceref(J, J->parent); UNUSED(T);
+#ifdef EXITSTATE_CHECKEXIT
+  if (J->exitno == T->nsnap) {  /* Treat stack check like a parent exit. */
+    lua_assert(T->root != 0);
+    J->exitno = T->ir[REF_BASE].op2;
+    J->parent = T->ir[REF_BASE].op1;
+    T = traceref(J, J->parent);
+  }
+#endif
+  lua_assert(T != NULL && J->exitno < T->nsnap);
   exd.J = J;
   exd.exptr = exptr;
   errcode = lj_vm_cpcall(L, NULL, &exd, trace_exit_cp);
@@ -769,6 +786,7 @@ int LJ_FASTCALL lj_trace_exit(jit_State *J, void *exptr)
 	J->patchins = *pc;
 	J->patchpc = (BCIns *)pc;
 	*J->patchpc = *retpc;
+	J->bcskip = 1;
       } else {
 	pc = retpc;
 	setcframe_pc(cf, pc);
diff --git a/third_party/luajit/src/lj_vm.h b/third_party/luajit/src/lj_vm.h
index 3f6777ad11fc81682e216e00984ead8817510038..da940b9fa3e42080b6c03a80b90f8347e5981e7a 100644
--- a/third_party/luajit/src/lj_vm.h
+++ b/third_party/luajit/src/lj_vm.h
@@ -66,18 +66,21 @@ LJ_ASMF void lj_vm_powi_sse(void);
 #else
 LJ_ASMF double lj_vm_trunc(double);
 LJ_ASMF double lj_vm_powi(double, int32_t);
-#if defined(__ANDROID__) || defined(__symbian__)
+#ifdef LUAJIT_NO_LOG2
 LJ_ASMF double lj_vm_log2(double);
 #else
 #define lj_vm_log2	log2
 #endif
-#if defined(__symbian__)
+#ifdef LUAJIT_NO_EXP2
 LJ_ASMF double lj_vm_exp2(double);
 #else
 #define lj_vm_exp2	exp2
 #endif
 #endif
 LJ_ASMF int32_t LJ_FASTCALL lj_vm_modi(int32_t, int32_t);
+#if LJ_HASFFI
+LJ_ASMF int lj_vm_errno(void);
+#endif
 #endif
 
 /* Continuations for metamethods. */
@@ -88,6 +91,8 @@ LJ_ASMF void lj_cont_condt(void);  /* Branch if result is true. */
 LJ_ASMF void lj_cont_condf(void);  /* Branch if result is false. */
 LJ_ASMF void lj_cont_hook(void);  /* Continue from hook yield. */
 
+enum { LJ_CONT_TAILCALL, LJ_CONT_FFI_CALLBACK };  /* Special continuations. */
+
 /* Start of the ASM code. */
 LJ_ASMF char lj_vm_asm_begin[];
 
diff --git a/third_party/luajit/src/lj_vmevent.h b/third_party/luajit/src/lj_vmevent.h
index 857e5be52701c1245802d1783988df933dd226e8..8a0822f2c5192b17b46bf0008beb8dc0dbb414ef 100644
--- a/third_party/luajit/src/lj_vmevent.h
+++ b/third_party/luajit/src/lj_vmevent.h
@@ -31,7 +31,8 @@ typedef enum {
 } VMEvent;
 
 #ifdef LUAJIT_DISABLE_VMEVENT
-#define lj_vmevent_send(L, ev, args)	UNUSED(L)
+#define lj_vmevent_send(L, ev, args)		UNUSED(L)
+#define lj_vmevent_send_(L, ev, args, post)	UNUSED(L)
 #else
 #define lj_vmevent_send(L, ev, args) \
   if (G(L)->vmevmask & VMEVENT_MASK(LJ_VMEVENT_##ev)) { \
@@ -41,6 +42,15 @@ typedef enum {
       lj_vmevent_call(L, argbase); \
     } \
   }
+#define lj_vmevent_send_(L, ev, args, post) \
+  if (G(L)->vmevmask & VMEVENT_MASK(LJ_VMEVENT_##ev)) { \
+    ptrdiff_t argbase = lj_vmevent_prepare(L, LJ_VMEVENT_##ev); \
+    if (argbase) { \
+      args \
+      lj_vmevent_call(L, argbase); \
+      post \
+    } \
+  }
 
 LJ_FUNC ptrdiff_t lj_vmevent_prepare(lua_State *L, VMEvent ev);
 LJ_FUNC void lj_vmevent_call(lua_State *L, ptrdiff_t argbase);
diff --git a/third_party/luajit/src/lj_vmmath.c b/third_party/luajit/src/lj_vmmath.c
index 8ae8863bc81c1d2a401af6d2952f725ad75085ea..8b1772071791c3abfa1c5e4f7b36aaf190ce21a0 100644
--- a/third_party/luajit/src/lj_vmmath.c
+++ b/third_party/luajit/src/lj_vmmath.c
@@ -6,6 +6,7 @@
 #define lj_vmmath_c
 #define LUA_CORE
 
+#include <errno.h>
 #include <math.h>
 
 #include "lj_obj.h"
@@ -25,21 +26,21 @@ LJ_FUNCA double lj_vm_tanh(double x) { return tanh(x); }
 
 #if LJ_HASJIT
 
-#if defined(__ANDROID__) || defined(__symbian__)
+#ifdef LUAJIT_NO_LOG2
 double lj_vm_log2(double a)
 {
   return log(a) * 1.4426950408889634074;
 }
 #endif
 
-#if defined(__symbian__)
+#ifdef LUAJIT_NO_EXP2
 double lj_vm_exp2(double a)
 {
   return exp(a * 0.6931471805599453);
 }
 #endif
 
-#if !LJ_TARGET_ARM
+#if !(LJ_TARGET_ARM || LJ_TARGET_PPC)
 int32_t LJ_FASTCALL lj_vm_modi(int32_t a, int32_t b)
 {
   uint32_t y, ua, ub;
@@ -81,7 +82,7 @@ double lj_vm_powi(double x, int32_t k)
   else if (k == 1)
     return x;
   else if (k == 0)
-    return 1;
+    return 1.0;
   else
     return 1.0 / lj_vm_powui(x, (uint32_t)-k);
 }
@@ -108,4 +109,11 @@ double lj_vm_foldfpm(double x, int fpm)
 }
 #endif
 
+#if LJ_HASFFI
+int lj_vm_errno(void)
+{
+  return errno;
+}
+#endif
+
 #endif
diff --git a/third_party/luajit/src/ljamalg.c b/third_party/luajit/src/ljamalg.c
index 57ad78515f05aa4b4ca693b720b52c4ab2694fcc..17c4b65e2c911990b65480e1c15e45f0e73cec16 100644
--- a/third_party/luajit/src/ljamalg.c
+++ b/third_party/luajit/src/ljamalg.c
@@ -16,7 +16,7 @@
 #define ljamalg_c
 #define LUA_CORE
 
-/* To get the mremap prototype. Must be defind before any system includes. */
+/* To get the mremap prototype. Must be defined before any system includes. */
 #if defined(__linux__) && !defined(_GNU_SOURCE)
 #define _GNU_SOURCE
 #endif
@@ -52,6 +52,7 @@
 #include "lj_cdata.c"
 #include "lj_cconv.c"
 #include "lj_ccall.c"
+#include "lj_ccallback.c"
 #include "lj_carith.c"
 #include "lj_clib.c"
 #include "lj_cparse.c"
diff --git a/third_party/luajit/src/luaconf.h b/third_party/luajit/src/luaconf.h
index 4a243ffbf22d0d808132bde22866b9d5b09fd392..5b04ad438611f895bd8bb54a5fde1a24cf800598 100644
--- a/third_party/luajit/src/luaconf.h
+++ b/third_party/luajit/src/luaconf.h
@@ -26,12 +26,12 @@
 #define LUA_LDIR	LUA_ROOT "share/lua/5.1/"
 #define LUA_CDIR	LUA_ROOT "lib/lua/5.1/"
 #ifdef LUA_XROOT
-#define LUA_JDIR	LUA_XROOT "share/luajit-2.0.0-beta8/"
+#define LUA_JDIR	LUA_XROOT "share/luajit-2.0.0-beta9/"
 #define LUA_XPATH \
   ";" LUA_XROOT "share/lua/5.1/?.lua;" LUA_XROOT "share/lua/5.1/?/init.lua"
 #define LUA_XCPATH	LUA_XROOT "lib/lua/5.1/?.so;"
 #else
-#define LUA_JDIR	LUA_ROOT "share/luajit-2.0.0-beta8/"
+#define LUA_JDIR	LUA_ROOT "share/luajit-2.0.0-beta9/"
 #define LUA_XPATH
 #define LUA_XCPATH
 #endif
diff --git a/third_party/luajit/src/luajit.h b/third_party/luajit/src/luajit.h
index 38be73da0e79034105e6a3c6bd74d10200ce7b7c..2421502d4bb384a31ade52a98c0077e90d4be387 100644
--- a/third_party/luajit/src/luajit.h
+++ b/third_party/luajit/src/luajit.h
@@ -30,9 +30,9 @@
 
 #include "lua.h"
 
-#define LUAJIT_VERSION		"LuaJIT 2.0.0-beta8"
+#define LUAJIT_VERSION		"LuaJIT 2.0.0-beta9"
 #define LUAJIT_VERSION_NUM	20000  /* Version 2.0.0 = 02.00.00. */
-#define LUAJIT_VERSION_SYM	luaJIT_version_2_0_0_beta8
+#define LUAJIT_VERSION_SYM	luaJIT_version_2_0_0_beta9
 #define LUAJIT_COPYRIGHT	"Copyright (C) 2005-2011 Mike Pall"
 #define LUAJIT_URL		"http://luajit.org/"
 
diff --git a/third_party/luajit/src/msvcbuild.bat b/third_party/luajit/src/msvcbuild.bat
index cd182362aca047d68443677c9cb54beeed045e24..422d16586e2ba393acacc6aac5c82aa30c19d16c 100644
--- a/third_party/luajit/src/msvcbuild.bat
+++ b/third_party/luajit/src/msvcbuild.bat
@@ -24,45 +24,77 @@
 
 if not exist buildvm_x86.h^
   %DASM% -LN -o buildvm_x86.h buildvm_x86.dasc
+@if errorlevel 1 goto :BAD
 if not exist buildvm_x64win.h^
   %DASM% -LN -D X64 -D X64WIN -o buildvm_x64win.h buildvm_x86.dasc
+@if errorlevel 1 goto :BAD
 
 %LJCOMPILE% /I "." /I %DASMDIR% buildvm*.c
+@if errorlevel 1 goto :BAD
 %LJLINK% /out:buildvm.exe buildvm*.obj
+@if errorlevel 1 goto :BAD
 if exist buildvm.exe.manifest^
   %LJMT% -manifest buildvm.exe.manifest -outputresource:buildvm.exe
 
 buildvm -m peobj -o lj_vm.obj
+@if errorlevel 1 goto :BAD
 buildvm -m bcdef -o lj_bcdef.h %ALL_LIB%
+@if errorlevel 1 goto :BAD
 buildvm -m ffdef -o lj_ffdef.h %ALL_LIB%
+@if errorlevel 1 goto :BAD
 buildvm -m libdef -o lj_libdef.h %ALL_LIB%
+@if errorlevel 1 goto :BAD
 buildvm -m recdef -o lj_recdef.h %ALL_LIB%
+@if errorlevel 1 goto :BAD
 buildvm -m vmdef -o ..\lib\vmdef.lua %ALL_LIB%
+@if errorlevel 1 goto :BAD
 buildvm -m folddef -o lj_folddef.h lj_opt_fold.c
+@if errorlevel 1 goto :BAD
 
+@if "%1" neq "debug" goto :NODEBUG
+@shift
+@set LJCOMPILE=%LJCOMPILE% /Zi
+@set LJLINK=%LJLINK% /debug
+:NODEBUG
 @if "%1"=="amalg" goto :AMALGDLL
 @if "%1"=="static" goto :STATIC
 %LJCOMPILE% /DLUA_BUILD_AS_DLL lj_*.c lib_*.c
+@if errorlevel 1 goto :BAD
 %LJLINK% /DLL /out:lua51.dll lj_*.obj lib_*.obj
+@if errorlevel 1 goto :BAD
 @goto :MTDLL
 :STATIC
 %LJCOMPILE% /DLUA_BUILD_AS_DLL lj_*.c lib_*.c
+@if errorlevel 1 goto :BAD
 %LJLIB% /OUT:lua51.lib lj_*.obj lib_*.obj
+@if errorlevel 1 goto :BAD
 @goto :MTDLL
 :AMALGDLL
 %LJCOMPILE% /DLUA_BUILD_AS_DLL ljamalg.c
+@if errorlevel 1 goto :BAD
 %LJLINK% /DLL /out:lua51.dll ljamalg.obj lj_vm.obj
+@if errorlevel 1 goto :BAD
 :MTDLL
 if exist lua51.dll.manifest^
   %LJMT% -manifest lua51.dll.manifest -outputresource:lua51.dll;2
 
 %LJCOMPILE% luajit.c
+@if errorlevel 1 goto :BAD
 %LJLINK% /out:luajit.exe luajit.obj lua51.lib
+@if errorlevel 1 goto :BAD
 if exist luajit.exe.manifest^
   %LJMT% -manifest luajit.exe.manifest -outputresource:luajit.exe
 
-del *.obj *.manifest buildvm.exe
+@del *.obj *.manifest buildvm.exe
+@echo.
+@echo === Successfully built LuaJIT ===
 
+@goto :END
+:BAD
+@echo.
+@echo *******************************************************
+@echo *** Build FAILED -- Please check the error messages ***
+@echo *******************************************************
 @goto :END
 :FAIL
 @echo You must open a "Visual Studio .NET Command Prompt" to run this script