木头云
d65eafe86a
fix(uninitialized): Fix MSVC compilation error with std::map node construction
...
The issue occurs when container_allocator calls ipc::construct<T>() with no arguments.
MSVC and GCC have different behaviors regarding std::is_constructible for std::map's
internal node type.
Solution:
- Add explicit overload for zero-argument construct() using value initialization T()
- Separate overloads for one or more arguments to avoid SFINAE ambiguity
- This ensures MSVC uses direct initialization T() instead of aggregate initialization T{}
Fixes compilation error on Visual Studio 2017:
error C2512: no appropriate default constructor available
note: Invalid aggregate initialization
2025-12-01 07:31:15 +00:00
mutouyun
32c2be29a9
Refactoring the generic memory allocator
2025-03-09 18:02:51 +08:00
mutouyun
2d38a6a6e7
Reimplement the allocator required for the container type with $new
2025-03-09 18:02:51 +08:00
mutouyun
831225f763
Use $new instead of alloc
2025-03-09 18:02:51 +08:00
mutouyun
db109165f3
Simplify the implementation of memory allocation management
2025-03-09 18:02:51 +08:00
mutouyun
180920968f
The memory allocator supports runtime dynamic size memory allocation
2025-03-09 18:02:51 +08:00
mutouyun
89e9f87f36
Add $new
2025-03-09 18:02:51 +08:00
mutouyun
edc1e80585
Add block_pool
2025-03-09 18:02:51 +08:00
mutouyun
3571fa58c8
Adjust the allocator name
2025-03-09 18:02:51 +08:00
mutouyun
70a1f68f01
Optimize memory_resource & add monotonic_buffer_resource
2025-03-09 18:02:51 +08:00
mutouyun
b8d01ddf68
Add intrusive_stack
2025-03-09 18:02:51 +08:00
mutouyun
40eaab7310
Add allocator and rewrite allocator_wrapper
2025-03-09 18:02:51 +08:00
mutouyun
48d4d6111d
Start refactoring memory management, adding memory_resource
2025-03-09 18:02:51 +08:00
mutouyun
85bf8263fb
Add system
2025-03-09 18:02:51 +08:00
mutouyun
6db5845a45
Add result
2025-03-09 18:02:51 +08:00
mutouyun
6c068f7ba4
IPC_EXPORT => LIBIPC_EXPORT
2025-03-09 18:02:51 +08:00
mutouyun
d2ba9dce52
Add log
2025-03-09 18:02:51 +08:00
mutouyun
72ec8ee42f
Add error
2025-03-09 18:02:51 +08:00
mutouyun
e30ab84ccc
Added fmt support for byte
2025-03-09 18:02:51 +08:00
mutouyun
e333bc754e
Add fmt
2025-03-09 18:02:50 +08:00
mutouyun
a2d82ec6f0
Add codecvt
2025-03-09 18:02:50 +08:00
mutouyun
54f05e9536
libimp => libipc
2025-03-09 18:02:50 +08:00
mutouyun
e5546179e2
Add nameof & scope_exit
2025-03-09 18:02:50 +08:00
mutouyun
e5a56f02f1
Move the export.h file to the imp directory
2025-03-09 18:02:50 +08:00
mutouyun
ed8f9d06a6
Add expected
2025-03-09 18:02:50 +08:00
mutouyun
67776aea65
Add imp for subsequent refactoring
2025-03-09 18:02:50 +08:00
mutouyun
5e5b347636
Complete the implementation of the clean interface and add unit tests
2024-12-01 19:06:50 +08:00
mutouyun
28fdf17279
Added cleanup interfaces for ipc chan
2024-12-01 17:49:34 +08:00
mutouyun
e1f377d7f6
Added a cleanup interface for the synchronization facilities
2024-11-17 17:39:03 +08:00
mutouyun
5071fb5db6
Added a cleanup interface for shared memory handles
2024-11-17 17:35:29 +08:00
mutouyun
fab3f6fffe
Add a user interface with a custom name prefix.
2023-10-28 16:44:16 +08:00
mutouyun
a46773bbd5
微调注释
2023-10-28 16:44:16 +08:00
mutouyun
162011d4b4
修正全局变量初始化时序问题导致的内存访问异常
2023-02-25 16:30:11 +08:00
mutouyun
d946ad0948
modify interface of sync.condition
2021-10-23 17:27:08 +08:00
mutouyun
f6bd578c8a
reduce the number of recheck times for the sleep function
2021-09-20 23:29:30 +08:00
mutouyun
ed8b1fd608
fix some bugs for linux-mutex
2021-09-20 20:31:08 +08:00
mutouyun
04fda1cc3d
use sync to refactor waiter
2021-09-20 15:59:44 +08:00
mutouyun
0cccdac868
merge issue-61; add condition for linux
2021-09-19 17:21:39 +08:00
mutouyun
d37a6740ea
add ut for sync::semaphore
2021-09-12 21:48:22 +08:00
mutouyun
d0e2a4d80c
add semaphore for win
2021-09-12 15:59:44 +08:00
木头云
78be14be37
Merge branch 'develop' into master
2021-08-29 11:05:24 +08:00
木头云
d80bea9b5d
fix: unexpected crash
...
An unexpected crash caused by an unconnected exit.
2021-08-23 13:10:03 +08:00
mutouyun
98a3449865
fix some bugs, adjust the test cases
2021-07-11 13:13:30 +08:00
mutouyun
69e1586b5a
remove tls
2021-07-10 14:22:31 +08:00
mutouyun
cca4664e84
option(LIBIPC_BUILD_SHARED_LIBS 'Build shared libraries (DLLs).' OFF)
2021-07-10 13:50:46 +08:00
mutouyun
455c0b479d
add sync::mutex for windows/linux
2021-06-20 23:50:39 +08:00
木头云
681f8e6736
add large_msg_align for cache memory alignment
2021-05-07 15:48:31 +08:00
mutouyun
6163618433
针对不同类型的策略,增加不同的sender/receiver个数检查。
...
- is_multi_producer:sender无限制;否则仅允许一个
- is_multi_consumer:receiver个数上限依赖is_broadcast指定;否则仅允许一个
- is_broadcast:receiver个数上限为32(uint_t<32>位数);否则无限制(uint_t<32>大小)
行为变更:
1. 在连接时根据模式检查sender/receiver是否超出上限,超出则返回false
2. 在send时确认是否允许发送(对receiver模式来说,send之前不会尝试确认sender个数)
3. 修正若干bug
2021-01-03 12:52:03 +08:00
mutouyun
af6ac84110
add comments
2021-01-01 12:39:32 +08:00
mutouyun
2255ae685a
调整接口;添加 msg_que demo
2020-09-20 14:55:47 +08:00