Topology Object Types


Defines

#define TOPO_OBJ_TYPE_MAX   (TOPO_OBJ_MISC+1)
 Maximal value of an Object Type.

Enumerations

enum  topo_obj_type_t {
  TOPO_OBJ_SYSTEM, TOPO_OBJ_MACHINE, TOPO_OBJ_NODE, TOPO_OBJ_SOCKET,
  TOPO_OBJ_CACHE, TOPO_OBJ_CORE, TOPO_OBJ_PROC, TOPO_OBJ_MISC
}
 Type of topology Object. More...

Functions

int topo_get_type_order (topo_obj_type_t type)
 Convert an object type into a number that permits to compare them.
topo_obj_type_t topo_get_order_type (int order)
 Converse of topo_get_type_oder().

Define Documentation

#define TOPO_OBJ_TYPE_MAX   (TOPO_OBJ_MISC+1)

Maximal value of an Object Type.


Enumeration Type Documentation

Type of topology Object.

Do not rely on the ordering of the values as new ones may be defined in the future! If you need to compare types, use the value returned by topo_get_type_order() instead.

Enumerator:
TOPO_OBJ_SYSTEM  Whole system (may be a cluster of machines). The whole system that is accessible to libtopology. That may comprise several machines in SSI systems like Kerrighed.
TOPO_OBJ_MACHINE  Machine. A set of processors and memory with cache coherency.
TOPO_OBJ_NODE  NUMA node. A set of processors around memory which the processors can directly access.
TOPO_OBJ_SOCKET  Socket, physical package, or chip. In the physical meaning, i.e. that you can add or remove physically.
TOPO_OBJ_CACHE  Data cache. Can be L1, L2, L3, ...
TOPO_OBJ_CORE  Core. A computation unit (may be shared by several logical processors).
TOPO_OBJ_PROC  (Logical) Processor. An execution unit (may share a core with some other logical processors, e.g. in the case of an SMT core).
TOPO_OBJ_MISC  Miscellaneous objects. Objects which do not fit in the above but are detected by libtopology and are useful to take into account for affinity. For instance, some OSes expose their arbitrary processors aggregation this way.


Function Documentation

topo_obj_type_t topo_get_order_type ( int  order  ) 

Converse of topo_get_type_oder().

This is the converse of topo_get_type_order().

int topo_get_type_order ( topo_obj_type_t  type  ) 

Convert an object type into a number that permits to compare them.

Types shouldn't be compared as they are, since newer ones may be added in the future. This function returns an integer value that can be used instead.

Note:
topo_get_type_order(TOPO_OBJ_SYSTEM) will always be the lowest value, and topo_get_type_order(TOPO_OBJ_PROC) will always be the highest value.


Generated on Fri Jul 3 19:00:23 2009 for libtopology by  doxygen 1.5.9