r/kernel • • 4d ago

Linux kernel modules in Go

https://jespino.github.io/gokm/
28 Upvotes

10 comments sorted by

View all comments

10

u/Thin_Dragonfruit2254 4d ago

It might have a usecase but "garbage-collected Go heap inside the kernel" is a bit concerning, no?

-9

u/Charming_Skin_8549 4d ago

There shouldn't be issues if Go memory isn't passed to Linux kernel.

1

u/paulstelian97 3d ago

You do not want unnecessary memory allocations in the kernel — any memory allocated and unused by the kernel is not easy to free up when there’s a need for it. Also memory leaks. Also memory fragmentation. The kernel is intended to be stingy for stuff running in kernel space, so the userspace has access to as much as possible.