惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

D
Docker
博客园 - 【当耐特】
S
SegmentFault 最新的问题
阮一峰的网络日志
阮一峰的网络日志
大猫的无限游戏
大猫的无限游戏
WordPress大学
WordPress大学
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
The Cloudflare Blog
Apple Machine Learning Research
Apple Machine Learning Research
小众软件
小众软件
博客园 - 三生石上(FineUI控件)
Martin Fowler
Martin Fowler
云风的 BLOG
云风的 BLOG
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
F
Fortinet All Blogs
Y
Y Combinator Blog
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
J
Java Code Geeks
Engineering at Meta
Engineering at Meta
MyScale Blog
MyScale Blog
B
Blog
酷 壳 – CoolShell
酷 壳 – CoolShell
人人都是产品经理
人人都是产品经理

The Register

Shadow IT has given way to shadow AI. Enter AI-BOMs Zed team releases version 1.0 of Rust-built editor: Traditional editor and AI tool Microsoft boss tells investors the company is working to 'win back fans' What type of 'C2 on a sleep cycle' do they leave behind? Novel Chinese spy group found in critical networks in Poland, Asia NASA boss: Make Pluto A Planet Again GitHub says sorry and vows to do better as uptime slips and devs complain Age checks could turn internet into an ID checkpoint, complains Proton CEO Microsoft gives your Word documents an AI co-author you didn’t ask for Datadog digs down into GPU efficiency as AI costs soar If malware via monitor cables is a matter of national security, this might be the gadget for you Thunderbird in hand worth 2 Outlooks as fresh FOSS fave and Firefox arrive Grafana offers AI assistant for free, warns users not to go mad Right to repair champ Framework punts modular 13in laptop with Core Ultra Series 3 France's 'Secure' ID agency probes breach as crooks claim 19M records Scotland Yard can keep using live facial recognition on Londoners, say judges UK tribunal sends £2B claim accusing Microsoft of overcharging for licensing to trial Nation-states want to cause harm, not just steal cash - stop handing your cyber defenses to the cheapest contractor Murder, she wrote: Ex-FBI chief wants some ransomware crims charged with homicide Phone-to-satellite use goes into orbit, growing 25% in 8 months macOS ClickFix attacks deliver AppleScript stealers to snarf credentials, wallets Anthropic bakes memory fixes into Bun 1.1.13 as developers complain of leaks The spaghettified DBMS chart that shows Oracle's crown is slowly slipping Yet another ex-ransomware negotiator admits turning rogue after payoff from crimelords FAA grounds Blue Origin's New Glenn as it probes missed satellite delivery 'mishap' AMD's Ryzen 9 9950X3D2 Dual Edition tested: Gratuitous overkill with a price to match AI-assisted intruders pwned Vercel via OAuth abuse and a pilfered employee account Crook claims to leak 'video surveillance footage' of companies Met police trials snoop tech platform in push to cuff more London shoplifters England's school phone ban gets teeth, just in time to bite no one Adaptavist Group breach spawns imposter emails as ransomware crew claims mega-haul
Ruby inventor Matz working on native compiler with AI help
Tim Anderson · 2026-05-06 · via The Register

DevOps

Matz gets together with Anthropic's Claude to create an experimental ahead-of-time compiler for Ruby – though with many limitations

Yukihiro Matsumoto - better known as Matz - is building Spinel, a native compiler for Ruby, with help from Anthropic's Claude Code.

Spinel, which is on GitHub under the MIT license, works by parsing Ruby code into AST (abstract syntax tree) files, then converting it to C code for compilation by a standard C compiler. In Matz’s tests, Spinel-compiled code runs approximately 11.6 times faster than MiniRuby - a stripped-down Ruby build - using the in-development Roby 4.1.0. 

The output is C code, compilable to a native executable via gcc (GNU Compiler Collection) on Linux or Windows (with MinGW - Minimalist GNU for Windows), or via LLVM's Clang on Linux or macOS. BSD will "probably work", according to the readme, but is not tested.

Ruby is an interpreted language, meaning it depends on a runtime engine to parse and run the code. In order to improve performance, Ruby can use just-in-time (JIT) compilers including MJIT (method-based JIT), YJIT and ZJIT, with the latter two developed by Shopify, a prominent Ruby user. Spinel is different in that it generates standalone native code executables, which can be deployed without any additional runtime.

The downside of Spinel is that it supports only a subset of Ruby. Unsupported features include eval statements, which evaluate and execute Ruby code at runtime, threads, text encoding other than UTF-8, metaprogramming such as defining a method at runtime, and deeply nested lambda functions.

Ruby variables are not typed, though objects are strongly typed. Spinel performs type inference to enable C code generation, since C is a strongly typed language. The code makes use of an existing and mature Ruby parser called Prism. There are many optimizations, such as method inlining and dead code elimination, and the generated C compiles cleanly at the default warning level. Spinel includes a garbage collector, to reclaim memory automatically, and supports FFI (foreign function interface) for integrating with native code libraries such as libc or SQLite.

Spinel is experimental and will not work with most existing Ruby code, including the web application framework Ruby on Rails. But it is possible for Ruby developers to write code with Spinel in mind, such as for helper functions that can then be called from other Ruby code, as a means of optimization.

Matz presented Spinel at RubyKaigi 2026, a conference in Hakodate, Japan last month. According to attendees such as this one (original text in Japanese) Matz said the idea for Spinel was conceived three years ago, but has now been implemented in a few weeks using AI. 

Most of the code in the Spinel repository is headed with a comment including "co-authored by: Claude Open 4.7 (1M context)." 

Further, the project has already been rebuilt three times over, in a series of experiments.

Matz, perhaps, is an ideal user of AI-generated code. He understands the code, and can benefit from the increased speed of development without losing grip on what the code does, and is able to refine it with his existing skills as well as with further AI prompting, and the code is covered by hundreds of tests and benchmarks. ®