Skip to content

Commit 54a832b

Browse files
committed
some tidy fixes
1 parent 3e54f15 commit 54a832b

8 files changed

Lines changed: 18 additions & 35 deletions

File tree

compiler/rustc_target/src/spec/mod.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1764,7 +1764,6 @@ supported_targets! {
17641764

17651765
("bpfeb-unknown-none", bpfeb_unknown_none),
17661766
("bpfel-unknown-none", bpfel_unknown_none),
1767-
("bpfel-unknown-unknown", bpfel_unknown_unknown),
17681767
("sbf-solana-solana", sbf_solana_solana),
17691768
("sbpf-solana-solana", sbpf_solana_solana),
17701769
("sbpfv0-solana-solana", sbpfv0_solana_solana),

library/compiler-builtins/ci/ci-util.py

Lines changed: 15 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -40,14 +40,10 @@
4040
4141
Note that `--extract` will overwrite files in `gungraun-home`.
4242
43-
check-regressions [--home iai-home] [--allow-pr-override pr_number]
44-
Check `iai-home` (or `iai-home` if unspecified) for `summary.json`
45-
files and see if there are any regressions. This is used as a workaround
46-
for `iai-callgrind` not exiting with error status; see
47-
<https://github.com/iai-callgrind/iai-callgrind/issues/337>.
48-
49-
If `--allow-pr-override` is specified, the regression check will not exit
50-
with failure if any line in the PR starts with `allow-regressions`.
43+
handle-bench-regressions PR_NUMBER
44+
Exit with success if the pull request contains a line starting with
45+
`ci: allow-regressions`, indicating that regressions in benchmarks should
46+
be accepted. Otherwise, exit 1.
5147
"""
5248
)
5349

@@ -428,27 +424,22 @@ def locate_baseline(flags: list[str]) -> None:
428424
eprint("baseline extracted successfully")
429425

430426

431-
def check_iai_regressions(args: list[str]):
432-
"""Find regressions in iai summary.json files, exit with failure if any are
433-
found.
434-
"""
427+
def handle_bench_regressions(args: list[str]):
428+
"""Exit with error unless the PR message contains an ignore directive."""
435429

436-
iai_home_str = "iai-home"
437-
pr_number = None
430+
match args:
431+
case [pr_number]:
432+
pr_number = pr_number
433+
case _:
434+
eprint(USAGE)
435+
exit(1)
438436

439437
pr = PrInfo.from_pr(pr_number)
440438
if pr.cfg.allow_regressions:
441439
eprint("PR allows regressions")
442440
return
443441

444-
eprint("Found regressions:", json.dumps(regressions, indent=4))
445-
446-
if pr_number is not None:
447-
pr = PrInfo.load(pr_number)
448-
if pr.contains_directive(REGRESSION_DIRECTIVE):
449-
eprint("PR allows regressions, returning")
450-
return
451-
442+
eprint("Regressions were found; benchmark failed")
452443
exit(1)
453444

454445

@@ -459,8 +450,8 @@ def main():
459450
ctx.emit_workflow_output()
460451
case ["locate-baseline", *flags]:
461452
locate_baseline(flags)
462-
case ["check-regressions", *args]:
463-
check_iai_regressions(args)
453+
case ["handle-bench-regressions", *args]:
454+
handle_bench_regressions(args)
464455
case ["--help" | "-h"]:
465456
print(USAGE)
466457
exit()

library/std/src/sys/pal/sbf/path.rs

Whitespace-only changes.

library/std/src/sys/pal/sbf/thread.rs

Whitespace-only changes.

src/bootstrap/src/core/config/config.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -611,8 +611,8 @@ impl Config {
611611
offload_clang_dir: llvm_clang_dir,
612612
polly: llvm_polly,
613613
clang: llvm_clang,
614-
enable_warnings: llvm_enable_warnings,
615614
enable_projects: llvm_enable_projects,
615+
enable_warnings: llvm_enable_warnings,
616616
download_ci_llvm: llvm_download_ci_llvm,
617617
build_config: llvm_build_config,
618618
} = toml.llvm.unwrap_or_default();
@@ -1377,8 +1377,8 @@ impl Config {
13771377
llvm_clang_cl,
13781378
llvm_clang_dir: llvm_clang_dir.map(PathBuf::from),
13791379
llvm_cxxflags,
1380-
llvm_enable_warnings: llvm_enable_warnings.unwrap_or(false),
13811380
llvm_enable_projects: llvm_enable_projects,
1381+
llvm_enable_warnings: llvm_enable_warnings.unwrap_or(false),
13821382
llvm_enzyme: llvm_enzyme.unwrap_or(false),
13831383
llvm_experimental_targets,
13841384
llvm_from_ci,

src/bootstrap/src/lib.rs

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1314,13 +1314,6 @@ impl Build {
13141314
base.push("-fno-omit-frame-pointer".into());
13151315
}
13161316

1317-
if &*target.triple == "bpfel-unknown-unknown" {
1318-
base.push("-Xclang".into());
1319-
base.push("-target-feature".into());
1320-
base.push("-Xclang".into());
1321-
base.push("+solana".into());
1322-
}
1323-
13241317
if let Some(map_to) = self.debuginfo_map_to(which, RemapScheme::NonCompiler) {
13251318
let map = format!("{}={}", self.src.display(), map_to);
13261319
let cc = self.cc(target);

src/ci/docker/host-x86_64/dist-various-1/Dockerfile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,6 @@ ENV TARGETS=$TARGETS,armv8r-none-eabihf
119119
ENV TARGETS=$TARGETS,thumbv7neon-unknown-linux-gnueabihf
120120
ENV TARGETS=$TARGETS,armv7a-none-eabi
121121
ENV TARGETS=$TARGETS,armv7a-none-eabihf
122-
ENV TARGETS=$TARGETS,bpfel-unknown-unknown
123122

124123
ENV CFLAGS_armv5te_unknown_linux_musleabi="-march=armv5te -marm -mfloat-abi=soft" \
125124
CFLAGS_arm_unknown_linux_musleabi="-march=armv6 -marm" \

src/tools/tidy/src/target_specific_tests.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,7 @@ fn arch_to_llvm_component(arch: &str) -> String {
115115
_ if arch.starts_with("mips") => "mips".into(),
116116
_ if arch.starts_with("powerpc") => "powerpc".into(),
117117
_ if arch.starts_with("riscv") => "riscv".into(),
118+
_ if arch.starts_with("sbpf") => "sbf".into(),
118119
_ => arch.to_ascii_lowercase(),
119120
}
120121
}

0 commit comments

Comments
 (0)