site_archiver@lists.apple.com Delivered-To: darwin-dev@lists.apple.com Le 20 juin 08 à 09:56, Jean-luc Chasseriau a écrit : Hi! Do you have an idea of how to solve this problem? Thanks to all! jeanluc man 3 sysctl. _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (Darwin-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-dev/site_archiver%40lists.appl... This email sent to site_archiver@lists.apple.com I'm please to be a new member of darwin-dev so here is the first question :) I would like to retrieve the current cpu frequency of each cpu/core installed (this frequency can change depending on the use -thanks to the intel speedstep technology-). Does anyone know which system call should be use to do so? Currently I'm using the asm instruction "rdtsc" (which retrieve the number of tick elapsed since the cpu started) then using a timer to calculate the frequency. This is working fine, but this is not reliable for multi-cpu/core architecture. Have a look at sysctl. This function can tell you a lot about your OS and your machine. You can also type "sysctl -a" in your terminal to get a preview of which info you can retreive using this function. smime.p7s
participants (1)
-
Jean-Daniel Dupas