Commit Graph

2667 Commits

Author SHA1 Message Date
Леонид Юрьев (Leonid Yuriev)
8a013763b1 mdbx: preliminary-draft of mdbx_get_cached() (to get acquainted with the new feature and API). 2025-11-12 21:37:54 +03:00
Leonid Yuriev
0c294c6386 mdbx-windows: refine assertion handling for debug builds. 2025-11-12 21:37:54 +03:00
Леонид Юрьев (Leonid Yuriev)
2f33449f2a mdbx-windows: use timeouts instead of retries for file locking. 2025-11-12 17:54:57 +03:00
Leonid Yuriev
aac890314c mdbx-windows: refine assertion handling for debug builds. 2025-11-12 17:54:40 +03:00
Leonid Yuriev
cfb9a55ebc mdbx: fix tls-dtor in case library unloading with an incomplete initialized env instance. 2025-11-10 21:38:06 +03:00
Леонид Юрьев (Leonid Yuriev)
f2f2cc3b40 mdbx: add workaround for ext4 fast-commit bug. 2025-11-07 21:17:18 +03:00
Леонид Юрьев (Leonid Yuriev)
a17e041830 mdbx: refactoring fetch/refresh/create/open tables and DBI-handles.
The (rare, quirky) scenario of recreating a previously opened and used table/DBI-handle
after it has been deleted by another process is now supported.
2025-11-06 10:26:28 +03:00
Леонид Юрьев (Leonid Yuriev)
3813333b28 mdbx: clean reader locktable by rthc_drown() only when no inprocess-neighbor. 2025-11-05 14:51:44 +03:00
Леонид Юрьев (Leonid Yuriev)
7628369819 mdbx: fix dummy coverity-scan warning. 2025-11-05 14:51:44 +03:00
Леонид Юрьев (Leonid Yuriev)
3bec0dbc6e mdbx: ending the transaction and return an error in case reader-slot was evicted. 2025-11-05 14:51:44 +03:00
Леонид Юрьев (Leonid Yuriev)
c07cfd30e1 mdbx: refine description of MDBX_BAD_RSLOT. 2025-11-05 14:51:44 +03:00
Леонид Юрьев (Leonid Yuriev)
ffb822cb61 mdbx: refine internal env_info_sys(). 2025-11-05 01:20:10 +03:00
Леонид Юрьев (Leonid Yuriev)
7f8e3c8781 mdbx: more refining chk-output. 2025-11-05 01:20:10 +03:00
Леонид Юрьев (Leonid Yuriev)
916e6e817d mdbx: refine handling sys_allocation_granularity. 2025-11-05 01:20:10 +03:00
Леонид Юрьев (Leonid Yuriev)
bf3f9be98a mdbx: using clang-format-22. 2025-11-05 01:20:10 +03:00
Леонид Юрьев (Leonid Yuriev)
7b112df36e mdbx: fix unused functions warning from modern clang. 2025-11-05 01:20:10 +03:00
Леонид Юрьев (Leonid Yuriev)
baf3eb267f mdbx: fix extra type-casting typo. 2025-11-05 01:20:10 +03:00
Леонид Юрьев (Leonid Yuriev)
0b24446e8e mdbx: fix typo assertion-failure regression. 2025-11-05 01:20:09 +03:00
Леонид Юрьев (Leonid Yuriev)
0838af8f3d mdbx-tools: cleanup mdbx_stat from float-point. 2025-11-05 01:20:09 +03:00
Леонид Юрьев (Leonid Yuriev)
255a431bc1 mdbx-tools: cleanup mdbx_chk from float-point. 2025-11-05 01:20:09 +03:00
Леонид Юрьев (Leonid Yuriev)
dccc807aff mdbx: add float-point-free mdbx_ratio2percents() and mdbx_ratio2digits() to API for tools. 2025-11-05 01:20:09 +03:00
Леонид Юрьев (Leonid Yuriev)
8b2aa9fb65 mdbx: add getenv_bool() and fetching debug-options from the process environment. 2025-11-05 01:20:09 +03:00
Леонид Юрьев (Leonid Yuriev)
0d9b59dda1 mdbx: add osal_strcasecmp() and osal_strncasecmp(). 2025-11-05 01:20:09 +03:00
Леонид Юрьев (Leonid Yuriev)
65184ff73b mdbx: rework/refine chk reporting tree/pages/tables information (squashed). 2025-11-05 01:20:09 +03:00
Леонид Юрьев (Leonid Yuriev)
b8f4d6ccdd mdbx: rename "other" pages to "broken" in chk-output. 2025-11-05 01:20:09 +03:00
Леонид Юрьев (Leonid Yuriev)
c466dea250 mdbx: clean library core from using a float-point. 2025-11-05 01:20:09 +03:00
Леонид Юрьев (Leonid Yuriev)
1cf65cd880 mdbx: refine handling the MDBX_WITHOUT_MSVC_CRT option. 2025-11-05 01:20:09 +03:00
Леонид Юрьев (Leonid Yuriev)
7e43e14c7b mdbx: more info-output from mdbx_env_chk().
Print system io-block size, unified-page-cache block size, space allocated for the dxb-file in a filesystem.
2025-11-05 01:20:09 +03:00
Леонид Юрьев (Leonid Yuriev)
410bbbd9a5 mdbx: extending MDBX_envinfo. 2025-11-05 01:20:09 +03:00
Леонид Юрьев (Leonid Yuriev)
06b6739e68 mdbx: fix assertion inside gc_alloc_ex(). 2025-11-05 01:20:09 +03:00
Леонид Юрьев (Leonid Yuriev)
045968b46a mdbx: fix txn_basis_snapshot(). 2025-11-05 01:20:09 +03:00
Леонид Юрьев (Leonid Yuriev)
60d5ba9790 mdbx: minor workaround for HarmonyOS's bug.
The libc from HarmonyOS SDK erroneously defines `EOWNERDEAD`,
`_POSIX_THREAD_PROCESS_SHARED >= 200809` and `PTHREAD_MUTEX_ROBUST` but
the same time doesn't provide `pthread_mutexattr_setrobust()` and
`pthread_mutex_consistent()`.

This commit add a minor workaround for such bug for successful building
without explicitly defining `MDBX_LOCKING=2001`.

Related to https://github.com/erthink/libmdbx/issues/285, https://github.com/vorot93/libmdbx-rs/issues/41, https://github.com/isar-community/isar-community/issues/28.
2025-10-29 00:10:06 +03:00
Leonid Yuriev
43c4503a77 mdbx: minor clean-up tautology in assertion. 2025-10-26 18:02:04 +03:00
Leonid Yuriev
aafe0f0fba mdbx: use Windows10 SDK by default. 2025-10-26 18:02:04 +03:00
Леонид Юрьев (Leonid Yuriev)
dc5f119de1 mdbx-cmake: support of MDBX_USE_FALLOCATE for CMake and Conan. 2025-10-20 12:52:36 +03:00
Леонид Юрьев (Leonid Yuriev)
2b0bfb9eea mdbx: revert/drop MDBX_DBG_NOFALLOC_INCORE and introduce osal_fsetsize().
This fixes regression after the 2a7f460345 as when
a DXB file remains longer than necessary on Mac or Linux when building without `_GNU_SOURCE`.
2025-10-18 12:36:29 +03:00
Леонид Юрьев (Leonid Yuriev)
ee6a045f17 mdbx: add MDBX_DBG_NOFALLOC_INCORE.
It is a workaround to sporadic test failures due to lack of space in tmpfs and/or free memory.
2025-10-09 23:26:18 +03:00
Леонид Юрьев (Leonid Yuriev)
bdbbf3db68 mdbx: fix rare/specific unexpected assertion failure bmi > 0 on 32-bit debug builds. 2025-09-11 19:06:14 +03:00
Леонид Юрьев (Leonid Yuriev)
f2a5ca26a6 mdbx: using atomic_yield() inside safe64_read() retry loop. 2025-09-09 22:26:40 +03:00
Леонид Юрьев (Leonid Yuriev)
4adba731f5 mdbx: introduce internal lck_setlk_with3retries() as workaround EAGAIN on Android. 2025-09-08 10:46:30 +03:00
Леонид Юрьев (Leonid Yuriev)
815d483803 mdbx: extract internal osal_yield(). 2025-09-08 10:32:17 +03:00
Леонид Юрьев (Leonid Yuriev)
74ef6502e3 mdbx-windows: move the LockFileEx(LOCKFILE_FAIL_IMMEDIATELY) repeats for using in all cases. 2025-09-07 13:33:13 +03:00
Леонид Юрьев (Leonid Yuriev)
cd27aa017f mdbx: add internal txn_basis_snapshot(). 2025-09-07 00:28:58 +03:00
Леонид Юрьев (Leonid Yuriev)
222d8f13f8 mdbx: extract internal check_key(). 2025-09-07 00:28:29 +03:00
Леонид Юрьев (Leonid Yuriev)
d7e3c2a0fc mdbx: add internal ptr2page(). 2025-09-07 00:28:22 +03:00
Леонид Юрьев (Leonid Yuriev)
eee21feba7 mdbx: rename internal page2payload() and payload2page(). 2025-09-07 00:28:02 +03:00
Леонид Юрьев (Leonid Yuriev)
9ad4fe8f96 mdbx: refine ceil/rounding to be perfectly close to system allocation granularity. 2025-09-03 22:50:29 +03:00
Леонид Юрьев (Leonid Yuriev)
9c0886972d mdbx: alter the globals.sys_allocation_granularity guessing. 2025-09-03 21:38:05 +03:00
Леонид Юрьев (Leonid Yuriev)
26d5ef6b2d mdbx: add xyz_ceil2ag_xyz(), i.e. ceiling to system allocation granularity. 2025-09-03 21:38:05 +03:00
Леонид Юрьев (Leonid Yuriev)
41abfffeb3 mdbx: rename xyz_align2os_xyz() to xyz_ceil2sp_xyz() (cosmetics). 2025-09-03 20:18:41 +03:00