Skip to content

Add frailbox buddy allocator#28

Open
Soengkit wants to merge 1 commit into
GautamKumarOffical:mainfrom
Soengkit:soengkit/buddy-allocator-4
Open

Add frailbox buddy allocator#28
Soengkit wants to merge 1 commit into
GautamKumarOffical:mainfrom
Soengkit:soengkit/buddy-allocator-4

Conversation

@Soengkit

Copy link
Copy Markdown

Summary

  • Adds a frailbox buddy allocator with 64-byte minimum blocks, power-of-two splitting, coalescing on free, and allocation/free statistics.
  • Adds a focused test binary for allocator behavior and stats.
  • Keeps the frailbox build portable for local validation while preserving Linux hardening flags.

Fixes #4.

Testing

  • make -C frailbox clean
  • python3 build.py -m frailbox (frailbox: PASS)
  • make -C frailbox test-buddy
  • gcc -Wall -Wextra -Wpedantic -std=c2x -O1 -g -fsanitize=address,undefined -Iinclude tests/test_buddy.c src/buddy.c -o build/test_buddy_san && ./build/test_buddy_san
  • git diff --check
  • python3 -m json.tool diagnostic/build-2b54872c.json

Note: build.py created diagnostic/build-2b54872c.json, but the encrypted .logd artifact could not be produced because the bundled tools/encryptly/macos-arm64/encryptly executable exits with status 1 in this environment. The JSON records the successful frailbox build and the .logd failure.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[$35 BOUNTY] [C] Buddy allocator for frailbox

1 participant