property_based_interpolator( const value_type& head_, const value_type& tail_, const property_extractor_type& extractor = property_extractor_type()): head(head_), tail(tail_), stepping(get_stepping(head_, tail_)) {}
void hwloc_init_cpuInfo(cpu_set_t cpuSet) { int i; hwloc_obj_t obj; hwloc_topology_init(&hwloc_topology); hwloc_topology_set_flags(hwloc_topology, HWLOC_TOPOLOGY_FLAG_WHOLE_IO ); hwloc_topology_load(hwloc_topology); obj = hwloc_get_obj_by_type(hwloc_topology, HWLOC_OBJ_SOCKET, 0); cpuid_info.model = 0; cpuid_info.family = 0; cpuid_info.isIntel = 0; cpuid_info.osname = malloc(MAX_MODEL_STRING_LENGTH * sizeof(char)); for(i=0;i<obj->infos_count;i++) { if (strcmp(obj->infos[i].name ,"CPUModelNumber") == 0) { cpuid_info.model = atoi(hwloc_obj_get_info_by_name(obj, "CPUModelNumber")); } else if (strcmp(obj->infos[i].name, "CPUFamilyNumber") == 0) { cpuid_info.family = atoi(hwloc_obj_get_info_by_name(obj, "CPUFamilyNumber")); } else if (strcmp(obj->infos[i].name, "CPUVendor") == 0 && strcmp(hwloc_obj_get_info_by_name(obj, "CPUVendor"), "GenuineIntel") == 0) { cpuid_info.isIntel = 1; } else if (strcmp(obj->infos[i].name ,"CPUModel") == 0) { strcpy(cpuid_info.osname, obj->infos[i].value); } } cpuid_topology.numHWThreads = hwloc_get_nbobjs_by_type(hwloc_topology, HWLOC_OBJ_PU); cpuid_info.stepping = get_stepping(); DEBUG_PRINT(DEBUGLEV_DEVELOP, HWLOC CpuInfo Family %d Model %d Stepping %d isIntel %d numHWThreads %d activeHWThreads %d, cpuid_info.family, cpuid_info.model, cpuid_info.stepping, cpuid_info.isIntel, cpuid_topology.numHWThreads, cpuid_topology.activeHWThreads) return; }