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

推荐订阅源

freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
爱范儿
爱范儿
WordPress大学
WordPress大学
博客园 - 三生石上(FineUI控件)
J
Java Code Geeks
Vercel News
Vercel News
aimingoo的专栏
aimingoo的专栏
T
Tailwind CSS Blog
罗磊的独立博客
B
Blog
博客园_首页
A
About on SuperTechFans
有赞技术团队
有赞技术团队
V
V2EX
U
Unit 42
I
InfoQ
IT之家
IT之家
博客园 - 司徒正美
阮一峰的网络日志
阮一峰的网络日志
博客园 - 叶小钗
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
Stack Overflow Blog
Stack Overflow Blog
The Cloudflare Blog
H
Help Net Security

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
Windows devs rerolled old code to save precious bytes
Richard Speed · 2026-06-17 · via The Register

OS PLaTFORMS

There was a time when Microsoft cared about every KB

Microsoft's latest Windows update might or might not have improved performance for the company's flagship operating system, but there was a time when its engineers cared about performance. A lot. 

Veteran Microsoft engineer Raymond Chen on Monday hearked back to that time by telling another war story from the glory days of Windows, when a team was working on an x86-32 emulator for an unnamed processor (though it isn't particularly difficult to identify potential candidates).

The emulator used binary translation – native code was generated for the original x86-32 code. Chen explained, "This offered a significant performance improvement over emulation via interpreter. You can imagine that x86-32 is just a bytecode, and the emulator is a JIT compiler."

The team came across a function that needed to allocate 64 KB of memory. Simple enough stuff – check that there is enough memory available, subtract 65536 from the stack pointer, and then initialize the memory in a loop.

Use the comments to correct me, but this sounds like loop rolling, where repetitive code gets condensed into a loop.

However, it appeared that a compiler had … optimized … the code "by unrolling the loop into 65,536 individual 'write byte to memory' instructions, each 4 bytes long."

Perhaps a bit quicker, but goodness – quite the memory hog. "All in all," wrote Chen, "it took this program 256 kilobytes of code to initialize 64 kilobytes of data."

Almost like a glimpse into a future where operating systems don't appear to give two hoots about efficient use of storage. What would that look like?

As for the engineers working on the CPU emulator, Chen said, "This offended the team so much that they added special code to the translator to detect this horrible function and replace it with the equivalent tight loop."

It would be interesting to know what that same team would make of the internals of some Windows binaries today, but it is heartening to know that, at one point, engineers cared about memory efficiency enough to reroll something. Sure, there might, just might, have been a performance hit, but spitting out 256 KB of code just to initialize 64 KB of data?

Naughty. Very naughty. The much younger version of this hack, optimizing the heck out of code to fit within the confines of computers from yesteryear, would have been horrified. ®