Enable more tests on AArch64 (#2994)

Copyright (c) 2021, Arm Limited.
This commit is contained in:
Anton Kirilov
2021-06-21 18:26:44 +01:00
committed by GitHub
parent 443eb7a843
commit cb93726250
9 changed files with 44 additions and 28 deletions

View File

@@ -5,7 +5,9 @@ mod debug;
mod externals;
mod fuel;
mod func;
mod funcref;
mod fuzzing;
mod gc;
mod globals;
mod host_funcs;
mod iloop;
@@ -29,14 +31,7 @@ mod table;
mod traps;
mod wast;
// TODO(#1886): Cranelift only supports reference types on x64.
#[cfg(target_arch = "x86_64")]
mod funcref;
#[cfg(target_arch = "x86_64")]
mod gc;
/// A helper to compile a module in a new store with reference types enabled.
#[cfg(target_arch = "x86_64")]
pub(crate) fn ref_types_module(
source: &str,
) -> anyhow::Result<(wasmtime::Store<()>, wasmtime::Module)> {
@@ -54,3 +49,11 @@ pub(crate) fn ref_types_module(
Ok((store, module))
}
/// A helper determining whether the pooling allocator tests should be skipped.
pub(crate) fn skip_pooling_allocator_tests() -> bool {
// There are a couple of issues when running the pooling allocator tests under QEMU:
// - high memory usage that may exceed the limits imposed by the environment (e.g. CI)
// - https://github.com/bytecodealliance/wasmtime/pull/2518#issuecomment-747280133
std::env::var("WASMTIME_TEST_NO_HOG_MEMORY").is_ok()
}