Re: Micro-optimizations to avoid some strlen calls.

2021-07-21 Thread Ranier Vilela
Em qua., 21 de jul. de 2021 às 09:28, Ranier Vilela escreveu: > Em qua., 21 de jul. de 2021 às 07:44, David Rowley > escreveu: > >> On Tue, 20 Jul 2021 at 10:49, Ranier Vilela wrote: >> > There are some places, where strlen can have an overhead. >> > This patch tries to fix this. >> >> I'm with

Re: Micro-optimizations to avoid some strlen calls.

2021-07-21 Thread Ranier Vilela
Em qua., 21 de jul. de 2021 às 07:44, David Rowley escreveu: > On Tue, 20 Jul 2021 at 10:49, Ranier Vilela wrote: > > There are some places, where strlen can have an overhead. > > This patch tries to fix this. > > I'm with Michael and David on this. > > I don't really feel like doing; > > - snpr

Re: Micro-optimizations to avoid some strlen calls.

2021-07-21 Thread David Rowley
On Tue, 20 Jul 2021 at 10:49, Ranier Vilela wrote: > There are some places, where strlen can have an overhead. > This patch tries to fix this. I'm with Michael and David on this. I don't really feel like doing; - snprintf(buffer, sizeof(buffer), "E%s%s\n", + buflen = snprintf(buffer, sizeof(buf

Re: Micro-optimizations to avoid some strlen calls.

2021-07-20 Thread David G. Johnston
On Tue, Jul 20, 2021 at 5:28 PM Michael Paquier wrote: > On Mon, Jul 19, 2021 at 07:48:55PM -0300, Ranier Vilela wrote: > > There are some places, where strlen can have an overhead. > > This patch tries to fix this. > > > > Pass check-world at linux ubuntu (20.04) 64 bits. > > Why does it matter?

Re: Micro-optimizations to avoid some strlen calls.

2021-07-20 Thread Michael Paquier
On Mon, Jul 19, 2021 at 07:48:55PM -0300, Ranier Vilela wrote: > There are some places, where strlen can have an overhead. > This patch tries to fix this. > > Pass check-world at linux ubuntu (20.04) 64 bits. Why does it matter? No code paths you are changing here are performance-critical, meani