search for: readchild

Displaying 6 results from an estimated 6 matches for "readchild".

Did you mean: read_child
2018 Jun 21
1
DOCUMENTATION(?): parallel::mcparallel() gives various types of "Error in unserialize(r) : ..." errors if value is of type raw
...nput format I can reproduce this on Linux using R 3.5.0 all the way back to R 3.3.2 (didn't try further) and R development (unstable) (2018-06-19 r74919). Diving into the code of parallel::mccollect(), it looks that the 'raw' data type has a special purpose: r <- readChild(pid) if (is.integer(r) || is.null(r)) fin[pid == pids] <- TRUE if (is.raw(r)) res[which(pid == pids)] <- list(unserialize(r)) However, I don't see this behavior document in ?parallel::mcparallel. The closest I ge...
2019 May 19
2
Race condition on parallel package's mcexit and rmChild
...rary/parallel/R/unix/mcfork.R: mcexit <- function(exit.code = 0L, send = NULL) { if (!is.null(send)) try(sendMaster(send), silent = TRUE) .Call(C_mc_exit, as.integer(exit.code)) } Between sendMaster() and mc_exit() calls, which are made in the child process, the master process may call readChild() followed by rmChild(). rmChild closes the pipe on the master side, and if it's called before child calls mc_exit, a SIGPIPE will be raised when child tries to write to the pipe in mc_exit. rmChild is defined but not used in parallel package, so this problem won't surface in most cases....
2019 May 20
1
Race condition on parallel package's mcexit and rmChild
...end = NULL) > > { > > if (!is.null(send)) try(sendMaster(send), silent = TRUE) > > .Call(C_mc_exit, as.integer(exit.code)) > > } > > > > Between sendMaster() and mc_exit() calls, which are made in the child > > process, the master process may call readChild() followed by > > rmChild(). rmChild closes the pipe on the master side, and if it's > > called before child calls mc_exit, a SIGPIPE will be raised when child > > tries to write to the pipe in mc_exit. > > > > rmChild is defined but not used in parallel package,...
2019 May 20
0
Race condition on parallel package's mcexit and rmChild
...rary/parallel/R/unix/mcfork.R: mcexit <- function(exit.code = 0L, send = NULL) { if (!is.null(send)) try(sendMaster(send), silent = TRUE) .Call(C_mc_exit, as.integer(exit.code)) } Between sendMaster() and mc_exit() calls, which are made in the child process, the master process may call readChild() followed by rmChild(). rmChild closes the pipe on the master side, and if it's called before child calls mc_exit, a SIGPIPE will be raised when child tries to write to the pipe in mc_exit. rmChild is defined but not used in parallel package, so this problem won't surface in most cases....
2019 May 20
0
Race condition on parallel package's mcexit and rmChild
...it <- function(exit.code = 0L, send = NULL) > { > if (!is.null(send)) try(sendMaster(send), silent = TRUE) > .Call(C_mc_exit, as.integer(exit.code)) > } > > Between sendMaster() and mc_exit() calls, which are made in the child > process, the master process may call readChild() followed by > rmChild(). rmChild closes the pipe on the master side, and if it's > called before child calls mc_exit, a SIGPIPE will be raised when child > tries to write to the pipe in mc_exit. > > rmChild is defined but not used in parallel package, so this problem > won&...
2017 Jul 21
0
Problem with mclapply in package parallel
Dear fellow R users, I am experiencing some problem using function mclapply from recommended R package parallel. This problem is a bit "deep in source code" (maybe r-devel list would be more appropriate ?). Actually, I have noticed on a specific Linux HPC system that the various readChild() calls in mclapply did not end the children processes, as would be expected (ie compared to what happens on some other Linux machines that I am used to use). Trying to localize the problem, I have recompiled R (R-3.2.5, Intel compilers) after having the 'MC_DEBUG' macro activated in C file...