This is the mail archive of the cygwin@sourceware.cygnus.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: Optimizing code with cygwin gcc??


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]