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 5 pull requests #130979

Merged
merged 13 commits into from
Sep 28, 2024
Merged

Rollup of 5 pull requests #130979

merged 13 commits into from
Sep 28, 2024

Commits on Sep 27, 2024

  1. improve LLVM submodule handling logic in llvm::prebuilt_llvm_config

    Signed-off-by: onur-ozkan <work@onurozkan.dev>
    onur-ozkan committed Sep 27, 2024
    Configuration menu
    Copy the full SHA
    cd1b245 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    f46057b View commit details
    Browse the repository at this point in the history

Commits on Sep 28, 2024

  1. Configuration menu
    Copy the full SHA
    76bce58 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    ed417f4 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    6ca5e29 View commit details
    Browse the repository at this point in the history
  4. Further clarificarion for atomic and UnsafeCell docs:

    - UnsafeCell: mention the term "data race", and reference the data race definition
    - atomic: failing RMWs are just reads, reorder and reword docs
    RalfJung committed Sep 28, 2024
    Configuration menu
    Copy the full SHA
    96be76b View commit details
    Browse the repository at this point in the history
  5. compiletest: rename "runtest/crash.rs" to "runtest/crashes.rs" to be …

    …in line with the test directory
    
    r? jieyouxu
    matthiaskrgr committed Sep 28, 2024
    Configuration menu
    Copy the full SHA
    84c944c View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    e174b92 View commit details
    Browse the repository at this point in the history
  7. Rollup merge of rust-lang#128778 - RalfJung:atomic-read-read-races, r…

    …=Mark-Simulacrum
    
    atomics: allow atomic and non-atomic reads to race
    
    We currently define our atomics in terms of C++ `atomic_ref`. That has the unfortunate side-effect of making it UB for an atomic and a non-atomic read to race (concretely, [this code](https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=d1a743774e60923db33def7fe314d754) has UB). There's really no good reason for this, all the academic models of the C++ memory model I am aware of allow this -- C++ just disallows this because of their insistence on an "object model" with typed memory, where `atomic_ref` temporarily creates an "atomic object" that may not be accesses via regular non-atomic operations.
    
    So instead of tying our operations to `atomic_ref`, let us tie them directly to the underlying C++ memory model. I am not sure what is the best way to phrase this, so here's a first attempt.
    
    We also carve out an exception from the "no mixed-size atomic accesses" rule to permit mixed-size atomic reads -- given that we permit mixed-size non-atomic reads, it seems odd that this would be disallowed for atomic reads. However, when an atomic write races with any other atomic operation, they must use the same size.
    
    With this change, it is finally the case that every non-atomic access can be replaced by an atomic access without introducing UB.
    
    Cc `@rust-lang/opsem` `@chorman0773` `@m-ou-se` `@WaffleLapkin` `@Amanieu`
    
    Fixes rust-lang/unsafe-code-guidelines#483
    matthiaskrgr authored Sep 28, 2024
    Configuration menu
    Copy the full SHA
    5e4eab4 View commit details
    Browse the repository at this point in the history
  8. Rollup merge of rust-lang#130918 - onur-ozkan:better-llvm-submodule-h…

    …andling, r=Kobzol
    
    simplify LLVM submodule handling
    
    Fixes rust-lang#130906.
    matthiaskrgr authored Sep 28, 2024
    Configuration menu
    Copy the full SHA
    f33fa3f View commit details
    Browse the repository at this point in the history
  9. Rollup merge of rust-lang#130960 - cuviper:cdylib-soname, r=petrochenkov

    Only add an automatic SONAME for Rust dylibs
    
    rust-lang#126094 added an automatic relative `SONAME` to all dynamic libraries, but it was really only needed for Rust `--crate-type="dylib"`. In Fedora, it was a surprise to see `SONAME` on `"cdylib"` libraries like Python modules, especially because that generates an undesirable RPM `Provides`. We can instead add a `SONAME` just for Rust dylibs by passing the crate-type argument farther.
    
    Ref: https://bugzilla.redhat.com/show_bug.cgi?id=2314879
    matthiaskrgr authored Sep 28, 2024
    Configuration menu
    Copy the full SHA
    cfe0cff View commit details
    Browse the repository at this point in the history
  10. Rollup merge of rust-lang#130973 - matthiaskrgr:crash_rename, r=jieyouxu

    compiletest: rename "runtest/crash.rs" to "runtest/crashes.rs" to be in line with the test directory
    
    r? jieyouxu
    matthiaskrgr authored Sep 28, 2024
    Configuration menu
    Copy the full SHA
    1d29bfc View commit details
    Browse the repository at this point in the history
  11. Rollup merge of rust-lang#130976 - matthiaskrgr:clonee, r=jieyouxu

    remove couple redundant clones
    matthiaskrgr authored Sep 28, 2024
    Configuration menu
    Copy the full SHA
    2fca8e5 View commit details
    Browse the repository at this point in the history