Live data from Hacker News

JSLinux Now Supports x86_64

bellard.org

121–130 of 148 posts

Re: JSLinux Now Supports x86_64

#121
post #19

The thing I most want to use this (or some other WASM Linux engine) for is running a coding agent against a virtual operating system directly in my browser. Claude Code / Codex CLI / etc are all great because they know how to drive Bash and other Linux tools. The browser is probably the best sandbox we have. Being able to run an agent loop against a WebAssembly Linux would be a very cool trick. I had a play with v86…

> The thing I most want to use this (or some other WASM Linux engine) for is running a coding agent against a virtual operating system directly in my browser. Well, there it is, the dumbest thing I'll read on the internet all week. Most of the engineering in Linux revolves around efficiently managing hardware interfaces to build up higher-level primitives, upon which your browser builds even higher-level primitives,…

> while taking the joyful bits of software development away from you

Quick question: by "joyful bits of software development," do you mean the bit where you design robust architectures, services, and their communication/data concepts to solve specific problems, or the part where you have to assault a keyboard for extended periods of time _after_ all that interesting work so that it all actually does anything?

Because I sure know which of these has been "taken from me," and it's certainly not the joyful one.

Re: JSLinux Now Supports x86_64

#122
post #119

Earlier quoted context omitted.

> The thing I most want to use this (or some other WASM Linux engine) for is running a coding agent against a virtual operating system directly in my browser. Well, there it is, the dumbest thing I'll read on the internet all week. Most of the engineering in Linux revolves around efficiently managing hardware interfaces to build up higher-level primitives, upon which your browser builds even higher-level primitives,…

> Well, there it is, the dumbest thing I'll read on the internet all week. Rude. In case you're open to learning, here's why I think this is useful. The big lesson we've learned from Claude Code, Codex CLI et al over the past twelve months is that the most useful tool you can provide to an LLM is Bash. Last year there was enormous buzz around MCP - Model Context Protocol. The idea was to provide a standard for wiring…

> 10MB WASM bundle with a full existing Linux build

We'll get there I'm sure of it. In case you hadn't seen: https://github.com/edubart/webcm

> Linux RISC-V virtual machine, powered by the Cartesi Machine emulator, running in the browser via WebAssembly

> a single 32MiB WebAssembly file containing the emulator, the kernel and Alpine Linux operating system. Networking supports HTTP/HTTPS requests, but is subject to CORS restrictions

Re: JSLinux Now Supports x86_64

#123
post #119

Earlier quoted context omitted.

> Well, there it is, the dumbest thing I'll read on the internet all week. Rude. In case you're open to learning, here's why I think this is useful. The big lesson we've learned from Claude Code, Codex CLI et al over the past twelve months is that the most useful tool you can provide to an LLM is Bash. Last year there was enormous buzz around MCP - Model Context Protocol. The idea was to provide a standard for wiring…

> 10MB WASM bundle with a full existing Linux build We'll get there I'm sure of it. In case you hadn't seen: https://github.com/edubart/webcm > Linux RISC-V virtual machine, powered by the Cartesi Machine emulator, running in the browser via WebAssembly > a single 32MiB WebAssembly file containing the emulator, the kernel and Alpine Linux operating system. Networking supports HTTP/HTTPS requests, but is subject to CO…

My demo here loads 12.7MB (if you watch the browser network panel) to get to a usable Linux machine, it even has Lua! https://tools.simonwillison.net/v86

Re: JSLinux Now Supports x86_64

#124
post #123

Earlier quoted context omitted.

> 10MB WASM bundle with a full existing Linux build We'll get there I'm sure of it. In case you hadn't seen: https://github.com/edubart/webcm > Linux RISC-V virtual machine, powered by the Cartesi Machine emulator, running in the browser via WebAssembly > a single 32MiB WebAssembly file containing the emulator, the kernel and Alpine Linux operating system. Networking supports HTTP/HTTPS requests, but is subject to CO…

My demo here loads 12.7MB (if you watch the browser network panel) to get to a usable Linux machine, it even has Lua! https://tools.simonwillison.net/v86

Ooh that looks great, I'll enjoy exploring this!

Re: JSLinux Now Supports x86_64

#126

Out of interest I tried running my Primes benchmark [1] on both the x86_64 and x86 Alpine and the riscv64 Buildroot, both in Chrome on M1 Mac Mini. Both are 2nd run so that all needed code is already cached locally. x86_64: localhost:~# time gcc -O primes.c -o primes real 0m 3.18s user 0m 1.30s sys 0m 1.47s localhost:~# time ./primes Starting run 3713160 primes found in 456995 ms 245 bytes of code in countPrimes() re…

x86 is a lot easier to JIT to Arm or RISC-V though, because it has fewer registers.

Re: JSLinux Now Supports x86_64

#127
post #110
post #94

Earlier quoted context omitted.

TBH I’ve been here a while, never felt what the point with the above is but do feel LLM:s are a new valuable affordance in computer use. I mean I don’t have to remember the horrible git command line anymore which already improves my exprience as a dev 50%. It’s not all hype bs this time.

> I mean I don’t have to remember the horrible git command line anymore Every time I see a comment like this, I have to wonder what the heck other devs were doing. Don’t you know there were shell aliases, and snippet managers, and a ton of other tools already? I never had to commit special commands to memory, and I could always reference them faster than it takes to query any LLM.

You do realize it does not help _me_ at all if _you_ have found your perfect custom setup.

Because it’s custom there is no standard curriculum you could point me to etc.

So it’s great you’ve found a setup that works for you but I hope you realize it’s silly to become idignant I don’t share it.

Re: JSLinux Now Supports x86_64

#128
post #19

The thing I most want to use this (or some other WASM Linux engine) for is running a coding agent against a virtual operating system directly in my browser. Claude Code / Codex CLI / etc are all great because they know how to drive Bash and other Linux tools. The browser is probably the best sandbox we have. Being able to run an agent loop against a WebAssembly Linux would be a very cool trick. I had a play with v86…

> The thing I most want to use this (or some other WASM Linux engine) for is running a coding agent against a virtual operating system directly in my browser. Well, there it is, the dumbest thing I'll read on the internet all week. Most of the engineering in Linux revolves around efficiently managing hardware interfaces to build up higher-level primitives, upon which your browser builds even higher-level primitives,…

> I'll bet you can't name a single advantage such a system would have over cloud hosting or a local Docker instance.

Cheaper than renting a server, more isolated than a container.

Re: JSLinux Now Supports x86_64

#130

Earlier quoted context omitted.

GP says "You don't want to just run that code in ... even a very well protected VM." Why?

Because unless you can fund several teams - kernel, firmware(bios,etc), GPU drivers, qemu, KVM, extra hardening(eg. qemu runs under something like bpfilter) + a red team, security through obscurity is cheaper. The attack surface area is just too large.

What is this "security through obscurity" you're talking about? We're talking about running linux in a VM running in a browser. That has just as much attack surface (and in some ways, more) as running linux in a hypervisor.
Post reply on HN