This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] analysis of global statics and removal associated vdefsand vuses


However, once we get the aliasing really working, we may find that this is a significant performance problem in real (i.e. non bench marking) code. In real code, significant number of functions have calls to printf and because of this extension a call to any function that calls printf, must clobber every static variable. Without the extension, the calls to printf (assuming we could properly annotate them,) would not effect the clobber sets at all.

I wonder, how many application have inner loops that call printf or sprintf?!? And even if there were, I doubt that not clobbering all static variables around printf is going to give any real advantage. So this glibc extension is not a problem.


Most examples of functions that are amenable to this optimization *and* are used in inner loops, will already be pure; and it is true even without taking glibc extensions into account, that callbacks will hinder this optimization by not allowing to make the function pure (think bsearch).

Paolo


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]