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

[WIP] polymorphisation: re-enable #75185

Closed

Conversation

davidtwco
Copy link
Member

Do not merge this PR!
Before re-enabling polymorphisation, we're going to perform a crater run to make sure that there are no more regressions.

r? @lcnr

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Aug 5, 2020
@davidtwco
Copy link
Member Author

@bors try

@bors
Copy link
Contributor

bors commented Aug 5, 2020

⌛ Trying commit 9dbbc9b7348a0d8385685610ca95a42f96c2cae5 with merge 38eae7d349c20cfc48c6beefd91af9499a4470cc...

@bors
Copy link
Contributor

bors commented Aug 5, 2020

☀️ Try build successful - checks-actions, checks-azure
Build commit: 38eae7d349c20cfc48c6beefd91af9499a4470cc (38eae7d349c20cfc48c6beefd91af9499a4470cc)

@davidtwco

This comment has been minimized.

@craterbot

This comment has been minimized.

@craterbot craterbot added S-waiting-on-crater Status: Waiting on a crater run to be completed. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Aug 5, 2020
@davidtwco

This comment has been minimized.

@craterbot

This comment has been minimized.

@craterbot craterbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-crater Status: Waiting on a crater run to be completed. labels Aug 5, 2020
@davidtwco
Copy link
Member Author

@craterbot run mode=build-and-test

@craterbot
Copy link
Collaborator

👌 Experiment pr-75185 created and queued.
🤖 Automatically detected try build 38eae7d349c20cfc48c6beefd91af9499a4470cc
🔍 You can check out the queue and this experiment's details.

ℹ️ Crater is a tool to run experiments across parts of the Rust ecosystem. Learn more

@craterbot craterbot added S-waiting-on-crater Status: Waiting on a crater run to be completed. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Aug 5, 2020
@lcnr
Copy link
Contributor

lcnr commented Aug 8, 2020

Should we rebase this and requeue the crater run, considering the recent changes?

@davidtwco
Copy link
Member Author

Should we rebase this and requeue the crater run, considering the recent changes?

I'm tempted to, we'd only go back one spot in the queue.

@lcnr
Copy link
Contributor

lcnr commented Aug 8, 2020

yeah, we can then also reuse this PR for perf ✨

@davidtwco davidtwco force-pushed the polymorphisation-re-enable branch from 9dbbc9b to 151b4c6 Compare August 8, 2020 18:35
@davidtwco
Copy link
Member Author

@bors try @rust-timer queue

@rust-timer
Copy link
Collaborator

Awaiting bors try build completion

@bors
Copy link
Contributor

bors commented Aug 8, 2020

⌛ Trying commit 151b4c67ff89fd6ca485fddb114cb262ca4d96c5 with merge 0f97a070e9c9b216b3c18ed674269987207357b4...

@rust-log-analyzer
Copy link
Collaborator

The job dist-x86_64-linux of your PR failed (pretty log, 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.
   Compiling itertools v0.9.0
   Compiling unicode-normalization v0.1.12
   Compiling getopts v0.2.21
   Compiling rustc_lexer v0.1.0 (/checkout/src/librustc_lexer)
error[E0391]: cycle detected when determining which generic parameters are unused by `Pack::SHIFT`
   --> /cargo/registry/src/jackfan.us.kg-1ecc6299db9ec823/sharded-slab-0.0.9/src/lib.rs:605:5
    |
605 |     const SHIFT: usize = Self::Prev::SHIFT + Self::Prev::LEN;
    |
    |
    = note: ...which again requires determining which generic parameters are unused by `Pack::SHIFT`, completing the cycle
note: cycle used when determining which generic parameters are unused by `page::slot::<impl at /cargo/registry/src/jackfan.us.kg-1ecc6299db9ec823/sharded-slab-0.0.9/src/page/slot.rs:51:1: 68:2>::LEN`
   --> /cargo/registry/src/jackfan.us.kg-1ecc6299db9ec823/sharded-slab-0.0.9/src/page/slot.rs:54:5
    |
54  |     const LEN: usize = (cfg::WIDTH - C::RESERVED_BITS) - Self::SHIFT;

   Compiling rustc_serialize v0.0.0 (/checkout/src/librustc_serialize)
error: aborting due to previous error


For more information about this error, try `rustc --explain E0391`.
error: could not compile `sharded-slab`.
To learn more, run the command again with --verbose.
warning: build failed, waiting for other jobs to finish...
error: build failed
error: build failed
command did not execute successfully: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0/bin/cargo" "build" "--target" "x86_64-unknown-linux-gnu" "-Zbinary-dep-depinfo" "-j" "16" "--release" "--locked" "--color" "always" "--features" "jemalloc llvm" "--manifest-path" "/checkout/src/rustc/Cargo.toml" "--message-format" "json-render-diagnostics"
failed to run: /checkout/obj/build/bootstrap/debug/bootstrap dist --host x86_64-unknown-linux-gnu --target x86_64-unknown-linux-gnu
Build completed unsuccessfully in 0:13:19
== clock drift check ==
  local time: Sat Aug  8 18:53:23 UTC 2020
  local time: Sat Aug  8 18:53:23 UTC 2020
  network time: Sat, 08 Aug 2020 18:53:23 GMT
== end clock drift check ==
##[error]Process completed with exit code 1.
Terminate orphan process: pid (5528) (python)

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 @rust-lang/infra. (Feature Requests)

@bors
Copy link
Contributor

bors commented Aug 8, 2020

💔 Test failed - checks-actions

@bors bors added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-crater Status: Waiting on a crater run to be completed. labels Aug 8, 2020
@lcnr
Copy link
Contributor

lcnr commented Aug 10, 2020

@craterbot abort

@craterbot
Copy link
Collaborator

🗑️ Experiment pr-75185 deleted!

ℹ️ Crater is a tool to run experiments across parts of the Rust ecosystem. Learn more

@craterbot craterbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Aug 10, 2020
@davidtwco davidtwco force-pushed the polymorphisation-re-enable branch from 151b4c6 to 8665640 Compare August 11, 2020 15:35
@lcnr
Copy link
Contributor

lcnr commented Aug 11, 2020

@bors try @rust-timer queue

@rust-timer
Copy link
Collaborator

Awaiting bors try build completion

@bors
Copy link
Contributor

bors commented Aug 11, 2020

⌛ Trying commit 86656408006a330ceaf5ef3106777f4ef954dee4 with merge 725c03a00dafa941e19ba48fbecd171d4af1ac02...

@bors
Copy link
Contributor

bors commented Aug 11, 2020

☀️ Try build successful - checks-actions, checks-azure
Build commit: 725c03a00dafa941e19ba48fbecd171d4af1ac02 (725c03a00dafa941e19ba48fbecd171d4af1ac02)

@rust-timer
Copy link
Collaborator

Queued 725c03a00dafa941e19ba48fbecd171d4af1ac02 with parent 4b9ac51, future comparison URL.

@rust-timer
Copy link
Collaborator

Finished benchmarking try commit (725c03a00dafa941e19ba48fbecd171d4af1ac02): comparison url.

Benchmarking this pull request likely means that it is perf-sensitive, so we're automatically marking it as not fit for rolling up. Please note that if the perf results are neutral, you should likely undo the rollup=never given below by specifying rollup- to bors.

Importantly, though, if the results of this run are non-neutral do not roll this PR up -- it will mask other regressions or improvements in the roll up.

@bors rollup=never

@davidtwco
Copy link
Member Author

Incremental has gotten really bad but everything else is mostly unaffected. I assume that no longer storing a "no unused params" result is worse when polymorphization is enabled.

I'd expect no real gains - we know that there aren't many polymorphization opportunities (especially with the script benchmark removed) in the benchmark suite.

@Mark-Simulacrum Mark-Simulacrum changed the title polymorphisation: re-enable [WIP] polymorphisation: re-enable Aug 11, 2020
@Mark-Simulacrum
Copy link
Member

I'd expect no real gains - we know that there aren't many polymorphization opportunities (especially with the script benchmark removed) in the benchmark suite.

To be clear, this is with current polymorphization, right? We know of at least one case that I identified last night that could be a win (drop_in_place).

Regardless -- I am personally hesitant to see it enabled by default with no wins and only losses on the nightly/beta/stable compilers. Maybe we can just enable it in rustc's test suite? (At least on some builders, so we're still testing both?) Or do we expect nightly coverage to be really beneficial?

@davidtwco
Copy link
Member Author

davidtwco commented Aug 11, 2020

Regardless -- I am personally hesitant to see it enabled by default with no wins and only losses on the nightly/beta/stable compilers. Maybe we can just enable it in rustc's test suite? (At least on some builders, so we're still testing both?) Or do we expect nightly coverage to be really beneficial?

I'm not that interested in actually enabling polymorphization in this PR - it primarily exists to do a crater run.

I intend to wait until we support more cases and have a better understanding of how incr-comp is interacting with polymorphization.

To be clear, this is with current polymorphization, right? We know of at least one case that I identified last night that could be a win (drop_in_place).

Yeah - absolutely. Hopefully as polymorphization becomes more capable we'll see that in the benchmark suite.

This commit re-enables polymorphisation now that regressions have been
fixed.

Signed-off-by: David Wood <[email protected]>
@davidtwco davidtwco force-pushed the polymorphisation-re-enable branch from 8665640 to e4ab512 Compare August 30, 2020 18:14
@jyn514 jyn514 added -Zpolymorphize Unstable option: Polymorphization. S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Sep 15, 2020
@jackh726 jackh726 added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label Dec 18, 2021
@Dylan-DPC
Copy link
Member

@davidtwco any updates on this? do we need to still keep it open?

@davidtwco
Copy link
Member Author

@davidtwco any updates on this? do we need to still keep it open?

No updates, we're still working on fixing some of the bugs with polymorphization then we'll look at resurrecting this.

@Dylan-DPC Dylan-DPC added S-blocked Status: Blocked on something else such as an RFC or other implementation work. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Feb 21, 2022
@JohnCSimon
Copy link
Member

@davidtwco
Ping from triage: I'm closing this due to inactivity, Please reopen when you are ready to continue with this.
Note: if you do please open the PR BEFORE you push to it, else you won't be able to reopen - this is a quirk of github.

@rustbot label: +S-inactive

@JohnCSimon JohnCSimon closed this Nov 27, 2022
@rustbot rustbot added the S-inactive Status: Inactive and waiting on the author. This is often applied to closed PRs. label Nov 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
-Zpolymorphize Unstable option: Polymorphization. S-blocked Status: Blocked on something else such as an RFC or other implementation work. S-inactive Status: Inactive and waiting on the author. This is often applied to closed PRs. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.