lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Florian Weimer wrote:
> Here's an experimental patch to shrink the size of a Lua value to 64
> bit on LP64 architectures, by encoding non-double values as special
> NaNs.  I think this was initially suggested by Mike Pall, but I'm not
> sure if it's been implemented yet.

Yes, it will be in LuaJIT 2.x. But as I've mentioned in the past
it doesn't pay off for the Lua interpreter:

  http://lua-users.org/lists/lua-l/2008-02/msg00093.html

Apart from the portability problem (the popular targets are ILP32,
LP64 and LLP64) your patch is lacking the important tricks to make
it fast. I've disclosed a couple of them in a bug report for Tamarin:

  https://bugzilla.mozilla.org/show_bug.cgi?id=416398

--Mike