-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
Always emit an error for a query cycle #57880
Conversation
The job Click to expand the log.
I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
The job Click to expand the log.
I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
The job Click to expand the log.
I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
The job Click to expand the log.
I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
The job Click to expand the log.
I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
531c85a
to
e139e86
Compare
☔ The latest upstream changes (presumably #57948) made this pull request unmergeable. Please resolve the merge conflicts. |
ping from triage @Zoxc you have conflicts and failing tests to resolve |
The job Click to expand the log.
I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
Sorry, I'm behind on reviewing this... |
☔ The latest upstream changes (presumably #58341) made this pull request unmergeable. Please resolve the merge conflicts. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The PR looks good. @rust-lang/compiler who is looking into MIR inlining at the moment? There are some changes in here that might affect it (but I assume that the current solution is temporary anyway?).
src/librustc/ty/steal.rs
Outdated
@@ -43,4 +43,8 @@ impl<T> Steal<T> { | |||
let value = value_ref.take(); | |||
value.expect("attempt to read from stolen value") | |||
} | |||
|
|||
pub fn stolen(&self) -> bool { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this used anywhere? I don't see it anywhere else in the diff.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was used in a previous version. I'll remove it.
@michaelwoerister I've played around with it a bit in the past. FYI, there's some more context for this PR here https://rust-lang.zulipchat.com/#narrow/stream/131828-t-compiler/topic/always.20error.20on.20query.20cycles |
OK, r=me with the nits addressed. |
The job Click to expand the log.
I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
let callee_mir = if let Some(callee_node_id) = callee_node_id { | ||
// Avoid a cycle here by only using `optimized_mir` only if we have | ||
// a lower node id than the callee. This ensures that the callee will | ||
// not inline us. This trick only works without incremental compilation. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why does this only work without incremental? Even if the order of evaluation is the other way around, the node id comparison will impose a strict order. The actual optimizations done might vary between incremental compilations, but that should be sound.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We do not want optimizations to vary though.
☔ The latest upstream changes (presumably #58432) made this pull request unmergeable. Please resolve the merge conflicts. |
@bors r=michaelwoerister |
@bors r=michaelwoerister |
📌 Commit 82d7e33 has been approved by |
⌛ Testing commit 82d7e33 with merge 50e4593fa38407ee1aa95857ce7527d64daf6d2e... |
💔 Test failed - checks-travis |
Your PR failed on Travis (raw log). Through arcane magic we have determined that the following fragments from the build log may contain information about the problem. Click to expand the log.
I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
@bors retry -- apparently we can't clone the repo anymore on macOS |
Always emit an error for a query cycle r? @michaelwoerister cc @nikomatsakis @wesleywiser
☀️ Test successful - checks-travis, status-appveyor |
Your PR failed on Travis (raw log). Through arcane magic we have determined that the following fragments from the build log may contain information about the problem. Click to expand the log.
I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
r? @michaelwoerister
cc @nikomatsakis @wesleywiser