[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

-O (optimization): different results?



I have ns-allinone-2.1b5 (not '5a) [on a Linux machine].  I wanted to
reduce the time required for some simulations, so I did 'make clean',
then changed
CCOPT = -g -Wall
in the Makefile to
CCOPT = -O -Wall
so that gcc would compile ns with optimizations.  I then did 'make', and
re-ran my simulation.  Unfortunately, this yielded results which were
vastly different than those obtained with the unoptimized compilation.

Any thoughts as to why this should be so?

Thanks,
--dan

---------------------------------------------------------------------------
 Daniel Friedman    [email protected]    http://www.isr.umd.edu/~danielf