Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

travis: Randomly try to suppress OSX segfaults #40243

Closed

Conversation

alexcrichton
Copy link
Member

This is a complete random shot in the dark to help suppress the OSX linker
segfaults being found on #38878. The segfault happens apparently during an
assertion in this source file. That apparently is related to a worker
thread pool for parsing a bunch of object files. Presumably there's some
concurrency bug triggering the segfault?

Poking around the source to see if we could disable this multithreading behavior
didn't turn up many results, but one check in the file above was related to
_options.pipelineEnabled() which seemed suspicious. That in turn is read from
[this file] in the fPipelineFifo instance variable (if it's non-null).

That instance variable is in turn set from another file as a result of
getenv("LD_PIPELINE_FIFO"). This PR now sets that env var for all builders,
including the OSX ones.

Will this help? I have no idea! But it at least seems related and hopefully
isn't too hard to try out and/or back out.

This is a complete random shot in the dark to help suppress the OSX linker
segfaults being found on rust-lang#38878. The segfault happens apparently during an
assertion in [this source file][1]. That apparently is related to a worker
thread pool for parsing a bunch of object files. Presumably there's some
concurrency bug triggering the segfault?

Poking around the source to see if we could disable this multithreading behavior
didn't turn up many results, but one check in the [file above][1] was related to
`_options.pipelineEnabled()` which seemed suspicious. That in turn is read from
[this file] in the `fPipelineFifo` instance variable (if it's non-null).

That instance variable is in turn set from [another file][3] as a result of
`getenv("LD_PIPELINE_FIFO")`. This PR now sets that env var for all builders,
including the OSX ones.

Will this help? I have no idea! But it at least seems related and hopefully
isn't too hard to try out and/or back out.

[1]: https://opensource.apple.com/source/ld64/ld64-274.2/src/ld/InputFiles.cpp.auto.html
[2]: https://opensource.apple.com/source/ld64/ld64-274.2/src/ld/Options.h.auto.html
[3]: https://opensource.apple.com/source/ld64/ld64-274.2/src/ld/Options.cpp.auto.html
@rust-highfive
Copy link
Collaborator

r? @aturon

(rust_highfive has picked a reviewer for you, use r? to override)

@Mark-Simulacrum
Copy link
Member

Looks like true isn't the right value for the environment variable. Seems to want a file path?

ld: pipelined linking error - failed to open stream. fopen() returns No such file or directory for "true"

@alexcrichton
Copy link
Member Author

Alas it appears so :(

Turns out this isn't just about the behavior, but it literally wants a FIFO! Makes sense in retrospect...

Unfortunately I think that means that this won't be useful :(

@alexcrichton alexcrichton deleted the random-stabs-in-the-dark branch March 3, 2017 23:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants