aboutsummaryrefslogtreecommitdiff
path: root/src/keeper.h (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Change linda:limit()Benoit Germain2024-06-261-0/+1
| | | | | | * read the current limit of a key if no limit is provided * "unlimited" is to be used to clear the limit * fix linda:set() not ignoring the limit
* More char* -> std::string_view conversionsBenoit Germain2024-06-141-2/+2
|
* More fixes to make clang happyBenoit Germain2024-06-141-1/+1
|
* All Lua headers included just once in _pch.hBenoit Germain2024-06-111-9/+0
|
* Use a precompiled header to speed up the buildBenoit Germain2024-06-071-5/+0
|
* Code boyscoutingBenoit Germain2024-06-071-1/+1
|
* Moved keeper functions aroundBenoit Germain2024-06-041-6/+6
|
* Keeper management modernisation and improvementsBenoit Germain2024-05-301-5/+48
| | | | | | | * use a std::variant to manage the distinction between one or more keeper states. Use std::unique_ptr<Keeper[]> to manage the multiple keeper case. * setting "nb_keepers" renamed "nb_user_keepers", to indicate these are in addition to internal keeper #0 used for timers. * stricter lanes.linda() argument checking. group is imposed if more than one keeper is used. * more tests
* Fix __lanesignoreBenoit Germain2024-05-221-1/+0
|
* Shuffling code aroundBenoit Germain2024-05-141-3/+2
|
* Progressively applying the coding rulesBenoit Germain2024-05-131-1/+1
|
* Move InterCopyContext implementation in a separate fileBenoit Germain2024-05-131-1/+0
|
* Progressively applying the coding rulesBenoit Germain2024-05-021-1/+1
|
* Progressively applying the coding rulesBenoit Germain2024-04-301-3/+3
|
* Progressively applying the coding rulesBenoit Germain2024-04-291-2/+2
|
* Function parameters L → L_Benoit Germain2024-04-291-11/+11
|
* All headers reformatted with updated clang-format settingsBenoit Germain2024-04-291-1/+2
|
* Formalize a few coding style rules, start to enforce them for constantsBenoit Germain2024-04-261-2/+2
|
* C++ integration: cleanup in Linda/Keeper interactionBenoit Germain2024-04-251-5/+2
|
* C++ migration: using KeeperState = Unique<lua_State*>Benoit Germain2024-04-241-3/+5
|
* C++ migration: split UniqueKey into UniqueKey+RegistryUniqueKeyBenoit Germain2024-04-241-1/+1
|
* C++ migration: deep userdata API rework. bye bye idfunc, hello DeepFactoryBenoit Germain2024-04-151-1/+1
|
* C++ migration: keeper_call returns a std::optionalBenoit Germain2024-04-151-2/+4
|
* C++ migration: [[nodiscard]] everywhere. still have to check all std::ignoreBenoit Germain2024-04-091-13/+13
|
* C++ migration: use strong type safety for source and destination states in ↵Benoit Germain2024-04-091-1/+1
| | | | transfer functions
* C++ migration: still more threading code cleanup. 'sudo' global moved in the ↵Benoit Germain2024-04-091-1/+1
| | | | Universe
* C++ migration: use std::jthread, std::condition_variable, std::chrono.Benoit Germain2024-04-081-4/+6
| | | | | | | | win32 pthread support is gone new setting configure.shutdown_mode for cancellation of free-running threads at shutdown. no more hard thread termination! If a thread doesn't cooperate, an error is raised. lane.status "killed" is gone lane:cancel can't force-kill.
* Enable manual control of GC inside keeper statesBenoit Germain2024-04-051-0/+1
|
* C++ migration: all enums are enum classBenoit Germain2024-03-291-1/+1
|
* C++ migration: Linda is a proper class with overloaded operator new/deleteBenoit Germain2024-03-281-4/+4
|
* C++ migration: STACK_GROW is no longer a macro, sanitized and fixed warnings ↵Benoit Germain2024-03-221-21/+21
| | | | in keeper.cpp
* C++ migration: removed most typedef, removed uint_tBenoit Germain2024-03-201-10/+6
|
* C++ migration: UniqueKeyBenoit Germain2024-03-201-1/+1
|
* C++ migration: buildfixesBenoit Germain2024-03-191-4/+8
| | | | Essentially, buildfixes when compiling as C++, plus properly marking public API as extern "C"
* new .internal_allocator configuration IUNTESTED)Benoit Germain2023-08-091-1/+1
| | | | new configuration option .internal_allocator to help LuaJIT users. THIS IS YET UNTESTED, USE AT YOUR OWN RISKS.
* Changed all indentations to all whitespacesBenoit Germain2022-02-071-5/+5
| | | | Tabs mess up alignment of stack contents comments, so I'm done with them.
* Make sure any linda operation that can raise an error won't ever leave a ↵Benoit Germain2018-11-081-0/+1
| | | | mutex unreleased
* Improve LuaJIT-x64 compatibilityBenoit Germain2018-10-301-1/+3
| | | | | Restrict internal "light userdata constants" to 47 significant bits when compiling against LuaJIT-x64
* More MinGW buildfixes (I hope)Benoit Germain2018-10-251-1/+3
|
* Fix Lanes build by reorganizing types around a bitBenoit Germain2018-10-251-7/+16
|
* Fix 64 bits compilation warningsBenoit Germain2016-11-211-3/+3
|
* linda:send() improvementsBenoit Germain2014-02-271-0/+2
| | | | | | | | | * Bumped version to 3.9.3 * new exposed variable linda.null that exposes the internal NIL_SENTINEL marker * linda:send() interprets send key linda.null as authorization to silently send a single nil when not provided with anything to send (useful when sending results of a function that can return nothing)
* Multiverse compatibilityBenoit Germain2014-02-261-8/+14
| | | | | | | | | | | | | | | * bumped version to 3.9.2 * Internal rework: the whole Lanes engine now works "per universe" to allow concurrent Lanes execution in more than one embedded master state * this universe is a full userdata created in the master state, selfdestruct_gc is the __gc for this userdata * most of what was initialized only once is now per-universe * Fixed potential crashes at desinit if problems occur during keeper states initialisation * Fixed require() not always serialized properly * Raise an error instead of crashing on deep userdata prelude memory allocation failure * Added forgotten mutex desinitialisation at universe shutdown
* Lanes init crash fixBenoit Germain2014-02-181-9/+2
| | | | | | | | | | | * bumped version to 3.9.1 * keeper array is allocated with master state's alloc function instead of malloc()/free() * prevent application crash when specifying a very large number of keepers in the configuration options * removed some keeper desinit legacy dead code * any error occuring during one-time inits is raised outside the one-time mutex protected code region
* lindas can have a group for keeper state assignation controlBenoit Germain2014-02-171-3/+4
|
* get()/set() improvementsBenoit Germain2014-01-201-1/+1
| | | | | | | * bumped version to 3.8.0 * linda:set() accepts multiple values to set in the specified slot * linda:get() accepts an optional count to peek several values at once * nil values are now converted just as in send()/receive()
* version 3.7.0Benoit Germain2013-10-111-1/+1
| | | | | | | | | | | | * fix lanes.threads() not being available in a lane where lanes.configure() settings didn't contain track_lanes although the initial configure() call did. * require "lanes".configure() sequence is only necessary at the first require "lanes". * fix a crash at application shutdown where in some situations we could deinitialize the protected allocator mutex while a lane was still using it. * fix timers broken by change 69
* Reduce memory footprint, simplify module order setup in conjuction with ↵Benoit Germain2013-09-261-11/+0
| | | | | | | | | | | | Lanes, and send over native functions a bit faster as well * Lanes no longer has to internally require modules inside the keeper states because they no longer need a lookup database. the lookup name is stored as-is and actually converted in the destination state * optimisation: bypass cache when sending native functions over * removed all the KEEPER_MODEL_LUA code, as it can no longer work anyway
* version 3.5.0Benoit Germain2013-01-301-1/+1
| | | | | | | | | | | | | | * new: API lanes.require(), use it instead of regular require() for modules that export C functions you need to send over. * new: lanes no longer require 'lanes.core' by default in every created state. Use {required={"lanes.core"}} if you need to transfer lanes functions. * internal: because of the above, reworked the timer implementation to remove upvalue-dependency on lanes.core * new: API lanes.timer_lane, to be able to operate on timer lane if need be * improved: if a module is a full userdata, scan its metatable for function database population * improved: on_state_create can be a Lua function * changed: on_state_create is called after the base libraries are loaded * package[loaders|searchers] is no longer transfered as function naming depends on slot order * internal: changed separator from '.' to '/' in lookup databases to be able to distinguish search levels and dot coming from module names * added some mode debug spew * updated tests to reflect the above changes
* version 3.4.3v3.4.3Benoit Germain2013-01-241-1/+1
| | | | | | | | | | | * raise an error if lane generator libs specification contains a lib more than once * bit32 is a valid lib name in the libs specification (silently ignored by the Lua 5.1 build) * improved lanes.nameof to search inside table- and userdata- metatables for an object's name * fixed an unwarranted error when trying to discover a function name upon a failed transfer * contents of package.[path,cpath,preload,loaders|searchers] are pulled *only once* inside keeper states at initialisation * Lua function upvalues equal to the global environment aren't copied by value, but bound to the destination's global environment especially useful for Lua 5.2 _ENV * fixed loading of base libraries that didn't create the global tables when built for Lua 5.2