Make queue more efficient