more performance fixes