summaryrefslogtreecommitdiff
path: root/src/backend/access
AgeCommit message (Collapse)Author
2000-06-19Clean up bogosities in pg_opclass, pg_amop, pg_amproc. There are amprocTom Lane
entries now for int8 and network hash indexes. int24_ops and int42_ops are gone. pg_opclass no longer contains multiple entries claiming to be the default opclass for the same datatype. opr_sanity regress test extended to catch errors like these in the future.
2000-06-18Reimplement nodeMaterial to use a temporary BufFile (or even memory, if theTom Lane
materialized tupleset is small enough) instead of a temporary relation. This was something I was thinking of doing anyway for performance, and Jan says he needs it for TOAST because he doesn't want to cope with toasting noname relations. With this change, the 'noname table' support in heap.c is dead code, and I have accordingly removed it. Also clean up 'noname' plan handling in planner --- nonames are either sort or materialize plans, and it seems less confusing to handle them separately under those names.
2000-06-17Get rid of IndexIsUniqueNoCache() kluge by the simple expedient ofTom Lane
passing the index-is-unique flag to index build routines (duh! ... why wasn't it done this way to begin with?). Aside from eliminating an eyesore, this should save a few milliseconds in btree index creation because a full scan of pg_index is not needed any more.
2000-06-15Final #include cleanup.Bruce Momjian
2000-06-15Clean up #include's.Bruce Momjian
2000-06-14I had overlooked the fact that some fmgr-callable functions return voidTom Lane
--- ie, they're only called for side-effects. Add a PG_RETURN_VOID() macro and use it where appropriate. This probably doesn't change the machine code by a single bit ... it's just for documentation.
2000-06-13Another batch of fmgr updates. I think I have gotten all old-styleTom Lane
functions that take pass-by-value datatypes. Should be ready for port testing ...
2000-06-09Another round of updates for new fmgr, mostly in the datetime code.Tom Lane
2000-06-08Mark functions as static and ifdef NOT_USED as appropriate.Bruce Momjian
2000-06-05Latest round of fmgr updates. All functions with bool,char, or int2Tom Lane
inputs have been converted to newstyle. This should go a long way towards fixing our portability problems with platforms where char and short parameters are passed differently from int-width parameters. Still more to do for the Alpha port however.
2000-06-02Remove NT-specific file open defines by defining our own open macros forBruce Momjian
"rb" and "wb".
2000-06-02heap' xlog recordsVadim B. Mikheev
2000-06-02Create an fd.c entry point that is just like plain open(2) except thatTom Lane
it will close VFDs if necessary to surmount ENFILE or EMFILE failures. Make use of this in md.c, xlog.c, and user.c routines that were formerly vulnerable to these failures. In particular, this should handle failures of mdblindwrt() that have been observed under heavy load conditions. (By golly, every other process on the system may crash after Postgres eats up all the kernel FDs, but Postgres will keep going!)
2000-05-31The heralded `Grand Unified Configuration scheme' (GUC)Peter Eisentraut
That means you can now set your options in either or all of $PGDATA/configuration, some postmaster option (--enable-fsync=off), or set a SET command. The list of options is in backend/utils/misc/guc.c, documentation will be written post haste. pg_options is gone, so is that pq_geqo config file. Also removed were backend -K, -Q, and -T options (no longer applicable, although -d0 does the same as -Q). Added to configure an --enable-syslog option. changed all callers from TPRINTF to elog(DEBUG)
2000-05-30Third round of fmgr updates: eliminate calls using fmgr() andTom Lane
fmgr_faddr() in favor of new-style calls. Lots of cleanup of sloppy casts to use XXXGetDatum and DatumGetXXX ...
2000-05-30Remove unused include files. Do not touch /port or includes used by defines.Bruce Momjian
2000-05-29Generated header files parse.h and fmgroids.h are now copied intoTom Lane
the src/include tree, so that -I backend is no longer necessary anywhere. Also, clean up some bit rot in contrib tree.
2000-05-28First round of changes for new fmgr interface. fmgr itself and theTom Lane
key call sites are changed, but most called functions are still oldstyle. An exception is that the PL managers are updated (so, for example, NULL handling now behaves as expected in plperl and plpgsql functions). NOTE initdb is forced due to added column in pg_proc.
2000-05-22CleanupBruce Momjian
2000-05-22I am attempting to integrate postgres (v 7.0) with an open sourceBruce Momjian
project I am working on (Recall - a distributed, fault-tolerant, replicated, storage framework @ http://www.fault-tolerant.org). Recall is written in C++. I need to include the postgres headers and there are some problems when including the headers w/C++. Attached is a patch generated from postgres/src that fixes my problems. I was hoping to get this into the main source. It's very small (2k) and 3 files are changed: backend/utils/fmgr/fmgr.c, backend/utils/Gen_fmgrtab.sh.in, and include/access/tupdesc.h. In C++, you get a multiply defined symbol because the variable (FmgrInfo *fmgr_pl_finfo) is defined in the header (the patch moves it to the .c file). The other problem in tupdesc.h is the use of typeid is a problem in c++ (I renamed it to oidtypeid). Thanks, Neal Norwitz
2000-05-21Repair memory leaks that caused CacheCxt to grow without bound. WeTom Lane
really ought to fix relcache entry construction so that it does not do so much with CurrentMemoryContext = CacheCxt. As is, relatively harmless leaks in either sequential or index scanning translate to permanent leaks if they occur when called from relcache build. For the moment, however, the path of least resistance is to repair all such leaks...
2000-04-12Ye-old pgindent run. Same 4-space tabs.Bruce Momjian
2000-04-09Buffer manager modifications to keep a local buffer-dirtied bit as wellTom Lane
as a shared dirtybit for each shared buffer. The shared dirtybit still controls writing the buffer, but the local bit controls whether we need to fsync the buffer's file. This arrangement fixes a bug that allowed some required fsyncs to be missed, and should improve performance as well. For more info see my post of same date on pghackers.
2000-03-31Get rid of SetBufferWriteMode(), which was an accident waiting to happen.Tom Lane
In the event of an elog() while the mode was set to immediate write, there was no way for it to be set back to the normal delayed write. The mechanism was a waste of space and cycles anyway, since the only user was varsup.c, which could perfectly well call FlushBuffer directly. Now it does just that, and the notion of a write mode is gone.
2000-03-20Turn XLOG off (do not create log file).Vadim B. Mikheev
2000-03-17Fix a bunch of minor portability problems and maybe-bugs revealed byTom Lane
running gcc and HP's cc with warnings cranked way up. Signed vs unsigned comparisons, routines declared static and then defined not-static, that kind of thing. Tedious, but perhaps useful...
2000-03-14Cache fmgr lookup data for index's getnext() function in IndexScanDesc,Tom Lane
so that the fmgr lookup only has to happen once per index scan and not once per tuple. Seems to save 5% or so of CPU time for an indexscan.
2000-03-07I've recently written to pgsql-ports about a problem with PG7.0 on NTBruce Momjian
(Subj: [PORTS] initdb problem on NT with 7.0). Since nobody helped me, I had to find out the reson. The difference between NT and Linux (for instance) is that "open( path, O_RDWR );" opens a file in text mode. So sometime less block can be read than required. I suggest a following patch. BTW the situation appeared before, see hba.c, pqcomm.c and others. Alexei Zakharov
2000-03-01Change reindex command to work properly with gist/hash/rtreeHiroshi Inoue
2000-02-21Clean up some really grotty coding in catcache.c, improve hashingTom Lane
performance in catcache lookups.
2000-02-18Implement reindex commandHiroshi Inoue
2000-02-18Replace inefficient _bt_invokestrat calls with direct calls to theTom Lane
appropriate btree three-way comparison routine. Not clear why the three-way comparison routines were being used in some paths and not others in btree --- incomplete changes by someone long ago, maybe? Anyway, this makes for a nice speedup in CREATE INDEX.
2000-02-15Fix up error and log messages.Thomas G. Lockhart
2000-02-10Add btree indexing of boolean valuesBruce Momjian
Don Baccus
2000-02-09Enable backward sequential scan even after reaching EOF.Hiroshi Inoue
2000-01-31Fix problems seen in parallel regress tests when SI buffer overruns (causingTom Lane
syscache and relcache flushes). Relcache entry rebuild now preserves original tupledesc, rewrite rules, and triggers if possible, so that pointers to these things remain valid --- if these things change while relcache entry has positive refcount, we elog(ERROR) to avoid later crash. Arrange for xact-local rels to be rebuilt when an SI inval message is seen for them, so that they are updated by CommandCounterIncrement the same as regular rels. (This is useful because of Hiroshi's recent changes to process our own SI messages at CommandCounterIncrement time.) This allows simplification of some routines that previously hacked around the lack of an automatic update. catcache now keeps its own copy of tupledesc for its relation, rather than depending on the relcache's copy; this avoids needing to reinitialize catcache during a cache flush, which saves some cycles and eliminates nasty circularity problems that occur if a cache flush happens while trying to initialize a catcache. Eliminate a number of permanent memory leaks that used to happen during catcache or relcache flush; not least of which was that catcache never freed any cached tuples! (Rule parsetree storage is still leaked, however; will fix that separately.) Nothing done yet about code that uses tuples retrieved by SearchSysCache for longer than is safe.
2000-01-29A few minor psql enhancementsPeter Eisentraut
Initdb help correction Changed end/abort to commit/rollback and changed related notices Commented out way old printing functions in libpq Fixed a typo in alter table / alter column
2000-01-28Patch from Hiroshi for overflow btree comparison.Bruce Momjian
2000-01-26Add:Bruce Momjian
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc to all files copyright Regents of Berkeley. Man, that's a lot of files.
2000-01-22Revise handling of index-type-specific indexscan cost estimation, perTom Lane
pghackers discussion of 5-Jan-2000. The amopselect and amopnpages estimators are gone, and in their place is a per-AM amcostestimate procedure (linked to from pg_am, not pg_amop).
2000-01-22added ALTER TABLE DROP COLUMN, early versionPeter Eisentraut
2000-01-20Added new pg_id to fix initdb problemsPeter Eisentraut
New INSTALL file Fixed a copyright notice
2000-01-19Fix handling of NULL constraint conditions: per SQL92 spec, a NULL resultTom Lane
from a constraint condition does not violate the constraint (cf. discussion on pghackers 12/9/99). Implemented by adding a parameter to ExecQual, specifying whether to return TRUE or FALSE when the qual result is really NULL in three-valued boolean logic. Currently, ExecRelCheck is the only caller that asks for TRUE, but if we find any other places that have the wrong response to NULL, it'll be easy to fix them.
2000-01-19Removed MBFLAGS from makefiles since it's now done in include/config.h.Peter Eisentraut
2000-01-17setheapoverride() is history. Uses replaced with CommandCounterIncrement()Tom Lane
where necessary --- several of them didn't really need it, though. tqual-checking macros simplified accordingly.
2000-01-15Fixed all elog related warnings, as well as a few others.Peter Eisentraut
2000-01-11More cleanups. Still doesn't work.Bruce Momjian
2000-01-10Make number of args to a function configurable.Bruce Momjian
2000-01-10Rename oid8 -> oidvector and int28 -> int2vector. Cleanup of *out functions.Bruce Momjian
2000-01-10Improve cache invalidation handling. EespeciallyHiroshi Inoue
this would fix TODO * elog() flushes cache, try invalidating just entries from current xact, perhaps using invalidation cache