some speed optimization in horizon