[haiku-development] Re: Haiku R1/alpha updating (was decisions)

  • From: "Axel Dörfler" <axeld@xxxxxxxxxxxxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Thu, 07 Aug 2008 22:25:26 +0200 CEST

Bruno Albuquerque <bga@xxxxxxxxxxxxx> wrote:
> Axel Dörfler wrote:
> > Maybe we should have a mechanism that prevents the system from
> > reloading add-ons in the update case. At least we should test this
> > before releasing any version of Haiku :-)
> Yep, we need that. Specially because, at least right now, it tends to
> crash the system. Try a jam install-haiku to the same partition where
> you are running it from and you will see what I mean. :)

What could also cause this is if we are just rewriting the same file
instead of replacing it. "cp" for example just does that - in this
case, code that isn't currently paged in will see the new binary
whenever it gets there. Linux has the same problem, btw.
So we could either change our build system to properly replace the
files (ie. by passing the --remove-destination option to it, in case it
supports that), or let the VM handle this case gracefully (see MAP_COPY
for more info: http://www.ussg.iu.edu/hypermail/linux/kernel/0110.1/1506.html
- in case you want to have a good read). Despite Linus' slight aversion
against MAP_COPY, I think this would actually be the preferred method
(but for executables; I agree it doesn't really make sense as a
replacement for read()).

Bye,
   Axel.


Other related posts: