cli: adds compile command and -cachedir option (#945)

This adds a `compile` command and a `-cachedir` option to expose our
compilation cache to end users. This allows substantial speedup
especially for large wasm.

Signed-off-by: Adrian Cole <adrian@tetrate.io>
Co-authored-by: Anuraag Agrawal <anuraaga@gmail.com>
This commit is contained in:
Crypt Keeper
2022-12-20 13:56:29 +08:00
committed by GitHub
parent d63c747d53
commit 796fca4689
7 changed files with 376 additions and 58 deletions

View File

@@ -3,7 +3,6 @@ package wasmdebug_test
import (
"fmt"
"math"
"strings"
"sync"
"testing"
@@ -247,8 +246,6 @@ func TestDWARFLines_Line_Rust(t *testing.T) {
t.Run(fmt.Sprintf("%#x/%s", tc.offset, tc.exp), func(t *testing.T) {
actual := mod.DWARFLines.Line(tc.offset)
fmt.Println(strings.Join(actual, "\n"))
require.Equal(t, len(tc.exp), len(actual))
for i := range tc.exp {
require.Contains(t, actual[i], tc.exp[i])