fix some performance