All Projects → owenthereal → Godzilla

owenthereal / Godzilla

Licence: mit
Godzilla is a ES2015 to Go source code transpiler and runtime

Programming Languages

javascript
184084 projects - #8 most used programming language
go
31211 projects - #10 most used programming language
Makefile
30231 projects

Projects that are alternatives of or similar to Godzilla

Retyped
Access 3600+ libraries from C# and let Bridge.NET compile your project into JavaScript.
Stars: ✭ 216 (-85.25%)
Mutual labels:  compiler, transpiler
Haxe
Haxe - The Cross-Platform Toolkit
Stars: ✭ 4,665 (+218.65%)
Mutual labels:  compiler, transpiler
Ratel Core
High performance JavaScript to JavaScript compiler with a Rust core
Stars: ✭ 367 (-74.93%)
Mutual labels:  compiler, transpiler
Elixirscript
Converts Elixir to JavaScript
Stars: ✭ 1,504 (+2.73%)
Mutual labels:  compiler, transpiler
Elchemy
Write Elixir code using statically-typed Elm-like syntax (compatible with Elm tooling)
Stars: ✭ 1,080 (-26.23%)
Mutual labels:  compiler, transpiler
Transcrypt
Python 3.7 to JavaScript compiler - Lean, fast, open! -
Stars: ✭ 2,502 (+70.9%)
Mutual labels:  compiler, transpiler
Bytecoder
Rich Domain Model for JVM Bytecode and Framework to interpret and transpile it.
Stars: ✭ 401 (-72.61%)
Mutual labels:  compiler, transpiler
Crossshader
⚔️ A tool for cross compiling shaders. Convert between GLSL, HLSL, Metal Shader Language, or older versions of GLSL.
Stars: ✭ 113 (-92.28%)
Mutual labels:  compiler, transpiler
Typescripttolua
Typescript to lua transpiler. https://typescripttolua.github.io/
Stars: ✭ 783 (-46.52%)
Mutual labels:  compiler, transpiler
J2cl
Java to Closure JavaScript transpiler
Stars: ✭ 773 (-47.2%)
Mutual labels:  compiler, transpiler
Wax
A tiny programming language that transpiles to C, C++, Java, TypeScript, Python, C#, Swift, Lua and WebAssembly 🚀
Stars: ✭ 373 (-74.52%)
Mutual labels:  compiler, transpiler
Fetlang
Fetish-themed programming language
Stars: ✭ 1,337 (-8.67%)
Mutual labels:  compiler, transpiler
Nimporter
Compile Nim Extensions for Python On Import!
Stars: ✭ 474 (-67.62%)
Mutual labels:  compiler, transpiler
Jsweet
A Java to JavaScript transpiler.
Stars: ✭ 1,167 (-20.29%)
Mutual labels:  compiler, transpiler
Evm2wasm
[ORPHANED] Transcompiles EVM code to eWASM
Stars: ✭ 96 (-93.44%)
Mutual labels:  compiler, transpiler
Orchestra
One language to be RegExp's Successor. Visually readable and rich, technically safe and extended, naturally scalable, advanced, and optimized
Stars: ✭ 103 (-92.96%)
Mutual labels:  compiler
Parcel
The zero configuration build tool for the web. 📦🚀
Stars: ✭ 39,670 (+2609.7%)
Mutual labels:  compiler
Babel Preset Github
GitHub.com's Babel configuration
Stars: ✭ 103 (-92.96%)
Mutual labels:  transpiler
Purescript Python
A Python backend for PureScript.
Stars: ✭ 103 (-92.96%)
Mutual labels:  compiler
Quickjs
The official repo is at bellard/quickjs.
Stars: ✭ 1,429 (-2.39%)
Mutual labels:  compiler

Godzilla: Go running JavaScript

Overview

Godzilla is a ES2015 to Go source code transpiler and runtime that is intended to be a near drop-in replacement for Node.js. It compiles ES2015 source code to Go source code which is then compiled to native code. The compiled Go source code is a series of calls to the Godzilla runtime, a Go library serving a similar purpose to Node.js.

Godzilla parses ES2015 source code with the awesome babylon. That means at the moment Node.js is required for compilation. As Godzilla becomes mature, babylon will be compiled to Go source code using Godzilla itself so that the Node.js dependency can be dropped.

Note that Godzilla is at a very early stage and only very few language features are implemented

asciicast

Compiling

Make sure Go and Node.js are installed properly, then run:

$ make

Running

$ echo "console.log('Hello, Godzilla')" | bin/godzilla run
Hello, Godzilla
$ echo "console.log('Hello, Godzilla')" | bin/godzilla build -o hello
$ ./hello
Hello, Godzilla

Performance

There are still lots of works to get Godzilla to a stable state, but this is one preliminary benchmark for a simple script about program startup time:

$ echo "console.log('Hello, Godzilla')" | bin/godzilla build -o hello
$ time ./hello
Hello, Godzilla
./hello  0.00s user 0.00s system 30% cpu 0.013 total

$ echo "console.log('Hello, Godzilla')" > hello.js
$ time node hello.js
Hello, Godzilla
node hello.js  0.07s user 0.03s system 70% cpu 0.137 total

Talks

You can find my GopherCon 2017 lightening talk here.

Related Arts

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].