https://github.com/petbrain/libpussy
Pet's collection of essentials.
https://github.com/petbrain/libpussy
allocators arena-allocator bitmap-allocator bitmap-dump hexdump ringbuffer synchronization timespec
Last synced: 5 months ago
JSON representation
Pet's collection of essentials.
- Host: GitHub
- URL: https://github.com/petbrain/libpussy
- Owner: petbrain
- License: other
- Created: 2025-04-20T11:15:29.000Z (8 months ago)
- Default Branch: main
- Last Pushed: 2025-08-10T15:34:58.000Z (5 months ago)
- Last Synced: 2025-08-10T17:26:31.105Z (5 months ago)
- Topics: allocators, arena-allocator, bitmap-allocator, bitmap-dump, hexdump, ringbuffer, synchronization, timespec
- Language: C
- Homepage:
- Size: 28.3 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# libpussy: collection of basic things
Everything is work in progress and subject to change.
## Allocators
### arena allocator
[arena.h](include/arena.h)
Uses `mmap` as underlying allocator.
### pet allocator
[allocator.h](include/allocator.h)
The main allocator is bitmap-based. Other twos are for debugging purposes:
* wrapper for malloc/realloc/free
* debug allocator that detects bubblewrap corruption around allocated blocks
## Dump functions
[dump.h](include/dump.h)
Hex and bitmap dump functions.
## MMarray
[mmarray.h](include/mmarray.h)
Simple dynamic array using `mmap` as allocator.
## Ring buffers
[ringbuffer.h](include/ringbuffer.h)
Basic and thread-safe implementations of ring buffer.
Using `mmap` as allocator.
## Synchronization primitives
[sync.h](include/sync.h)
Synchronization primitives based on condition variable.
Event implementation only for now.
## Timespec utils
[timespec.h](include/timespec.h)
Utilities that work with `struct timespec`.