Re: [HACKERS] Varlena and binary

2011-02-07 Thread Robert Haas
On Mon, Feb 7, 2011 at 11:12 AM, Tom Lane wrote: > =?utf-8?q?Rados=C5=82aw_Smogura?= writes: >> I'm sending small patch for textsend. It reduces unnecessary copies, and >> memory usage for duplication of varlena data. May you look? > > This code will break the day that text and bytea don't have t

Re: [HACKERS] Varlena and binary

2011-02-07 Thread Radosław Smogura
Just from curious may I ask in which direction this will go, and how this will affect performance of text and binary format? Actually I started to make smaller improvements, and I think about one big to encode text (when client and server encoding are different) directly to StringInfo, without

Re: [HACKERS] Varlena and binary

2011-02-07 Thread Tom Lane
=?utf-8?q?Rados=C5=82aw_Smogura?= writes: > I'm sending small patch for textsend. It reduces unnecessary copies, and > memory usage for duplication of varlena data. May you look? This code will break the day that text and bytea don't have the same internal representation, which seems likely to b

[HACKERS] Varlena and binary

2011-02-06 Thread Radosław Smogura
Hi, I'm sending small patch for textsend. It reduces unnecessary copies, and memory usage for duplication of varlena data. May you look? Kind regards, Radosław Smogura diff --git a/src/backend/utils/adt/varlena.c b/src/backend/utils/adt/varlena.c index e111d26..f24bbcd 100644 --- a/src/backend/u