forked from rust-lang/rust
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Auto merge of rust-lang#127489 - GuillaumeGomez:rollup-rhqfeom, r=Gui…
…llaumeGomez Rollup of 4 pull requests Successful merges: - rust-lang#126427 (Rewrite `intrinsic-unreachable`, `sepcomp-cci-copies`, `sepcomp-inlining` and `sepcomp-separate` `run-make` tests to rmake.rs) - rust-lang#127237 (Improve code of `run-make/llvm-ident`) - rust-lang#127325 (Migrate `target-cpu-native`, `target-specs` and `target-without-atomic-cas` `run-make` tests to rmake) - rust-lang#127482 (Infer async closure signature from (old-style) two-part `Fn` + `Future` bounds) Failed merges: - rust-lang#127357 (Remove `StructuredDiag`) r? `@ghost` `@rustbot` modify labels: rollup
- Loading branch information
Showing
20 changed files
with
329 additions
and
124 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
// intrinsics::unreachable tells the compiler that a certain point in the code | ||
// is not reachable by any means, which enables some useful optimizations. | ||
// In this test, exit-unreachable contains this instruction and exit-ret does not, | ||
// which means the emitted artifacts should be shorter in length. | ||
// See https://github.com/rust-lang/rust/pull/16970 | ||
|
||
//@ needs-asm-support | ||
//@ ignore-windows | ||
// Reason: Because of Windows exception handling, the code is not necessarily any shorter. | ||
|
||
use run_make_support::{fs_wrapper, rustc}; | ||
|
||
fn main() { | ||
rustc().opt().emit("asm").input("exit-ret.rs").run(); | ||
rustc().opt().emit("asm").input("exit-unreachable.rs").run(); | ||
assert!( | ||
fs_wrapper::read_to_string("exit-unreachable.s").lines().count() | ||
< fs_wrapper::read_to_string("exit-ret.s").lines().count() | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
// Check that cross-crate inlined items are inlined in all compilation units | ||
// that refer to them, and not in any other compilation units. | ||
// Note that we have to pass `-C codegen-units=6` because up to two CGUs may be | ||
// created for each source module (see `rustc_const_eval::monomorphize::partitioning`). | ||
// See https://github.com/rust-lang/rust/pull/16367 | ||
|
||
use run_make_support::{ | ||
count_regex_matches_in_files_with_extension, cwd, fs_wrapper, has_extension, regex, rustc, | ||
shallow_find_files, | ||
}; | ||
|
||
fn main() { | ||
rustc().input("cci_lib.rs").run(); | ||
rustc().input("foo.rs").emit("llvm-ir").codegen_units(6).arg("-Zinline-in-all-cgus").run(); | ||
let re = regex::Regex::new(r#"define\ .*cci_fn"#).unwrap(); | ||
assert_eq!(count_regex_matches_in_files_with_extension(&re, "ll"), 2); | ||
} |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.