Hartmut Kaiser, le Wed 14 Mar 2012 08:52:59 -0500, a écrit :
> 
> > Le 14/03/2012 09:39, Brice Goglin a écrit :
> > > Le 13/03/2012 19:08, Hartmut Kaiser a écrit :
> > >>> -          hwloc_bitmap_from_ith_ulong(obj->cpuset,
> > GroupMask[i].Group,
> > >>> GroupMask[i].Mask);
> > >>> +          hwloc_bitmap_from_ith_ulong(obj->cpuset,
> > 2*GroupMask[i].Group,
> > >>> GroupMask[i].Mask & 0xfffffff);
> > > There's a missing 'f' above.
> > > Here's another almost untested patch, with additional debug printf.
> > > Please remove the previous one and apply this one instead.
> > 
> > Grrr, I failed to fix the missing f. New patch attached.
> 
> Your patch relies on two symbols which I'm not able to resolve:
> hwloc_debug_bitmap_2args and hwloc_debug_2args. If I comment those the
> picture has changed (see attached), but still no overall luck....

Here is a fixed patch concerning the debugging statements.

Samuel
Index: src/topology-windows.c
===================================================================
--- src/topology-windows.c      (révision 4385)
+++ src/topology-windows.c      (copie de travail)
@@ -532,7 +532,9 @@
        obj = hwloc_alloc_setup_object(type, id);
         obj->cpuset = hwloc_bitmap_alloc();
        hwloc_debug("%s#%u mask %lx\n", hwloc_obj_type_string(type), id, 
procInfo[i].ProcessorMask);
-       hwloc_bitmap_from_ulong(obj->cpuset, procInfo[i].ProcessorMask);
+       hwloc_bitmap_from_ulong(obj->cpuset, procInfo[i].ProcessorMask & 
0xffffffff);
+       hwloc_bitmap_from_ith_ulong(obj->cpuset, i, procInfo[i].ProcessorMask 
>> 32);
+       hwloc_debug_2args_bitmap("%s#%u bitmap %s\n", 
hwloc_obj_type_string(type), id, obj->cpuset);

        switch (type) {
          case HWLOC_OBJ_NODE:
@@ -634,7 +636,9 @@
              mask = procInfo->Group.GroupInfo[id].ActiveProcessorMask;
              hwloc_debug("group %u %d cpus mask %lx\n", id,
                   procInfo->Group.GroupInfo[id].ActiveProcessorCount, mask);
-             hwloc_bitmap_from_ith_ulong(obj->cpuset, id, mask);
+             hwloc_bitmap_from_ith_ulong(obj->cpuset, 2*id, mask & 0xffffffff);
+             hwloc_bitmap_from_ith_ulong(obj->cpuset, 2*id+1, mask >> 32);
+             hwloc_debug_2args_bitmap("group %u %d bitmap %s\n", id, 
procInfo->Group.GroupInfo[id].ActiveProcessorCount, obj->cpuset);
              hwloc_insert_object_by_cpuset(topology, obj);
            }
            continue;
@@ -648,8 +652,10 @@
         obj->cpuset = hwloc_bitmap_alloc();
         for (i = 0; i < num; i++) {
           hwloc_debug("%s#%u %d: mask %d:%lx\n", hwloc_obj_type_string(type), 
id, i, GroupMask[i].Group, GroupMask[i].Mask);
-          hwloc_bitmap_from_ith_ulong(obj->cpuset, GroupMask[i].Group, 
GroupMask[i].Mask);
+          hwloc_bitmap_from_ith_ulong(obj->cpuset, 2*GroupMask[i].Group, 
GroupMask[i].Mask & 0xfffffff);
+          hwloc_bitmap_from_ith_ulong(obj->cpuset, 2*GroupMask[i].Group+1, 
GroupMask[i].Mask >> 32);
         }
+       hwloc_debug("%s#%u bitmap %lx\n", hwloc_obj_type_string(type), id, 
obj->cpuset);

        switch (type) {
          case HWLOC_OBJ_NODE:

Reply via email to