1. 01 4月, 2019 2 次提交
  2. 03 8月, 2018 1 次提交
  3. 02 8月, 2018 1 次提交
    • R
      Merge with PostgreSQL 9.2beta2. · 4750e1b6
      Richard Guo 提交于
      This is the final batch of commits from PostgreSQL 9.2 development,
      up to the point where the REL9_2_STABLE branch was created, and 9.3
      development started on the PostgreSQL master branch.
      
      Notable upstream changes:
      
      * Index-only scan was included in the batch of upstream commits. It
        allows queries to retrieve data only from indexes, avoiding heap access.
      
      * Group commit was added to work effectively under heavy load. Previously,
        batching of commits became ineffective as the write workload increased,
        because of internal lock contention.
      
      * A new fast-path lock mechanism was added to reduce the overhead of
        taking and releasing certain types of locks which are taken and released
        very frequently but rarely conflict.
      
      * The new "parameterized path" mechanism was added. It allows inner index
        scans to use values from relations that are more than one join level up
        from the scan. This can greatly improve performance in situations where
        semantic restrictions (such as outer joins) limit the allowed join orderings.
      
      * SP-GiST (Space-Partitioned GiST) index access method was added to support
        unbalanced partitioned search structures. For suitable problems, SP-GiST can
        be faster than GiST in both index build time and search time.
      
      * Checkpoints now are performed by a dedicated background process. Formerly
        the background writer did both dirty-page writing and checkpointing. Separating
        this into two processes allows each goal to be accomplished more predictably.
      
      * Custom plan was supported for specific parameter values even when using
        prepared statements.
      
      * API for FDW was improved to provide multiple access "paths" for their tables,
        allowing more flexibility in join planning.
      
      * Security_barrier option was added for views to prevents optimizations that
        might allow view-protected data to be exposed to users.
      
      * Range data type was added to store a lower and upper bound belonging to its
        base data type.
      
      * CTAS (CREATE TABLE AS/SELECT INTO) is now treated as utility statement. The
        SELECT query is planned during the execution of the utility. To conform to
        this change, GPDB executes the utility statement only on QD and dispatches
        the plan of the SELECT query to QEs.
      Co-authored-by: NAdam Lee <ali@pivotal.io>
      Co-authored-by: NAlexandra Wang <lewang@pivotal.io>
      Co-authored-by: NAshwin Agrawal <aagrawal@pivotal.io>
      Co-authored-by: NAsim R P <apraveen@pivotal.io>
      Co-authored-by: NDaniel Gustafsson <dgustafsson@pivotal.io>
      Co-authored-by: NGang Xiong <gxiong@pivotal.io>
      Co-authored-by: NHaozhou Wang <hawang@pivotal.io>
      Co-authored-by: NHeikki Linnakangas <hlinnakangas@pivotal.io>
      Co-authored-by: NJesse Zhang <sbjesse@gmail.com>
      Co-authored-by: NJinbao Chen <jinchen@pivotal.io>
      Co-authored-by: NJoao Pereira <jdealmeidapereira@pivotal.io>
      Co-authored-by: NMelanie Plageman <mplageman@pivotal.io>
      Co-authored-by: NPaul Guo <paulguo@gmail.com>
      Co-authored-by: NRichard Guo <guofenglinux@gmail.com>
      Co-authored-by: NShujie Zhang <shzhang@pivotal.io>
      Co-authored-by: NTaylor Vesely <tvesely@pivotal.io>
      Co-authored-by: NZhenghua Lyu <zlv@pivotal.io>
      4750e1b6
  4. 06 2月, 2017 1 次提交
  5. 28 10月, 2015 1 次提交
  6. 26 8月, 2014 1 次提交
  7. 29 5月, 2014 2 次提交
    • T
      Revert "Fix bogus %name-prefix option syntax in all our Bison files." · 71ed8b3c
      Tom Lane 提交于
      This reverts commit 45b7abe5.
      
      It turns out that the %name-prefix syntax without "=" does not work
      at all in pre-2.4 Bison.  We are not prepared to make such a large
      jump in minimum required Bison version just to suppress a warning
      message in a version hardly any developers are using yet.
      When 3.0 gets more popular, we'll figure out a way to deal with this.
      In the meantime, BISONFLAGS=-Wno-deprecated is recommendable for
      anyone using 3.0 who doesn't want to see the warning.
      71ed8b3c
    • T
      Fix bogus %name-prefix option syntax in all our Bison files. · 45b7abe5
      Tom Lane 提交于
      %name-prefix doesn't use an "=" sign according to the Bison docs, but it
      silently accepted one anyway, until Bison 3.0.  This was originally a
      typo of mine in commit 012abeba, and we
      seem to have slavishly copied the error into all the other grammar files.
      
      Per report from Vik Fearing; analysis by Peter Eisentraut.
      
      Back-patch to all active branches, since somebody might try to build
      a back branch with up-to-date tools.
      45b7abe5
  8. 18 4月, 2014 1 次提交
    • P
      Create function prototype as part of PG_FUNCTION_INFO_V1 macro · e7128e8d
      Peter Eisentraut 提交于
      Because of gcc -Wmissing-prototypes, all functions in dynamically
      loadable modules must have a separate prototype declaration.  This is
      meant to detect global functions that are not declared in header files,
      but in cases where the function is called via dfmgr, this is redundant.
      Besides filling up space with boilerplate, this is a frequent source of
      compiler warnings in extension modules.
      
      We can fix that by creating the function prototype as part of the
      PG_FUNCTION_INFO_V1 macro, which such modules have to use anyway.  That
      makes the code of modules cleaner, because there is one less place where
      the entry points have to be listed, and creates an additional check that
      functions have the right prototype.
      
      Remove now redundant prototypes from contrib and other modules.
      e7128e8d
  9. 29 7月, 2013 1 次提交
    • T
      Fix contrib/cube and contrib/seg to build with bison 3.0. · 55cbfa53
      Tom Lane 提交于
      These modules used the YYPARSE_PARAM macro, which has been deprecated
      by the bison folk since 1.875, and which they finally removed in 3.0.
      Adjust the code to use the replacement facility, %parse-param, which
      is a much better solution anyway since it allows specification of the
      type of the extra parser parameter.  We can thus get rid of a lot of
      unsightly casting.
      
      Back-patch to all active branches, since somebody might try to build
      a back branch with up-to-date tools.
      55cbfa53
  10. 12 2月, 2013 1 次提交
  11. 14 1月, 2013 1 次提交
    • T
      Improve handling of ereport(ERROR) and elog(ERROR). · b853eb97
      Tom Lane 提交于
      In commit 71450d7f, we added code to inform
      suitably-intelligent compilers that ereport() doesn't return if the elevel
      is ERROR or higher.  This patch extends that to elog(), and also fixes a
      double-evaluation hazard that the previous commit created in ereport(),
      as well as reducing the emitted code size.
      
      The elog() improvement requires the compiler to support __VA_ARGS__, which
      should be available in just about anything nowadays since it's required by
      C99.  But our minimum language baseline is still C89, so add a configure
      test for that.
      
      The previous commit assumed that ereport's elevel could be evaluated twice,
      which isn't terribly safe --- there are already counterexamples in xlog.c.
      On compilers that have __builtin_constant_p, we can use that to protect the
      second test, since there's no possible optimization gain if the compiler
      doesn't know the value of elevel.  Otherwise, use a local variable inside
      the macros to prevent double evaluation.  The local-variable solution is
      inferior because (a) it leads to useless code being emitted when elevel
      isn't constant, and (b) it increases the optimization level needed for the
      compiler to recognize that subsequent code is unreachable.  But it seems
      better than not teaching non-gcc compilers about unreachability at all.
      
      Lastly, if the compiler has __builtin_unreachable(), we can use that
      instead of abort(), resulting in a noticeable code savings since no
      function call is actually emitted.  However, it seems wise to do this only
      in non-assert builds.  In an assert build, continue to use abort(), so that
      the behavior will be predictable and debuggable if the "impossible"
      happens.
      
      These changes involve making the ereport and elog macros emit do-while
      statement blocks not just expressions, which forces small changes in
      a few call sites.
      
      Andres Freund, Tom Lane, Heikki Linnakangas
      b853eb97
  12. 11 10月, 2012 1 次提交
    • P
      Refactor flex and bison make rules · 8521d131
      Peter Eisentraut 提交于
      Numerous flex and bison make rules have appeared in the source tree
      over time, and they are all virtually identical, so we can replace
      them by pattern rules with some variables for customization.
      
      Users of pgxs will also be able to benefit from this.
      8521d131
  13. 05 7月, 2012 1 次提交
  14. 02 11月, 2011 1 次提交
  15. 13 10月, 2011 1 次提交
    • T
      Throw a useful error message if an extension script file is fed to psql. · 458857cc
      Tom Lane 提交于
      We have seen one too many reports of people trying to use 9.1 extension
      files in the old-fashioned way of sourcing them in psql.  Not only does
      that usually not work (due to failure to substitute for MODULE_PATHNAME
      and/or @extschema@), but if it did work they'd get a collection of loose
      objects not an extension.  To prevent this, insert an \echo ... \quit
      line that prints a suitable error message into each extension script file,
      and teach commands/extension.c to ignore lines starting with \echo.
      That should not only prevent any adverse consequences of loading a script
      file the wrong way, but make it crystal clear to users that they need to
      do it differently now.
      
      Tom Lane, following an idea of Andrew Dunstan's.  Back-patch into 9.1
      ... there is not going to be much value in this if we wait till 9.2.
      458857cc
  16. 01 9月, 2011 1 次提交
  17. 26 8月, 2011 1 次提交
  18. 19 5月, 2011 2 次提交
  19. 26 4月, 2011 1 次提交
    • P
      Support "make check" in contrib · f8ebe3bc
      Peter Eisentraut 提交于
      Added a new option --extra-install to pg_regress to arrange installing
      the respective contrib directory into the temporary installation.
      This is currently not yet supported for Windows MSVC builds.
      
      Updated the .gitignore files for contrib modules to ignore the
      leftovers of a temp-install check run.
      
      Changed the exit status of "make check" in a pgxs build (which still
      does nothing) to 0 from 1.
      
      Added "make check" in contrib to top-level "make check-world".
      f8ebe3bc
  20. 12 4月, 2011 1 次提交
  21. 10 4月, 2011 1 次提交
  22. 14 2月, 2011 2 次提交
    • T
      Avoid use of CREATE OR REPLACE FUNCTION in extension installation files. · 029fac22
      Tom Lane 提交于
      It was never terribly consistent to use OR REPLACE (because of the lack of
      comparable functionality for data types, operators, etc), and
      experimentation shows that it's now positively pernicious in the extension
      world.  We really want a failure to occur if there are any conflicts, else
      it's unclear what the extension-ownership state of the conflicted object
      ought to be.  Most of the time, CREATE EXTENSION will fail anyway because
      of conflicts on other object types, but an extension defining only
      functions can succeed, with bad results.
      029fac22
    • T
      Convert contrib modules to use the extension facility. · 629b3af2
      Tom Lane 提交于
      This isn't fully tested as yet, in particular I'm not sure that the
      "foo--unpackaged--1.0.sql" scripts are OK.  But it's time to get some
      buildfarm cycles on it.
      
      sepgsql is not converted to an extension, mainly because it seems to
      require a very nonstandard installation process.
      
      Dimitri Fontaine and Tom Lane
      629b3af2
  23. 16 12月, 2010 2 次提交
    • T
      Fix contrib/seg's GiST picksplit method. · 2a6ebe70
      Tom Lane 提交于
      This patch replaces Guttman's generalized split method with a simple
      sort-by-center-points algorithm.  Since the data is only one-dimensional
      we don't really need the slow and none-too-stable Guttman method.
      
      This is in part a bug fix, since seg has the same size_alpha versus
      size_beta typo that was recently fixed in contrib/cube.  It seems
      prudent to apply this rather aggressive fix only in HEAD, though.
      Back branches will just get the typo fix.
      
      Alexander Korotkov, reviewed by Yeb Havinga
      2a6ebe70
    • T
      Fix contrib/seg's GiST picksplit method. · 04a1f093
      Tom Lane 提交于
      Fix the same size_alpha versus size_beta typo that was recently fixed
      in contrib/cube.  Noted by Alexander Korotkov.
      
      Back-patch to all supported branches (there is a more invasive fix in
      HEAD).
      04a1f093
  24. 24 11月, 2010 1 次提交
  25. 23 9月, 2010 2 次提交
  26. 22 9月, 2010 2 次提交
  27. 21 9月, 2010 1 次提交
  28. 29 8月, 2009 1 次提交
  29. 12 6月, 2009 1 次提交
  30. 11 6月, 2009 1 次提交
  31. 26 11月, 2008 1 次提交
  32. 03 9月, 2008 1 次提交
  33. 02 9月, 2008 1 次提交