frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Formally Verifying Peephole Optimisations in Lean

https://l-m.dev/cs/formally-verifying-peephole-optimisations-in-lean/
7•l-mdev•6d ago

Comments

amluto•35m ago
Is this concept of UB as poison actually sound? It seems to me (and I apologize for not using real notation, as I can read a little bit of Lean but I’ve never tried writing it, and my experience writing optimizers is nonexistent):

Suppose we start when an SSA-style function with inputs x and y:

    0
And we rewrite it as:

    let z = x +nsw y --or anything else that is UB for some input
    0
The original code is a function that takes x and y and returns an instance of iN {n}, namely bitvec 0.

The new code also takes any input to bitvec 0, although it may discard a poison value along the way. But this is UB in the C model!

I wonder whether this situation can be avoided by declaring that there is no control flow and that the program representation disallows discarding values. (And select would need to return poison if any argument is poison even if the selector says that the poison is not used.)

yablak•28m ago
iiic the model assumes no flow control, only select.
amluto•7m ago
It does. But maybe someone should prove (in Lean?) that the lack of flow control is sufficient.

Without a constraint that values aren’t ignored, the lack of flow control is certainly not sufficient, so trying to do this right would require defining (in Lean!) what an expression is.

What an unprocessed photo looks like

https://maurycyz.com/misc/raw_photo/
1553•zdw•12h ago•259 comments

Show HN: Z80-μLM, a 'Conversational AI' That Fits in 40KB

https://github.com/HarryR/z80ai
178•quesomaster9000•5h ago•42 comments

Staying ahead of censors in 2025

https://forum.torproject.org/t/staying-ahead-of-censors-in-2025-what-weve-learned-from-fighting-c...
146•ggeorgovassilis•5h ago•100 comments

Asking Gemini 3 for Brainf*ck code puts it in an infinite loop

https://teodordyakov.github.io/brainfuck-agi/
28•TeodorDyakov•1h ago•21 comments

You can make up HTML tags

https://maurycyz.com/misc/make-up-tags/
272•todsacerdoti•8h ago•101 comments

Developing a Beautiful and Performant Block Editor in Qt C++ and QML

https://rubymamistvalove.com/block-editor
49•michaelsbradley•2d ago•15 comments

Binaries

https://fzakaria.com/2025/12/28/huge-binaries
49•todsacerdoti•5h ago•19 comments

Show HN: My not-for-profit search engine with no ads, no AI, & all DDG bangs

https://nilch.org
87•UnmappedStack•5h ago•48 comments

Unity's Mono problem: Why your C# code runs slower than it should

https://marekfiser.com/blog/mono-vs-dot-net-in-unity/
203•iliketrains•13h ago•104 comments

My First Meshtastic Network

https://rickcarlino.com/notes/electronics/my-first-meshtastic-network.html
53•rickcarlino•6h ago•23 comments

Koine

https://github.com/pattern-zones-co/koine
9•handfuloflight•3d ago•2 comments

As AI gobbles up chips, prices for devices may rise

https://www.npr.org/2025/12/28/nx-s1-5656190/ai-chips-memory-prices-ram
173•geox•12h ago•249 comments

Software engineers should be a little bit cynical

https://www.seangoedecke.com/a-little-bit-cynical/
205•zdw•13h ago•140 comments

Growing up in “404 Not Found”: China's nuclear city in the Gobi Desert

https://substack.com/inbox/post/182743659
772•Vincent_Yan404•1d ago•341 comments

MongoBleed Explained Simply

https://bigdata.2minutestreaming.com/p/mongobleed-explained-simply
197•todsacerdoti•14h ago•79 comments

Researchers discover molecular difference in autistic brains

https://medicine.yale.edu/news-article/molecular-difference-in-autistic-brains/
140•amichail•12h ago•78 comments

Best practices for long-run LED strip installs (20–50M) to avoid flicker?

4•emmasuntech•4d ago•0 comments

PySDR: A Guide to SDR and DSP Using Python

https://pysdr.org/content/intro.html
184•kklisura•15h ago•8 comments

Spherical Cow

https://lib.rs/crates/spherical-cow
98•Natfan•12h ago•14 comments

EU to build no-fee payments service like Visa/Mastercard and Apple/Google Pay

https://www.independent.ie/business/digital-euro-what-it-is-and-how-we-will-use-the-new-form-of-c...
63•seanieb•1h ago•47 comments

Fast GPU Interconnect over Radio

https://spectrum.ieee.org/rf-over-fiber
30•montroser•7h ago•3 comments

Formally Verifying Peephole Optimisations in Lean

https://l-m.dev/cs/formally-verifying-peephole-optimisations-in-lean/
7•l-mdev•6d ago•3 comments

Mouse: Computer Programming Language

http://mouse.davidgsimpson.com/
13•gappy•2d ago•3 comments

Slaughtering Competition Problems with Quantifier Elimination (2021)

https://grossack.site/2021/12/22/qe-competition.html
56•todsacerdoti•12h ago•0 comments

Formulaic Delimiters in the Iliad and the Odyssey

https://glthr.com/formulaic-delimiters-in-the-iliad-and-the-odyssey
19•glth•2d ago•7 comments

Fast CVVDP implementation in C

https://github.com/halidecx/fcvvdp
37•todsacerdoti•11h ago•8 comments

Line scan camera image processing

https://daniel.lawrence.lu/blog/2025-09-21-line-scan-camera-image-processing/
41•vasco•4d ago•2 comments

A bitwise reproducible deep learning framework

https://github.com/microsoft/RepDL
25•noosphr•1w ago•0 comments

Finding Jingle Town: Debugging an N64 Game Without Symbols

https://blog.chrislewis.au/finding-jingle-town-debugging-an-n64-game-without-symbols/
34•knackers•5d ago•3 comments

Why I Disappeared – My week with minimal internet in a remote island chain

https://www.kenklippenstein.com/p/why-i-disappeared
84•eh_why_not•13h ago•100 comments