@@ -189,27 +189,31 @@ static umf_result_t query_attribute_value(void *srcMemoryTarget,
189
189
memattr_type_t type ) {
190
190
hwloc_topology_t topology = umfGetTopology ();
191
191
if (!topology ) {
192
+ LOG_ERR ("umfGetTopology() failed" );
192
193
return UMF_RESULT_ERROR_NOT_SUPPORTED ;
193
194
}
194
195
195
196
hwloc_obj_t srcNumaNode = hwloc_get_obj_by_type (
196
197
topology , HWLOC_OBJ_NUMANODE ,
197
198
((struct numa_memory_target_t * )srcMemoryTarget )-> physical_id );
198
199
if (!srcNumaNode ) {
200
+ LOG_ERR ("hwloc_get_obj_by_type() failed" );
199
201
return UMF_RESULT_ERROR_INVALID_ARGUMENT ;
200
202
}
201
203
202
204
hwloc_obj_t dstNumaNode = hwloc_get_obj_by_type (
203
205
topology , HWLOC_OBJ_NUMANODE ,
204
206
((struct numa_memory_target_t * )dstMemoryTarget )-> physical_id );
205
207
if (!dstNumaNode ) {
208
+ LOG_ERR ("hwloc_get_obj_by_type() failed" );
206
209
return UMF_RESULT_ERROR_INVALID_ARGUMENT ;
207
210
}
208
211
209
212
// Given NUMA nodes aren't local, HWLOC returns an error in such case.
210
213
if (!hwloc_bitmap_intersects (srcNumaNode -> cpuset , dstNumaNode -> cpuset )) {
211
214
// Since we want to skip such query, we return the worst possible
212
215
// value for given memory attribute.
216
+ LOG_ERR ("hwloc_bitmap_intersects() failed - memattr_get_worst_value()" );
213
217
* value = memattr_get_worst_value (type );
214
218
return UMF_RESULT_SUCCESS ;
215
219
}
@@ -234,6 +238,7 @@ static umf_result_t query_attribute_value(void *srcMemoryTarget,
234
238
int ret = hwloc_memattr_get_value (topology , hwlocMemAttrType , dstNumaNode ,
235
239
& initiator , 0 , & memAttrValue );
236
240
if (ret ) {
241
+ LOG_PERR ("hwloc_memattr_get_value() failed" );
237
242
return (errno == EINVAL ) ? UMF_RESULT_ERROR_NOT_SUPPORTED
238
243
: UMF_RESULT_ERROR_UNKNOWN ;
239
244
}
0 commit comments