Move logic to compute_resources_vms_helper