Mail Archives: djgpp/1998/11/08/23:24:00
mark reed wrote:
> about the djgpp compiler, When i had it do the fixed point stuff, it kept
> thinking that fmul (%ecx) and fld
> (%edx), and fstp (%eax) were somehow changing the values of ecx, edx, and
> eax. So it kept reloading each of them every time they were used. lots of
> unnecesary movl 12(%ebp), %ecx . Anyone know why this would be?
What optimization flags did you use? Try `-O2', if you haven't. Also,
is it possible some of your variables are declared `volatile'?
> also is there a pentium optimization flag or anything? i found another
> thing that it did not do, fstp,
> requires that its target be not used one cycle before fstp is called, and
> the compiler put faddp with %eax,
> right before fstp with %eax. Putting some addl's in between sped up my code
> about .6 cycles per instance of faddp fstps. Which came to 6 cycles per
> matrix multiplication which isnt much. Dont know if it will do the same on
> other processors? Or if it is too much of a bother to add in to the
> compiler.
`-mpentium' may be what you're looking for. Alternatively, there is
PGCC (www.goof.com, IIRC), which does a lot of Pentium-specific
optimizations.
--
Nate Eldredge
nate AT cartsys DOT com
- Raw text -