0.22.0
This release contains significantly improved standard library support with many more packages passing all tests. Especially the os package was improved a lot with many functions added to match the standard Go os package. In addition, we upgraded LLVM to LLVM 13, improved the build cache (no tinygo clean
anymore), and of course we've made various other improvements and bug fixes.
We've added the following boards this release:
- blues wireless Swan
- M5Stack
- M5Stamp C3
- Seeed LoRa-E5 Development Kit
- ST Micro STM32F469 "Discovery"
- ST Micro "Nucleo" WL55JC
- The Things Industries Generic Node Sensor Edition
Here are the changes in detail:
- command line
- add asyncify to scheduler flag help
- support -run for tests
- remove FreeBSD target support
- add LLVM 12 and LLVM 13 support, use LLVM 13 by default
- add support for ARM64 MacOS
- improve help
- check /run/media as well as /media on Linux for non-debian-based distros
test
: set cmd.Dir even when running emulatorsinfo
: add JSON output using the-json
flag
- compiler
builder
: fix off-by-one in size calculationbuilder
: handle concurrent library header renamebuilder
: use flock to avoid double-compilesbuilder
: use build ID as cache keybuilder
: add -fno-stack-protector to musl buildbuilder
: update clang header search path to look in /usr/libbuilder
: explicitly disable unwind tables for ARMcgo
: add support forC.CString
and related functionscompiler
: fix ranging over maps with particular map typescompiler
: add correct debug location to init instructionscompiler
: fix emission of large object layoutscompiler
: work around AVR atomics bugscompiler
: predeclare runtime.trackPointerinterp
: work around AVR function pointers in globalsinterp
: run goroutine starts and checks at runtimeinterp
: always run atomic and volatile loads/stores at runtimeinterp
: bump timeout to 180 secondsinterp
: handle type assertions on nil interfacesloader
: elminate goroot cache inconsistencyloader
: respect $GOROOT when runninggo list
transform
: allocate the correct amount of bytes in an allocatransform
: remove switched func lowering
- standard library
crypto/rand
: show error if platform has no rngdevice/*
: add*_Msk
field for each bit field and avoid duplicatesdevice/*
: provide Set/Get for each register field described in the SVD filesinternal/task
: swap stack chain when switching goroutinesinternal/task
: remove-scheduler=coroutines
machine
: addDevice
string constantnet
: add bare Interface implementationnet
: add net.Buffersos
: stub out support for some featuresos
: obey TMPDIR on unix, TMP on Windows, etcos
: implementReadAt
,Mkdir
,Remove
,Stat
,Lstat
,CreateTemp
,MkdirAll
,Chdir
,Chmod
,Clearenv
,Unsetenv
,Setenv
,MkdirTemp
,Rename
,Seek
,ExpandEnv
,Symlink
,Readlink
os
: implementFile.Stat
os
: fixIsNotExist
on nonexistent pathos
: fix opening files on WASI in read-only modeos
: work around lack ofsyscall.seek
on 386 and armreflect
: make sure indirect pointers are handled correctlyruntime
: allow comparing interfacesruntime
: use LLVM intrinsic to read the stack pointerruntime
: strengthen hashmap hash function for structs and arraysruntime
: fix float/complex hashingruntime
: fix nil map dereferenceruntime
: add realloc implementation to GCsruntime
: handle negative sleep timesruntime
: correct GC scan boundsruntime
: remove extalloc GCrumtime
: implement__sync
libcalls as critical sections for most microcontrollersruntime
: add stubs forFunc.FileLine
andFrame.PC
sync
: fix concurrent read-lock on write-locked RWMutexsync
: add a package docsync
: add testssyscall
: add support forMmap
andMprotect
syscall
: fix array size for mmap slice creationsyscall
: enableGetwd
in wasitesting
: add a stub forCoverMode
testing
: support -bench option to run benchmarks matching the given pattern.testing
: support b.SetBytes(); implement sub-benchmarks.testing
: replace spaces with underscores in test/benchmark names, as upstream doestesting
: implement testing.Cleanuptesting
: allow filtering subbenchmarks with the-bench
flagtesting
: implement-benchtime
flagtesting
: print durationtesting
: allow filtering of subtests using-run
- targets
all
: change LLVM features to match vanilla Clangavr
: use interrupt-based timer which is much more accuratenrf
: fix races in I2Csamd51
: implement TRNG for randomnessstm32
: pull-up on I2C linesstm32
: fix timeout for i2c commsstm32f4
,stm32f103
: initial implementation for ADCstm32f4
,stm32f7
,stm32l0x2
,stm32l4
,stm32l5
,stm32wl
: TRNG implementation in crypto/randstm32wl
: add I2C supportwindows
: add support for the-size=
flagwasm
: add support fortinygo test
wasi
,wasm
: raise default stack size to 16 KiB
- boards
- add M5Stack
- add lorae5 (stm32wle) support
- add Generic Node Sensor Edition
- add STM32F469 Discovery
- add M5Stamp C3
- add Blues Wireless Swan
bluepill
: add definitions for ADC pinsstm32f4disco
: add definitions for ADC pinsstm32l552ze
: use supported stlink interfacemicrobit-v2
: add some pin definitions