optimizing out string functions when the string contains a NUL
ohav chochmah
philomath868@gmail.com
Wed Jun 20 17:55:00 GMT 2012
On 6/20/12, Alexander Monakov <amonakov@ispras.ru> wrote:
> Unlike printf(), puts() outputs a newline after the string, which is why it
> cannot be optimized out.
>
> Alexander
>
>
Correct, I realized that right after sending...
it could still have been optimized to putc('\n'), which is (most
probably) faster then puts, but as Ian explained, it's not worth it.
Thanks.
More information about the Gcc-help
mailing list