-
Notifications
You must be signed in to change notification settings - Fork 13k
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
propagate TIME_DEPTH to the helper threads for -Z time-passes #38645
Conversation
@bors: r+ |
📌 Commit ad747c5 has been approved by |
@bors p=1 Time-sensitive, needed to fix perf results for incr. comp. tests. |
⌛ Testing commit ad747c5 with merge 26366b2... |
💔 Test failed - status-travis |
@bors: retry |
⌛ Testing commit ad747c5 with merge 8ad040c... |
💔 Test failed - status-travis |
thread_local!(static TIME_DEPTH: Cell<usize> = Cell::new(0)); | ||
|
||
/// Read the current depth of `time()` calls. This is used to | ||
/// encourage indentation across threads. |
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.
This comment seems to be nonsensical given that TIME_DEPTH is a thread-local static. Perhaps it should be an AtomicUsize and shared across threads instead?
/// `set_time_depth()` with the result from `time_depth()` in the | ||
/// parent thread. | ||
pub fn set_time_depth(depth: usize) { | ||
TIME_DEPTH.with(|slot| slot.set(depth)); |
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.
Oh.
@bors: retry
* network error
…On Wed, Dec 28, 2016 at 12:19 PM, bors ***@***.***> wrote:
💔 Test failed - status-travis
<https://travis-ci.org/rust-lang/rust/builds/187295305>
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#38645 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAD95J-wlDYInax78fw3gD-042r6R_Rkks5rMsRMgaJpZM4LWoad>
.
|
⌛ Testing commit ad747c5 with merge 07fdfe6... |
💔 Test failed - status-travis |
@bors: retry
|
Yes. |
⌛ Testing commit ad747c5 with merge ae38ba2... |
💔 Test failed - status-appveyor |
propagate TIME_DEPTH to the helper threads for -Z time-passes Currently, the timing measurements for LLVM passes and the like don't come out indented, which messes up `perf.rust-lang.org`. r? @nrc
☀️ Test successful - status-appveyor, status-travis |
Currently, the timing measurements for LLVM passes and the like don't come out indented, which messes up
perf.rust-lang.org
.r? @nrc