Problem
O1HeapPoolTest.OverAlignedAllocationsAreServedAtMaxAlignment fails in CI (native LLVM/GCC on ubuntu). The test requests allocate(1, 2 * alignof(std::max_align_t)) and expects a pointer aligned at alignof(max_align_t).
On glibc alignof(max_align_t)==16, so the request is 32. O1HeapPool::allocate rejects alignment > O1HEAP_ALIGNMENT (== 16 on 64-bit) with nullptr (modules/jarnax/source/cyphal/O1HeapPool.cpp:27), so the test assert pointer != nullptr fails.
On macOS/arm64 alignof(max_align_t)==8, the request computes to 16, the guard does not trip and the test passes locally — hence it only surfaced in CI.
Expected
The test comment documents the intended behavior: o1heap does not reject alignment requests beyond max_align_t; it serves the block at its own (O1HEAP_ALIGNMENT) granularity. The guard contradicts that.
Fix
Drop the alignment > O1HEAP_ALIGNMENT rejection in O1HeapPool::allocate so over-aligned requests are served at the pool's granularity; add/extend a unit test that exercises an alignment strictly greater than O1HEAP_ALIGNMENT, asserting the returned pointer is aligned at O1HEAP_ALIGNMENT.
Problem
O1HeapPoolTest.OverAlignedAllocationsAreServedAtMaxAlignmentfails in CI (native LLVM/GCC on ubuntu). The test requestsallocate(1, 2 * alignof(std::max_align_t))and expects a pointer aligned atalignof(max_align_t).On glibc
alignof(max_align_t)==16, so the request is 32.O1HeapPool::allocaterejectsalignment > O1HEAP_ALIGNMENT(== 16 on 64-bit) withnullptr(modules/jarnax/source/cyphal/O1HeapPool.cpp:27), so the test assertpointer != nullptrfails.On macOS/arm64
alignof(max_align_t)==8, the request computes to 16, the guard does not trip and the test passes locally — hence it only surfaced in CI.Expected
The test comment documents the intended behavior: o1heap does not reject alignment requests beyond max_align_t; it serves the block at its own (O1HEAP_ALIGNMENT) granularity. The guard contradicts that.
Fix
Drop the
alignment > O1HEAP_ALIGNMENTrejection in O1HeapPool::allocate so over-aligned requests are served at the pool's granularity; add/extend a unit test that exercises an alignment strictly greater than O1HEAP_ALIGNMENT, asserting the returned pointer is aligned at O1HEAP_ALIGNMENT.