-
Notifications
You must be signed in to change notification settings - Fork 1.6k
cargo clippy on chrono gives "thread 'main' has overflowed its stack" #1244
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
Comments
That's interesting. I recently clippy'd chrono just fine. Then again I'm on Linux, which has larger stack sizes IIRC. |
I'm getting the same issue compiling a small crate on the latest nightly, with the latest
Interestingly, when I run Let me know how I can help provide more info. My code is for a Coursera course, so I'm not supposed to publicly distribute it, but maybe we can figure out some way to give you guys the code without posting it publicly if you want to try to reproduce it. |
this isn't happening anymore for me |
Good to know, but AFAIK, we haven't done anything to fix that voluntarily 😕 |
must be rustc behaving differently then i guess |
I'm going to close to keep things tidy-ish, but don't hesitate to reopen if this reappears. |
I am still seeing it, on at least three crates: gcc v0.3.35, matrixmultiply v0.1.10 and rand Is there any way to prevent clippy from running on the dependencies of a given crate? |
Yes, latest master and git HEAD for clippy. I ran
and I get
|
I'm also still getting this on the latest |
Also repros with regex-syntax v0.3.9. rustc 1.16.0-nightly (4682271 2017-01-03) (windows 7 x64, MSVC) and clippy v0.0.106 The command-line invoked by
I can also repro against a local rust build at the same commit as that nightly, from which I got the stack trace: Long stack trace here
but I'm not sure how reliable this is since it doesn't seem to properly match up against the actual rustc_mir code. It is 100% reproable though and has the same stack everytime. |
cc @eddyb looks like a MIR bug? Clippy doesn't call into MIR functions (yet) and the stacktrace seems pure rustc. We don't mutate anything iirc so this shouldn't be affected. |
This vaguely looks like rust-lang/rust#35408. |
Amusingly, a rust build compiled with |
I found a repro with the unoptimized rust build - rustc-demangle v0.1.3 Command-line:
Long stack trace here
Based on the |
This does not fix all clippy warnings since there seems to be a problem with stack overflows https://github.com/Manishearth/rust-clippy/issues/1244
This does not fix all clippy warnings since there seems to be a problem with stack overflows https://github.com/Manishearth/rust-clippy/issues/1244
I've hit this at https://github.com/durka/cellsplit/tree/v0.2. Running |
Also getting this issue in nightly 1.17.0, MSVC, in a project with the following crates:
Assume I can't go removing dependencies to narrow it down as it no longer builds then. But figured the information may be useful as @Luthaf commented on 24 Oct 2016 about libc also. |
I don't think it is rust-lang/rust#35408 because the crates build normally, just not under clippy. |
Is there anything we can do to provide more diagnostic info? This bug renders clippy completely useless, seemingly on any nontrivial crate. |
@eddyb the overflows seem to involve MIR? |
Is |
Yeah, it's a custom rustc driver. Can't wait to be part of the distribution so that hack goes away. @oli-obk IIRC you originally wrote the clippy rustc driver, could you update it to handle the min stack size stuff? |
(you're supposed to use the |
I'm still skeptical, because even `RUST_MIN_STACK=16777216 cargo clippy`
fails.
…On Wed, Feb 22, 2017 at 3:25 PM, Eduard-Mihai Burtescu < ***@***.***> wrote:
(you're supposed to use the monitor function instead of running rustc in
your own thread)
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<https://github.com/Manishearth/rust-clippy/issues/1244#issuecomment-281791900>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAC3n5WBkZJ0pSQSRa9LctdvDA5TO5Knks5rfJm0gaJpZM4KGAJJ>
.
|
@durka Is it on the main thread's stack? Because AFAIK that's fixed by the OS. |
I'm having the same problem recently with my own small project, only using json and nom as dependencies. Without clippy it builds just fine.
|
Yeah I think |
my crate was getting stackoverflow on running cargo clippy. narrowed it down to running just against chrono :( not sure how to investigate further
am using 09-21 nightly (windows-gnu and windows-msvc) and chrono v0.2.25
The text was updated successfully, but these errors were encountered: