My thought about a Go interrpreter. I had thought of making a Go transpiler using either the D programming language, or the Julia programming language as the target.
Julia is very interesting. It is using the LLVM JIT. In the Julia REPL it is very easy to show the machine code or LLVM bitcode for some function, so i guess running a per line bunch of LLVM bit code is possible. Julia can call C code with no glue code. Implementation ideas * Interpreter is stack less (each go routine is a pointer to a struct of type GoRoutine) * Switching between Go routines is then copy go routine pointer to the wait or run queue, and take one pointer from the run queue, and resume execution. * If all go routines are deadlocked, then the run queue will be empty. The scheduler will then panic = Show an error in the REPL. The user can now poke around, and *read* (not write) go routine states/variables. An interpreter vet tool (build into the interpreter) could maybe do some interesting stuff, now that all states and variables are frozen in time. Den mandag den 7. september 2015 kl. 06.49.03 UTC+2 skrev Elliott Stoneham: > > I’ve been working with Sebastien Binet to develop some initial ideas for a > Go interpreter, we’d welcome some feedback. > > > You can see the document at > https://docs.google.com/document/d/1Hvxf6NMPaCUd-1iqm_968SuHN1Vf8dLZQyHjvPyVE0Q/edit?usp=sharing > > > There is also a reddit entry at > https://www.reddit.com/r/golang/comments/3jx2bb/proposal_for_a_go_interpreter/?ref=share&ref_source=link > > Thank you for your interest. > > Elliott > -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.