Nicheloom

Market intelligence for builders — see what's gaining traction before it's crowded.

Lunar, a "fast", memory-efficient Lua 5.1 VM written in Go

Details

External ID
49156306
Source
HN
Company
—
Product
Lunar, a "fast", memory-efficient Lua 5.1 VM written in Go
Website domain
github.com
Launched
Aug. 3, 2026
Cohort
—
Upvotes
8
Upvotes percentile
0.4731182795698925
Tags
—
Fetched at
Sept. 10, 2026, 5:32 a.m.
Updated at
Sept. 10, 2026, 5:32 a.m.

Description

I'm releasing Lunar, a new Lua 5.1 compiler and virtual machine written entirely in Go. It includes the standard libraries, coroutines as well as supporting Lua 5.2-style goto.The embedding API avoids the Lua C API’s stack-based interface in favor of typed Go values and callback frames. Libraries and script-file access are opt-in, so the host explicitly controls what Lua code can access.On my current benchmarks and use-cases, Lunar is often ~1.5x to 2x faster than GopherLua and Shopify’s go-lua. Its largest improvement however is memory use: loading a 9 MB CBOR-derived object graph (hundreds of thousands of tables) allocates about 107 MB versus 785 MB with GopherLua, with roughly 72 MiB versus 542 MiB retained after GC.The public API is still stabilizing, and I’d especially appreciate feedback on the embedding design and Go interface.(Note that this project started in another repo when I still had hopes of porting some of my changes back upstream to another existing library.)

Enrichment

Theme
lightweight and on-device AI runtimes
Vertical
Horizontal
Function
Model & infra
Audience
Developer
AI stance
Not AI
Project type
Hobby / open-source project
Normalized one-liner
memory-efficient lua virtual machine
Manually corrected
False

Could you build this?

No Writing a full programming language compiler, bytecode interpreter, and memory-efficient virtual machine in Go requires deep, specialized compiler design expertise.

What it would actually take: The project requires building a complete lexical scanner, recursive-descent parser, AST-to-bytecode compiler, and a register- or stack-based virtual machine implementing the Lua 5.1 specification and 5.2 goto semantics. It involves handling Lua coroutines, custom garbage collection interaction with Go's GC, and crafting a zero-alloc value representation (tagged unions or NaN-boxing). This level of language VM engineering demands extensive computer science expertise in formal grammar, bytecode execution, and low-level memory layout.

Discussion

2 comments analyzed.

Competitors

Other products that read as similar to this one — 37 launches clear the similarity bar, closest 8 shown.

Attention rank: #23 of 38 (itself plus its competitors, highest first — normalized so YC and Product Hunt are compared fairly).

Launched 271 days after the earliest competitor.

Other launches for this product

Same idea, different domain

Nobody's really built a model & infra tool for Fintech yet.