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

Rollup of 6 pull requests #118780

Merged
merged 26 commits into from
Dec 9, 2023
Merged

Rollup of 6 pull requests #118780

merged 26 commits into from
Dec 9, 2023

Commits on Dec 4, 2023

  1. Configuration menu
    Copy the full SHA
    199098b View commit details
    Browse the repository at this point in the history

Commits on Dec 6, 2023

  1. De-pub some functions.

    nnethercote committed Dec 6, 2023
    Configuration menu
    Copy the full SHA
    856b55f View commit details
    Browse the repository at this point in the history
  2. Identify impossible cases in ascii_escapes_should_be_ascii.

    Raw strings (of all kinds) don't support escapes, so this function
    should never be called on them.
    nnethercote committed Dec 6, 2023
    Configuration menu
    Copy the full SHA
    e290582 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    c6bbb37 View commit details
    Browse the repository at this point in the history

Commits on Dec 7, 2023

  1. Configuration menu
    Copy the full SHA
    f312775 View commit details
    Browse the repository at this point in the history
  2. Remove impl_visitable!.

    It is used just once. With it removed, the relevant code is a little
    boilerplate-y but much easier to read, and is the same length. Overall I
    think it's an improvement.
    nnethercote committed Dec 7, 2023
    Configuration menu
    Copy the full SHA
    60e7c68 View commit details
    Browse the repository at this point in the history
  3. Remove BorrowckAnalyses.

    This results in two non-generic types being used: `BorrowckResults` and
    `BorrowckFlowState`. It's a net reduction in lines of code, and a little
    easier to read.
    nnethercote committed Dec 7, 2023
    Configuration menu
    Copy the full SHA
    0158404 View commit details
    Browse the repository at this point in the history
  4. Tweak GenKillAnalysis.

    `GenKillAnalysis` has five methods that take a transfer function arg:
    - `statement_effect`
    - `before_statement_effect`
    - `terminator_effect`
    - `before_terminator_effect`
    - `call_return_effect`
    
    All the transfer function args have type `&mut impl GenKill<Self::Idx>`,
    except for `terminator_effect`, which takes the simpler `Self::Domain`.
    
    But only the first two need to be `impl GenKill`. The other
    three can all be `Self::Domain`, just like `Analysis`. So this commit
    changes the last two to take `Self::Domain`, making `GenKillAnalysis`
    and `Analysis` more similar.
    
    (Another idea would be to make all these methods `impl GenKill`. But
    that doesn't work: `MaybeInitializedPlaces::terminator_effect` requires
    the arg be `Self::Domain` so that `self_is_unwind_dead(place, state)`
    can be called on it.)
    nnethercote committed Dec 7, 2023
    Configuration menu
    Copy the full SHA
    4b364b6 View commit details
    Browse the repository at this point in the history

Commits on Dec 8, 2023

  1. Configuration menu
    Copy the full SHA
    08b8ba0 View commit details
    Browse the repository at this point in the history
  2. Remove explicit \n and \t handling in unescape_str_common.

    The fallback `_` case works for these chars, no need to treat them
    specially.
    nnethercote committed Dec 8, 2023
    Configuration menu
    Copy the full SHA
    f883762 View commit details
    Browse the repository at this point in the history
  3. Eliminate is_byte: bool args in unescaping code.

    These don't really make sense since C string literals were added. This
    commit removes them in favour for `mode: Mode` args. `ascii_check` still
    has a `characters_should_be_ascii: bool` arg.
    
    Also, `characters_should_be_ascii` is renamed to be shorter.
    nnethercote committed Dec 8, 2023
    Configuration menu
    Copy the full SHA
    119b1d0 View commit details
    Browse the repository at this point in the history
  4. Tweak the no-nuls.rs test.

    The `empty!` macro calls should be outside the `cfg(FALSE)` function.
    nnethercote committed Dec 8, 2023
    Configuration menu
    Copy the full SHA
    9741dba View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    adc46e5 View commit details
    Browse the repository at this point in the history
  6. Tweak Mode.

    - Add `use Mode::*` to avoid all the qualifiers.
    - Reorder the variants. The existing order makes no particular sense,
      which has bugged me for some time. I've chosen an order that makes
      sense to me.
    nnethercote committed Dec 8, 2023
    Configuration menu
    Copy the full SHA
    0a401b6 View commit details
    Browse the repository at this point in the history

Commits on Dec 9, 2023

  1. Configuration menu
    Copy the full SHA
    3818fc0 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    97de8fb View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    c980fae View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    bba9862 View commit details
    Browse the repository at this point in the history
  5. Avoid target_os and target_arch in some check-cfg tests

    as they unnecessarily clutter the diagnostic output and make the
    experience of adding a new target to the compiler more painful than
    it should be.
    
    target_os and target_arch are still being tested in the
    well-known-values.rs test, but in one place.
    Urgau committed Dec 9, 2023
    Configuration menu
    Copy the full SHA
    4c16716 View commit details
    Browse the repository at this point in the history
  6. Add simd_masked_{load,store} platform-intrinsics

    This maps to the LLVM intrinsics: llvm.masked.load and llvm.masked.store
    farnoy committed Dec 9, 2023
    Configuration menu
    Copy the full SHA
    97ae509 View commit details
    Browse the repository at this point in the history
  7. Rollup merge of rust-lang#117953 - farnoy:masked-load-store, r=workin…

    …gjubilee
    
    Add more SIMD platform-intrinsics
    
    - [x] simd_masked_load
      - [x] LLVM codegen - llvm.masked.load
      - [x] cranelift codegen - implemented but untested
    - [ ] simd_masked_store
      - [x] LLVM codegen - llvm.masked.store
      - [ ] cranelift codegen
    
    Also added a run-pass test to test both intrinsics, and additional build-fail & check-fail to cover validation for both intrinsics
    GuillaumeGomez authored Dec 9, 2023
    Configuration menu
    Copy the full SHA
    c57b054 View commit details
    Browse the repository at this point in the history
  8. Rollup merge of rust-lang#118057 - bvanjoi:fix-118048, r=cjgillot

    dedup for duplicate suggestions
    
    Fixes rust-lang#118048
    
    An easy fix.
    GuillaumeGomez authored Dec 9, 2023
    Configuration menu
    Copy the full SHA
    0865eef View commit details
    Browse the repository at this point in the history
  9. Rollup merge of rust-lang#118638 - nnethercote:rustc_mir_dataflow-mor…

    …e, r=cjgillot
    
    More `rustc_mir_dataflow` cleanups
    
    r? `@cjgillot`
    GuillaumeGomez authored Dec 9, 2023
    Configuration menu
    Copy the full SHA
    546643c View commit details
    Browse the repository at this point in the history
  10. Rollup merge of rust-lang#118702 - Urgau:check-cfg-strengthen-well-kn…

    …own, r=nnethercote
    
    Strengthen well known check-cfg names and values test
    
    rust-lang#118494 is changing the implementation of how we expect well known check-cfg names and values, but we currently don't have a test that checks every well known only some of them.
    
    This PR therefore strengthen our well known names/values test to include all of the configs to at least avoid unintended regressions and validate new entry.
    
    *this PR also contains some drive-by consolidation of unexpected `target_os`, `target_arch` into a single file*
    
    r? `@nnethercote` (maybe? feel free to re-assign)
    GuillaumeGomez authored Dec 9, 2023
    Configuration menu
    Copy the full SHA
    78d2c8e View commit details
    Browse the repository at this point in the history
  11. Rollup merge of rust-lang#118734 - nnethercote:literal-cleanups, r=fe…

    …e1-dead
    
    Unescaping cleanups
    
    Minor improvements I found while working on rust-lang#118699.
    
    r? `@fee1-dead`
    GuillaumeGomez authored Dec 9, 2023
    Configuration menu
    Copy the full SHA
    a1c252f View commit details
    Browse the repository at this point in the history
  12. Rollup merge of rust-lang#118766 - compiler-errors:lower-spans, r=spa…

    …storino
    
    Lower some forgotten spans
    
    I wrote a HIR visitor that visited all of the spans in the HIR, and made it ICE when we have a unlowered span. That led me to discover these unlowered spans.
    GuillaumeGomez authored Dec 9, 2023
    Configuration menu
    Copy the full SHA
    fd60c5a View commit details
    Browse the repository at this point in the history