🧵Can we trust Chinese open weight models? Was a question a lot of people asked after GLM 5.2 was released, scoring very well on coding benchmarks, and suspiciously Claude-like. So I turned an open-weight coding model into a backdoor with 1hr and <$100. Let's talk about it
in the next 2 minutes, I'll walk you through why every single AI company, including Nvidia, was unnecessarily sacrificing model intelligence, speed, and often both... and how we fixed it
the tldr:
- error(layer a) + error(layer b) < error(layer a) alone
- quantizing MORE of the model can result in the same or HIGHER quality model, if you know which layers to quantize.
let's take GLM5.2 architecture as an example. tokens here go through:
1) normalize 2) attention 3) normalize 4) moe
repeated 78 times
moe:
> just a big mlp, split into 257 separate smaller mlps (experts)
> 8 are routed and one is shared (only 3.5% of the mlp is activated)
so we say, let's make the matrix multiplications faster.
we quantize the matrices to nvfp4
but what do you quantize: every single one of the 257 experts, the attention projections, both?
Nvidia, and every other quant scheme, settles on a somewhat intuitive solution:
"""
a) there is only one router per layer, only one shared expert, and only one output projection per layer.
b) every single token goes through these, so they must be pretty important, and if we quantize these,
errors will compound across the xN number of tokens input.
c) so let's leave the shared experts and projections unquantized.
d) let's quantize ONLY the 256 routed experts
"""
-this is literally nvidia/GLM-5.2-NVFP4
intuitive.
simple to reason about.
wrong.
empirically:
if you have a model that processes its input through layer a, then layer b, it is possible that a scheme
quantizing BOTH layer a and layer b performs better than a scheme quantizing just one of these.
by way of example, our config quantizes every single out projection (all 78) of the attention, and 43 of the 78 shared experts. Nvidia quantizes none of these.
we score the same on benchmarks (quality).
we get a free 20% higher throughput.
i leave the math proof as an exercise for the reader in the paper...
and some pictures to click through if you'd rather skip the (43 pages of) math
Anthropic's Claude team just showed how to build an AI agent with real memory in under 30 minutes.
24-minutes. free. by the people who built Claude.
one person + 10 agents with memory = a team that runs 24/7, remembers every customer improves itself.
worth than $500 vibe-coding course.
Obfuscation vs The Optimizer: A Battle in LLVM Middle End.
@yates82 shows us how the continuous improvement of the LLVM optimizer defeats naive code obfuscation, and how the obfuscator can fight back.
An eternal fight in which all victories are ephemeral
https://t.co/KGRcbImqf4
This 1-pager from Xusheng Li on GDB internals of how watchpoints are implemented is a delight to read! (especially that double-write behaviour false positive - I did not know about that)
New post: deep dive into BEDaisy.sys, BattlEye’s kernel anti-cheat driver used in PUBG, R6 Siege, Escape from Tarkov, and more.
WinDbg output + annotated IDA pseudocode included.
https://t.co/0q1cnGP8ql
#ReverseEngineering#WindowsInternals#AntiCheat
Writing a simple 16 bit VM in less than 125 lines of C
learn how (some) virtual machines operate under the hood, by building register-based VM capable of interpreting and running a limited set of ASM instructions + some bonus programs to test
https://t.co/eHD9CmYuDD
Building a Compiler in C
- good series of videos on building compilers using C language
- in total there are 14 videos each one of them are in-depth
YouTube: https://t.co/Pi1acMGNTV
More Low-Level Learning Resources: https://t.co/OGmlzy4Ufi
Linux Kernel Programming: A Comprehensive Guide to Kernel Internals, Writing Kernel Modules, and Kernel Synchronization
You can read the book here: https://t.co/wFZcrE9fK6
Mini-Book On Executables: https://t.co/T2rWuAR7gz
Book On Operating Systems: https://t.co/fvmn7Msvoi
From Source to Binary: A C Programmer's Guide to Linking and Loading
I wrote a series of blogs as the chapter on what happens after you run the program.
Github: https://t.co/KOREmX0rW8
Website: https://t.co/N2oY8sajk8
There is currently one article in each of the thirteen chapters, but I'm working on adding more.
The next and previous buttons make it simple to move between chapters, and you can quickly determine which chapter is the next or previous by looking beneath the button.
If you would like to contribute, I would be delighted to hear your thoughts and suggestions. Any kind of contribution is welcome; you can make suggestions, submit a pull request with a clear description, or raise an issue on GitHub.