This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] analysis of global statics and removal associated vdefsand vuses
On Sun, 29 Aug 2004, Zack Weinberg wrote:
> I gotta wonder how many real users of this particular glibc extension
> there are. I've never heard of anyone using it. Perhaps the users
> that do exist, would be willing to modify their code slightly to put
> gcc on notice that it couldn't optimize around printf quite so much...
It's not all users of the extension either, just those with custom formats
that modify static variables. The most obvious uses wouldn't need to
modify static variables.
The most natural way for users to disable special handling for printf, if
they do use custom formats that modify statics, is -fno-builtin-printf,
which they probably want anyway to avoid format warnings for their new
conversions (presuming they use -Wall).
snprintfv (as in autogen) also provides the same facility for custom
formats, but as it #defines printf to its own function name the same
problems don't arise.
--
Joseph S. Myers http://www.srcf.ucam.org/~jsm28/gcc/
http://www.srcf.ucam.org/~jsm28/gcc/#c90status - status of C90 for GCC 3.5
jsm@polyomino.org.uk (personal mail)
jsm28@gcc.gnu.org (Bugzilla assignments and CCs)