Skip to content

Commit

Permalink
utils/info: don't display unknown memattr initiator OS index
Browse files Browse the repository at this point in the history
we have the logical index before it, just remove the
OS index instead of printing 4294967295.

Refs #468

Signed-off-by: Brice Goglin <Brice.Goglin@inria.fr>
  • Loading branch information
bgoglin committed May 28, 2021
1 parent 5c61a8c commit 97e37e5
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion utils/hwloc/hwloc-info.c
Expand Up @@ -280,7 +280,10 @@ hwloc_info_show_obj(hwloc_topology_t topology, hwloc_obj_t obj, const char *type
} else if (initiators[j].type == HWLOC_LOCATION_TYPE_OBJECT) {
char types[64];
hwloc_obj_type_snprintf(types, sizeof(types), initiators[j].location.object, 1);
snprintf(_inits, sizeof(_inits), "%s L#%u P#%u", types, initiators[j].location.object->logical_index, initiators[j].location.object->os_index);
if (initiators[j].location.object->os_index != (unsigned)-1)
snprintf(_inits, sizeof(_inits), "%s L#%u P#%u", types, initiators[j].location.object->logical_index, initiators[j].location.object->os_index);
else
snprintf(_inits, sizeof(_inits), "%s L#%u", types, initiators[j].location.object->logical_index);
inits = _inits;
} else {
assert(0);
Expand Down

0 comments on commit 97e37e5

Please sign in to comment.