Commit graph

33 commits

Author SHA1 Message Date
Nekotekina 6b40d69a8f Introduce coroutine support (util/coro.hpp)
Implement coroutine types `lazy` and `generator` in stx namespace.
Implement fs::list_dir_recursively.
2021-12-07 13:04:10 +03:00
DH 56d922999f Fixed debug build compilation errors
const_str_t constructor without arguments shoud be constexpr for usage as default initializer in constexpr functions
2021-12-02 21:36:57 +03:00
Eladash 0628a5d931 serialization.hpp: Fixes 2021-06-11 08:59:02 +03:00
Nekotekina 696be6aacd Implement fmt::ensure (assert-like with formatted message) + fmt::tie
Arguments should be provided via fmt::tie() due to some limitations.
Allow to specify simple message (non-formatting) for plain ::ensure().
Remove redundant function for narrow error.
2021-06-10 21:16:57 +03:00
Nekotekina 2d3fe7ce1c fixed_typemap.hpp: add range iterator
Remove recently added functions.
2021-06-09 00:07:15 +03:00
Eladash 2169e8d935 Implement serialization.hpp, remove cereal submodule
Bump RSX capture version, use new serializer.
2021-06-07 16:28:42 +03:00
Nekotekina f5e529db61 shared_ptr.hpp: don't use fake objects
This lifts the limitation for casting with abstract classes.
Use new C++20 feature (constexpr allocator) to test viability.
Add SamePtr concept to types.hpp
2021-05-30 15:07:17 +03:00
Nekotekina eec9578619 types.hpp: add PtrCastable concept 2021-05-29 18:32:13 +03:00
Nekotekina 2491aad6f2 types.hpp: implement min_v<>, max_v<>, SignedInt, UnsignedInt, FPInt concepts
Restrict smax to only work with signed values for consistency.
Cleanup <climits> includes.
Cleanup <limits> includes.
2021-05-23 19:43:51 +03:00
Nekotekina 4b239a0b87 types.hpp: rewrite _u16-_u64 suffixes
_u48 is unused and gone, blends into _u64.
2021-05-23 07:33:54 +03:00
Nekotekina 2768727e2f types.hpp: replace custom std::bit_cast
Remove memcpy version.
Use builtin instead.
2021-05-23 07:33:19 +03:00
Nekotekina 160b131de3 types.hpp: implement smin, smax, amin, amax
Rewritten the following global utility constants:
`umax` returns max number, restricted to unsigned.
`smax` returns max signed number, restricted to integrals.
`smin` returns min signed number, restricted to signed.
`amin` returns smin or zero, less restricted.
`amax` returns smax or umax, less restricted.

Fix operators == and <=> for synthesized rel-ops.
2021-05-22 12:10:57 +03:00
Nekotekina 04cac6cd33 logs.hpp: refactoring (logs::message)
Make .error/.warning/... callable objects which can be pointed to.
Make .always() more hard to access.
Memory layout optimizations.
2021-05-20 01:08:32 +03:00
Nekotekina f0ad20a250 Implement const_str_t<> helper 2021-05-13 10:23:33 +03:00
Nekotekina 327c000c82 Implement s128 type (based on u128) 2021-05-04 18:02:52 +03:00
Nekotekina 5724d2d4c7 Simplify umax
Add operator less and conversion operator.
2021-04-29 12:21:12 +03:00
Nekotekina 4d9a167f56 u128: add multiplication support (for MSVC) 2021-04-25 18:17:38 +03:00
Nekotekina 7dae376646 Implement fill_array() utility 2021-04-19 12:33:32 +03:00
David Carlier b6732fbae9 MacOs build fix proposal.
Made on Big Sur, removing few unnecessary old specifics.
Build with LLVM homebrew.
2021-04-18 17:18:09 +03:00
Eladash 67e2e154fa Replace simple_type with std::common_type 2021-04-17 10:27:55 +03:00
Nekotekina 5bdd1cf837 Remove some redundant code
Potential fix for future warnings.
2021-03-09 03:09:50 +03:00
Nekotekina 87af905018 Enable -Wunused-parameter 2021-03-06 18:07:08 +03:00
Nekotekina 4f8cac731b Fix SAFE_BUFFERS attribute for GCC 2021-02-09 12:33:50 +03:00
Nekotekina a8e0d261b7 types.hpp: more cleanup
Also fix compilation.
2020-12-22 19:08:09 +03:00
Nekotekina 43a58df8a0 Butcher narrow cast a little (don't print value).
Also remove some forward declarations from util/types.hpp
If they don't work properly, it's easier to remove them.
2020-12-22 14:32:30 +03:00
Nekotekina bd269bccaf types.hpp: remove intrinsic includes
Replace v128 with u128 in some places.
Removed some unused files.
2020-12-21 21:11:25 +03:00
Nekotekina eec11bfba9 Move align helpers to util/asm.hpp
Also add some files:
GLTextureCache.cpp
VKTextureCache.cpp
2020-12-18 18:07:42 +03:00
Nekotekina fb29933d3d Add usz alias for std::size_t 2020-12-18 12:23:53 +03:00
Nekotekina 360c4d1554 Simplify f16 type 2020-12-18 12:23:53 +03:00
Nekotekina 4cfa9b11f3 Move busy_wait() to asm.hpp 2020-12-18 12:23:53 +03:00
Nekotekina e321765c54 Split BEType.h to util/v128.hpp and util/to_endian.hpp 2020-12-13 16:34:45 +03:00
Nekotekina a6a5292cd7 Use uptr (std::uintptr_t alias) 2020-12-12 16:29:55 +03:00
Nekotekina b59f142d4e Move types.h to util/types.hpp 2020-12-12 15:12:01 +03:00
Renamed from Utilities/types.h (Browse further)