misc optimizations