In opts-common.cc: bool jobserver_info::get_token () { int fd = pipe_path.empty () ? rfd : pipefd; char c; unsigned n = read (fd, &c, 1); if (n != 1) { gcc_assert (errno == EAGAIN); return false; } else return true; } We've had cases where that errno is something else. This leads to an ICE if the jobserver (from MAKEFLAGS="--jobserver-auth=fifo:/dev/foo") is in any way unreadable (e.g. doesn't exist or bad permissions). Unfortunately, connect doesn't check for an error on open either which makes this worse (the assert would probably be okay otherwise): void jobserver_info::connect () { if (!pipe_path.empty ()) { #if HOST_HAS_O_NONBLOCK pipefd = open (pipe_path.c_str (), O_RDWR | O_NONBLOCK); is_connected = true; #else is_connected = false; #endif } else is_connected = true; }
IMO fatal_error is the prefered way to deal with these kind of errors (when recovery otherwise isn't easily possible, like by running single-threaded?)