This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
-fno-common
- From: "Dave Korn" <dave dot korn at artimi dot com>
- To: <gcc at gcc dot gnu dot org>
- Date: Thu, 31 Mar 2005 19:33:53 +0100
- Subject: -fno-common
According to the manual,
----------------------snip----------------------
`-fno-common'
In C, allocate even uninitialized global variables in the data
section of the object file, rather than generating them as common
blocks.
----------------------snip----------------------
When I compile the following declaration:
----------------------snip----------------------
unsigned int operatingMode;
----------------------snip----------------------
at file-scope, with -fno-common, it actually gets allocated to the .bss
section.
Is the manual wording just slightly vague here, and both .data and .bss
are regarded as covered by the phrase "the data section of the object file"?
Or should it actually have ended up in .data, not .bss after all?
cheers,
DaveK
--
Can't think of a witty .sigline today....