Re: Faster str to int conversion (was Table with large number of int columns, very slow COPY FROM)

2018-07-20 Thread Andres Freund
Hi, On 2018-07-20 08:27:34 -0400, Robert Haas wrote: > On Thu, Jul 19, 2018 at 4:32 PM, Andres Freund wrote: > >> 1. Why the error message changes? If there's a good reason, it should > >> be done as a separate commit, or at least well-documented in the > >> commit message. > > > > Because

Re: Faster str to int conversion (was Table with large number of int columns, very slow COPY FROM)

2018-07-20 Thread Robert Haas
On Thu, Jul 19, 2018 at 4:32 PM, Andres Freund wrote: >> 1. Why the error message changes? If there's a good reason, it should >> be done as a separate commit, or at least well-documented in the >> commit message. > > Because there's a lot of "invalid input syntax for type %s: \"%s\"", > error

Re: Faster str to int conversion (was Table with large number of int columns, very slow COPY FROM)

2018-07-19 Thread Andres Freund
Hi, On 2018-07-18 14:34:34 -0400, Robert Haas wrote: > On Sat, Jul 7, 2018 at 4:01 PM, Andres Freund wrote: > > FWIW, here's a rebased version of this patch. Could probably be polished > > further. One might argue that we should do a bit more wide ranging > > changes, to convert scanint8 and

Re: Faster str to int conversion (was Table with large number of int columns, very slow COPY FROM)

2018-07-18 Thread Robert Haas
On Sat, Jul 7, 2018 at 4:01 PM, Andres Freund wrote: > FWIW, here's a rebased version of this patch. Could probably be polished > further. One might argue that we should do a bit more wide ranging > changes, to convert scanint8 and pg_atoi to be also unified. But it > might also just be

Re: Faster str to int conversion (was Table with large number of int columns, very slow COPY FROM)

2018-07-07 Thread Andres Freund
Hi, On 2017-12-08 13:44:37 -0800, Andres Freund wrote: > On 2017-12-08 10:17:34 -0800, Andres Freund wrote: > > the strtoll is libc functionality triggered by pg_atoi(), something I've > > seen show up in numerous profiles. I think it's probably time to have > > our own optimized version of it