[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <d2d1acae-b2a1-9f41-d3bf-9d3b35a62664@landley.net>
Date: Fri, 8 Sep 2017 16:18:10 -0500
From: Rob Landley <rob@...dley.net>
To: Alan Cox <gnomes@...rguk.ukuu.org.uk>,
Geert Uytterhoeven <geert@...ux-m68k.org>
Cc: Linux Embedded <linux-embedded@...r.kernel.org>,
Oleg Nesterov <oleg@...hat.com>, dalias@...c.org,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: execve(NULL, argv, envp) for nommu?
On 09/05/2017 08:12 PM, Rob Landley wrote:
> On 09/05/2017 08:24 AM, Alan Cox wrote:
>>>> honoring the suid bit if people feel that way. I just wanna unblock
>>>> vfork() while still running this code.
>>
>> Would it make more sense to have a way to promote your vfork into a
>> fork when you hit these cases (I appreciate that fork on NOMMU has a much
>> higher performance cost as you start having to softmmu copy or swap
>> pages).
>
> It's not the performance cost, it's rewriting all the pointers.
>
> Without address translation, copying the existing mappings to a new
> range requires finding and adjusting every pointer to the old data,
> which you can do for the executable mappings in PIE* binaries, but
> tracking down all the pointers on the stack, heap, and in your global
> variables? Flaming pain.
>
> Making fork() work on nommu is basically the same problem as making
> garbage collection work in C on mmu. Thus those of us who defend vfork()
> from the people who don't understand why it exists periodically
> suggesting we remove it.
So is exec(NULL, argv, envp) a reasonable thing to want?
Rob
Powered by blists - more mailing lists