sily
parent
13562d35ff
commit
2831e25ba5
|
@ -1,5 +1,5 @@
|
||||||
cmake_minimum_required(VERSION 3.25)
|
cmake_minimum_required(VERSION 3.25)
|
||||||
project(blt-gp VERSION 0.0.9)
|
project(blt-gp VERSION 0.0.10)
|
||||||
|
|
||||||
option(ENABLE_ADDRSAN "Enable the address sanitizer" OFF)
|
option(ENABLE_ADDRSAN "Enable the address sanitizer" OFF)
|
||||||
option(ENABLE_UBSAN "Enable the ub sanitizer" OFF)
|
option(ENABLE_UBSAN "Enable the ub sanitizer" OFF)
|
||||||
|
|
|
@ -271,9 +271,20 @@ void test()
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
struct silly
|
||||||
|
{
|
||||||
|
long nyah;
|
||||||
|
int bruh;
|
||||||
|
};
|
||||||
|
|
||||||
int main()
|
int main()
|
||||||
{
|
{
|
||||||
test();
|
test();
|
||||||
|
std::cout << alignof(silly) << " " << sizeof(silly) << std::endl;
|
||||||
|
|
||||||
|
blt::size_t remaining_bytes = 4096;
|
||||||
|
//auto* pointer = static_cast<void*>(head->metadata.offset);
|
||||||
|
//return std::align(alignment, bytes, pointer, remaining_bytes);
|
||||||
|
|
||||||
blt::gp::operation<float, float, int, bool> silly([](float f, int i, bool b) -> float {
|
blt::gp::operation<float, float, int, bool> silly([](float f, int i, bool b) -> float {
|
||||||
return static_cast<float>(f);
|
return static_cast<float>(f);
|
||||||
|
|
|
@ -88,6 +88,7 @@ namespace blt::gp
|
||||||
class stack_allocator
|
class stack_allocator
|
||||||
{
|
{
|
||||||
constexpr static blt::size_t PAGE_SIZE = 0x1000;
|
constexpr static blt::size_t PAGE_SIZE = 0x1000;
|
||||||
|
constexpr static blt::size_t MAX_ALIGNMENT = 8;
|
||||||
public:
|
public:
|
||||||
/**
|
/**
|
||||||
* Pushes an instance of an object on to the stack
|
* Pushes an instance of an object on to the stack
|
||||||
|
|
Loading…
Reference in New Issue