Skip to contentSkip to conversation

Compile Options for Optimized Programs

DISCUSSION 1stFlight 2 participants 2 messages Aug 10, 2002

lore
Share & tools
lore

1stFlight

author
#0 lore raw

Awhile back I found some options for optimizing programs on a i686 (Athlon)
processor during compile..something along the lines of - O3 -mpcu -march do things options (environment settings I believe) ring a bell to anyone, and if so how do I impliement them? Thanks!

Darryl
-
To unsubscribe from this list: send the line "unsubscribe linux-newbie" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.linux-learn.org/faqs

#1 lore raw

For optimizing your compiled apps, there are a lot of options:

-O3
-march=ARCH
-mcpu=ARCH

but there are many else. Make man gcc and go to the Optimization Options section. For enabling them just put them on the command line at compile time.

If you want to modify an existing makefile, you can set the CFLAGS and the CPPFLAGS environment variables. If you use bash, this can be done with
export CFLAGS="-option1 -option2 ..."

Hope this helps

Benoit

Quoted 11 lines · On Fri, Aug 09, 2002 at 10:36:48PM, 1stFlight wrote:

Awhile back I found some options for optimizing programs on a i686 (Athlon)
processor during compile..something along the lines of - O3 -mpcu -march do things options (environment settings I believe) ring a bell to anyone, and if so how do I impliement them? Thanks!

Darryl
-
To unsubscribe from this list: send the line "unsubscribe linux-newbie" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.linux-learn.org/faqs

---end quoted text---

Signature · 4 lines
Benoit JOSEPH 
Manex SPRL: [email protected]
Perso: [email protected]
       [email protected]