No details provided.
I have posted this to the valgrind-users mailing list along with a sample program which demonstrates the problem. this bug tracking system does not allow uploads so which details would you like?
You certainly can upload things - use the "Create a New Attachment" link. What we really need is not a test case though (although that may help) but a description of what you think is wrong - what you are doing, what is happening and what you think should happen. The fact that you may have posted those details on the mailing list at some point is helpful, but it will be far easier if they are here than if we have to go searching the mailing list to find them.
Created attachment 12250 [details] fork a cople of processes to demonstrate valgrind behaviour
Hi, we have some very large apps which load massive amount of shared libs. After trying valgrind on one of them (app has around 10-20 child processes) I noticed that the logfile for the child does not get written. Instead I have all messages appear in the parents log (the PID does get appended to the file). Also I just tried running some sample code that forks 5 children does some stuff and exits (see attached file). I ran this then using: valgrind --trace-children=yes --log-file=foo ./fork I would have expected valgrind to make an individual logfile for every child. I checked the NEWS file (and archives) on that. The NEWS file says - Small changes in control log file naming which make it easier to use valgrind for debugging MPI-based programs. The relevant new flags are --log-file-exactly= and --log-file-qualifier=. what are those 2 new flags for? The man page says to the --log-file= option: ... the file name used is created by concatenating the text filename, ".pid" and the process ID, so as to create a file per process. should this still apply? thanks & best regards, joachim
Sections 2.3 and 2.6.2 of the valgrind manual describe what --log-file-exactly and --log-file-qualifier do. As far as your other problem goes, the logging stream for a single instance of valgrind always goes to a single place established when that instance starts, and forking does not create a new instance of valgrind. If one of those children were to exec a new process (and --trace-children was set) then the command line arguments would be re-evaluated and new log file would be opened based on the new PID value. It would certainly be possible to establish a new logging stream on fork, but it is a non-trivial change.
*** This bug has been marked as a duplicate of bug 162848 ***