mirror of
https://github.com/postgres/postgres.git
synced 2025-07-31 22:04:40 +03:00
First phase of memory management rewrite (see backend/utils/mmgr/README
for details). It doesn't really do that much yet, since there are no short-term memory contexts in the executor, but the infrastructure is in place and long-term contexts are handled reasonably. A few long- standing bugs have been fixed, such as 'VACUUM; anything' in a single query string crashing. Also, out-of-memory is now considered a recoverable ERROR, not FATAL. Eliminate a large amount of crufty, now-dead code in and around memory management. Fix problem with holding off SIGTRAP, SIGSEGV, etc in postmaster and backend startup.
This commit is contained in:
8
src/backend/utils/cache/temprel.c
vendored
8
src/backend/utils/cache/temprel.c
vendored
@ -8,7 +8,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/utils/cache/Attic/temprel.c,v 1.24 2000/06/20 06:41:12 tgl Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/utils/cache/Attic/temprel.c,v 1.25 2000/06/28 03:32:25 tgl Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -67,7 +67,7 @@ create_temp_relation(const char *relname, HeapTuple pg_class_tuple)
|
||||
MemoryContext oldcxt;
|
||||
TempTable *temp_rel;
|
||||
|
||||
oldcxt = MemoryContextSwitchTo((MemoryContext) CacheCxt);
|
||||
oldcxt = MemoryContextSwitchTo(CacheMemoryContext);
|
||||
|
||||
temp_rel = (TempTable *) palloc(sizeof(TempTable));
|
||||
temp_rel->user_relname = (char *) palloc(NAMEDATALEN);
|
||||
@ -135,7 +135,7 @@ remove_temp_relation(Oid relid)
|
||||
List *l,
|
||||
*prev;
|
||||
|
||||
oldcxt = MemoryContextSwitchTo((MemoryContext) CacheCxt);
|
||||
oldcxt = MemoryContextSwitchTo(CacheMemoryContext);
|
||||
|
||||
prev = NIL;
|
||||
l = temp_rels;
|
||||
@ -185,7 +185,7 @@ invalidate_temp_relations(void)
|
||||
List *l,
|
||||
*prev;
|
||||
|
||||
oldcxt = MemoryContextSwitchTo((MemoryContext) CacheCxt);
|
||||
oldcxt = MemoryContextSwitchTo(CacheMemoryContext);
|
||||
|
||||
prev = NIL;
|
||||
l = temp_rels;
|
||||
|
Reference in New Issue
Block a user