Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Added gcc option '-Wconversion' | Roberto Ierusalimschy | 2024-07-27 | 1 | -9/+9 |
| | | | | | No warnings for standard numerical types. Still pending alternative numerical types. | ||||
* | Cleaning of llimits.h | Roberto Ierusalimschy | 2024-06-20 | 1 | -0/+1 |
| | | | | | | Several definitions that don't need to be "global" (that is, that concerns only specific parts of the code) moved out of llimits.h, to more appropriate places. | ||||
* | 'luaH_get' functions return tag of the result | Roberto Ierusalimschy | 2024-03-21 | 1 | -2/+3 |
| | | | | | | | Undoing previous commit. Returning TValue increases code size without any visible gains. Returning the tag is a little simpler than returning a special code (HOK/HNOTFOUND) and the tag is useful by itself in some cases. | ||||
* | 'luaH_get' functions return 'TValue' | Roberto Ierusalimschy | 2024-03-18 | 1 | -2/+2 |
| | | | | | | Instead of receiving a parameter telling them where to put the result of the query, these functions return the TValue directly. (That is, they return a structure.) | ||||
* | Removed type 'varint_t' | Roberto Ierusalimschy | 2024-03-13 | 1 | -9/+13 |
| | | | | | | size_t should be big enough to count the number of strings in a dump. (And, by definition, it is big enough to count the length of each string.) | ||||
* | Revising code for Varint encoding in dumps | Roberto Ierusalimschy | 2024-02-12 | 1 | -17/+18 |
| | | | | | | | | - Usign lua_Unsigned to count strings. - Varint uses a type large enough both for size_t and lua_Unsigned. - Most-Significant Bit 0 means last byte, to conform to common usage. - (unrelated) Change in macro 'getaddr' so that multiplication is by constants. | ||||
* | Fixed buffers reuse absolute line information | Roberto Ierusalimschy | 2023-12-27 | 1 | -3/+4 |
| | |||||
* | Cleaner protocol between 'lua_dump' and writer function | Roberto Ierusalimschy | 2023-12-14 | 1 | -7/+23 |
| | | | | | 'lua_dump' signals to the writer function the end of a dump, so that is has more freedom when using the stack. | ||||
* | Correct anchoring and GC barriers in 'loadString' | Roberto Ierusalimschy | 2023-11-13 | 1 | -5/+2 |
| | | | | | | Call to 'luaH_setint' could call the GC with the string unanchored. Moreover, previously saved strings were being assigned to the prototype without a barrier. | ||||
* | Fixed buffers save long strings as external. | Roberto Ierusalimschy | 2023-11-10 | 1 | -1/+1 |
| | |||||
* | Solving merge issue with use of tables in dump/undump | Roberto Ierusalimschy | 2023-11-08 | 1 | -4/+4 |
| | | | | | | The use of tables in dump/undump to reuse strings did not exist in the version that changed the representation of arrays, so it was not corrected for the new API for tables. | ||||
* | New macro 'getlstr' | Roberto Ierusalimschy | 2023-08-30 | 1 | -7/+8 |
| | | | | Accesses content and length of a 'TString'. | ||||
* | Field 'Proto.is_vararg' uses only one bit | Roberto Ierusalimschy | 2023-08-30 | 1 | -1/+1 |
| | | | | So that the other bits can be used for other purposes. | ||||
* | Opcode in dumps is stored properly aligned | Roberto Ierusalimschy | 2023-08-25 | 1 | -0/+14 |
| | |||||
* | Merge branch 'master' into nextversion | Roberto Ierusalimschy | 2023-06-22 | 1 | -2/+6 |
|\ | |||||
| * | Bug: Loading a corrupted binary file can segfault | Roberto Ierusalimschy | 2023-03-17 | 1 | -2/+6 |
| | | | | | | | | | | The size of the list of upvalue names are stored separated from the size of the list of upvalues, but they share the same array. | ||||
* | | Dump doesn't need to reuse 'source' | Roberto Ierusalimschy | 2022-12-20 | 1 | -6/+6 |
| | | | | | | | | All strings are being reused now, including 'source'. | ||||
* | | Dump/undump reuse strings | Roberto Ierusalimschy | 2022-12-15 | 1 | -6/+31 |
|/ | | | | | A repeated string in a dump is represented as an index to its first occurence, instead of another copy of the string. | ||||
* | Back to old encoding of versions in binary files | Roberto Ierusalimschy | 2020-05-06 | 1 | -1/+1 |
| | | | | | | (Undoing part of commit f53eabeed8.) It is better to keep this encoding stable, so that all Lua versions can read at least the version of a binary file. | ||||
* | Code style in 'ldump'/'lundump'. | Roberto Ierusalimschy | 2020-02-27 | 1 | -76/+76 |
| | | | | | - function names start with lower case; - state is always the first parameter. | ||||
* | Clearer distinction between types and tags | Roberto Ierusalimschy | 2020-01-31 | 1 | -9/+9 |
| | | | | | LUA_T* represents only types; tags (types + Variants) are represented by LUA_V* constants. | ||||
* | Changed internal representation of booleans | Roberto Ierusalimschy | 2020-01-06 | 1 | -4/+1 |
| | | | | | | | Instead of an explicit value (field 'b'), true and false use different tag variants. This avoids reading an extra field and results in more direct code. (Most code that uses booleans needs to distinguish between true and false anyway.) | ||||
* | First implementation of constant propagation | Roberto Ierusalimschy | 2019-07-12 | 1 | -1/+1 |
| | | | | | Local constant variables initialized with compile-time constants are optimized away from the code. | ||||
* | New implementation for constants | Roberto Ierusalimschy | 2019-07-09 | 1 | -0/+1 |
| | | | | | | | | | VLOCAL expressions keep a reference to their corresponding 'Vardesc', and 'Upvaldesc' (for upvalues) has a field 'ro' (read-only). So, it is easier to check whether a variable is read-only. The decoupling in VLOCAL between 'vidx' ('Vardesc' index) and 'sidx' (stack index) should also help the forthcoming implementation of compile-time constant propagation. | ||||
* | Small changes in the header of binary files | Roberto Ierusalimschy | 2019-03-19 | 1 | -3/+1 |
| | | | | | | | | | - LUAC_VERSION is equal to LUA_VERSION_NUM, and it is stored as an int. - 'sizeof(int)' and 'sizeof(size_t)' removed from the header, as the binary format does not depend on these sizes. (It uses its own serialization for unsigned integer values.) | ||||
* | Removed extra information from RCS keyword strings | Roberto Ierusalimschy | 2018-08-23 | 1 | -1/+1 |
| | | | | | Version numbers and dates (mostly wrong) from RCS keyword strings removed from all source files; only the file name are kept. | ||||
* | better names for macros for tags and types. | Roberto Ierusalimschy | 2018-02-26 | 1 | -3/+3 |
| | | | | | rttype -> rawtt; ttyperaw -> withvariant; ttype -> ttypetag; tnov -> ttype | ||||
* | detail (identation of switch) | Roberto Ierusalimschy | 2017-11-28 | 1 | -18/+17 |
| | |||||
* | dumping ints and size_ts compacted | Roberto Ierusalimschy | 2017-06-27 | 1 | -11/+21 |
| | |||||
* | 'lineinfo' in prototypes saved as differences instead of absolute | Roberto Ierusalimschy | 2017-06-27 | 1 | -1/+7 |
| | | | | | | values, so that the array can use bytes instead of ints, reducing its size. (A new array 'abslineinfo' is used when line differences do not fit in a byte.) | ||||
* | avoid calling write function with empty block | Roberto Ierusalimschy | 2015-10-08 | 1 | -2/+2 |
| | |||||
* | avoid expression with side effect (in debug mode) inside 'sizeof' | Roberto Ierusalimschy | 2015-03-30 | 1 | -2/+3 |
| | |||||
* | size of short strings stored in a single byte, to reduce the size | Roberto Ierusalimschy | 2015-01-16 | 1 | -2/+2 |
| | | | | of struct 'TString' | ||||
* | added include for 'lprefix.h', for stuff that must be added before | Roberto Ierusalimschy | 2014-11-02 | 1 | -3/+6 |
| | | | | any other header file | ||||
* | type 'TString' refers directly to the structure inside the union | Roberto Ierusalimschy | 2014-07-18 | 1 | -3/+3 |
| | | | | (union used only for size purposes) | ||||
* | allows different 'source' for each prototype, but inherits it from | Roberto Ierusalimschy | 2014-06-18 | 1 | -10/+17 |
| | | | | | parent when they are equal (only possible case for chunks created by the parser) | ||||
* | added assertion about sources being the same for all protos in a chunk | Roberto Ierusalimschy | 2014-06-18 | 1 | -2/+4 |
| | |||||
* | source for all prototypes must be equal in a chunk; no need to store | Roberto Ierusalimschy | 2014-06-18 | 1 | -2/+2 |
| | | | | each one separated | ||||
* | some details to avoid warnings | Roberto Ierusalimschy | 2014-04-01 | 1 | -2/+2 |
| | |||||
* | missplelling in comments/function names (endianess -> endianness) | Roberto Ierusalimschy | 2014-03-27 | 1 | -2/+2 |
| | |||||
* | make all dumps/loads go trhough Load/DumpVector (so it is easier | Roberto Ierusalimschy | 2014-03-11 | 1 | -4/+10 |
| | | | | to adapt the code to correct endianess, if needed) | ||||
* | keep chunk's headers compatible at least up to LUAC_VERSION (to be | Roberto Ierusalimschy | 2014-03-11 | 1 | -3/+5 |
| | | | | able to detect correctly version mismatches) | ||||
* | "indent -kr -i2 -br -brf -nut" plus a few manual formating | Roberto Ierusalimschy | 2014-03-10 | 1 | -137/+141 |
| | |||||
* | no need to store a full 'size_t' fo the size of (frequent) small strings | Roberto Ierusalimschy | 2014-03-01 | 1 | -11/+11 |
| | |||||
* | more regularity with vectors + sizeof computed by the macros themselves | Roberto Ierusalimschy | 2014-02-28 | 1 | -11/+11 |
| | |||||
* | all chars used in binary dumps are unsigned ('lu_byte') | Roberto Ierusalimschy | 2014-02-28 | 1 | -18/+18 |
| | |||||
* | store number of upvalues of main function in front of the dump, | Roberto Ierusalimschy | 2014-02-27 | 1 | -1/+2 |
| | | | | so that undump can create initial closure before reading its prototype | ||||
* | more explicit handling of headers for binary chunks | Roberto Ierusalimschy | 2014-02-27 | 1 | -4/+12 |
| | |||||
* | dumping and undumping integers | Roberto Ierusalimschy | 2013-04-26 | 1 | -6/+14 |
| | |||||
* | 'ttypenv' -> 'ttnov' | Roberto Ierusalimschy | 2013-04-12 | 1 | -3/+3 |
| |