0.26.0
This is another TinyGo release with many small changes, including over 110 commits.
This release introduces two possible breaking changes:
-
The
machine
package has had some changes in the public API, to remove some unintentionally exported constants. It is likely that very little real-world code is affected by this change. -
WebAssembly files could previously import functions by leaving a Go function unimplemented, like so:
func add(a, b int) int
This worked by accident. With this release, this is no longer possible. Instead, functions will need to be imported explicitly to avoid a compiler error:
//export add func add(a, b int) int
(The
//export
may be confusing, we intend to add a less-confusing//go:wasm-import
directive in the future).
Here is a detailed changelog for this release:
- general
- remove support for LLVM 13
- remove calls to deprecated ioutil package
- move from
os.IsFoo
toerrors.Is(err, ErrFoo)
- fix for builds using an Android host
- make interp timeout configurable from command line
- ignore ports with VID/PID if there is no candidates
- drop support for Go 1.16 and Go 1.17
- update serial package to v1.3.5 for latest bugfixes
- remove GOARM from
tinygo info
- add flag for setting the goroutine stack size
- add serial port monitoring functionality
- compiler
cgo
: implement support for static functionscgo
: fix panic when FuncType.Results is nilcompiler
: add aliases foredwards25519/field.feMul
andfield.feSquare
compiler
: fix incorrect DWARF type in some generic parameterscompiler
: use LLVM math builtins everywherecompiler
: replace some math operation bodies with LLVM intrinsicscompiler
: replace math aliases with intrinsicscompiler
: fixunsafe.Sizeof
for chan and map valuescompileopts
: use tags parser from buildutilcompileopts
: use backticks for regexp to avoid extra escapescompileopts
: fail fast on duplicate values in target field slicescompileopts
: fix windows/arm target triplecompileopts
: improve error handling when loading target/*.jsoncompileopts
: add support for stlink-dap programmercompileopts
: do not complain about-no-debug
on MacOSgoenv
: supportGOOS=android
interp
: fix reading from external globalloader
: fix link error forcrypto/internal/boring/sig.StandardCrypto
- standard library
- rename assembly files to .S extension
machine
: add PWM peripheral comments to pinsmachine
: improve UARTParity slightlymachine
: do not export DFU_MAGIC_* constants on nrf52840machine
: renamePinInputPullUp
/PinInputPullDown
machine
: addKHz
,MHz
,GHz
constants, deprecateTWI_FREQ_*
constantsmachine
: remove level triggered pin interruptsmachine
: do not exposeRESET_MAGIC_VALUE
machine
: useNoPin
constant where appropriate (instead of0
for example)net
: sync net.go with Go 1.18 stdlibos
: addSyscallError.Timeout
os
: addErrProcessDone
errorreflect
: implementCanInterface
and fix stringIndex
runtime
: makeMemStats
available to leaking collectorruntime
: addMemStats.TotalAlloc
runtime
: addMemStats.Mallocs
andFrees
runtime
: add support fortime.NewTimer
andtime.NewTicker
runtime
: implementresetTimer
runtime
: ensure some headroom for the GC to runruntime
: make gc and scheduler asserts settable with build tagsruntime/pprof
: addWriteHeapProfile
runtime/pprof
:runtime/trace
: stub some additional functionssync
: implementMap.LoadAndDelete
syscall
: group WASI consts by purposesyscall
: add WASI{D,R}SYNC
,NONBLOCK
FD flagssyscall
: add ENOTCONN on darwintesting
: add support for -benchmem
- targets
- remove USB vid/pid pair of bootloader
esp32c3
: remove unusedUARTStopBits
constantsnrf
: implementGetRNG
functionnrf
:rp2040
: addmachine.ReadTemperature
nrf52
: cleanup s140v6 and s140v7 uf2 targetsrp2040
: implement semi-random RNG based on ROSC based on pico-sdkwasm
: add summary of wasm examples and fix callback bugwasm
: do not allow undefined symbols (--allow-undefined
)wasm
: make sure buffers returned bymalloc
are kept untilfree
is calledwindows
: save and restore xmm registers when switching goroutines
- boards
- add Pimoroni's Tufty2040
- add XIAO ESP32C3
- add Adafruit QT2040
- add Adafruit QT Py RP2040
esp32c3-12f
:matrixportal-m4
:p1am-100
: remove duplicate build tagshifive1-qemu
: remove this emulated boardwioterminal
: add UART3 for RTL8720DNxiao-ble
: fix usbpid