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

Use the base profile name when returning finishing #5492

Closed

Conversation

dwijnand
Copy link
Member

@dwijnand dwijnand commented May 6, 2018

See the NOTE block: this is still "a bit inaccurate", but perhaps it's
more accurate than just "release"/"dev".

Refs #4140

See the NOTE block: this is still "a bit inaccurate", but perhaps it's
more accurate than just "release"/"dev".

Refs rust-lang#4140
@rust-highfive
Copy link

r? @matklad

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

@@ -266,6 +265,7 @@ impl<'a> JobQueue<'a> {
// profiles used. However, to keep it simple and compatible with old
// behavior, we just display what the base profile is.
let profile = cx.bcx.profiles.base_profile(self.is_release);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hm, I think the comment here is intended to refer primarily to optimized and debuginfo settings, because different crates might be compiled with different optimization/debuginfo settings, even if they are linked into a single artifact at the end. Nevertheless, the profile is the same across the whole compilation, the variation is internal to profile.

We also are thinking about removing profiles other than dev/release, so I would say that the current behavior is what we actually want, even if it is not 100% technically accurate.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK. No harm done.

Perhaps some of what you said should appended to #4140.

@dwijnand dwijnand closed this May 12, 2018
@dwijnand dwijnand deleted the finished-bench-targets-message branch May 12, 2018 01:13
@dwijnand
Copy link
Member Author

Thanks to your comment in Gitter (https://gitter.im/rust-lang/cargo?at=5af6d407862c5e33e92bf2ca) I was able to test that this had no effect on my manual test case:

22:27:53 $ cargo +nightly bench
    Finished release [optimized] target(s) in 0.05 secs
     Running target/release/deps/t_release_profile-5c15914beb0601d3

running 1 test
test tests::bench_add_two ... bench:           0 ns/iter (+/- 0)

test result: ok. 0 passed; 0 failed; 0 ignored; 1 measured; 0 filtered out


22:29:03 $ rustup run nightly /d/cargo/target/debug/cargo bench
    Finished release [optimized] target(s) in 0.04s
     Running target/release/deps/t_release_profile-81bdca9b0b4ae7a6

running 1 test
test tests::bench_add_two ... bench:           0 ns/iter (+/- 0)

test result: ok. 0 passed; 0 failed; 0 ignored; 1 measured; 0 filtered out

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.

3 participants