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 10 pull requests #74245

Merged
merged 29 commits into from
Jul 12, 2020
Merged

Rollup of 10 pull requests #74245

merged 29 commits into from
Jul 12, 2020

Commits on Jun 25, 2020

  1. Modify type names on MSVC to make tuples .natvis compatible.

    - Mangles (T0, T1) as tuple<T0, T1>, possibly unblocking rust-lang#70052 "Update hashbrown to 0.8.0"
    - Prettifies Rust tuples similar to VS2017's std::tuple
    - Improves debuginfo test coverage
    MaulingMonkey committed Jun 25, 2020
    Configuration menu
    Copy the full SHA
    f8eb81b View commit details
    Browse the repository at this point in the history
  2. debuginfo: Define int/float types in terms of MSVC-recognized types.

    PDB debug information doesn't appear to be emitted for basic types.
    By defining u32 as a typedef for unsigned __int32 when targeting MSVC,
    we allow CDB and other debuggers to recognize "u32" as a type/expression.
    
    This in turn unblocks rust-lang#70052 "Update hashbrown to 0.8.0" by
    allowing $T1 ..= $T3 to resolve, which would otherwise fail to resolve
    when builtin types fail to parse.
    MaulingMonkey committed Jun 25, 2020
    Configuration menu
    Copy the full SHA
    24a728a View commit details
    Browse the repository at this point in the history

Commits on Jul 5, 2020

  1. Optimize is_ascii for &str and &[u8]

    Thom Chiovoloni committed Jul 5, 2020
    Configuration menu
    Copy the full SHA
    980d8e1 View commit details
    Browse the repository at this point in the history
  2. Avoid vec! allocation in is_ascii_slice_* benches

    Thom Chiovoloni committed Jul 5, 2020
    Configuration menu
    Copy the full SHA
    63e2e2e View commit details
    Browse the repository at this point in the history
  3. Add benchmark for slice is_ascii using align_to

    Thom Chiovoloni committed Jul 5, 2020
    Configuration menu
    Copy the full SHA
    e1d4db6 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    13e380d View commit details
    Browse the repository at this point in the history
  5. Add 'unrolled' is_ascii_align_to benchmark, and move is_ascii benchma…

    …rks into own file
    Thom Chiovoloni committed Jul 5, 2020
    Configuration menu
    Copy the full SHA
    dc4a644 View commit details
    Browse the repository at this point in the history

Commits on Jul 6, 2020

  1. Remove pointless black_box call, add a comment about the `unaligned…

    …_` benches, and clean up stray semicolon
    Thom Chiovoloni committed Jul 6, 2020
    Configuration menu
    Copy the full SHA
    a150dcc View commit details
    Browse the repository at this point in the history

Commits on Jul 8, 2020

  1. Fix cross-compilation of LLVM to aarch64 Windows targets

    When cross-compiling, the LLVM build system recurses to build tools
    that need to run on the host system. However, since we pass cmake defines
    to set the compiler and target, LLVM still compiles these tools for the
    target system, rather than the host. The tools then fail to execute
    during the LLVM build.
    
    This change sets defines for the tools that need to run on the
    host (llvm-nm, llvm-tablegen, and llvm-config), so that the LLVM build
    does not attempt to build them, and instead relies on the tools already built.
    
    If compiling with clang-cl, this change also adds the `--target` option
    to specify the target triple. MSVC compilers do not require this, since there
    is a separate compiler binary for cross-compilation.
    arlosi committed Jul 8, 2020
    Configuration menu
    Copy the full SHA
    59f979f View commit details
    Browse the repository at this point in the history
  2. linker: illumos ld does not support --eh-frame-hdr

    As of rust-lang#73564, the --eh-frame-hdr flag is unconditionally
    passed to linkers on many platforms.  The illumos link editor does not
    currently support this flag.
    
    The linker machinery in the Rust toolchain currently seems to use the
    (potentially cross-compiled) target to choose linker flags, rather than
    looking at what might be running on the build system.  Disabling the
    flag for all illumos/Solaris targets seems like the best we can do for
    now without more serious surgery.
    jclulow committed Jul 8, 2020
    Configuration menu
    Copy the full SHA
    7fb421b View commit details
    Browse the repository at this point in the history

Commits on Jul 9, 2020

  1. Configuration menu
    Copy the full SHA
    520fb92 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    6864546 View commit details
    Browse the repository at this point in the history
  3. Tweak wording

    JohnTitor committed Jul 9, 2020
    Configuration menu
    Copy the full SHA
    a9b6476 View commit details
    Browse the repository at this point in the history

Commits on Jul 10, 2020

  1. Minor refactor for rustc_resolve diagnostics match

    Use `matches!` instead of old `if let`
    pickfire committed Jul 10, 2020
    Configuration menu
    Copy the full SHA
    1fb0ed0 View commit details
    Browse the repository at this point in the history

Commits on Jul 11, 2020

  1. Configuration menu
    Copy the full SHA
    dd872be View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    b929f72 View commit details
    Browse the repository at this point in the history
  3. update miri

    RalfJung committed Jul 11, 2020
    Configuration menu
    Copy the full SHA
    6bda2e8 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    f5de23b View commit details
    Browse the repository at this point in the history
  5. Rollup merge of rust-lang#72920 - oli-obk:const_transmute, r=RalfJung

    Stabilize `transmute` in constants and statics but not const fn
    
    cc rust-lang#53605 (leaving issue open so we can add `transmute` to `const fn` later)
    
    Previous attempt: rust-lang#64011
    
    r? @RalfJung
    
    cc @rust-lang/wg-const-eval
    Manishearth committed Jul 11, 2020
    Configuration menu
    Copy the full SHA
    90f1d72 View commit details
    Browse the repository at this point in the history
  6. Rollup merge of rust-lang#73715 - MaulingMonkey:pr-natvis-tuples, r=A…

    …manieu
    
    debuginfo:  Mangle tuples to be natvis friendly, typedef basic types
    
    These changes are meant to unblock rust-lang#70052 "Update hashbrown to 0.8.0" by allowing the use of `tuple<u64, u64>` as a .natvis expression in MSVC style debuggers (MSVC, WinDbg, CDB, etc.)
    
    * f8eb81b does the actual mangling of `(u64, u64)` -> `tuple<u64, 64>`
    * 24a728a allows `u64` to resolve (fixing `$T1` / `$T2` when used to visualize `HashMap<u64, u64, ...>`)
    Manishearth committed Jul 11, 2020
    Configuration menu
    Copy the full SHA
    084ac77 View commit details
    Browse the repository at this point in the history
  7. Rollup merge of rust-lang#74066 - thomcc:optimize-is-ascii, r=nagisa

    Optimize is_ascii for str and [u8].
    
    This optimizes the `is_ascii` function for `[u8]` and `str`. I've been surprised this wasn't done for a while, so I just did it.
    
    Benchmarks comparing before/after look like:
    
    ```
    test ascii::long_readonly::is_ascii_slice_iter_all              ... bench:         174 ns/iter (+/- 79) = 40172 MB/s
    test ascii::long_readonly::is_ascii_slice_libcore               ... bench:          16 ns/iter (+/- 5) = 436875 MB/s
    test ascii::medium_readonly::is_ascii_slice_iter_all            ... bench:          12 ns/iter (+/- 3) = 2666 MB/s
    test ascii::medium_readonly::is_ascii_slice_libcore             ... bench:           2 ns/iter (+/- 0) = 16000 MB/s
    test ascii::short_readonly::is_ascii_slice_iter_all             ... bench:           3 ns/iter (+/- 0) = 2333 MB/s
    test ascii::short_readonly::is_ascii_slice_libcore              ... bench:           4 ns/iter (+/- 0) = 1750 MB/s
    ```
    
    (Taken on a x86_64 macbook 2.9 GHz Intel Core i9 with 6 cores)
    
    Where `is_ascii_slice_iter_all` is the old version, and `is_ascii_slice_libcore` is the new.
    
    I tried to document the code well, so hopefully it's understandable. It has fairly exhaustive tests ensuring size/align doesn't get violated -- because `miri` doesn't really help a lot for this sort of code right now, I tried to `debug_assert` all the safety invariants I'm depending on. (Of course, none of them are required for correctness or soundness -- just allows us to test that this sort of pointer manipulation is sound and such).
    
    Anyway, thanks. Let me know if you have questions/desired changes.
    Manishearth committed Jul 11, 2020
    Configuration menu
    Copy the full SHA
    1979fa8 View commit details
    Browse the repository at this point in the history
  8. Rollup merge of rust-lang#74116 - arlosi:aarch64build, r=pietroalbini

    Fix cross compilation of LLVM to aarch64 Windows targets
    
    When cross-compiling, the LLVM build system recurses to build tools that need to run on the host system. However, since we pass cmake defines to set the compiler and target, LLVM still compiles these tools for the target system, rather than the host. The tools then fail to execute during the LLVM build.
    
    This change sets defines for the tools that need to run on the host (llvm-nm, llvm-tablegen, and llvm-config), so that the LLVM build does not attempt to build them, and instead relies on the tools already built.
    
    If compiling with clang-cl, adds the `--target` option to specify the target triple. MSVC compilers do not require this, since there is a separate compiler binary for each cross-compilation target.
    
    Related issue: rust-lang#72881
    Requires LLVM change: rust-lang/llvm-project#67
    Manishearth committed Jul 11, 2020
    Configuration menu
    Copy the full SHA
    9614238 View commit details
    Browse the repository at this point in the history
  9. Rollup merge of rust-lang#74167 - jclulow:illumos-linker-eh-frame-hdr…

    …-fix, r=petrochenkov
    
    linker: illumos ld does not support --eh-frame-hdr
    
    As of rust-lang#73564, the --eh-frame-hdr flag is unconditionally
    passed to linkers on many platforms.  The illumos link editor does not
    currently support this flag.
    
    The linker machinery in the Rust toolchain currently seems to use the
    (potentially cross-compiled) target to choose linker flags, rather than
    looking at what might be running on the build system.  Disabling the
    flag for all illumos/Solaris targets seems like the best we can do for
    now without more serious surgery.
    Manishearth committed Jul 11, 2020
    Configuration menu
    Copy the full SHA
    8f8ff15 View commit details
    Browse the repository at this point in the history
  10. Rollup merge of rust-lang#74168 - JohnTitor:help-for-in-band-lifetime…

    …s, r=petrochenkov
    
    Add a help to use `in_band_lifetimes` in nightly
    
    Fixes rust-lang#73775
    Manishearth committed Jul 11, 2020
    Configuration menu
    Copy the full SHA
    9f7b64e View commit details
    Browse the repository at this point in the history
  11. Rollup merge of rust-lang#74197 - estebank:self-sugg, r=petrochenkov

    Reword incorrect `self` token suggestion
    Manishearth committed Jul 11, 2020
    Configuration menu
    Copy the full SHA
    e15fa45 View commit details
    Browse the repository at this point in the history
  12. Rollup merge of rust-lang#74213 - pickfire:patch-1, r=jonas-schievink

    Minor refactor for rustc_resolve diagnostics match
    
    Use `matches!` instead of old `if let`
    Manishearth committed Jul 11, 2020
    Configuration menu
    Copy the full SHA
    6204a73 View commit details
    Browse the repository at this point in the history
  13. Configuration menu
    Copy the full SHA
    aa04ffb View commit details
    Browse the repository at this point in the history
  14. Rollup merge of rust-lang#74241 - RalfJung:miri, r=RalfJung

    update miri
    
    This incorporates rust-lang/miri#1474. [Last time](rust-lang#74146) that change caused trouble but I fixed xargo since then and [now it should work](rust-lang#74146 (comment)).
    
    Cc @rust-lang/miri r? @ghost
    Manishearth committed Jul 11, 2020
    Configuration menu
    Copy the full SHA
    95c5fb8 View commit details
    Browse the repository at this point in the history
  15. Configuration menu
    Copy the full SHA
    c8c4fd7 View commit details
    Browse the repository at this point in the history