Skip to content

Commit 4221073

Browse files
authored
Fix the new logged-filetests.rs test (#10605)
This test unfortunately didn't actually have any effect in CI. Locally setting `RUST_LOG` and running `cargo run test filetests` showed a panic in the s390x backend that this test was not uncovering. The reason that this test wasn't actually doing anything on CI is that it's tested adjacently with the `wasmtime-cli` crate. Both crates are tested with `--all-features` which enables the CLI's `disable-logging` feature which meant that all logging statements, including the ones we want to test, were compiled out. This commit fixes the s390x panic and then additionally adds a special CI job (repurposing an existing one) for testing just this test in isolation.
1 parent 096e5b2 commit 4221073

2 files changed

Lines changed: 8 additions & 6 deletions

File tree

.github/workflows/main.yml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -433,17 +433,18 @@ jobs:
433433
- uses: ./.github/actions/cancel-on-failure
434434
if: failure()
435435

436-
fiber_tests:
437-
name: wasmtime-fiber tests
436+
special_tests:
437+
name: One-off special tests
438438
runs-on: ubuntu-latest
439-
env:
440-
CARGO_NDK_VERSION: 2.12.2
439+
needs: determine
440+
if: needs.determine.outputs.run-full
441441
steps:
442442
- uses: actions/checkout@v4
443443
with:
444444
submodules: true
445445
- uses: ./.github/actions/install-rust
446446
- run: cargo test -p wasmtime-fiber --no-default-features
447+
- run: cargo test -p cranelift-tools --test logged-filetests
447448

448449
# common logic to cancel the entire run if this job fails
449450
- uses: ./.github/actions/cancel-on-failure
@@ -1200,7 +1201,7 @@ jobs:
12001201
- cargo_vet
12011202
- doc
12021203
- micro_checks
1203-
- fiber_tests
1204+
- special_tests
12041205
- clippy
12051206
- monolith_checks
12061207
- platform_checks

cranelift/codegen/src/isa/s390x/abi.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1036,7 +1036,8 @@ impl S390xMachineDeps {
10361036
// (but after restoring FPRs, which might clobber %r1).
10371037
let temp_dest = match dest {
10381038
CallInstDest::Indirect { reg }
1039-
if is_reg_saved_in_prologue(call_conv, reg.to_real_reg().unwrap()) =>
1039+
if reg.to_real_reg().is_some()
1040+
&& is_reg_saved_in_prologue(call_conv, reg.to_real_reg().unwrap()) =>
10401041
{
10411042
insts.push(Inst::Mov64 {
10421043
rd: writable_gpr(1),

0 commit comments

Comments
 (0)