This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: A recent patch increased GCC's memory consumption in some cases!
- From: "Andrew Pinski" <pinskia at gmail dot com>
- To: "Jan Hubicka" <jh at suse dot cz>, "GCC Development" <gcc at gcc dot gnu dot org>
- Cc: gcctest at suse dot de, dvorakz at suse dot cz, andrew_pinski at playstation dot sony dot com, rguenther at suse dot de, gcc-regression at gcc dot gnu dot org
- Date: Sun, 22 Apr 2007 18:43:00 -0700
- Subject: Re: A recent patch increased GCC's memory consumption in some cases!
- References: <462B685C.mail2PF14OOH0@suse.de> <20070422201222.GF23507@kam.mff.cuni.cz> <de8d50360704221539m2c6b7f1t5959cecad89558bb@mail.gmail.com>
On 4/22/07, Andrew Pinski <pinskia@gmail.com> wrote:
I think it was just by accident that the libfuncs would fit in
phi_node+3 operand slot. Also I think extra_order_size_table needs to
be relooked at after my phi_node and the gimple_stmt patches as I
think we now put have some duplicates and the sizes have slightly
changed.
Ok, it was just happened on x86 to be sizeof(struct
tree_function_decl) == sizeof (struct tree_phi_node) + sizeof (struct
phi_arg_d) * 3 which is no longer true any more. Now we are wasting
32bytes on x86 per function decl. This was never true on any other
target anyways as sizeof(struct tree_function_decl) was always bigger.
So the only thing to do is to add sizeof(struct tree_function_decl) to
extra_order_size_table or change how we deal with small allocations.
Thanks,
Andrew Pinski