Minor performance improvements, etc.