Enables more tests for wazevo on amd64 (#1988)
Signed-off-by: Takeshi Yoneda <t.y.mathetake@gmail.com>
This commit is contained in:
2
.github/workflows/integration.yaml
vendored
2
.github/workflows/integration.yaml
vendored
@@ -228,7 +228,7 @@ jobs:
|
||||
- name: Run test binaries
|
||||
run: |
|
||||
cd ${{ env.STDLIB_TESTS }}
|
||||
go test -bench='BenchmarkTinyGo/' -benchtime=1x
|
||||
go test -bench='BenchmarkTinyGo/${{ matrix.compiler }}' -benchtime=1x
|
||||
|
||||
wasi-testsuite:
|
||||
name: wasi-testsuite
|
||||
|
||||
@@ -2,16 +2,16 @@ package opt_test
|
||||
|
||||
import (
|
||||
"context"
|
||||
"runtime"
|
||||
"testing"
|
||||
|
||||
"github.com/tetratelabs/wazero"
|
||||
"github.com/tetratelabs/wazero/experimental/opt"
|
||||
"github.com/tetratelabs/wazero/internal/platform"
|
||||
"github.com/tetratelabs/wazero/internal/testing/require"
|
||||
)
|
||||
|
||||
func TestUseOptimizingCompiler(t *testing.T) {
|
||||
if runtime.GOARCH != "arm64" {
|
||||
if !platform.CompilerSupported() {
|
||||
return
|
||||
}
|
||||
c := opt.NewRuntimeConfigOptimizingCompiler()
|
||||
|
||||
@@ -73,7 +73,6 @@ func (f fakeFinalizer) setFinalizer(obj interface{}, finalizer interface{}) {
|
||||
}
|
||||
|
||||
func TestEngine_CompileModule(t *testing.T) {
|
||||
skipOnAmd64(t)
|
||||
ctx := context.Background()
|
||||
e := NewEngine(ctx, 0, nil).(*engine)
|
||||
ff := fakeFinalizer{}
|
||||
|
||||
@@ -22,21 +22,12 @@ func TestMain(m *testing.M) {
|
||||
os.Exit(m.Run())
|
||||
}
|
||||
|
||||
// TODO: delete once we complete the implementation for amd64.
|
||||
func skipOnAmd64(t *testing.T) {
|
||||
if runtime.GOARCH == "amd64" {
|
||||
t.Skip("skip on amd64")
|
||||
}
|
||||
}
|
||||
|
||||
func TestNewEngine(t *testing.T) {
|
||||
skipOnAmd64(t)
|
||||
e := NewEngine(ctx, api.CoreFeaturesV1, nil)
|
||||
require.NotNil(t, e)
|
||||
}
|
||||
|
||||
func TestEngine_CompiledModuleCount(t *testing.T) {
|
||||
skipOnAmd64(t)
|
||||
e, ok := NewEngine(ctx, api.CoreFeaturesV1, nil).(*engine)
|
||||
require.True(t, ok)
|
||||
require.Equal(t, uint32(0), e.CompiledModuleCount())
|
||||
@@ -45,7 +36,6 @@ func TestEngine_CompiledModuleCount(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestEngine_DeleteCompiledModule(t *testing.T) {
|
||||
skipOnAmd64(t)
|
||||
e, ok := NewEngine(ctx, api.CoreFeaturesV1, nil).(*engine)
|
||||
require.True(t, ok)
|
||||
id := wasm.ModuleID{0xaa}
|
||||
|
||||
@@ -10,7 +10,6 @@ import (
|
||||
"math"
|
||||
"os"
|
||||
"path"
|
||||
"runtime"
|
||||
"strings"
|
||||
|
||||
"github.com/tetratelabs/wazero"
|
||||
@@ -92,9 +91,6 @@ func newCompilerConfig() wazero.RuntimeConfig {
|
||||
|
||||
//export test_signal_stack
|
||||
func test_signal_stack() {
|
||||
if runtime.GOARCH != "arm64" { // TODO: amd64.
|
||||
return
|
||||
}
|
||||
// (module
|
||||
// (func (export "long_loop")
|
||||
// (loop
|
||||
|
||||
Reference in New Issue
Block a user