This was caused by the file_dirscan() function in the filent.c module not working correctly when passed '\' as its dir. It then messed up when formatting its file-selection parameter for the _findfirst()/findfirst() API and constructed it as '\/*' which caused that API to fail and return -1 which was in turn being interpreted as 'file not found'.
[SVN r44088]
Solved the problem with bjam going into an active wait state, hogging up processor resources, when waiting for one of its child processes to terminate while not all of its available child process slots are being used. To see this bug in action, try compiling a simple C++ program on a 2 processor PC with the -j 2 command-line option and watching how much processor resources bjam uses while linking. Was caused by treating unused process slots as used in the try_wait() function, causing the WaitForMultipleObjects() Windows API call to exit instantly with an error which was then getting incorrectly interpreted as a timeout, starting the whole cycle anew.
Solved a race condition between bjam's output reading/child process termination detection and the child process's output generation/termination which could have caused bjam not to collect the terminated process's final output.
Extracted all GetExitCodeProcess() API calls into one location so it no longer gets called in three separate places.
Minor comment changes in code touched by previous fixes.
[SVN r44087]
requires both the parent and child process to explicitly set
the process group id. Vfork guarantees the child process
runs to the exec before it releases the parent process.
Now that we use fork instead of vfork, it's possible for the
parent to wait on the child process without having the child
setpgid on itself. This eliminates spurious hangs on ppc
darwin caused by either a race condition between vfork and
execvp, or a bug in the vfork implementation.
Added a test to ensure we don't try to read from the
stderr pipe descriptor if the descriptor's not valid.
[SVN r43176]
Consequences & checks:
* Final __ACTION_RULE__ rule parameter has changed from output ? to output-lines *.
* Updated corresponding Jam documentation.
* Updated the all related Boost Build code.
* No code on the Boost trunk uses this rule except for Boost Build itself.
[SVN r42629]
* Reflect added start/end timestamps for actions in xml output. And update action rules for new args.
execcmd.h
* Add start/end timestamps to action timing info.
execnt.c
* Fix filetime_seconds calculation when time is larger than low 32 bit value.
* Add calc of C time_t from Windows FILETIME.
* Add start/end timestamps recording to action timing info.
execunix.c
* Add start/end timestamps recording to action timing info.
jam.c
* Change JAMDATE to use common ISO date format.
make1.c
* Redo __TIMING_RULE__ and __ACTION__RULE__ invocations to new argument ordering and added end/result timestamp values.
[SVN r41431]
silly mistakes like using a negative time for the select
timeout.
Also added the setrlimit call back in since the
named_condition_test occassionally consumes multiple cpus
worth of time. That is, when I ran this test -j4, I found
the named_condition test consuming 4 cpus worth of time so
after 300 seconds of elapsed time when the test timed out,
it had consumed almost 1200 seconds worth of cpu. While the
test is killed after the elapsed time expired, setting a hard
cpu limit ensures it's killed after consuming either -lx seconds
worth of cpu or -lx seconds of elapsed time.
[SVN r39613]
Added an optimization to the -lx unix timeout code. I
compute the amount of time the select call should sleep
until the "oldest" process times out. This ensures that
all processes that timeout will be killed within one
second of their expiration.
[SVN r39534]
The intel based darwin system was killing subprocesses
okay but for some reason, ppc systems were not. This
change fixes the timeout code so subprocesses are
properly killed on ppc darwin systems.
[SVN r39514]