This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
GCC4.3.4 downside against GCC3.4.4 on mips?
- From: "Amker.Cheng" <amker dot cheng at gmail dot com>
- To: gcc at gcc dot gnu dot org
- Date: Tue, 25 May 2010 16:28:37 +0800
- Subject: GCC4.3.4 downside against GCC3.4.4 on mips?
Hi all,
I compared assembly files of a function compiled by GCC4.3.4 and GCC3.4.4.
The function focuses on array computation and has no branch, or any
loop structure,
The command line is like "-march=mips32r2 -O3", and here is the
instruction statics:
total : 1879 : 1534
addiu : 6 : 6
addu : 216 : 129
jr : 1 : 1
lui : 5 : 5
lw : 396 : 353
madd : 41 : 0
mfhi : 80 : 80
mflo : 121 : 86
move : 0 : 21
mtlo : 39 : 0
mul : 85 : 0
mult : 18 : 80
multu : 64 : 0
or : 80 : 80
sll : 80 : 80
sra : 79 : 47
srl : 80 : 80
subu : 80 : 80
sw : 408 : 406
Considering there is no any branch or loop structure ,It seems result
of GCC3.4.4
is much better, since generating much less instructions.
secondly, GCC4.3.4 does consume less stack slots(1224 bytes against 1408).
So, any comments? Thanks in advance.
--
Best Regards.