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

Automated pull from upstream master #78

Merged
merged 58 commits into from
Nov 1, 2023

Commits on Oct 29, 2023

  1. Configuration menu
    Copy the full SHA
    51e22be View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    40556b9 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    a119158 View commit details
    Browse the repository at this point in the history

Commits on Oct 30, 2023

  1. Configuration menu
    Copy the full SHA
    50ca5ef View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    1e5b2da View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    5c7cf83 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    2fe7d17 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    8afb40b View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    1e10fe9 View commit details
    Browse the repository at this point in the history
  7. Add a stable MIR visitor

    Add a few utility functions as well and extend most `mir` and `ty`
    ADTs to implement `PartialEq` and `Eq`.
    celinval committed Oct 30, 2023
    Configuration menu
    Copy the full SHA
    af7472e View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    48491c1 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    b106167 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    c523672 View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    e8868af View commit details
    Browse the repository at this point in the history
  12. Configuration menu
    Copy the full SHA
    add09e6 View commit details
    Browse the repository at this point in the history

Commits on Oct 31, 2023

  1. Configuration menu
    Copy the full SHA
    dccf10e View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    8b8906b View commit details
    Browse the repository at this point in the history
  3. Auto merge of #117419 - compiler-errors:gen, r=oli-obk

    Some more coroutine renamings
    
    a few places where `gen_` names leaked through but should be coroutine.
    
    r? oli-obk
    bors committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    ffb7ed9 View commit details
    Browse the repository at this point in the history
  4. Auto merge of #117377 - dtolnay:deprecatedsince, r=cjgillot

    Store #[deprecated] attribute's `since` value in parsed form
    
    This PR implements the first followup bullet listed in rust-lang/rust#117148 (comment).
    
    We centralize error handling to the attribute parsing code in `compiler/rustc_attr/src/builtin.rs`, and thereby remove some awkward error codepaths from later phases of compilation that had to make sense of these #\[deprecated\] attributes, namely `compiler/rustc_passes/src/stability.rs` and `compiler/rustc_middle/src/middle/stability.rs`.
    bors committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    22b2712 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    5b7cc9d View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    078144e View commit details
    Browse the repository at this point in the history
  7. coverage: Promote some debug-only checks to always run

    These checks should be cheap, so there's little reason for them to be
    debug-only.
    Zalathar committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    8ef67d0 View commit details
    Browse the repository at this point in the history
  8. coverage: Replace impossible coverage::Error with assertions

    Historically, these errors existed so that the coverage debug code could dump
    additional information before reporting a compiler bug. That debug code was
    removed by #115962, so we can now simplify these methods by making them panic
    when they detect a bug.
    Zalathar committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    6d956a2 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    7c673db View commit details
    Browse the repository at this point in the history
  10. Simplify all require_simd invocations by moving all of the shared i…

    …nvocation arguments into the macro
    oli-obk committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    9a49ef3 View commit details
    Browse the repository at this point in the history
  11. Merge simd size and type extraction into checking whether a type is s…

    …imd, as these always go together.
    oli-obk committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    f8372df View commit details
    Browse the repository at this point in the history
  12. Reorder passes.

    cjgillot committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    ed27cb0 View commit details
    Browse the repository at this point in the history
  13. Configuration menu
    Copy the full SHA
    c748ac1 View commit details
    Browse the repository at this point in the history
  14. Configuration menu
    Copy the full SHA
    0b13e63 View commit details
    Browse the repository at this point in the history
  15. Configuration menu
    Copy the full SHA
    096196d View commit details
    Browse the repository at this point in the history
  16. Configuration menu
    Copy the full SHA
    cb91890 View commit details
    Browse the repository at this point in the history
  17. Configuration menu
    Copy the full SHA
    ae2e211 View commit details
    Browse the repository at this point in the history
  18. Rollup merge of #116267 - oli-obk:simd_cleanups, r=petrochenkov

    Some codegen cleanups around SIMD checks
    
    See rust-lang/rust#115933 (comment) for the reason.
    
    This PR essentially just deduplicates code by moving it into a macro
    matthiaskrgr committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    d0833c4 View commit details
    Browse the repository at this point in the history
  19. Rollup merge of #116712 - estebank:issue-116252, r=petrochenkov

    When encountering unclosed delimiters during lexing, check for diff markers
    
    Fix #116252.
    matthiaskrgr committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    7035c3d View commit details
    Browse the repository at this point in the history
  20. Rollup merge of #117416 - compiler-errors:tait-in-bad-body, r=oli-obk

    Also consider TAIT to be uncomputable if the MIR body is tainted
    
    Not totally sure if this is the best solution. We could, alternatively, look at the hir typeck results and try to take a type from there instead of just falling back to type error, inferring `u8` instead of `{type error}`. Not certain it really matters, though.
    
    Happy to iterate on this.
    
    Fixes #117413
    
    r? ``@oli-obk`` cc ``@Nadrieril``
    matthiaskrgr committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    8daa317 View commit details
    Browse the repository at this point in the history
  21. Rollup merge of #117421 - Zalathar:error, r=oli-obk,Swatinem

    coverage: Replace impossible `coverage::Error` with assertions
    
    Historically, these errors existed so that the coverage debug code could dump additional information before reporting a compiler bug. That debug code was removed by #115962, so we can now simplify these methods by making them panic immediately when they detect a bug.
    matthiaskrgr committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    793776f View commit details
    Browse the repository at this point in the history
  22. Rollup merge of #117438 - cjgillot:deterministic-error, r=oli-obk

    Do not ICE on constant evaluation failure in GVN.
    
    Fixes rust-lang/rust#117362
    matthiaskrgr committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    f623530 View commit details
    Browse the repository at this point in the history
  23. Auto merge of #117444 - matthiaskrgr:rollup-43s0spc, r=matthiaskrgr

    Rollup of 5 pull requests
    
    Successful merges:
    
     - #116267 (Some codegen cleanups around SIMD checks)
     - #116712 (When encountering unclosed delimiters during lexing, check for diff markers)
     - #117416 (Also consider TAIT to be uncomputable if the MIR body is tainted)
     - #117421 (coverage: Replace impossible `coverage::Error` with assertions)
     - #117438 (Do not ICE on constant evaluation failure in GVN.)
    
    r? `@ghost`
    `@rustbot` modify labels: rollup
    bors committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    045f158 View commit details
    Browse the repository at this point in the history
  24. Configuration menu
    Copy the full SHA
    de83057 View commit details
    Browse the repository at this point in the history
  25. Configuration menu
    Copy the full SHA
    8eb932d View commit details
    Browse the repository at this point in the history
  26. Configuration menu
    Copy the full SHA
    8b4fa0f View commit details
    Browse the repository at this point in the history
  27. Configuration menu
    Copy the full SHA
    4512f21 View commit details
    Browse the repository at this point in the history
  28. Auto merge of #117407 - compiler-errors:derive-clone, r=oli-obk

    Use derivative for `Clone`/`PartialOrd`/`Ord`/`Hash` in `rustc_type_ir`
    
    This uses `derivative` to derive `Clone`/`PartialOrd`/`Ord`/`Hash` for types in `rustc_type_ir`. This doesn't derive `PartialEq`/`Eq` yet, because I have no idea why those are generating slower implementations from derivative.
    bors committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    d7d9f15 View commit details
    Browse the repository at this point in the history
  29. Add support for pre-unix-epoch file dates on Apple platforms (#108277)

    Time in UNIX system calls counts from the epoch, 1970-01-01. The timespec
    struct used in various system calls represents this as a number of seconds and
    a number of nanoseconds. Nanoseconds are required to be between 0 and
    999_999_999, because the portion outside that range should be represented in
    the seconds field; if nanoseconds were larger than 999_999_999, the seconds
    field should go up instead.
    
    Suppose you ask for the time 1969-12-31, what time is that? On UNIX systems
    that support times before the epoch, that's seconds=-86400, one day before the
    epoch. But now, suppose you ask for the time 1969-12-31 23:59:00.1. In other
    words, a tenth of a second after one minute before the epoch.  On most UNIX
    systems, that's represented as seconds=-60, nanoseconds=100_000_000. The macOS
    bug is that it returns seconds=-59, nanoseconds=-900_000_000.
    
    While that's in some sense an accurate description of the time (59.9 seconds
    before the epoch), that violates the invariant of the timespec data structure:
    nanoseconds must be between 0 and 999999999. This causes this assertion in the
    Rust standard library.
    
    So, on macOS, if we get a Timespec value with seconds less than or equal to
    zero, and nanoseconds between -999_999_999 and -1 (inclusive), we can add
    1_000_000_000 to the nanoseconds and subtract 1 from the seconds, and then
    convert.  The resulting timespec value is still accepted by macOS, and when fed
    back into the OS, produces the same results. (If you set a file's mtime with
    that timestamp, then read it back, you get back the one with negative
    nanoseconds again.)
    
    Co-authored-by: Josh Triplett <josh@joshtriplett.org>
    Byron and joshtriplett committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    a8ece11 View commit details
    Browse the repository at this point in the history
  30. Configuration menu
    Copy the full SHA
    77174d3 View commit details
    Browse the repository at this point in the history
  31. Auto merge of #117450 - oli-obk:rustdoc_verify, r=estebank

    Accept less invalid Rust in rustdoc
    
    pulled out of rust-lang/rust#117213 where this change was already approved
    
    This only affects rustdoc, and has up to [20% perf regressions in rustdoc](rust-lang/rust#117213 (comment)). These are unavoidable, as we are simply doing more checks now, but it's part of the longer term plan of making rustdoc more resistant to ICEs by only accepting valid Rust code.
    bors committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    50be229 View commit details
    Browse the repository at this point in the history
  32. Rollup merge of #113241 - poliorcetics:85138-doc-object-safety, r=Gui…

    …llaumeGomez
    
    rustdoc: Document lack of object safety on affected traits
    
    Closes #85138
    
    I saw the issue didn't have any recent activity, if there is another MR for it I missed it.
    
    I want the issue to move forward so here is my proposition.
    
    It takes some space just before the "Implementors" section and only if the trait is **not** object
    safe since it is the only case where special care must be taken in some cases and this has the
    benefit of avoiding generation of HTML in (I hope) the common case.
    matthiaskrgr committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    51b275b View commit details
    Browse the repository at this point in the history
  33. Rollup merge of #117388 - oli-obk:dequerification, r=RalfJung

    Turn const_caller_location from a query to a hook
    
    blocked on rust-lang/rust#117317
    
    cc `@RalfJung`
    matthiaskrgr committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    83990ba View commit details
    Browse the repository at this point in the history
  34. Rollup merge of #117417 - celinval:smir-visitor, r=oli-obk

    Add a stable MIR visitor
    
    This change also adds a few utility functions as well and extend most `mir` and `ty` ADTs to implement `PartialEq` and `Eq`.
    
    Fixes rust-lang/project-stable-mir#32
    
    r? `@oli-obk`
    matthiaskrgr committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    290daf9 View commit details
    Browse the repository at this point in the history
  35. Rollup merge of #117439 - lcnr:prepopulate-earlier, r=compiler-errors

    prepopulate opaque ty storage before using it
    
    doesn't have any significant impact rn afaict, as we freely define new opaque types during MIR typeck.
    
    It will be relevant with #117278 and once we stop allowing the definition of new opaques in MIR typeck
    
    r? `@compiler-errors`
    matthiaskrgr committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    86d69f9 View commit details
    Browse the repository at this point in the history
  36. Rollup merge of #117451 - Byron:issue-108277-apple-fix, r=joshtriplett

    Add support for pre-unix-epoch file dates on Apple platforms (#108277)
    
    Please note that even though the assertion being hit is the same on MacOS and thus similar to what's described in #108277, on MacOS it's possible to convert the numbers such that they are valid, don't hit the assertion and are round-trippable.
    Doing so effectively fixes the issue on Apple platforms.
    
    This PR does not attempt to harden other platforms against negative nanoseconds, which can happen for many reasons including mild filesystem corruption.
    
    ----
    
    Time in UNIX system calls counts from the epoch, 1970-01-01. The timespec
    struct used in various system calls represents this as a number of seconds and
    a number of nanoseconds. Nanoseconds are required to be between 0 and
    999_999_999, because the portion outside that range should be represented in
    the seconds field; if nanoseconds were larger than 999_999_999, the seconds
    field should go up instead.
    
    Suppose you ask for the time 1969-12-31, what time is that? On UNIX systems
    that support times before the epoch, that's seconds=-86400, one day before the
    epoch. But now, suppose you ask for the time 1969-12-31 23:59:00.1. In other
    words, a tenth of a second after one minute before the epoch.  On most UNIX
    systems, that's represented as seconds=-60, nanoseconds=100_000_000. The macOS
    bug is that it returns seconds=-59, nanoseconds=-900_000_000.
    
    While that's in some sense an accurate description of the time (59.9 seconds
    before the epoch), that violates the invariant of the timespec data structure:
    nanoseconds must be between 0 and 999999999. This causes this assertion in the
    Rust standard library.
    
    So, on macOS, if we get a Timespec value with seconds less than or equal to
    zero, and nanoseconds between -999_999_999 and -1 (inclusive), we can add
    1_000_000_000 to the nanoseconds and subtract 1 from the seconds, and then
    convert.  The resulting timespec value is still accepted by macOS, and when fed
    back into the OS, produces the same results. (If you set a file's mtime with
    that timestamp, then read it back, you get back the one with negative
    nanoseconds again.)
    
    Co-authored-by: Josh Triplett <josh@joshtriplett.org>
    matthiaskrgr and joshtriplett committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    d06200b View commit details
    Browse the repository at this point in the history
  37. Update cargo

    weihanglo committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    7ea6977 View commit details
    Browse the repository at this point in the history
  38. Auto merge of #117462 - weihanglo:update-cargo, r=weihanglo

    Update cargo
    
    7 commits in 708383d620e183a9ece69b8fe930c411d83dee27..b4d18d4bd3db6d872892f6c87c51a02999b80802
    2023-10-27 21:09:26 +0000 to 2023-10-31 18:19:10 +0000
    - refactor(toml): Cleanup noticed on the way to rust-lang/cargo#12801 (rust-lang/cargo#12902)
    - feat(trim-paths): set env `CARGO_TRIM_PATHS` for build scripts (rust-lang/cargo#12900)
    - feat: implement RFC 3127 `-Ztrim-paths` (rust-lang/cargo#12625)
    - docs: clarify config to use vendored source is printed to stdout (rust-lang/cargo#12893)
    - Improve the margin calculation for the search command's UI (rust-lang/cargo#12890)
    - Add new packages to [workspace.members] automatically (rust-lang/cargo#12779)
    - refactor(toml): Decouple parsing from interning system (rust-lang/cargo#12881)
    
    r? ghost
    bors committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    9d83ac2 View commit details
    Browse the repository at this point in the history
  39. Auto merge of #117459 - matthiaskrgr:rollup-t3osb3c, r=matthiaskrgr

    Rollup of 5 pull requests
    
    Successful merges:
    
     - #113241 (rustdoc: Document lack of object safety on affected traits)
     - #117388 (Turn const_caller_location from a query to a hook)
     - #117417 (Add a stable MIR visitor)
     - #117439 (prepopulate opaque ty storage before using it)
     - #117451 (Add support for pre-unix-epoch file dates on Apple platforms (#108277))
    
    r? `@ghost`
    `@rustbot` modify labels: rollup
    bors committed Oct 31, 2023
    Configuration menu
    Copy the full SHA
    09ac6e4 View commit details
    Browse the repository at this point in the history

Commits on Nov 1, 2023

  1. Auto merge of #113970 - cjgillot:assume-all-the-things, r=nikic

    Replace switch to unreachable by assume statements
    
    `UnreachablePropagation` currently keeps some switch terminators alive in order to ensure codegen can infer the inequalities on the discriminants.
    
    This PR proposes to encode those inequalities as `Assume` statements.
    
    This allows to simplify MIR further by removing some useless terminators.
    bors committed Nov 1, 2023
    Configuration menu
    Copy the full SHA
    98f5ebb View commit details
    Browse the repository at this point in the history
  2. remove excluded files from upstream

    This commit is generated by `ferrocene/tools/pull-upstream/pull.sh`.
    The list of excluded files is defined in `.gitattributes`.
    github-actions[bot] committed Nov 1, 2023
    Configuration menu
    Copy the full SHA
    18168b8 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    0df4dc9 View commit details
    Browse the repository at this point in the history
  4. add newly-added tests to conflict marker allowlist

    There were added in 50ca5ef
    tshepang committed Nov 1, 2023
    Configuration menu
    Copy the full SHA
    d549a5c View commit details
    Browse the repository at this point in the history