1. 29 Sep, 2001 1 commit
    • Tom Lane's avatar
      Implement new 'lightweight lock manager' that's intermediate between · 499abb0c
      Tom Lane authored
      existing lock manager and spinlocks: it understands exclusive vs shared
      lock but has few other fancy features.  Replace most uses of spinlocks
      with lightweight locks.  All remaining uses of spinlocks have very short
      lock hold times (a few dozen instructions), so tweak spinlock backoff
      code to work efficiently given this assumption.  All per my proposal on
      pghackers 26-Sep-01.
      499abb0c
  2. 06 Jul, 2001 1 commit
  3. 22 Mar, 2001 1 commit
  4. 24 Jan, 2001 1 commit
  5. 18 Dec, 2000 1 commit
  6. 30 Nov, 2000 1 commit
    • Tom Lane's avatar
      Rearrange bufmgr header files so that buf_internals.h need not be · 680b7357
      Tom Lane authored
      included by everything that includes bufmgr.h --- it's supposed to be
      internals, after all, not part of the API!  This fixes the conflict
      against FreeBSD headers reported by Rosenman, by making it unnecessary
      for s_lock.h to be included by plperl.c.
      680b7357
  7. 28 Nov, 2000 1 commit
    • Tom Lane's avatar
      Significant cleanups in SysV IPC handling (shared mem and semaphores). · c715fdea
      Tom Lane authored
      IPC key assignment will now work correctly even when multiple postmasters
      are using same logical port number (which is possible given -k switch).
      There is only one shared-mem segment per postmaster now, not 3.
      Rip out broken code for non-TAS case in bufmgr and xlog, substitute a
      complete S_LOCK emulation using semaphores in spin.c.  TAS and non-TAS
      logic is now exactly the same.
      When deadlock is detected, "Deadlock detected" is now the elog(ERROR)
      message, rather than a NOTICE that comes out before an unhelpful ERROR.
      c715fdea
  8. 23 Oct, 2000 1 commit
  9. 18 Oct, 2000 1 commit
  10. 31 May, 2000 1 commit
    • Peter Eisentraut's avatar
      The heralded `Grand Unified Configuration scheme' (GUC) · 6a68f426
      Peter Eisentraut authored
      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)
      6a68f426
  11. 12 Apr, 2000 1 commit
  12. 09 Apr, 2000 1 commit
    • Tom Lane's avatar
      Buffer manager modifications to keep a local buffer-dirtied bit as well · 1f6d8b90
      Tom Lane authored
      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.
      1f6d8b90
  13. 26 Jan, 2000 1 commit
    • Bruce Momjian's avatar
      Add: · 5c25d602
      Bruce Momjian authored
        * Portions Copyright (c) 1996-2000, PostgreSQL, Inc
      
      to all files copyright Regents of Berkeley.  Man, that's a lot of files.
      5c25d602
  14. 06 Oct, 1999 1 commit
  15. 24 Sep, 1999 1 commit
    • Tom Lane's avatar
      Several changes here, not very related but touching some of the same files. · e812458b
      Tom Lane authored
      * Buffer refcount cleanup (per my "progress report" to pghackers, 9/22).
      * Add links to backend PROC structs to sinval's array of per-backend info,
      and use these links for routines that need to check the state of all
      backends (rather than the slow, complicated search of the ShmemIndex
      hashtable that was used before).  Add databaseOID to PROC structs.
      * Use this to implement an interlock that prevents DESTROY DATABASE of
      a database containing running backends.  (It's a little tricky to prevent
      a concurrently-starting backend from getting in there, since the new
      backend is not able to lock anything at the time it tries to look up
      its database in pg_database.  My solution is to recheck that the DB is
      OK at the end of InitPostgres.  It may not be a 100% solution, but it's
      a lot better than no interlock at all...)
      * In ALTER TABLE RENAME, flush buffers for the relation before doing the
      rename of the physical files, to ensure we don't get failures later from
      mdblindwrt().
      * Update TRUNCATE patch so that it actually compiles against current
      sources :-(.
      You should do "make clean all" after pulling these changes.
      e812458b
  16. 17 Jul, 1999 2 commits
  17. 16 Jul, 1999 2 commits
  18. 26 Jun, 1999 1 commit
  19. 12 Jun, 1999 1 commit
  20. 25 May, 1999 1 commit
  21. 22 Feb, 1999 1 commit
  22. 13 Feb, 1999 1 commit
  23. 15 Dec, 1998 1 commit
  24. 01 Sep, 1998 1 commit
  25. 27 Jun, 1998 1 commit
  26. 07 Jan, 1998 1 commit
  27. 05 Jan, 1998 1 commit
  28. 02 Nov, 1997 1 commit
  29. 18 Sep, 1997 2 commits
  30. 08 Sep, 1997 1 commit
  31. 07 Sep, 1997 1 commit
  32. 28 Jul, 1997 1 commit
  33. 18 Apr, 1997 1 commit
  34. 28 Mar, 1997 1 commit
    • Marc G. Fournier's avatar
      From: Dan McGuirk <mcguirk@indirect.com> · 159f8c63
      Marc G. Fournier authored
      Reply-To: hackers@hub.org, Dan McGuirk <mcguirk@indirect.com>
      To: hackers@hub.org
      Subject: [HACKERS] tmin writeback optimization
      
      I was doing some profiling of the backend, and noticed that during a certain
      benchmark I was running somewhere between 30% and 75% of the backend's CPU
      time was being spent in calls to TransactionIdDidCommit() from
      HeapTupleSatisfiesNow() or HeapTupleSatisfiesItself() to determine that
      changed rows' transactions had in fact been committed even though the rows'
      tmin values had not yet been set.
      
      When a query looks at a given row, it needs to figure out whether the
      transaction that changed the row has been committed and hence it should pay
      attention to the row, or whether on the other hand the transaction is still
      in progress or has been aborted and hence the row should be ignored.  If
      a tmin value is set, it is known definitively that the row's transaction
      has been committed.  However, if tmin is not set, the transaction
      referred to in xmin must be looked up in pg_log, and this is what the
      backend was spending a lot of time doing during my benchmark.
      
      So, implementing a method suggested by Vadim, I created the following
      patch that, the first time a query finds a committed row whose tmin value
      is not set, sets it, and marks the buffer where the row is stored as
      dirty.  (It works for tmax, too.)  This doesn't result in the boost in
      real time performance I was hoping for, however it does decrease backend
      CPU usage by up to two-thirds in certain situations, so it could be
      rather beneficial in high-concurrency settings.
      159f8c63
  35. 26 Jan, 1997 1 commit
  36. 25 Jan, 1997 1 commit
  37. 23 Jan, 1997 1 commit