mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-02 14:48:15 +00:00
LibC: Run constructors on process startup.
Cooperate with the compiler to generate and execute the _init_array list of constructor functions on userspace program statup. This took two days to get working, my goodness. :^)
This commit is contained in:
@@ -52,6 +52,8 @@ void* mmx_memcpy(void* dest, const void* src, size_t len)
|
||||
return dest;
|
||||
}
|
||||
|
||||
#ifdef KERNEL
|
||||
|
||||
static inline uint32_t divq(uint64_t n, uint32_t d)
|
||||
{
|
||||
uint32_t n1 = n >> 32;
|
||||
@@ -144,5 +146,6 @@ uint64_t __udivmoddi4(uint64_t n, uint64_t d, uint64_t* r)
|
||||
|
||||
return q;
|
||||
}
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user