This is the mail archive of the
mailing list for the GCC project.
gcc optimization and stack allocation.
- From: "Yang Ye" <leafyoung at yahoo dot com>
- To: <gcc-help at gcc dot gnu dot org>
- Cc: "'wei lei'" <wrag201 at hotmail dot com>
- Date: Thu, 17 Jun 2004 16:47:44 +0800
- Subject: gcc optimization and stack allocation.
Do you have any idea on this scenario:
When gcc(3.3.3) allocating space for local varibles, e.g. a statement like
'char buf;', the allocated buffers in stack always come with some
space filled in at the end. If choose higher optimization level, let's say
gcc -O6, the spaced filled at the end are smaller. I searched quite a lot
documents, cannot find the official reason.