LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (http://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   Identifying CPU/Architecture for GCC Optimisations (http://www.linuxquestions.org/questions/linux-hardware-18/identifying-cpu-architecture-for-gcc-optimisations-317203/)

detly 04-26-2005 03:19 AM

Identifying CPU/Architecture for GCC Optimisations
 
Is there a way to probe or somehow identify the type of machine I'm logged into, even if such information wasn't used to compile the kernel or other software? The purpose of the info is for the -mtune= and -mcpu= flags for GCC compilation.

This is half out of necessity, half out of curiosity (since I could always ask the owner of the machine in question).

jschiwal 04-26-2005 04:30 AM

Look at the man page for uname. There is 'uname -m' for machine, and 'uname -p' for processor, or use the long options --machine, --processor. I'm not sure when there would be a difference.

hw-tph 04-26-2005 07:23 AM

You can also view /proc/cpuinfo to see exactly what features your CPU supports (SSE, 3dnow, etc).


Håkan

detly 04-27-2005 09:44 PM

Excellent. Thanks for the help.


All times are GMT -5. The time now is 09:58 PM.