mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-14 16:03:41 +00:00
Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 67b45dd14d |
-28
@@ -299,39 +299,30 @@ test: wasi-libc check-nodejs-version
|
|||||||
TEST_PACKAGES_SLOW = \
|
TEST_PACKAGES_SLOW = \
|
||||||
compress/bzip2 \
|
compress/bzip2 \
|
||||||
crypto/dsa \
|
crypto/dsa \
|
||||||
crypto/ecdsa \
|
|
||||||
index/suffixarray \
|
index/suffixarray \
|
||||||
|
|
||||||
# Standard library packages that pass tests quickly on darwin, linux, wasi, and windows
|
# Standard library packages that pass tests quickly on darwin, linux, wasi, and windows
|
||||||
TEST_PACKAGES_FAST = \
|
TEST_PACKAGES_FAST = \
|
||||||
cmp \
|
|
||||||
compress/lzw \
|
compress/lzw \
|
||||||
compress/zlib \
|
compress/zlib \
|
||||||
container/heap \
|
container/heap \
|
||||||
container/list \
|
container/list \
|
||||||
container/ring \
|
container/ring \
|
||||||
crypto/des \
|
crypto/des \
|
||||||
crypto/elliptic \
|
|
||||||
crypto/md5 \
|
crypto/md5 \
|
||||||
crypto/rc4 \
|
crypto/rc4 \
|
||||||
crypto/sha1 \
|
crypto/sha1 \
|
||||||
crypto/sha256 \
|
crypto/sha256 \
|
||||||
crypto/sha512 \
|
crypto/sha512 \
|
||||||
database/sql/driver \
|
|
||||||
debug/macho \
|
debug/macho \
|
||||||
embed \
|
|
||||||
embed/internal/embedtest \
|
embed/internal/embedtest \
|
||||||
encoding \
|
encoding \
|
||||||
encoding/ascii85 \
|
encoding/ascii85 \
|
||||||
encoding/asn1 \
|
|
||||||
encoding/base32 \
|
encoding/base32 \
|
||||||
encoding/base64 \
|
encoding/base64 \
|
||||||
encoding/csv \
|
encoding/csv \
|
||||||
encoding/hex \
|
encoding/hex \
|
||||||
go/ast \
|
|
||||||
go/format \
|
|
||||||
go/scanner \
|
go/scanner \
|
||||||
go/version \
|
|
||||||
hash \
|
hash \
|
||||||
hash/adler32 \
|
hash/adler32 \
|
||||||
hash/crc64 \
|
hash/crc64 \
|
||||||
@@ -343,7 +334,6 @@ TEST_PACKAGES_FAST = \
|
|||||||
math/cmplx \
|
math/cmplx \
|
||||||
net/http/internal/ascii \
|
net/http/internal/ascii \
|
||||||
net/mail \
|
net/mail \
|
||||||
net/textproto \
|
|
||||||
os \
|
os \
|
||||||
path \
|
path \
|
||||||
reflect \
|
reflect \
|
||||||
@@ -367,17 +357,11 @@ endif
|
|||||||
# archive/zip requires os.ReadAt, which is not yet supported on windows
|
# archive/zip requires os.ReadAt, which is not yet supported on windows
|
||||||
# bytes requires mmap
|
# bytes requires mmap
|
||||||
# compress/flate appears to hang on wasi
|
# compress/flate appears to hang on wasi
|
||||||
# context requires recover(), which is not yet supported on wasi
|
|
||||||
# crypto/aes requires recover(), which is not yet supported on wasi
|
|
||||||
# crypto/hmac fails on wasi, it exits with a "slice out of range" panic
|
# crypto/hmac fails on wasi, it exits with a "slice out of range" panic
|
||||||
# debug/plan9obj requires os.ReadAt, which is not yet supported on windows
|
# debug/plan9obj requires os.ReadAt, which is not yet supported on windows
|
||||||
# go/build/constraint requires recover(), which is not yet supported on wasi
|
|
||||||
# image requires recover(), which is not yet supported on wasi
|
# image requires recover(), which is not yet supported on wasi
|
||||||
# io/ioutil requires os.ReadDir, which is not yet supported on windows or wasi
|
# io/ioutil requires os.ReadDir, which is not yet supported on windows or wasi
|
||||||
# mime exits with "bufio.Scanner: Read returned impossible count" on wasi
|
|
||||||
# mime/multipart has a nil pointer dereference (stack overflow?)
|
|
||||||
# mime/quotedprintable requires syscall.Faccessat
|
# mime/quotedprintable requires syscall.Faccessat
|
||||||
# regexp/syntax requires recover() which is not yet supported on wasi
|
|
||||||
# strconv requires recover() which is not yet supported on wasi
|
# strconv requires recover() which is not yet supported on wasi
|
||||||
# text/tabwriter requires recover(), which is not yet supported on wasi
|
# text/tabwriter requires recover(), which is not yet supported on wasi
|
||||||
# text/template/parse requires recover(), which is not yet supported on wasi
|
# text/template/parse requires recover(), which is not yet supported on wasi
|
||||||
@@ -387,20 +371,14 @@ endif
|
|||||||
TEST_PACKAGES_LINUX := \
|
TEST_PACKAGES_LINUX := \
|
||||||
archive/zip \
|
archive/zip \
|
||||||
compress/flate \
|
compress/flate \
|
||||||
context \
|
|
||||||
crypto/aes \
|
|
||||||
crypto/hmac \
|
crypto/hmac \
|
||||||
debug/dwarf \
|
debug/dwarf \
|
||||||
debug/plan9obj \
|
debug/plan9obj \
|
||||||
go/build/constraint \
|
|
||||||
image \
|
image \
|
||||||
io/ioutil \
|
io/ioutil \
|
||||||
mime \
|
|
||||||
mime/multipart \
|
|
||||||
mime/quotedprintable \
|
mime/quotedprintable \
|
||||||
net \
|
net \
|
||||||
os/user \
|
os/user \
|
||||||
regexp/syntax \
|
|
||||||
strconv \
|
strconv \
|
||||||
text/tabwriter \
|
text/tabwriter \
|
||||||
text/template/parse
|
text/template/parse
|
||||||
@@ -409,14 +387,8 @@ TEST_PACKAGES_DARWIN := $(TEST_PACKAGES_LINUX)
|
|||||||
|
|
||||||
TEST_PACKAGES_WINDOWS := \
|
TEST_PACKAGES_WINDOWS := \
|
||||||
compress/flate \
|
compress/flate \
|
||||||
context \
|
|
||||||
crypto/aes \
|
|
||||||
crypto/hmac \
|
crypto/hmac \
|
||||||
go/build/constraint \
|
|
||||||
mime \
|
|
||||||
mime/multipart \
|
|
||||||
os/user \
|
os/user \
|
||||||
regexp/syntax \
|
|
||||||
strconv \
|
strconv \
|
||||||
text/template/parse \
|
text/template/parse \
|
||||||
$(nil)
|
$(nil)
|
||||||
|
|||||||
@@ -239,7 +239,8 @@ func (r *runner) run(fn *function, params []value, parentMem *memoryView, indent
|
|||||||
// already be emitted in initAll.
|
// already be emitted in initAll.
|
||||||
continue
|
continue
|
||||||
case strings.HasPrefix(callFn.name, "runtime.print") || callFn.name == "runtime._panic" || callFn.name == "runtime.hashmapGet" || callFn.name == "runtime.hashmapInterfaceHash" ||
|
case strings.HasPrefix(callFn.name, "runtime.print") || callFn.name == "runtime._panic" || callFn.name == "runtime.hashmapGet" || callFn.name == "runtime.hashmapInterfaceHash" ||
|
||||||
callFn.name == "os.runtime_args" || callFn.name == "internal/task.start" || callFn.name == "internal/task.Current" ||
|
callFn.name == "os.runtime_args" || callFn.name == "syscall.runtime_envs" ||
|
||||||
|
callFn.name == "internal/task.start" || callFn.name == "internal/task.Current" ||
|
||||||
callFn.name == "time.startTimer" || callFn.name == "time.stopTimer" || callFn.name == "time.resetTimer":
|
callFn.name == "time.startTimer" || callFn.name == "time.stopTimer" || callFn.name == "time.resetTimer":
|
||||||
// These functions should be run at runtime. Specifically:
|
// These functions should be run at runtime. Specifically:
|
||||||
// * Print and panic functions are best emitted directly without
|
// * Print and panic functions are best emitted directly without
|
||||||
|
|||||||
+1
-1
@@ -218,7 +218,7 @@ func listGorootMergeLinks(goroot, tinygoroot string, overrides map[string]bool)
|
|||||||
// with the TinyGo version. This is the case on some targets.
|
// with the TinyGo version. This is the case on some targets.
|
||||||
func needsSyscallPackage(buildTags []string) bool {
|
func needsSyscallPackage(buildTags []string) bool {
|
||||||
for _, tag := range buildTags {
|
for _, tag := range buildTags {
|
||||||
if tag == "baremetal" || tag == "nintendoswitch" || tag == "tinygo.wasm" {
|
if tag == "baremetal" || tag == "nintendoswitch" || tag == "wasip1" || tag == "wasip2" || tag == "wasm_unknown" {
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
//go:build baremetal || (wasm && !wasip1 && !wasip2) || wasm_unknown
|
//go:build baremetal || wasm_unknown
|
||||||
|
|
||||||
// This file emulates some file-related functions that are only available
|
// This file emulates some file-related functions that are only available
|
||||||
// under a real operating system.
|
// under a real operating system.
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
//go:build !(baremetal || (wasm && !wasip1 && !wasip2) || wasm_unknown)
|
//go:build !(baremetal || wasm_unknown)
|
||||||
|
|
||||||
// This file assumes there is a libc available that runs on a real operating
|
// This file assumes there is a libc available that runs on a real operating
|
||||||
// system.
|
// system.
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
//go:build baremetal || js || wasm_unknown
|
//go:build baremetal || wasm_unknown
|
||||||
|
|
||||||
package syscall
|
package syscall
|
||||||
|
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
// Use of this source code is governed by a BSD-style
|
// Use of this source code is governed by a BSD-style
|
||||||
// license that can be found in the LICENSE file.
|
// license that can be found in the LICENSE file.
|
||||||
|
|
||||||
//go:build baremetal || nintendoswitch || js || wasm_unknown
|
//go:build baremetal || nintendoswitch || wasm_unknown
|
||||||
|
|
||||||
package syscall
|
package syscall
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user