This is the mail archive of the
cygwin@sourceware.cygnus.com
mailing list for the Cygwin project.
RE: Optimizing code with cygwin gcc??
- To: 'Dan Oelke' <Dan.Oelke@oelke.com>, "'cygwin@sourceware.cygnus.com'" <cygwin@sourceware.cygnus.com>, 'Raman Bakshi' <raman_bakshi@yahoo.com>
- Subject: RE: Optimizing code with cygwin gcc??
- From: Heribert Dahms <heribert_dahms@icon-gmbh.de>
- Date: Sat, 31 Jul 1999 01:53:12 +0200
Hi Dan,
cut&paste error: you trapped yourself 8-)
gcc -c obj1.c -O2
or
gcc -O2 -c obj1.c
Bye, Heribert (DAHMS@ifk20.mach.uni-karlsruhe.de)
> -----Original Message-----
> From: Dan Oelke [SMTP:Dan.Oelke@oelke.com]
> Sent: Thursday, July 29, 1999 21:14
> To: cygwin@sourceware.cygnus.com; Raman Bakshi
> Subject: Re: Optimizing code with cygwin gcc??
>
>
> [...]when i compile and link my code using
> >the -O1 or -O2 options i get get tons of error
> >messages during linking time ( gcc -o -O2 exe_name
> >obj1.o obj2.o). [...]
>
> To get rid of your error messages what you need to do is:
> gcc -o exe_name -O2 obj1.o obj2.o
> NOT
> gcc -o -O2 exe_name obj1.o obj2.o
>
> But, that will not do any optimization, because that is
> linking which won't do any real optimization.
> What you need to do is change your compile line
> that creates the .o files to look like
> gcc -c -O2 obj1.c
>
> Good luck!
> Dan
>
>
> --
> Want to unsubscribe from this list?
> Send a message to cygwin-unsubscribe@sourceware.cygnus.com
--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com