Add a few scary optimizations