aboutsummaryrefslogtreecommitdiffhomepage
path: root/testdata/channel.txt
AgeCommit message (Collapse)Author
2023-03-24feat: fix typosshivay
2020-05-12runtime: add cap and len support for chanscornelk
2019-11-04add blocking selectJaden Weiss
2019-09-22Improved blocking (#513)Jaden Weiss
core: major improvements to blocking, including support for buffered channels.
2019-08-15compiler,runtime: implement stack-based schedulerAyke van Laethem
This scheduler is intended to live along the (stackless) coroutine based scheduler which is needed for WebAssembly and unsupported platforms. The stack based scheduler is somewhat simpler in implementation as it does not require full program transform passes and supports things like function pointers and interface methods out of the box with no changes. Code size is reduced in most cases, even in the case where no scheduler scheduler is used at all. I'm not exactly sure why but these changes likely allowed some further optimizations somewhere. Even RAM is slightly reduced, perhaps some global was elminated in the process as well.
2019-06-12compiler,runtime: implement non-blocking selectsAyke van Laethem
Blocking selects are much more complicated, so let's do non-blocking ones first.
2019-05-14compiler: implement comparing channel valuesAyke van Laethem
2019-05-05compiler: allow larger-than-int values to be sent across a channelAyke van Laethem
Instead of storing the value to send/receive in the coroutine promise, store only a pointer in the promise. This simplifies the code a lot and allows larger value sizes to be sent across a channel. Unfortunately, this new system has a code size impact. For example, compiling testdata/channel.go for the BBC micro:bit, there is an increase in code size from 4776 bytes to 4856 bytes. However, the improved flexibility and simplicity of the code should be worth it. If this becomes an issue, we can always refactor the code at a later time.
2019-03-23all: implement trivial select statementsAyke van Laethem
Implement two trivial uses of the select statement. Always blocking: select {} No-op: select { default: } Go 1.12 added a `select {}` instruction to syscall/js, so this is needed for Go 1.12 support. More complete support for select will be added in the future.
2019-01-21compiler: add support for channel operationsAyke van Laethem
Support for channels is not complete. The following pieces are missing: * Channels with values bigger than int. An int in TinyGo can always contain at least a pointer, so pointers are okay to send. * Buffered channels. * The select statement.