From 3f50ba27cf417eb57fd310c2a88f76a6ea6b966e Mon Sep 17 00:00:00 2001 From: Tom Lane Date: Tue, 27 Jun 2006 02:51:40 +0000 Subject: Create infrastructure for 'MinimalTuple' representation of in-memory tuples with less header overhead than a regular HeapTuple, per my recent proposal. Teach TupleTableSlot code how to deal with these. As proof of concept, change tuplestore.c to store MinimalTuples instead of HeapTuples. Future patches will expand the concept to other places where it is useful. --- src/backend/commands/portalcmds.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) (limited to 'src/backend/commands/portalcmds.c') diff --git a/src/backend/commands/portalcmds.c b/src/backend/commands/portalcmds.c index 403b5c7064..c4c55c9cf3 100644 --- a/src/backend/commands/portalcmds.c +++ b/src/backend/commands/portalcmds.c @@ -14,7 +14,7 @@ * * * IDENTIFICATION - * $PostgreSQL: pgsql/src/backend/commands/portalcmds.c,v 1.46 2006/03/05 15:58:24 momjian Exp $ + * $PostgreSQL: pgsql/src/backend/commands/portalcmds.c,v 1.47 2006/06/27 02:51:39 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -411,17 +411,8 @@ PersistHoldablePortal(Portal portal) for (store_pos = 0; store_pos < portal->portalPos; store_pos++) { - HeapTuple tup; - bool should_free; - - tup = tuplestore_gettuple(portal->holdStore, true, - &should_free); - - if (tup == NULL) + if (!tuplestore_advance(portal->holdStore, true)) elog(ERROR, "unexpected end of tuple stream"); - - if (should_free) - pfree(tup); } } } -- cgit v1.2.1