Small sort ips fix
Multiple improvements