This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/21982] GCC should combine adjacent stdio calls
- From: "joseph at codesourcery dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 10 Jun 2005 14:28:36 -0000
- Subject: [Bug tree-optimization/21982] GCC should combine adjacent stdio calls
- References: <20050609125653.21982.ghazi@gcc.gnu.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From joseph at codesourcery dot com 2005-06-10 14:28 -------
Subject: Re: GCC should combine adjacent stdio
calls
On Fri, 10 Jun 2005, ghazi at gcc dot gnu dot org wrote:
> I have the cpu time, but it seems premature. Your patch as it stands only
> optimizes two adjacent printf calls. Not printf with putc or puts and none of
> the f* variants, right? And GCC uses mostly the f* variants. This is like
> asking for tree-ssa benchmarks when the framework was in but before any new
> passes were written.
Since putc and puts are typically faster than printf (not needing to parse
the input) and we optimize printf of constants into them, it's not clear
that merging printf with such functions would be an improvement either.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21982