IMO one of the most valuable things I've learned about static analysis is that the halting problem is overly pessimistic. It's easy to prove very interesting things about real-world code.
Things like dead-code removal are a pretty standard for modern optimizing compilers!