Skip to content

Make host_by_name faster

Fabien Chaix requested to merge chaix/simgrid:dev-get-hostname-faster into master

Currently, using the get_host_by_name_or_null function is quite inefficient because it tries also to look for VMs, which is also not ideal in terms of semantics.

In this MR, get_host_by_name_or_null is restricted to look for hosts only, which improves performance significantly, especially when creating large topologies.

In cases people do need to search for VMs, they will have to choose the host where to look for (or manually iterate over every host). The c-cloud-migration is modified to reflect this.

Merge request reports