@Shamar You are saying this as if fork was a good thing. It's not!
Conversation
Notices
-
Ekaitz Zárraga 👹 (ekaitz_zarraga@mastodon.social)'s status on Thursday, 09-Dec-2021 17:01:41 CET Ekaitz Zárraga 👹 -
shamar@qoto.org's status on Thursday, 09-Dec-2021 18:35:21 CET Shamar Why?
And well can it be worse then malloc/free?
-
shamar@qoto.org's status on Thursday, 09-Dec-2021 19:55:38 CET Shamar Well, this is a good answer, but in fact, on plan9 you only get a new process: memory is only copied on write.
So it's not necessarily a malloc.
Also rfork give you a good degree of control on what is copied.
-
shamar@qoto.org's status on Thursday, 09-Dec-2021 21:31:36 CET Shamar But AFAIK this happens with malloc too: pages are assigned to processes only on read/write faults. In modern systems memory is always overcommitted.
It is dangerous, but consider the alternative: most allocated memory would stay unused and you could run a fraction of the programs you run on the same hardware.
-