Jump to content

Building from sources and compiler flags


sherington
 Share

Recommended Posts

Hi,

 

Usually when I build packages from source, I just do:

 

configure

make

su -c "make install"

 

No problem with that.

 

What I'd like to make sure though, is that when I build from sources that I am getting the full benefit of compiler optimisations for my CPU - I'm not sure that configure and/or make is detecting my Athlon CPU and making the best possible optimisations.

 

I know that I can do something like this when I build, specifying flags such as...

 

-march=athlon

 

...but how do I know which marchitecture to choose?

 

From the gcc man page:

 

"The choices for cpu-type are i386, i486, i586, i686, pentium, pentium-mmx, pentiumpro, pentium2, pentium3, pentium4, k6, k6-2, k6-3, athlon, athlon-tbird, athlon-4, athlon-xp, athlon-mp, winchip-c6, winchip2 and c3."

 

Does it matter which of the athlon-xxx options I specify? How do I know which one I should use? Is there a tool I can use to give me definitive processor information? I have no idea which particular type of Athlon I have.

 

Any hints would be appreciated.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...