[ale] GCC options...
Doug McNash
dmcnash at charter.net
Thu Aug 28 23:25:48 EDT 2003
I believe -mcpu is pretty meaningless on a CISC (vs RISC)
processor. -march may allow the complier to emit
instructions special to that version of the processor
which in 99% of the time is meaningless on the x86 but I
have not examined the output of the latest compilier/CPU
combinations. That 1% can be significant. You can't lose
anything but portability and ease of maintaince by
specifing -march=.
Try it an see. You would be better off unrolling loops,
having loop code fit inside a cache line, testing which is
faster a for(), while() or do {} while() and avoiding
tests i.e. if() and switch()==a cascade of if()'s, put the
most likely match up first. A while loop is usually faster
but I have seen a case where a do-while was faster. In
other words reviewing your code will produce better gains.
--
Doug McNash <dmcnash at yahoo.com>
_______________________________________________
Ale mailing list
Ale at ale.org
http://www.ale.org/mailman/listinfo/ale
More information about the Ale
mailing list