Commit Graph

26 Commits

Author SHA1 Message Date
Benoit Blanchon
cc077c1b63 Store static strings in a dedicated pool
Because a slot id is smaller than a pointer, this change will ultimately allow reducing the slot size.
2025-07-10 19:17:13 +02:00
Benoit Blanchon
01e49b33b7 Update copyright year 2025-02-24 15:18:26 +01:00
Benoit Blanchon
362201241f Make MemoryPool generic 2024-08-25 14:58:23 +02:00
Benoit Blanchon
f2894552f2 Rename VariantPool to MemoryPool 2024-08-25 14:36:38 +02:00
Benoit Blanchon
55c3b9b3a7 CI: update macOS runner to macos-13 2024-06-18 13:51:40 +02:00
Benoit Blanchon
60fb268d9a Fix UBSAN error "member call does not point to an object of type"
runtime error: member call on address XXX which does not point to an object of type 'Allocator'
XXX: note: object is of type 'SpyingAllocator'

This is due to the fact that some of the compilation units have different library settings, so a different namespace, and therefore a different `Allocator` class.
2024-05-16 17:47:07 +02:00
Benoit Blanchon
72642e3090 Fix compatibility with GCC 4.8
Closes #2045
2024-02-01 21:37:45 +01:00
Benoit Blanchon
0e8a236583 Update copyright year 2024-01-03 08:47:06 +01:00
Benoit Blanchon
9a11d98117 Tests: make allocator assertions more readable 2023-07-26 09:28:21 +02:00
Benoit Blanchon
7a76da3bc7 Tests: rename ControllableAllocator to KillswitchAllocator 2023-07-25 14:46:25 +02:00
Benoit Blanchon
00c9d8680a Remove memoryUsage() 2023-07-24 17:21:25 +02:00
Benoit Blanchon
1a14499612 Preallocate pool list 2023-07-21 17:57:13 +02:00
Benoit Blanchon
42b2840009 Create more memory pools as needed (resolves #1074) 2023-07-18 09:08:55 +02:00
Benoit Blanchon
65c67d317a AllocatorLog: support nulls in deallocate() and reallocate() 2023-07-17 17:28:49 +02:00
Benoit Blanchon
dd46813dc0 Change naming convention from _member to member_ (fixes #1905)
Ported from 31ce648e63
2023-04-21 18:59:48 +02:00
Benoit Blanchon
6eb4f45fb9 Tests: ControllableAllocator controls reallocate() too 2023-04-08 09:18:15 +02:00
Benoit Blanchon
b3132cac3a Tests: add SpyingAllocator::clearLog() 2023-04-07 18:30:31 +02:00
Benoit Blanchon
d95a3bd19a Tests: add TimebombAllocator 2023-04-07 18:28:46 +02:00
Benoit Blanchon
6afa6b647c Test: Support failed allocations in SpyingAllocator 2023-04-03 09:51:10 +02:00
Benoit Blanchon
acd465b365 Test: change ControllableAllocator into a decorator 2023-04-03 09:51:10 +02:00
Benoit Blanchon
e858570afb Test: change SpyingAllocator into a decorator 2023-04-03 09:51:09 +02:00
Benoit Blanchon
a7cdf638e7 Test: move ControllableAllocator 2023-04-03 09:51:09 +02:00
Benoit Blanchon
57810af2ac Test: include deallocated size in allocator's log 2023-04-02 16:47:59 +02:00
Benoit Blanchon
2eb726b744 Test: add AllocatorLog 2023-04-02 16:47:59 +02:00
Benoit Blanchon
912137ccfb Test: share SpyingAllocator 2023-04-01 10:34:48 +02:00
Benoit Blanchon
5faa3df43f MemoryPool calls the Allocator directly 2023-03-20 15:03:09 +01:00