|
Boost : |
From: Ben Young (ben_at_[hidden])
Date: 2003-10-02 03:00:38
On Wed, 1 Oct 2003, Dave Gomboc wrote:
> > > Maybe we should add -fwritable-strings for GCC in Boost.Build unless
>
> > > <optimization>size is set?
> >
> > In my experience the links are slow only if -g is used. I
> > think it should be sufficient to add -fwritable-strings only
> > for debug builds. Ralf
>
> I have a (non-boost) source file that I need to use -fwritable-strings
> even without -g. Mind you, it has about 6.5x10^5 string literals in it.
> ;-)
>
> I'd still like to get confirmation from the original poster
> (ben.young_at_[hidden]) that using the -fwritable-strings switch will
> actually solve his lengthy compile times, but if it does, sure, Dave's
> proposed change to the Boost.Build setting works for me. If it doesn't,
> hopefully Ben's company will contribute their patch to GCC.
>
I'm afraid -fwritable-strings doesn't work. The problem is not in the code
string literals (which for non-optimized builds are conpiled with
-fno-merge-constants by default), but the debug_str sections, whose flags
are set as a compile time constants (well, a macro :) ). I will get onto
posting the patch to gcc, but I imagine it will be a while before it comes
out (if it is accepted at all)
Thanks for the feedback!
Ben
---
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk