https://go.dev/doc/faq#runtime does go have a runtime?
- go has a runtime
- go’s runtime does garbage collection, concurrency, stack management etc
- this causes go to be slower than some other compiled langauge like C and rust
- it is a part of every go program
- but it does NOT include a virtual machine (like how Java runtime does)
Go programs are compiled ahead of time to native machine code (or JavaScript or WebAssembly, for some variant implementations).
- go could be compiled to other languages, not always to machine codes
- for example, go be compiled to javascript gopherjs, so that go program can be run in broswers