Stream: git-wasmtime

Topic: wasmtime / issue #5901 Cranelift: Wrong result for `atomi...


view this post on Zulip Wasmtime GitHub notifications bot (Mar 01 2023 at 11:18):

afonso360 opened issue #5901:

:wave: Hey,

Fuzzgen found this overnight

.clif Test Case

test interpret
test run
target riscv64gc

function %a(i8) -> i8 sext system_v {
    ss2 = explicit_slot 2

block0(v0: i8):
    v2 = iconst.i16 0x00ff
    v3 = stack_addr.i64 ss2
    store v2, v3

    v4 = stack_addr.i64 ss2+1
    v5 = atomic_cas v4, v0, v0
    return v5
}

; run: %a(0) == 0

Steps to Reproduce

Expected Results

The test to pass

Actual Results

     Running `/home/afonso/git/qemu/qemu-7.2.0/build/qemu-riscv64 -cpu any,zba=true,zbb=true,zbc=true,zbs=true,zbkb=true,zbkc=true,zbkx=true,zknd=true,zkne=true,zknh=true,zksed=true,zksh=true,zkr=true -L /usr/riscv64-linux-gnu -E LD_LIBRARY_PATH=/usr/riscv64-linux-gnu/lib /home/afonso/git/wasmtime/target/riscv64gc-unknown-linux-gnu/debug/clif-util test ./lmao.clif`
 ERROR cranelift_filetests::concurrent > FAIL: run
FAIL ./lmao.clif: run

Caused by:
    Failed test: run: %a(0) == 0, actual: -1
1 tests
Error: 1 failure

Versions and Environment

Cranelift version or commit: main

Operating system: Linux

Architecture: riscv64

Extra Info

CC: @yuyang-ok

view this post on Zulip Wasmtime GitHub notifications bot (Mar 01 2023 at 11:18):

afonso360 labeled issue #5901:

:wave: Hey,

Fuzzgen found this overnight

.clif Test Case

test interpret
test run
target riscv64gc

function %a(i8) -> i8 sext system_v {
    ss2 = explicit_slot 2

block0(v0: i8):
    v2 = iconst.i16 0x00ff
    v3 = stack_addr.i64 ss2
    store v2, v3

    v4 = stack_addr.i64 ss2+1
    v5 = atomic_cas v4, v0, v0
    return v5
}

; run: %a(0) == 0

Steps to Reproduce

Expected Results

The test to pass

Actual Results

     Running `/home/afonso/git/qemu/qemu-7.2.0/build/qemu-riscv64 -cpu any,zba=true,zbb=true,zbc=true,zbs=true,zbkb=true,zbkc=true,zbkx=true,zknd=true,zkne=true,zknh=true,zksed=true,zksh=true,zkr=true -L /usr/riscv64-linux-gnu -E LD_LIBRARY_PATH=/usr/riscv64-linux-gnu/lib /home/afonso/git/wasmtime/target/riscv64gc-unknown-linux-gnu/debug/clif-util test ./lmao.clif`
 ERROR cranelift_filetests::concurrent > FAIL: run
FAIL ./lmao.clif: run

Caused by:
    Failed test: run: %a(0) == 0, actual: -1
1 tests
Error: 1 failure

Versions and Environment

Cranelift version or commit: main

Operating system: Linux

Architecture: riscv64

Extra Info

CC: @yuyang-ok

view this post on Zulip Wasmtime GitHub notifications bot (Mar 01 2023 at 11:18):

afonso360 labeled issue #5901:

:wave: Hey,

Fuzzgen found this overnight

.clif Test Case

test interpret
test run
target riscv64gc

function %a(i8) -> i8 sext system_v {
    ss2 = explicit_slot 2

block0(v0: i8):
    v2 = iconst.i16 0x00ff
    v3 = stack_addr.i64 ss2
    store v2, v3

    v4 = stack_addr.i64 ss2+1
    v5 = atomic_cas v4, v0, v0
    return v5
}

; run: %a(0) == 0

Steps to Reproduce

Expected Results

The test to pass

Actual Results

     Running `/home/afonso/git/qemu/qemu-7.2.0/build/qemu-riscv64 -cpu any,zba=true,zbb=true,zbc=true,zbs=true,zbkb=true,zbkc=true,zbkx=true,zknd=true,zkne=true,zknh=true,zksed=true,zksh=true,zkr=true -L /usr/riscv64-linux-gnu -E LD_LIBRARY_PATH=/usr/riscv64-linux-gnu/lib /home/afonso/git/wasmtime/target/riscv64gc-unknown-linux-gnu/debug/clif-util test ./lmao.clif`
 ERROR cranelift_filetests::concurrent > FAIL: run
FAIL ./lmao.clif: run

Caused by:
    Failed test: run: %a(0) == 0, actual: -1
1 tests
Error: 1 failure

Versions and Environment

Cranelift version or commit: main

Operating system: Linux

Architecture: riscv64

Extra Info

CC: @yuyang-ok

view this post on Zulip Wasmtime GitHub notifications bot (Mar 01 2023 at 11:18):

afonso360 labeled issue #5901:

:wave: Hey,

Fuzzgen found this overnight

.clif Test Case

test interpret
test run
target riscv64gc

function %a(i8) -> i8 sext system_v {
    ss2 = explicit_slot 2

block0(v0: i8):
    v2 = iconst.i16 0x00ff
    v3 = stack_addr.i64 ss2
    store v2, v3

    v4 = stack_addr.i64 ss2+1
    v5 = atomic_cas v4, v0, v0
    return v5
}

; run: %a(0) == 0

Steps to Reproduce

Expected Results

The test to pass

Actual Results

     Running `/home/afonso/git/qemu/qemu-7.2.0/build/qemu-riscv64 -cpu any,zba=true,zbb=true,zbc=true,zbs=true,zbkb=true,zbkc=true,zbkx=true,zknd=true,zkne=true,zknh=true,zksed=true,zksh=true,zkr=true -L /usr/riscv64-linux-gnu -E LD_LIBRARY_PATH=/usr/riscv64-linux-gnu/lib /home/afonso/git/wasmtime/target/riscv64gc-unknown-linux-gnu/debug/clif-util test ./lmao.clif`
 ERROR cranelift_filetests::concurrent > FAIL: run
FAIL ./lmao.clif: run

Caused by:
    Failed test: run: %a(0) == 0, actual: -1
1 tests
Error: 1 failure

Versions and Environment

Cranelift version or commit: main

Operating system: Linux

Architecture: riscv64

Extra Info

CC: @yuyang-ok

view this post on Zulip Wasmtime GitHub notifications bot (Mar 07 2023 at 14:19):

afonso360 closed issue #5901:

:wave: Hey,

Fuzzgen found this overnight

.clif Test Case

test interpret
test run
target riscv64gc

function %a(i8) -> i8 sext system_v {
    ss2 = explicit_slot 2

block0(v0: i8):
    v2 = iconst.i16 0x00ff
    v3 = stack_addr.i64 ss2
    store v2, v3

    v4 = stack_addr.i64 ss2+1
    v5 = atomic_cas v4, v0, v0
    return v5
}

; run: %a(0) == 0

Steps to Reproduce

Expected Results

The test to pass

Actual Results

     Running `/home/afonso/git/qemu/qemu-7.2.0/build/qemu-riscv64 -cpu any,zba=true,zbb=true,zbc=true,zbs=true,zbkb=true,zbkc=true,zbkx=true,zknd=true,zkne=true,zknh=true,zksed=true,zksh=true,zkr=true -L /usr/riscv64-linux-gnu -E LD_LIBRARY_PATH=/usr/riscv64-linux-gnu/lib /home/afonso/git/wasmtime/target/riscv64gc-unknown-linux-gnu/debug/clif-util test ./lmao.clif`
 ERROR cranelift_filetests::concurrent > FAIL: run
FAIL ./lmao.clif: run

Caused by:
    Failed test: run: %a(0) == 0, actual: -1
1 tests
Error: 1 failure

Versions and Environment

Cranelift version or commit: main

Operating system: Linux

Architecture: riscv64

Extra Info

CC: @yuyang-ok


Last updated: Dec 23 2024 at 13:07 UTC