cpu.h 720 B

1234567891011121314151617181920212223242526272829303132
  1. #ifndef _PCILIB_CPU_H
  2. #define _PCILIB_CPU_H
  3. #ifdef __cplusplus
  4. extern "C" {
  5. #endif
  6. /**
  7. * Return the mask of system memory page
  8. * @return - page mask, the bits which will correspond to offset within the page are set to 1
  9. */
  10. int pcilib_get_page_mask();
  11. /**
  12. * Number of CPU cores in the system (including HyperThreading cores)
  13. * @return - number of available CPU cores
  14. */
  15. int pcilib_get_cpu_count();
  16. /**
  17. * Returns the generation of Intel Core architecture
  18. * Processors up to Intel Core gen4 are recognized.
  19. * @return - Generation of Intel Core architecture (1 to 4) or 0 for non-Intel and Intel pre-Core architectures
  20. */
  21. int pcilib_get_cpu_gen();
  22. #ifdef __cplusplus
  23. }
  24. #endif
  25. #endif /* _PCILIB_CPU_H */