Re: i386 inline-asm string functions - some questions
"Zack Weinberg" <[email protected]> Sun, 28 Dec 2003 18:22:08 -0800
| Newsgroups | org.kernel.vger.linux-gcc |
|---|---|
| Message-ID | <[email protected]> |
Denis Zaitsev <[email protected]> writes: > On Sat, Dec 27, 2003 at 10:38:49AM -0800, Zack Weinberg wrote: >> Denis Zaitsev <[email protected]> writes: >> >> >> so, first off, I don't think this kind of optimization is libc's >> >> business; we have the tools to do a better job over here in the >> >> compiler. >> > >> > Should the compiler implement all the string functions? >> >> That is the trend. The compiler can make a better decision about >> whether memcpy (for example) should be inlined at all, if it knows >> the properties. > > Yes, but even if it can, it is rather a kinda political question - > should it do so, or this must be defined by the programmer. I > personally like the latter approach, but who knows... Meh. I personally am convinced that the compiler can do a *much* better job, and that trying to improve bits/string.h and bits/string2.h is a waste of time; in fact, I've felt that they have *always* caused the generated code to get worse, from the day they were introduced. I once tried to get Uli to take them out again, with hard numbers to back me up, but he ignored me. So I have very little interest in pursuing any of your suggestions. If you want to keep at them, though, and come up with patches, feel free. zw