Have finally put together the beginnings of a site for Mu (”) https://mu-lang.odev đ€ #mu #mu-lang
yes, yes thatâs right. Mu (”) now has a built-in LSP server for fans of VS Code / VSCodium đ
You just go install ./cmd/mu-lsp/... and install the VS extension and hey presto đ„ł You get outlines of any Mu source, Find References and Go to Definition!
./bin/mu -B -o ... -p muos/amd64 ... target.
@prologic@twtxt.net Iâd love to take a look at the code. đ
Iâm kind of curious to know how much Assembly I need vs. How much of a microkernel can I build purely in Mu (”)? đ€
Canât really answer that, because I only made a working kernel for 16-bit real mode yet. That is 99% C, though, only syscall entry points are Assembly. (The OpenWatcom compiler provides C wrappers for triggering software interrupts, which makes things easier.)
But in long mode? No idea yet. đ At least changing the page tables will require a tiny little bit of Assembly.
./bin/mu -B -o ... -p muos/amd64 ... target.
Iâm kind of curious to know how much Assembly I need vs. How much of a microkernel can I build purely in Mu (”)? đ€
./bin/mu -B -o ... -p muos/amd64 ... target.
Whohoo! đ„ł
You have no idea how great a feeling this is! This includes the Mu stdlib and runtime as well, not just some simple stupid program, this means a significant portion of the runtime and stdlib âjust worksââą đ€Ł
Btw @movq@www.uninformativ.de youâve inspired me to try and have a good âol crack at writing a bootloader, stage1 and customer microkernel (”Kernel) that will eventually load up a Mu (”) program and run it! đ€Ł I will teach Mu (”) to have a ./bin/mu -B -o ... -p muos/amd64 ... target.
Took me nearly all week (in my spare time), but Mu (”) finally officially support linux/amd64 đ„ł I completely refactored the native code backend and borrowed a lot of the structure from another project called wazero (the zero dependency Go WASM runtime/compiler). This is amazing stuff because now Mu (”) runs in more places natively, as well as running everywhere Go runs via the bytecode VM interpreter đ€
This week, Mu (”) get s bit more serious and starts to refactor the native backend (a lot). Soonâą we will support darwin/arm64, linux/arm64 and linux/amd64 (Yes, other forms of BSD will come!) â Mu (”) also last week grew concurrency support too! đ€Ł
Shin'ya M. > ./bin/mu
panic: native backend does not support syscall platform netbsd/amd64
goroutine 1 [running]:
git.mills.io/prologic/mu/internal/native/arm64.init.0()
/home/shinyoukai/mu/internal/native/arm64/emitter.go:45 +0x7bf
âŠthat was supposed to be the interpreter?
Mu (”) is coming along really nicely đ€Ł Few things left to do (in order):
- Finish the concurrency support.
- Add support for sockets
- Add support for
linux/amd64
- Rewrite the heap allocator
- Rewrite Mu (”) in well umm Mu (”) đ
Hereâs a screenshot showing off the builtin help(): 
Mu (”) is now getting much closer to where I want it to be, it now has:
- A
processstdlib module (very basic, but it works)
- An
ffistdob module that supportsdlopen/dlsymand calling C functions with a nice mu-esque wrapperffi.fn(...)
- A
sqlitestdlib module (also very basic) that shows off the FFI capabilities
đ
Opinion / Question timeâŠ
Do you think Mu (”)âs native compiler and therefore emitted machine code âruntimeâ (which obviously adds a bit of weight to the resulting binary, and runtime overheads) needs to support âruntime stack tracesâ, or would it be enough to only support that in the bytecode VM interpreter for debuggability / quick feedback loops and instead just rely on flat (no stacktraces) errors in natively built compiled executables?
So in effect:
Stack Traces:
- Bytecode VM Interpreter: â
- Native Code Executables: â
Nice! đ Here are the startup latencies for the simplest Mu (”) program. println("Hello World"):
- Interpreter: ~5ms
- Native Code: ~1.5ms
Hmmm đ€
Excluding merges, 1 author has pushed 171 commits to main and 175 commits to all branches. On main, 294 files have changed and there have been 52880 additions and 18269 deletions.
From the Mu (”) Gitea Activity Tab
mu (”) now has builtin code formatting and linting tools, making ” far more useful and useable as a general purpose programming language. Mu now includes:
- An interpreter for quick âscriptinogâ
- A native code compiler for building native executables (Darwin / macOS only for now)
- A builtin set of developer tools, currently: fmt (-fmt), check (-check) and test (-test).
@movq@www.uninformativ.de Mu (”)âs startup latency appears to be ~10ms on my machine:
$ time ./bin/mu ./foo.mu
real 0m0.011s
user 0m0.004s
sys 0m0.006s
println(1, 2) was bring printed as 1 2 in the bytecode VM and 1 nil when natively compiled to machine code on macOS. In the end it turned out the machine code being generated / emitted meant that the list pointers for the rest... of the variadic arguments was being slot into a register that was being clobbered by the mu_retain and mu_release calls and effectively getting freed up on first use by the RC (reference counting) garbage collector đ€Šââïž
@lyse@lyse.isobeef.org Yeah I remember you said some days back that your interest in compilers was rekindled by my work on mu (”) đ
Whoo! I fixed one of the hardest bugs in mu (”) I think Iâve had to figure out. Took me several days in fact to figure it out. The basic problem was, println(1, 2) was bring printed as 1 2 in the bytecode VM and 1 nil when natively compiled to machine code on macOS. In the end it turned out the machine code being generated / emitted meant that the list pointers for the rest... of the variadic arguments was being slot into a register that was being clobbered by the mu_retain and mu_release calls and effectively getting freed up on first use by the RC (reference counting) garbage collector đ€Šââïž
@movq@www.uninformativ.de Iâve managed to bring a simple âHello World!â in mu (”) (at least on macOS / Darwin / ARM64) down to ~86KB (previously ~146KB) đ„ł
Hmmm I need to figure out a way to reduce the no. of lines of code / complexity of the ARM64 native code emitter for mu (”). Itâs insane really, itâs a whopping ~6k SLOC, the next biggest source file is the compiler at only ~800 SLOC đ€
@movq@www.uninformativ.de Oh thatâs fine, Mu can compile to native code and so far binaries. at least on macOS are in the order of Kb in size đ
@movq@www.uninformativ.de Itâd be cool if you could get ” (Mu) running in your little toyOS đ€Ł Youâd technically only have to swap out the syscall() builtin for whatever your toy OS supports đ€
I just had a closer look at https://git.mills.io/prologic/mu and it motivated me to do some compiler building myself again. Hopefully, I find some time in the next free days. Iâm bad at it, but itâs always great fun.
@movq@www.uninformativ.de @kiwu@twtxt.net it just so happens to be a happy coincidence that Iâm extending muâs capabilities to now include a native toolchain-free compiler (doesnât rely on any external gcc/clang or linkers, etc) that lowers the mu source code into an intermediate representation / IR (what @movq@www.uninformativ.de refers to as âthick layers of abstractionsââŠ) and finally to SSA + ARM64 + Mach-O encoder to produce native binary executables (at least for me on my Mac, Linux may some later?) đ€Ł
@movq@www.uninformativ.de Pretty sure all my mu solutions are very slow, but not so slow as I optimized most of the implementations to avoid as much brute forcing as I could.
I cleaned up all my of AoC (Advent of Code) 2025 solutions, refactored many of the utilities I had to write as reusable libraries, re-tested Day 1 (but nothing else). here it is if youâre curious! This is written in mu, my own language I built as a self-hosted minimal compiler/vm with very few types and builtins.
I finished all 12 days of Advent of Code 2025! #AdventOfCode https://adventofcode.com â did it in my own language, mu (Go/Python-ish, dynamic, int/bool/string, no floats/bitwise). Found a VM bug, fixed it, and the self-hosted mu compiler/VM (written in mu, host in Go) carried me through. đ„ł
Ooops, Iâve run into a bug or limitation with mu for Day 9 đ€
@prologic@twtxt.net bilingual trivia: çĄ (mu) means nothing in Japanese
I just completed âPrinting Departmentâ - Day 4 - Advent of Code 2025 #AdventOfCode https://adventofcode.com/2025/day/4 â Again, Iâm doing this in mu, a Go(ish) / Python(ish) dynamic langugage that I had to design and build first which has very few builtins and only a handful of types (ints, no flots). đ€Ł
I just completed âLobbyâ - Day 3 - Advent of Code 2025 #AdventOfCode https://adventofcode.com/2025/day/3 â Again, Iâm doing this in mu, a Go(ish) / Python(ish) dynamic langugage that I had to design and build first which has very few builtins and only a handful of types (ints, no flots). đ€Ł
Did I mention mu only supports ints? đ€ Iâm not sure if Iâll need flots for this yearâs AoC? đ€
Iâm having to write my own functions like this in mu just to solve AoC puzzles :D
fn pow10(k) {
p := 1
i := 0
while i < k {
p = p * 10
i = i + 1
}
return p
}
I just completed âGift Shopâ - Day 2 - Advent of Code 2025 #AdventOfCode https://adventofcode.com/2025/day/2 â But again, Iâm solving this in my own language mu that I had to build first đ€Ł
I just completed âSecret Entranceâ - Day 1 - Advent of Code 2025 #AdventOfCode https://adventofcode.com/2025/day/1 â However I did it in my own toy programming language called mu, which I had to build first đ€Ł
Ahh thatâs because I forgot to call main() at the end of the source file. mu is a bit of a dynamic programming language, mix of Go(ish) and Python(ish).
$ ./bin/mu examples/aoc2025/day1.mu
Execution failed: undefined variable readline
Come back from my trip, run my AoC 2025 Day 1 solution in my own language (mu) and find it didnât run correctly đ€Ł Ooops!
$ ./bin/mu examples/aoc2025/day1.mu
closure[0x140001544e0]
I actually canât progress to day two till I get home đ€Ł â I havenât pushed the code for the mu compiler yet đ€Šââïž So no-one can check my work even if they were so kind đ€Ł
completely untested as i have no remote way of running mu code from Vietnam đ€Ł
AoC Day #1 solution (mu): https://gist.mills.io/prologic/d3c22bcbc22949939b715a850fe63131
The most interesting part about mu is that the language is actually self-hosted and written in itself. There is a stage zero compound written and go on a stage one compiler written in mu
Thinking about doing Advent of Code in my own tiny language mu this year.
mu is:
- Dynamically typed
- Lexically scoped with closures
- Has a Go-like curly-brace syntax
- Built around lists, maps, and first-class functions
Key syntax:
- Functions use
fnand braces:
fn add(a, b) {
return a + b
}
- Variables use
:=for declaration and=for assignment:
x := 10
x = x + 1
- Control flow includes
if/elseandwhile:
if x > 5 {
println("big")
} else {
println("small")
}
while x < 10 {
x = x + 1
}
- Lists and maps:
nums := [1, 2, 3]
nums[1] = 42
ages := {"alice": 30, "bob": 25}
ages["bob"] = ages["bob"] + 1
Supported types:
int
bool
string
list
map
fn
nil
mu feels like a tiny little Go-ish, Python-ish language â curious to see how far I can get with it for Advent of Code this year. đ
Andrej Ferko â storoÄnica narodenia
BĂĄsnik a lekĂĄr Dr. Andrej Ferko sa narodil 22. novembra 1925 v KysĂĄÄi. Do zĂĄkladnej ĆĄkoly chodil v rodisku (1932 â 1936), pÀƄ tried gymnĂĄzia vychodil v BĂĄÄskom Petrovci (1936 â 1941) a ĆĄiestu na srbskom gymnĂĄziu v Novom Sade (1941 â 1942). V Novom Sade sa stal ilegĂĄlnym Älenom nĂĄrodnooslobodzovacieho hnutia, preto bol okupaÄnĂœmi vrchnosĆ„ami v novembri 1942 zatknutĂœ a vĂ€znenĂœ do mĂĄja 1943 v PeĆĄti. Jeden rok bol doma, lebo mu okupanti zakĂĄzali ĆĄtudo ⊠â Read more
JĂĄn KvaÄala â PetrovÄan s najviac doktorĂĄtmi, na ktorĂ©ho sa zabĂșda
JĂĄn Radomil KvaÄala (1862 â 1934), rodĂĄk z Petrovca, znĂĄmy ako otec modernej komeniolĂłgie, sa poÄas svojho ĆŸivota stal drĆŸiteÄŸom ĆĄtyroch doktorĂĄtov. PhDr. obhĂĄjil v Lipsku, ThDr. vo Viedni, ÄestnĂ© doktorĂĄty mu udelili univerzity v Rige a VarĆĄave. V roku 1932 sa stal prvĂœm ÄestnĂœm predsedom juhoslovanskej Matice slovenskej Napriek tomu jeho meno dnes medzi vojvodinskĂœmi SlovĂĄkmi poznĂĄ len ⊠â Read more
Fotograf s duĆĄou maliara
ProfesionĂĄlny fotograf Michal MadackĂœ, ktorĂœ sa uĆŸ desaĆ„roÄia zaraÄuje medzi najvĂœraznejĆĄie postavy vojvodinskej fotografickej scĂ©ny, nedĂĄvno oslĂĄvil svoje vĂœznamnĂ© jubileum. Pri prĂleĆŸitosti jeho 70. narodenĂn mu 21. mĂĄja 2025 v Dome slovenskej kultĂșry v BĂ©keĆĄskej Äabe (MaÄarsko) otvorili samostatnĂș vĂœstavu umeleckĂœch a ĂșĆŸitkovĂœch fotografiĂ. VĂœstavu usporiadal Äabiansky regiĂłn Ăstavu kultĂșry SlovĂĄkov v MaÄarsku (ĂKSM). VĂœstava bude dostupnĂĄ do 6. jĂșna 2025. â Read more
VĂœroÄnĂ© zhromaĆŸdenie KomornĂ©ho zboru Musica viva
VÄerajĆĄie vĂœroÄnĂ© zhromaĆŸdenie KomornĂ©ho zboru Musica viva z BĂĄÄskeho Petrovca sa nieslo v duchu hodnotenia minuloroÄnej Äinnosti a stanovenia plĂĄnov na rok 2025. PrĂtomnĂœch privĂtala dirigentka a umeleckĂĄ vedĂșca zboru Mariena StankoviÄovĂĄ KrivĂĄkovĂĄ, ktorĂĄ v Ășvode zdĂŽraznila bohatĂș a aktĂvnu sezĂłnu zboru v uplynulom roku. SprĂĄvu o Äinnosti zboru za rok 2024 preÄĂtal VladimĂr KovĂĄÄ. V nej konĆĄtatoval, ĆŸe KomornĂœ zbor Mus ⊠â Read more
Ezurio Veda SL917 Expands Industrial IoT Connectivity with Wi-Fi 6 and Bluetooth LE
The Veda SL917, developed by Ezurio and based on the Silicon Labs SiWx917 chipset, is a low-power wireless module designed for industrial IoT applications. It provides connectivity options, including Wi-Fi 6, Bluetooth Low Energy 5.4, and support for Matter and IP networking, providing secure cloud connectivity and efficient power management. This device supports OFDMA, MU-MIMO ⊠â Read more
IN MEMORIAM: Gavra GovorÄin
Dnes rĂĄno sa KulpĂnom rozchĂœrila smutnĂĄ sprĂĄva: opustil nĂĄs ÄalĆĄĂ vĂœznamnĂœ KulpĂnÄan, Gavra GovorÄin. O dva mesiace by oslĂĄvil ĆŸivotnĂș osemdesiatku (15. 3. 1945), no zĂĄkernĂĄ choroba mu to prekazila. ĆœivotnĂœ Ășdel a krĂĆŸiky na chrbte dĂŽstojne znĂĄĆĄal a do poslednej chvĂle bol eĆĄte spoloÄensko-politicky aktĂvny â dodnes bol Älenom Obecnej rady BĂĄÄskopetrovskej obce. V KulpĂne sa takmer nenĂĄjde Älovek, ktorĂœ by ho nepoznal. Z pracovnej pozĂcie miestneho matrikĂĄra a ĆĄ ⊠â Read more
@movq@www.uninformativ.de Yes, the tools are surprisingly fast. Still, magrep takes about 20 seconds to search through my archive of 140K emails, so to speed things up I would probably combine it with an indexer like mu, mairix or notmuch.