Merge pull request #3009 from bjorn3/bye_x86_backend

[RFC] Remove the old x86 backend
This commit is contained in:
Chris Fallin
2021-09-30 09:20:14 -07:00
committed by GitHub
383 changed files with 258 additions and 40125 deletions

View File

@@ -133,44 +133,6 @@ check: exited with status
Ok(())
}
#[test]
#[ignore]
#[cfg(all(
any(target_os = "linux", target_os = "macos"),
target_pointer_width = "64",
// Ignore test on new backend. The value this is looking for is
// not available at the point that the breakpoint is set when
// compiled by the new backend.
feature = "old-x86-backend",
))]
pub fn test_debug_dwarf_ptr() -> Result<()> {
let output = lldb_with_script(
&[
"-g",
"--opt-level",
"0",
"tests/all/debug/testsuite/reverse-str.wasm",
],
r#"b reverse-str.c:9
r
p __vmctx->set(),&*s
c"#,
)?;
check_lldb_output(
&output,
r#"
check: Breakpoint 1: no locations (pending)
check: stop reason = breakpoint 1.1
check: frame #0
sameln: reverse(s=(__ptr =
check: "Hello, world."
check: resuming
"#,
)?;
Ok(())
}
#[test]
#[ignore]
#[cfg(all(

View File

@@ -108,27 +108,3 @@ check: DW_AT_decl_line (10)
"##,
)
}
#[test]
#[ignore]
#[cfg(all(
any(target_os = "linux", target_os = "macos"),
target_arch = "x86_64",
target_pointer_width = "64",
// Ignore test on new backend. This is a specific test with hardcoded
// offsets and the new backend compiles the return basic-block at a different
// offset, causing mismatches.
feature = "old-x86-backend",
))]
fn test_debug_dwarf5_translate_lines() -> Result<()> {
check_line_program(
"tests/all/debug/testsuite/fib-wasm-dwarf5.wasm",
r##"
check: Address Line Column File ISA Discriminator Flags
check: 0x000000000000013c 15 3 1 0 0
# The important point is that the following offset must be _after_ the `ret` instruction.
# FIXME: this +1 increment might vary on other archs.
nextln: 0x000000000000013d 15 3 1 0 0 end_sequence
"##,
)
}

View File

@@ -525,7 +525,6 @@ fn pass_cross_store_arg() -> anyhow::Result<()> {
}
#[test]
#[cfg_attr(feature = "old-x86-backend", ignore)]
fn externref_signature_no_reference_types() -> anyhow::Result<()> {
let mut config = Config::new();
config.wasm_reference_types(false);
@@ -569,7 +568,6 @@ fn trampolines_always_valid() -> anyhow::Result<()> {
}
#[test]
#[cfg(not(feature = "old-x86-backend"))]
fn typed_multiple_results() -> anyhow::Result<()> {
let mut store = Store::<()>::default();
let module = Module::new(
@@ -647,7 +645,6 @@ fn trap_doesnt_leak() -> anyhow::Result<()> {
}
#[test]
#[cfg(not(feature = "old-x86-backend"))]
fn wrap_multiple_results() -> anyhow::Result<()> {
fn test<T>(store: &mut Store<()>, t: T) -> anyhow::Result<()>
where

View File

@@ -189,7 +189,6 @@ fn many_live_refs() -> anyhow::Result<()> {
}
#[test]
#[cfg(not(feature = "old-x86-backend"))] // uses atomic instrs not implemented here
fn drop_externref_via_table_set() -> anyhow::Result<()> {
let (mut store, module) = ref_types_module(
r#"
@@ -285,7 +284,6 @@ fn global_drops_externref() -> anyhow::Result<()> {
}
#[test]
#[cfg(not(feature = "old-x86-backend"))] // uses atomic instrs not implemented here
fn table_drops_externref() -> anyhow::Result<()> {
test_engine(&Engine::default())?;
@@ -336,7 +334,6 @@ fn table_drops_externref() -> anyhow::Result<()> {
}
#[test]
#[cfg(not(feature = "old-x86-backend"))] // uses atomic instrs not implemented here
fn gee_i_sure_hope_refcounting_is_atomic() -> anyhow::Result<()> {
let mut config = Config::new();
config.wasm_reference_types(true);
@@ -426,7 +423,6 @@ fn global_init_no_leak() -> anyhow::Result<()> {
}
#[test]
#[cfg(not(feature = "old-x86-backend"))]
fn no_gc_middle_of_args() -> anyhow::Result<()> {
let (mut store, module) = ref_types_module(
r#"

View File

@@ -8,8 +8,6 @@
//! 32-bits, and right now object files aren't supported larger than 4gb anyway
//! so we would need a lot of other support necessary to exercise that.
#![cfg(not(feature = "old-x86-backend"))] // multi-value not supported here
use anyhow::Result;
use wasmtime::*;

View File

@@ -25,12 +25,6 @@ fn run_wast(wast: &str, strategy: Strategy, pooling: bool) -> anyhow::Result<()>
// by reference types.
let reftypes = simd || feature_found(wast, "reference-types");
// Threads & simd aren't implemented in the old backend, so skip those
// tests.
if (threads || simd) && cfg!(feature = "old-x86-backend") {
return Ok(());
}
let mut cfg = Config::new();
cfg.wasm_simd(simd)
.wasm_bulk_memory(bulk_mem)