Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Handling of memory errors when creating to-be-closed upvalues | Roberto Ierusalimschy | 2018-10-18 | 1 | -2/+1 |
| | |||||
* | First "complete" implementation of to-be-closed variables | Roberto Ierusalimschy | 2018-10-17 | 1 | -4/+3 |
| | | | | | | | Still missing: - handling of memory errors when creating upvalue (must run closing method all the same) - interaction with coroutines | ||||
* | Towards "to closed" local variables | Roberto Ierusalimschy | 2018-10-08 | 1 | -0/+6 |
| | | | | | | | | | | | | Start of the implementation of "scoped variables" or "to be closed" variables, local variables whose '__close' (or themselves) are called when they go out of scope. This commit implements the syntax, the opcode, and the creation of the corresponding upvalue, but it still does not call the finalizations when the variable goes out of scope (the most important part). Currently, the syntax is 'local scoped name = exp', but that will probably change. | ||||
* | Corrections in the implementation of '%' for floats. | Roberto Ierusalimschy | 2018-08-28 | 1 | -6/+12 |
| | | | | | | | | | The multiplication (m*b) used to test whether 'm' is non-zero and 'm' and 'b' have different signs can underflow for very small numbers, giving a wrong result. The use of explicit comparisons solves this problem. This commit also adds several new tests for '%' (both for floats and for integers) to exercise more corner cases, such as very large and very small values. | ||||
* | Deprecated the emulation of '__le' using '__lt' | Roberto Ierusalimschy | 2018-08-24 | 1 | -0/+2 |
| | | | | | | | | | | | As hinted in the manual for Lua 5.3, the emulation of the metamethod for '__le' using '__le' has been deprecated. It is slow, complicates the logic, and it is easy to avoid this emulation by defining a proper '__le' function. Moreover, often this emulation was used wrongly, with a programmer assuming that an order is total when it is not (e.g., NaN in floating-point numbers). | ||||
* | details | Roberto Ierusalimschy | 2018-08-17 | 1 | -6/+6 |
| | | | | | Minor optimizations in 'lvm.c'. (Not exactly optimizations, but more chances for optimizations.) | ||||
* | Fixed bug in OP_IDIVI | Roberto Ierusalimschy | 2018-07-09 | 1 | -2/+2 |
| | | | | | Opocode was using 'luai_numdiv' (float division) instead of 'luai_numidiv' (integer division). | ||||
* | in generational mode, an emergency collection can turn any object black | Roberto Ierusalimschy | 2018-06-18 | 1 | -3/+3 |
| | | | | | | during any memory allocation + 'luaT_getvarargs' may reallocate the stack, and therefore the top must be correct. | ||||
* | field 'sizearray' in struct 'Table' changed to 'alimit', which can | Roberto Ierusalimschy | 2018-06-15 | 1 | -2/+2 |
| | | | | be used as a hint for '#t' | ||||
* | no more 'luaH_emptyobject' and comparisons of addresses of global variables | Roberto Ierusalimschy | 2018-06-01 | 1 | -5/+5 |
| | | | | | (instead, use a different kind of nil to signal the fake entry returned when a key is not found in a table) | ||||
* | new macros 'likely'/'unlikely' with hints for jump predictions | Roberto Ierusalimschy | 2018-05-30 | 1 | -11/+11 |
| | | | | (used only in errors for now) | ||||
* | in 'luaD_poscall', there is no need to compute 'firstResult' when 'nres==0' | Roberto Ierusalimschy | 2018-05-22 | 1 | -9/+16 |
| | |||||
* | minimizing the code ran by 'vmfetch' + no more 'vra' | Roberto Ierusalimschy | 2018-05-02 | 1 | -113/+109 |
| | | | | (the code is simpler without 'vra' and conversion is a no-op) | ||||
* | no more nil-in-table | Roberto Ierusalimschy | 2018-04-04 | 1 | -14/+1 |
| | |||||
* | using unsigned comparison in 'l_intfitsf' (avoids one comparison) | Roberto Ierusalimschy | 2018-04-02 | 1 | -9/+13 |
| | |||||
* | cannot use 'defined' inside a macro + | Roberto Ierusalimschy | 2018-03-16 | 1 | -3/+8 |
| | | | | call to 'luaT_keydef' must be protected | ||||
* | new experimental syntax using reserved word 'undef' | Roberto Ierusalimschy | 2018-03-07 | 1 | -1/+13 |
| | |||||
* | using jump tables when available | Roberto Ierusalimschy | 2018-03-02 | 1 | -1/+14 |
| | |||||
* | better names for macros for tags and types. | Roberto Ierusalimschy | 2018-02-26 | 1 | -5/+5 |
| | | | | | rttype -> rawtt; ttyperaw -> withvariant; ttype -> ttypetag; tnov -> ttype | ||||
* | first version of empty entries in tables | Roberto Ierusalimschy | 2018-02-23 | 1 | -10/+11 |
| | | | | (so that, in the future, tables can contain regular nil entries) | ||||
* | conditional jumps "deunified" | Roberto Ierusalimschy | 2018-02-21 | 1 | -15/+28 |
| | | | | (if a jump table is used, the unification may harm jump prediction.) | ||||
* | new opcodes OP_GTI/OP_GEI | Roberto Ierusalimschy | 2018-02-21 | 1 | -17/+28 |
| | |||||
* | simpler implementation for 'LTintfloat'/'LEintfloat' | Roberto Ierusalimschy | 2018-02-21 | 1 | -45/+71 |
| | | | | + 'LTfloatint'/'LEfloatint' | ||||
* | small reorganization of 'luaV_flttointeger'/'luaV_tointeger' | Roberto Ierusalimschy | 2018-02-21 | 1 | -21/+27 |
| | |||||
* | more generic way to handle 'gclist' | Roberto Ierusalimschy | 2018-02-19 | 1 | -3/+3 |
| | |||||
* | correct way to check stack space for vararg functions | Roberto Ierusalimschy | 2018-02-17 | 1 | -4/+4 |
| | |||||
* | some simplifications/optimizations in returns from Lua functions | Roberto Ierusalimschy | 2018-02-15 | 1 | -34/+26 |
| | |||||
* | vararg back to '...' (but with another implementation) | Roberto Ierusalimschy | 2018-02-09 | 1 | -13/+27 |
| | | | | new implementation should have zero overhead for non-vararg functions | ||||
* | new opcode 'PREPVARARG' | Roberto Ierusalimschy | 2018-02-07 | 1 | -4/+19 |
| | | | | (avoids test for vararg function in all function calls) | ||||
* | call hooks for Lua functions called by 'luaV_execute' | Roberto Ierusalimschy | 2018-02-06 | 1 | -2/+5 |
| | |||||
* | warnings in VS (implicit casts from ptrdiff_t to int) | Roberto Ierusalimschy | 2018-01-29 | 1 | -2/+2 |
| | |||||
* | OP_CONCAT does not move its result (to simplify its execution) | Roberto Ierusalimschy | 2018-01-27 | 1 | -17/+7 |
| | |||||
* | 'OP_TAILCALL' calling C functions finishes the call and returns | Roberto Ierusalimschy | 2018-01-14 | 1 | -5/+10 |
| | | | | (instead of waiting for following 'OP_RETURN') | ||||
* | 'luaD_tryfuncTM' can ensure it does not change the stack | Roberto Ierusalimschy | 2018-01-10 | 1 | -4/+2 |
| | |||||
* | avoid jumping into a variable scope (C++ does not allow that) | Roberto Ierusalimschy | 2018-01-09 | 1 | -8/+8 |
| | |||||
* | typos in comments | Roberto Ierusalimschy | 2017-12-30 | 1 | -2/+2 |
| | |||||
* | keep control of stack top in Lua functions concentrated in 'luaV_execute' | Roberto Ierusalimschy | 2017-12-28 | 1 | -17/+29 |
| | |||||
* | new macros 'isOT'/'isIT' | Roberto Ierusalimschy | 2017-12-22 | 1 | -4/+4 |
| | | | | | (plus exchanged parameters of OP_VARARG to make it similar to other 'isOT' instructions) | ||||
* | when running Lua code, there is no need to keep 'L->top' "correct"; | Roberto Ierusalimschy | 2017-12-20 | 1 | -20/+6 |
| | | | | set it only when needed. | ||||
* | no need to save 'pc' in case of allocation errors | Roberto Ierusalimschy | 2017-12-19 | 1 | -3/+1 |
| | | | | (allocation errors do not call message handlers) | ||||
* | new opcodes 'FORLOOP1'/'FORPREP1' for "basic for" (integer variable | Roberto Ierusalimschy | 2017-12-18 | 1 | -1/+27 |
| | | | | with increment of 1) | ||||
* | new opcodes BANDK/BORK/BXORK. (They do not use immediate operands | Roberto Ierusalimschy | 2017-12-13 | 1 | -1/+35 |
| | | | | | because, too often, masks in bitwise operations are integers larger than one byte.) | ||||
* | new opcodes OP_SHLI/OP_SHRI | Roberto Ierusalimschy | 2017-12-04 | 1 | -2/+30 |
| | |||||
* | small peephole optimizations | Roberto Ierusalimschy | 2017-11-30 | 1 | -5/+5 |
| | |||||
* | new opcodes OP_RETURN0/OP_RETURN1 | Roberto Ierusalimschy | 2017-11-29 | 1 | -13/+56 |
| | |||||
* | 'luaV_execute' gets call info as extra argument (it is always | Roberto Ierusalimschy | 2017-11-29 | 1 | -3/+2 |
| | | | | available on call sites) | ||||
* | conditional jumps unified in label "condjump' + new variable 'vra' | Roberto Ierusalimschy | 2017-11-28 | 1 | -128/+106 |
| | | | | to avoid excessive use of macro 's2v' | ||||
* | using register 'k' for conditions in tests (we only need one bit there) | Roberto Ierusalimschy | 2017-11-28 | 1 | -44/+44 |
| | |||||
* | new opcodes 'OP_LTI' and 'OP_LEI' | Roberto Ierusalimschy | 2017-11-27 | 1 | -8/+45 |
| | |||||
* | small simplifications around 'luaT_callorderTM' | Roberto Ierusalimschy | 2017-11-23 | 1 | -17/+6 |
| |