nowfound

Dev tools · April 18, 2025

(bits) of a Libc, Optimized for Wasm

I make a no-CGO Go SQLite driver, by compiling the amalgamation to Wasm, then loading the result with wazero (a CGO-free Wasm runtime). To compile SQLite, I use wasi-sdk, which uses wasi-libc, which is based on musl. It's been said that musl is slow(er than glibc), which is true, to a point. musl uses SWAR on a size_t to implement various functions in string.h. This is fine, except size_t is just 32-bit on Wasm. I found that implementing a few of those functions with Wasm SIMD128 can make them go around 4x faster. Other functions don't even use SWAR; redoing those can make them 16x faster.…

(bits) of a Libc, Optimized for Wasm launched on April 18, 2025 with 78 votes, #549 of 7,818 launches that month and more than 95% of that year's launches. The site was not reachable when checked in September 2026.

Visit github.com ↗Alternativestop 7% of April 2025

In plain words

This is an optimized C standard library for WebAssembly, built on musl and designed to improve performance of Wasm-based applications. It replaces standard string and sorting functions with SIMD128 implementations that are significantly faster on 32-bit Wasm environments. The library is intended for developers building Wasm applications that need better performance from low-level C functions, such as Go programs using SQLite compiled to Wasm without CGO dependencies.

written from the facts on this page · September 2026

From the sources

In the maker’s words, at launch

I make a no-CGO Go SQLite driver, by compiling the amalgamation to Wasm, then loading the result with wazero (a CGO-free Wasm runtime). To compile SQLite, I use wasi-sdk, which uses wasi-libc, which is based on musl. It's been said that musl is slow(er than glibc), which is true, to a point. musl uses SWAR on a…

Does a similar job

all alternatives →
  • My Go SQLite driver did poorly on a benchmark, so I fixed it2023 · github.com · ▲234

    https://github.com/ncruces/go-sqlite3 was doing poorly on this benchmark that was posted yesterday to HackerNews [1]. With the help of some pprof, I was able to trace it to a serious performance regression introduced two weeks ago, and come up with the fix (happy to field questions, if you're interested in the nitty gritty). It's not the fastest driver around, but it's no longer the slowest: comfortably middle of the pack. It's based on a WASM build of SQLite, and thanks to https://wazero.io doesn't need CGO. [1]:…

  • A Wasm to Go TranslatorFeb 2026 · github.com · ▲7

    I've spent the past couple of weeks building a Wasm-to-Go translator. It supports a subset of Wasm useful enough to translate SQLite into 600k LoC (~20 MiB) of Go code. It already passes all of my Go SQLite driver's tests across the 20 platforms I support. Performance compared to https://wazero.io/ is a bit of a mixed bag: code that frequently crosses the Go-Wasm boundary improves, but code that spends most of its time in "Wasm land" doesn't. There's probably room for improvement (I'd love to hear your ideas), but this is also a testament to how good the wazero AOT compiler…

  • Roast my SQLite encryption at-rest2024 · github.com · ▲99

    SQLite encryption at-rest is a hot requested feature of both the “default” CGo driver [1] and the transpiled alternative driver [2]. So, this is a feature I wanted to bring to my own Wasm based Go driver/bindings [3]. Open-source SQLite encryption extensions have had a troubled last few years. For whatever reason, in 2020 the (undocumented) feature that made it easy to offer page-level encryption was removed [4]. Some solutions are stuck with SQLite 3.31.1, but Ulrich Telle stepped up with a VFS approach [5]. Still, their solution seemed harder than something I'd want to maintain, as it…

  • A pure C89 implementation of Go channels, with blocking selects2023 · github.com · ▲271

    A pure C (-std=c89) implementation of Go channels, including blocking and non-blocking selects. - GitHub - rochus-keller/CspChan: A pure C (-std=c89) implementation of Go channels, including blocking and non-blocking selects.

  • Gogosseract, a Go Lib for CGo-Free Tesseract OCR via Wazero2023 · github.com · ▲120

    Tesseract is one of the largest Open Source OCR (Optical Character Recognition) projects. There is already a Go library for using Tesseract from Go with CGo, called Gosseract. However if you are interested in OCR from Go without C complicating building and cross-compiling, there aren't any other options. Wazero is a Go WASM runtime that doesn't have any CGo dependencies. With Emscripten Tesseract has been compiled to WASM and ran within Wazero. Gogosseract provides a simple API on top of this. This project has been an interesting delve into the world of WASM.

  • A new stdlib for Golang focusing on platform native support2023 · github.com · ▲154

    No gc, No goroutines, Produces small binaries while using the unmodified official go toolchain, and comes with complete Web SDK (generated from w3c/webref). We are building `pcz` to provide a reimagination of Go the language, in an effort to make it suitable for all kinds of programming tasks, and currently you can use it to build efficient web applications in Go using the generated Web SDK (as shown with the live web demo[1]). The journey is just starting, any suggestions? or any critics? [1]: https://primecitizens.github.io/livedemos/10-plat-web/

More dev tools this month

the category →
  • /dev/null▲468

    a social network for devs

    Dev tools · 2d ago · dev-null.sh

  • open-source IDE for thoughtful software design. Contribute to devdotfast/whiteboard development by creating an account on GitHub.

    Dev tools · 27d ago · github.com

  • Contribute to reladraw/reladraw development by creating an account on GitHub.

    Dev tools · 25d ago · github.com

  • OpenBot▲362

    Grok Bot alternative: free, local, open-source, multiplayer

    Dev tools · 22d ago · openbot.run

  • Talanoa▲340

    Hi HN, I’m a fullstack developer, and honestly, I’ve lost count of how many side projects I’ve worked on over the years. But one idea kept coming back to me: a different kind of email client. It first came to me in 2014: “What if we could handle emails more like conversations?” Every year, I’d revisit this concept in my “Build Notes.” Ten years later, no one had built exactly what I had in mind — so I finally decided to do it myself. That’s how Talanoa was born. I wanted something focused on people, not timelines. I was tired of marking messages as unread just to remember to reply later, or…

    Dev tools · 20d ago · talanoa.email

  • CoreSpeed▲332

    One MCP for everything your agents need: apps, memory, tools

    Dev tools · 27d ago · corespeed.io

Source: Show HN post ↗ · launch text quoted in part

Launched alongside, April 2025

the whole month →
  • Hi everyone, I built PyXL — a hardware processor that executes a custom assembly generated from Python programs, without using a traditional interpreter or virtual machine. It compiles Python -> CPython Bytecode -> Instruction set designed for direct hardware execution. I’m sharing an early benchmark: a GPIO test where PyXL achieves a 480ns round-trip toggle — compared to 14-25 micro seconds on a MicroPython Pyboard - even though PyXL runs at a lower clock (100MHz vs. 168MHz). The design is stack-based, fully pipelined, and preserves Python's dynamic typing without static type restrictions.…

    Dev tools · 2025 · runpyxl.com

  • The Unsure Calculator is an online tool that lets you calculate with numbers you’re not sure about.

    Life & fun · 2025 · filiph.github.io

  • https://the-pocket.github.io/Tutorial-Codebase-Knowledge/

    AI · 2025 · github.com

  • Whatting▲898

    The iPad diary, just for you

    Work · 2025 · whatting.com

  • Browser with AI companions that automate web tasks

    AI · 2025 · strawberrybrowser.com

  • Peek▲828

    AI personal finance coach that guides you through decisions

    Work · 2025 · peek.money