[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: pkg/54192: lang/rust build error
The following reply was made to PR toolchain/54192; it has been noted by GNATS.
From: Martin Husemann <martin%duskware.de@localhost>
To: Kamil Rytarowski <n54%gmx.com@localhost>
Cc: gnats-bugs%netbsd.org@localhost, netbsd-bugs%netbsd.org@localhost, firstname.lastname@example.org
Subject: Re: pkg/54192: lang/rust build error
Date: Wed, 16 Oct 2019 15:50:51 +0200
Since it was not obvious to me, let me try to explain what happens:
- a multithreaded program calls fork()
- the forked child process only has a single lwp initially, wich has lid 1
So in the parent thread _lwp_self() (aka lid) was != 1, and now in the child
it has changed. Apparently something in ld.elf_so goes wrong later when
using _lwp_self() == 1 with a memory state inherited that was setup for
_lwp_self() != 1.
Joergs patch makes the single lwp inherit the lid from the forking parent
thread (instead of always being 1).
Main Index |
Thread Index |