Patchwork [gcc47] Deprecate -fconserve-space

login
register
mail settings
Submitter Steven Bosscher
Date June 4, 2012, 7:40 p.m.
Message ID <CABu31nPwMf-vYW_A1n5x1NjzbmAjJWdtRKChU2Vtmzud8CnDxw@mail.gmail.com>
Download mbox | patch
Permalink /patch/162861/
State New
Headers show

Comments

Steven Bosscher - June 4, 2012, 7:40 p.m.
(xf. http://gcc.gnu.org/ml/gcc/2012-06/msg00043.html)

On Mon, Jun 4, 2012 at 7:05 PM, Jason Merrill <jason at redhat dot com> wrote:
>>> Jason, is this flag something that we could deprecate for GCC 4.7 and
>>> remove?
>>
>>
>> The docs say the flag is not useful these days as BSS is widely available.
>
>
> Right.  So yes, go ahead.

Hello,

Here are the patches for wwwdocs and GCC 4.7 branch. Bootstrapped and
tested on x86_64-unknown-linux-gnu. OK?

Ciao!
Steven


 ObjC ObjC++ Joined MissingArgError(no class name specified with %qs)
Jason Merrill - June 4, 2012, 7:45 p.m.
In wwwdocs I would also mention that the flag has no effect on most 
targets.  In fact, I'm not sure it affects any targets that we still 
actually support; are there any a.out targets left?

Jason
Mike Stump - June 4, 2012, 9:37 p.m.
On Jun 4, 2012, at 12:45 PM, Jason Merrill wrote:
> In wwwdocs I would also mention that the flag has no effect on most targets.  In fact, I'm not sure it affects any targets that we still actually support; are there any a.out targets left?

The flag can go...  The days of not having bss are long gone...  Even AT&T had bss support for a.out.  The issue was if the assembler and linker didn't supported .bss, one would get hosed on ROM size.

Patch

Index: htdocs/gcc-4.7/changes.html
===================================================================
RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-4.7/changes.html,v
retrieving revision 1.110
diff -u -r1.110 changes.html
--- htdocs/gcc-4.7/changes.html	1 Jun 2012 09:27:10 -0000	1.110
+++ htdocs/gcc-4.7/changes.html	4 Jun 2012 19:35:22 -0000
@@ -15,6 +15,11 @@ 
 <h2>Caveats</h2>

   <ul>
+    <li><p>The <code>-fconserve-space</code> flag has been
+    deprecated.  The flag only had an effect for G++ but could
+    result in wrong semantics (please refer to the GCC manual
+    for further details).  The flag will be removed in GCC 4.8</p></li>
+
     <li><p>Support for a number of older systems and recently
     unmaintained or untested target ports of GCC has been declared
     obsolete in GCC 4.7.  Unless there is activity to revive them, the


gcc/
        * doc/invoke.texi (item -fconserve-space): This flag is deprecated

c-family/
        * c.opt (fconserve-space): Deprecate.

Index: doc/invoke.texi
===================================================================
--- doc/invoke.texi     (revision 188202)
+++ doc/invoke.texi     (working copy)
@@ -1940,6 +1940,8 @@  exhaustion is signalled by throwing @cod

 @item -fconserve-space
 @opindex fconserve-space
+This option is now deprecated.
+
 Put uninitialized or run-time-initialized global variables into the
 common segment, as C does.  This saves space in the executable at the
 cost of not diagnosing duplicate definitions.  If you compile with this
Index: c-family/c.opt
===================================================================
--- c-family/c.opt      (revision 188202)
+++ c-family/c.opt      (working copy)
@@ -745,7 +745,7 @@  Allow the arguments of the '?' operator

 fconserve-space
 C++ ObjC++ Var(flag_conserve_space)
-Reduce the size of object files
+Deprecated.  Reduce the size of object files, at the expense of wrong
semantics.

 fconstant-string-class=