summaryrefslogtreecommitdiff
path: root/src/backend/utils/adt/oracle_compat.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2007-09-21 17:36:53 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2007-09-21 17:36:53 +0000
commitda072ab2ab538bf1811abe5a1df131c0c9a8e6e4 (patch)
tree664ebca17e65551f70cc0dce22fedc2aa9094849 /src/backend/utils/adt/oracle_compat.c
parentbd0af827da5f5c648cb7530bb7157a24d8bd7a07 (diff)
Make some simple performance improvements in TransactionIdIsInProgress().
For XIDs of our own transaction and subtransactions, it's cheaper to ask TransactionIdIsCurrentTransactionId() than to look in shared memory. Also, the xids[] work array is always the same size within any given process, so malloc it just once instead of doing a palloc/pfree on every call; aside from being faster this lets us get rid of some goto's, since we no longer have any end-of-function pfree to do. Both ideas by Heikki.
Diffstat (limited to 'src/backend/utils/adt/oracle_compat.c')
0 files changed, 0 insertions, 0 deletions