Mail Archives: djgpp/1997/04/04/10:06:25
DoLooP <kst AT imaginet DOT fr> wrote:
> I'm new in c coding, and i'm trying djggp because a lot of demoscoder
> says that this is THE best compiler.
Not only for speed, there are other things that make DJGPP better.
> So i try a simple 50000 loop with a
> calcul in it. i've done a time mesure and the code generated is really
> NOT speed comparing to what the watcom c gives to me.
Are you using Pentium optimization in the Watcom version?, if yes, sorry but
DJGPP doesn't have it yet and can make a difference.
> it run 2 times better in watcom flat mode.
You aren't making all OK.
> i've used -o2 -forcemem -forceaddr -fstrengh... flags.
Hmmm be more explicit.
Use:
-O2 or try if -O3 helps.
-fomit-frame-pointer (be carrefull GCC have a bug regarding to the use of EBP
when omit-frame-pointer is enabled, if you use EBP in your inline assembler
test the generated code to see if you need to save EBP, even when you indicate
that EBP was used in your inline).
Pass parameters in registers if you are calling small routines inside of the
loop, that can make a big difference.
I don't know if -forcemem -forceaddr will help you, I don't think so.
-fstrengh-reduce, try with no-strengh-reduce, can modify the situation.
>(and perhaps some other one). could someone help
> me ?
In general GCC is very good optimizing but:
1) No Pentium optimization available yet (is under test and as a parallel
development).
2) The register convention call is harder to use.
SET
--------------- 0 --------------------------------
Salvador Eduardo Tropea (SET).
Address: Curapaligue 2124, Caseros, 3 de Febrero
Buenos Aires, (1678), ARGENTINA
TE: +(541) 759 0013
- Raw text -