This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: ARM: allow factorization of constants into addressing insns whenoptimizing for space
- From: Arpad Beszedes <beszedes at inf dot u-szeged dot hu>
- To: nico at cam dot org
- Cc: rearnsha at arm dot com, alga at rgai dot hu, gcc-patches at gcc dot gnu dot org
- Date: Tue, 28 Oct 2003 15:27:30 +0100
- Subject: Re: ARM: allow factorization of constants into addressing insns whenoptimizing for space
- Organization: SED
> Granted, 0.8% reduction isn't that big either, but just for the sake of
> arguing this is twice as significant. ;-)
It seems that the effect of the patch heavily depends on the type of the code.
Therefore I think that judging based on either of the test beds is
inappropriate; the same GCC will be used for compiling linux and applications as
well!
I suspect that even in vmlinux.2 there were objects for which the code size was
increased. In the CSiBE benchmark, out of the total 262 object files the patch
benefited only in 6 cases (5.5% of the total testbed size), and in 87 cases (51%
of the testbed size) the code size increased (other object sizes were not
affected). The benefit from these 6 cases was only 0.07%. Therefore the overall
0.4% code size increase.
To overcome this problem, I can only imagine adding a new compiler option to
manually enable or disable this transformation. We will prepare a patch for
this, if you support the idea.
It would also be nice if the compiler could estimate (or exactly compute) the
cost/benfit of applying the transformation or not :-) Maybe this is worth some
more research...
> Gábor, I think the benchmark might well benefit from some larger examples.
> It's a good start, but it really only has about a dozen small
> applications that it draws code from.
On the other end, I agree that we should extend the benchmark with larger
examples and/or with programs of other types. In this respect we would very much
appreciate your input. What kind of programs should we include? From the linux
kernel which parts are interesting? But please remember that the programs should
be able to be compileable for all platforms we investigate.
Best regards,
Arpad Beszedes
--
Arpad Beszedes - researcher
Software Engineering Department
University of Szeged, Hungary
e-mail: beszedes@inf.u-szeged.hu
web: http://www.inf.u-szeged.hu/~beszedes
tel.: (+36) 62 544145