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 9 pull requests #107324

Closed
wants to merge 120 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
120 commits
Select commit Hold shift + click to select a range
67b711a
Rename `assert_uninit_valid` intrinsic
Noratrieb Dec 12, 2022
98a276b
Merge commit '2bb3996244cf1b89878da9e39841e9f6bf061602' into sync_cg_…
bjorn3 Dec 14, 2022
b16dd91
Merge branch 'sync_from_rust'
bjorn3 Dec 14, 2022
808cba2
Extract Compiler creation from tests.rs
bjorn3 Dec 15, 2022
f626185
Update portable-simd to 582239ac3b32007613df04d7ffa78dc30f4c5645
bjorn3 Dec 15, 2022
0865e5a
Set RUSTDOCFLAGS again
bjorn3 Dec 15, 2022
06be70e
Implement simd_gather and simd_scatter (#1309)
bjorn3 Dec 15, 2022
e2a2739
Update not yet supported section of the readme
bjorn3 Dec 15, 2022
d74e5b6
Update actions/upload-artifact to v3
bjorn3 Dec 15, 2022
d841f93
Add .comment section with producer name
bjorn3 Dec 15, 2022
e082eeb
Run verifier checks during rustc tests too
bjorn3 Dec 15, 2022
cc3ac00
Move many env vars from CI configuration to the build system
bjorn3 Dec 15, 2022
6c88b08
Fix some build steps on Windows
bjorn3 Dec 15, 2022
1ca07b9
Fix running simple-raytracer benchmark on Windows
bjorn3 Dec 15, 2022
280fb29
Start running regex-shootout-regex-dna on Windows again
bjorn3 Dec 15, 2022
e735206
Unify Windows and non-Windows CI
bjorn3 Dec 15, 2022
a501d96
Merge branch 'staging'
bjorn3 Dec 15, 2022
9ca82a9
Fix ICE on unsized locals
bjorn3 Dec 16, 2022
b5ac64b
Don't PrintOnPanic on fatal errors
bjorn3 Dec 16, 2022
ec92c3e
Fix ICE on incompatible declarations of entry symbol
bjorn3 Dec 16, 2022
9165542
Ensure Cranelift errors are reported deterministically
bjorn3 Dec 16, 2022
14ca1df
Enable debug assertions on CI
bjorn3 Dec 16, 2022
ab0e2aa
Revert "Don't PrintOnPanic on fatal errors"
bjorn3 Dec 16, 2022
1c724ee
Re-enable some rustc tests
bjorn3 Dec 16, 2022
dffa6ac
Fix crash after simd type validation error
bjorn3 Dec 16, 2022
ee05e4d
Don't ICE on unimplemented call convs
bjorn3 Dec 16, 2022
8b47801
Don't ICE on C-cmse-nonsecure-call either
bjorn3 Dec 16, 2022
928d656
Auto merge of #105613 - Nilstrieb:rename-assert_uninit_valid, r=RalfJung
bors Dec 21, 2022
debd45c
Update to cranelift 0.91
bjorn3 Dec 13, 2022
97e2213
Enable inline stack probes on AArch64
bjorn3 Dec 22, 2022
571405d
Enable some fixed rustc tests
bjorn3 Jan 4, 2023
4c97569
Move patched sysroot from build_sysroot/ to download/
bjorn3 Jan 5, 2023
da37e16
Remove debuginfo files for compiled y.rs in clean_all.sh
bjorn3 Jan 5, 2023
e14e5c2
Don't use hyperfine during testing
bjorn3 Jan 5, 2023
20429c0
Merge pull request #1338 from bjorn3/build_system_rework5
bjorn3 Jan 5, 2023
4e47bd0
Change `src/test` to `tests` in source files, fix tidy and tests
albertlarsan68 Jan 5, 2023
fb788e3
Don't install hyperfine in y.rs prepare
bjorn3 Jan 11, 2023
caacef2
Retry downloads on network failure
bjorn3 Jan 11, 2023
8686383
Rustfmt
bjorn3 Jan 11, 2023
dbfbb29
Move LLVM simple-raytracer build to ./y.rs bench
bjorn3 Jan 13, 2023
cf22470
Disable CG_CLIF_DISPLAY_CG_TIME by default
bjorn3 Jan 13, 2023
70a1cb9
Pass around Compiler instead of target triples
bjorn3 Jan 13, 2023
f311ef5
Share cross-compilation code between building and testing
bjorn3 Jan 13, 2023
bb7ab82
Remove a lot of redundant rustc arguments for tests
bjorn3 Jan 13, 2023
af99a36
Use sparse cargo registry
bjorn3 Jan 13, 2023
397fafa
Don't require git user to be configured for testing rust
bjorn3 Jan 13, 2023
63fae6a
Introduce helpers for common test case commands
bjorn3 Jan 13, 2023
4074569
Add fixme
bjorn3 Jan 13, 2023
9a15db6
Add git_command helper
bjorn3 Jan 13, 2023
890c612
Set core.autocrlf=false in the build system instead of CI config
bjorn3 Jan 13, 2023
1a89507
Don't use the diff command in regex test
bjorn3 Jan 13, 2023
957d78c
Fetch all cargo dependencies in ./y.rs prepare
bjorn3 Jan 13, 2023
be8f656
Pass --frozen to cargo to ensure ./y.rs prepare fetches all deps
bjorn3 Jan 13, 2023
288c067
Set panic=abort for the build system
bjorn3 Jan 13, 2023
a346877
Rustfmt
bjorn3 Jan 13, 2023
3a27253
Enable VSCode formatOnSave
bjorn3 Jan 13, 2023
bdcbf47
Improve readme and build system help message
bjorn3 Jan 13, 2023
20a829a
Merge pull request #1339 from bjorn3/better_compiler_management
bjorn3 Jan 13, 2023
8af4eac
Update FreeBSD to 13.1
bjorn3 Jan 13, 2023
395eaa1
Remove Test nightly Cranelift workflow
bjorn3 Jan 14, 2023
9bc113f
Minor consistency improvement
bjorn3 Jan 14, 2023
a09712e
Use fs::remove_dir_all instead of cargo clean
bjorn3 Jan 14, 2023
5e452ba
Set RUSTC and RUSTDOC env vars to invalid values to catch forgetting …
bjorn3 Jan 14, 2023
fd1e824
Minor changes to the TestRunner::new signature
bjorn3 Jan 14, 2023
bbb7a3b
Rename Compiler variables for clarity
bjorn3 Jan 14, 2023
4dbafef
Return Compiler from build_sysroot
bjorn3 Jan 14, 2023
22c5249
Don't hard-code rustc path in get_rustc_version and get_default_sysroot
bjorn3 Jan 14, 2023
629eab7
Avoid hard-coded rustc when building wrappers
bjorn3 Jan 14, 2023
b31b74e
Merge pull request #1340 from bjorn3/non_rustup_build
bjorn3 Jan 14, 2023
c950f22
Build rtstartup for MinGW from scratch
bjorn3 Jan 14, 2023
6f1e177
Introduce SysrootTarget
bjorn3 Jan 14, 2023
0ac4456
Move rtstartup build to build_clif_sysroot_for_triple
bjorn3 Jan 14, 2023
fd83b27
Port llvm sysroot building to SysrootTarget too and dedup some code
bjorn3 Jan 14, 2023
280dffd
Build rtstartup for none sysroot too
bjorn3 Jan 14, 2023
1319732
Skip creating sysroot target dir if it will be empty
bjorn3 Jan 14, 2023
abcff71
Significantly speed up assembling of sysroots
bjorn3 Jan 15, 2023
0f4df8f
Eliminate a couple of extra calls
bjorn3 Jan 15, 2023
2b99b9f
Preserve split DWARF files when building archives.
khuey Jan 15, 2023
611c518
Merge pull request #1341 from bjorn3/build_sysroot_cleanup
bjorn3 Jan 15, 2023
7095783
Only run abi-cafe on cg_clif's CI
bjorn3 Jan 16, 2023
08c7230
Move compiler input and ouput paths into session
oli-obk Dec 7, 2022
1a6ab6c
Empty regions don't exist anymore, remove them from fluent
oli-obk Jan 17, 2023
49a9438
Remove double spaces after dots in comments
WaffleLapkin Nov 16, 2022
64e5f91
Handle diagnostics customization on the fluent side
oli-obk Jan 17, 2023
6fe4cf7
Migrate mir_build's borrow conflicts
mejrs Jan 17, 2023
739938d
Auto merge of #106810 - oli-obk:resolver_reverse_plumbing, r=petroche…
bors Jan 19, 2023
4e87f13
Fix a couple of TOCTOU occurences
bjorn3 Jan 19, 2023
954dfd1
Sync from rust 56ee85274e5a3a4dda92f3bf73d1664c74ff9c15
bjorn3 Jan 20, 2023
7d14e60
Rustup to rustc 1.68.0-nightly (4c83bd03a 2023-01-19)
bjorn3 Jan 20, 2023
92b4c76
Update rustup.sh for the moved dir of the sysroot source
bjorn3 Jan 20, 2023
fb6d048
Update patch
bjorn3 Jan 20, 2023
6c58be8
Fix rustc test suite
bjorn3 Jan 20, 2023
c6ad186
Use panic_nounwind and panic_cannot_unwind where necessary
bjorn3 Jan 20, 2023
219cdba
Fix clif ir writing for simd_gather
bjorn3 Jan 20, 2023
6eef214
Separate out abi-cafe runs into separate CI jobs
bjorn3 Jan 20, 2023
598f090
Update to Cranelift 0.92
bjorn3 Jan 7, 2023
afd5307
Move `ty::tls` to seperate file
Noratrieb Dec 31, 2022
0d11b77
Some ty::tls cleanups
Noratrieb Dec 31, 2022
db305d0
Use strict provenance APIs in ty::tls
Noratrieb Dec 31, 2022
f74ca88
Use a type-alias-impl-trait in `ObligationForest`
Noratrieb Jan 21, 2023
d7f6564
Encode AdtDef in the def-id loop.
cjgillot Jul 3, 2022
6ecf30d
Inline encode_enum_variant_info.
cjgillot Jul 3, 2022
4d11206
Tweak comments.
cjgillot Jan 22, 2023
b829bb7
Merge commit '598f0909568a51de8a2d1148f55a644fd8dffad0' into sync_cg_…
bjorn3 Jan 24, 2023
ae3aa71
Update tidy for cranelift-egraph removal and new windows-sys targets
bjorn3 Jan 24, 2023
1578b1c
Vendor newer version of cranelift-native
bjorn3 Jan 25, 2023
3808bc4
Fix CI
bjorn3 Jan 25, 2023
114eb2d
Replace ZST operands and debuginfo by constants.
cjgillot Jan 23, 2023
2a3b0e3
Rename method.
cjgillot Jan 25, 2023
49f4399
Generalize operation.
cjgillot Jan 25, 2023
d7f59e9
Custom mir: Add support for some remaining, easy to support constructs
JakobDegen Jan 26, 2023
a8f5028
Rollup merge of #106904 - khuey:preserve_debuginfo_for_rlibs, r=david…
matthiaskrgr Jan 26, 2023
d1bac82
Rollup merge of #106971 - oli-obk:tait_error, r=davidtwco
matthiaskrgr Jan 26, 2023
58e393c
Rollup merge of #106978 - mejrs:mir_build3, r=davidtwco
matthiaskrgr Jan 26, 2023
4d0bd4a
Rollup merge of #107150 - Nilstrieb:thread-local-cleanups, r=cjgillot
matthiaskrgr Jan 26, 2023
bde6876
Rollup merge of #107168 - Nilstrieb:if-a-tait-falls-in-the-forest,can…
matthiaskrgr Jan 26, 2023
bafd2a4
Rollup merge of #107189 - cjgillot:meta-adt, r=compiler-errors
matthiaskrgr Jan 26, 2023
85fed83
Rollup merge of #107269 - bjorn3:sync_cg_clif-2023-01-24, r=bjorn3
matthiaskrgr Jan 26, 2023
9c2336a
Rollup merge of #107270 - cjgillot:remove-zst, r=oli-obk
matthiaskrgr Jan 26, 2023
f183e30
Rollup merge of #107322 - JakobDegen:custom-mir, r=tmiasko
matthiaskrgr Jan 26, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 0 additions & 12 deletions compiler/rustc_borrowck/src/region_infer/opaque_types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -367,18 +367,6 @@ fn check_opaque_type_parameter_valid(
for (i, arg) in opaque_type_key.substs.iter().enumerate() {
let arg_is_param = match arg.unpack() {
GenericArgKind::Type(ty) => matches!(ty.kind(), ty::Param(_)),
GenericArgKind::Lifetime(lt) if lt.is_static() => {
tcx.sess
.struct_span_err(span, "non-defining opaque type use in defining scope")
.span_label(
tcx.def_span(opaque_generics.param_at(i, tcx).def_id),
"cannot use static lifetime; use a bound lifetime \
instead or remove the lifetime parameter from the \
opaque type",
)
.emit();
return false;
}
GenericArgKind::Lifetime(lt) => {
matches!(*lt, ty::ReEarlyBound(_) | ty::ReFree(_))
}
Expand Down
9 changes: 1 addition & 8 deletions compiler/rustc_codegen_cranelift/.cirrus.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,16 @@
task:
name: freebsd
freebsd_instance:
image: freebsd-12-1-release-amd64
image: freebsd-13-1-release-amd64
setup_rust_script:
- pkg install -y curl git bash
- curl https://sh.rustup.rs -sSf --output rustup.sh
- sh rustup.sh --default-toolchain none -y --profile=minimal
cargo_bin_cache:
folder: ~/.cargo/bin
target_cache:
folder: target
prepare_script:
- . $HOME/.cargo/env
- ./y.rs prepare
test_script:
- . $HOME/.cargo/env
- # Enable backtraces for easier debugging
- export RUST_BACKTRACE=1
- # Reduce amount of benchmark runs as they are slow
- export COMPILE_RUNS=2
- export RUN_RUNS=2
- ./y.rs test
140 changes: 50 additions & 90 deletions compiler/rustc_codegen_cranelift/.github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,10 @@ jobs:
runs-on: ${{ matrix.os }}
timeout-minutes: 60

defaults:
run:
shell: bash

strategy:
fail-fast: false
matrix:
Expand All @@ -46,36 +50,31 @@ jobs:
- os: ubuntu-latest
env:
TARGET_TRIPLE: s390x-unknown-linux-gnu
- os: windows-latest
env:
TARGET_TRIPLE: x86_64-pc-windows-msvc
- os: windows-latest
env:
TARGET_TRIPLE: x86_64-pc-windows-gnu

steps:
- uses: actions/checkout@v3

- name: Cache cargo installed crates
uses: actions/cache@v3
with:
path: ~/.cargo/bin
key: ${{ runner.os }}-cargo-installed-crates

- name: Cache cargo registry and index
uses: actions/cache@v3
with:
path: |
~/.cargo/registry
~/.cargo/git
key: ${{ runner.os }}-cargo-registry-and-index-${{ hashFiles('**/Cargo.lock') }}

- name: Cache cargo target dir
uses: actions/cache@v3
with:
path: build/cg_clif
key: ${{ runner.os }}-cargo-build-target-${{ hashFiles('rust-toolchain', '**/Cargo.lock') }}
key: ${{ runner.os }}-${{ matrix.env.TARGET_TRIPLE }}-cargo-build-target-${{ hashFiles('rust-toolchain', '**/Cargo.lock') }}

- name: Set MinGW as the default toolchain
if: matrix.os == 'windows-latest' && matrix.env.TARGET_TRIPLE == 'x86_64-pc-windows-gnu'
run: rustup set default-host x86_64-pc-windows-gnu

- name: Install MinGW toolchain and wine
if: matrix.os == 'ubuntu-latest' && matrix.env.TARGET_TRIPLE == 'x86_64-pc-windows-gnu'
run: |
sudo apt-get update
sudo apt-get install -y gcc-mingw-w64-x86-64 wine-stable
rustup target add x86_64-pc-windows-gnu

- name: Install AArch64 toolchain and qemu
if: matrix.os == 'ubuntu-latest' && matrix.env.TARGET_TRIPLE == 'aarch64-unknown-linux-gnu'
Expand All @@ -89,6 +88,13 @@ jobs:
sudo apt-get update
sudo apt-get install -y gcc-s390x-linux-gnu qemu-user

- name: Use sparse cargo registry
run: |
cat >> ~/.cargo/config.toml <<EOF
[unstable]
sparse-registry = true
EOF

- name: Prepare dependencies
run: ./y.rs prepare

Expand All @@ -104,70 +110,54 @@ jobs:
- name: Test
env:
TARGET_TRIPLE: ${{ matrix.env.TARGET_TRIPLE }}
run: |
# Enable backtraces for easier debugging
export RUST_BACKTRACE=1

# Reduce amount of benchmark runs as they are slow
export COMPILE_RUNS=2
export RUN_RUNS=2

# Enable extra checks
export CG_CLIF_ENABLE_VERIFIER=1

./y.rs test
run: ./y.rs test

- name: Package prebuilt cg_clif
run: tar cvfJ cg_clif.tar.xz dist

- name: Upload prebuilt cg_clif
if: matrix.env.TARGET_TRIPLE != 'x86_64-pc-windows-gnu'
uses: actions/upload-artifact@v2
if: matrix.os == 'windows-latest' || matrix.env.TARGET_TRIPLE != 'x86_64-pc-windows-gnu'
uses: actions/upload-artifact@v3
with:
name: cg_clif-${{ matrix.env.TARGET_TRIPLE }}
path: cg_clif.tar.xz

- name: Upload prebuilt cg_clif (cross compile)
if: matrix.env.TARGET_TRIPLE == 'x86_64-pc-windows-gnu'
if: matrix.os != 'windows-latest' && matrix.env.TARGET_TRIPLE == 'x86_64-pc-windows-gnu'
uses: actions/upload-artifact@v3
with:
name: cg_clif-${{ runner.os }}-cross-x86_64-mingw
path: cg_clif.tar.xz

windows:

abi_cafe:
runs-on: ${{ matrix.os }}
timeout-minutes: 60

defaults:
run:
shell: bash

strategy:
fail-fast: false
fail-fast: true
matrix:
include:
# Native Windows build with MSVC
- os: ubuntu-latest
env:
TARGET_TRIPLE: x86_64-unknown-linux-gnu
- os: macos-latest
env:
TARGET_TRIPLE: x86_64-apple-darwin
- os: windows-latest
env:
TARGET_TRIPLE: x86_64-pc-windows-msvc
# cross-compile from Windows to Windows MinGW
- os: windows-latest
env:
TARGET_TRIPLE: x86_64-pc-windows-gnu

steps:
- uses: actions/checkout@v3

- name: Cache cargo installed crates
uses: actions/cache@v3
with:
path: ~/.cargo/bin
key: ${{ runner.os }}-${{ matrix.env.TARGET_TRIPLE }}-cargo-installed-crates

- name: Cache cargo registry and index
uses: actions/cache@v3
with:
path: |
~/.cargo/registry
~/.cargo/git
key: ${{ runner.os }}-${{ matrix.env.TARGET_TRIPLE }}-cargo-registry-and-index-${{ hashFiles('**/Cargo.lock') }}

- name: Cache cargo target dir
uses: actions/cache@v3
with:
Expand All @@ -178,50 +168,20 @@ jobs:
if: matrix.env.TARGET_TRIPLE == 'x86_64-pc-windows-gnu'
run: rustup set default-host x86_64-pc-windows-gnu

- name: Prepare dependencies
- name: Use sparse cargo registry
run: |
git config --global core.autocrlf false
rustc y.rs -o y.exe -g
./y.exe prepare
cat >> ~/.cargo/config.toml <<EOF
[unstable]
sparse-registry = true
EOF

- name: Build without unstable features
env:
TARGET_TRIPLE: ${{ matrix.env.TARGET_TRIPLE }}
# This is the config rust-lang/rust uses for builds
run: ./y.rs build --no-unstable-features
- name: Prepare dependencies
run: ./y.rs prepare

- name: Build
run: ./y.rs build --sysroot none

- name: Test
run: |
# Enable backtraces for easier debugging
$Env:RUST_BACKTRACE=1

# Reduce amount of benchmark runs as they are slow
$Env:COMPILE_RUNS=2
$Env:RUN_RUNS=2

# Enable extra checks
$Env:CG_CLIF_ENABLE_VERIFIER=1

# WIP Disable some tests

# This fails due to some weird argument handling by hyperfine, not an actual regression
# more of a build system issue
(Get-Content config.txt) -replace '(bench.simple-raytracer)', '# $1' | Out-File config.txt

# This fails with a different output than expected
(Get-Content config.txt) -replace '(test.regex-shootout-regex-dna)', '# $1' | Out-File config.txt

./y.exe test

- name: Package prebuilt cg_clif
# don't use compression as xzip isn't supported by tar on windows and bzip2 hangs
run: tar cvf cg_clif.tar dist

- name: Upload prebuilt cg_clif
uses: actions/upload-artifact@v3
with:
name: cg_clif-${{ matrix.env.TARGET_TRIPLE }}
path: cg_clif.tar
- name: Test abi-cafe
env:
TARGET_TRIPLE: ${{ matrix.env.TARGET_TRIPLE }}
run: ./y.rs abi-cafe

This file was deleted.

Loading