diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2009-03-13 17:46:21 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2009-03-13 17:46:21 +0000 |
commit | d287c9eff0ba6e42f457ac71b07001f6e3ec3c90 (patch) | |
tree | abf44dd393d0d32f3444566e70b3fa82a875bfe7 /src/backend/storage/buffer/bufmgr.c | |
parent | 2dd9af8c0c1eafedd340ed6fce0cd76d54820649 (diff) | |
download | postgresql-d287c9eff0ba6e42f457ac71b07001f6e3ec3c90.tar.gz postgresql-d287c9eff0ba6e42f457ac71b07001f6e3ec3c90.zip |
Restore previous ordering of BUFFER_FLUSH_START probe. I had wanted to
make it include the time for the possible smgropen() call, but that
results in a null pointer dereference :-(.
An alternative solution would be to fetch the buffer tag instead of
looking at *reln, but I'll just put it back as it was for the moment.
BTW, this indicates that DTrace probes evaluate their arguments even
when nominally inactive. What was that about "zero cost", again?
Diffstat (limited to 'src/backend/storage/buffer/bufmgr.c')
-rw-r--r-- | src/backend/storage/buffer/bufmgr.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/backend/storage/buffer/bufmgr.c b/src/backend/storage/buffer/bufmgr.c index 2c93ad523ab..59e61decc01 100644 --- a/src/backend/storage/buffer/bufmgr.c +++ b/src/backend/storage/buffer/bufmgr.c @@ -8,7 +8,7 @@ * * * IDENTIFICATION - * $PostgreSQL: pgsql/src/backend/storage/buffer/bufmgr.c,v 1.246 2009/03/11 23:19:25 tgl Exp $ + * $PostgreSQL: pgsql/src/backend/storage/buffer/bufmgr.c,v 1.247 2009/03/13 17:46:21 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -1861,14 +1861,14 @@ FlushBuffer(volatile BufferDesc *buf, SMgrRelation reln) errcontext.previous = error_context_stack; error_context_stack = &errcontext; - TRACE_POSTGRESQL_BUFFER_FLUSH_START(reln->smgr_rnode.spcNode, - reln->smgr_rnode.dbNode, - reln->smgr_rnode.relNode); - /* Find smgr relation for buffer */ if (reln == NULL) reln = smgropen(buf->tag.rnode); + TRACE_POSTGRESQL_BUFFER_FLUSH_START(reln->smgr_rnode.spcNode, + reln->smgr_rnode.dbNode, + reln->smgr_rnode.relNode); + /* * Force XLOG flush up to buffer's LSN. This implements the basic WAL * rule that log updates must hit disk before any of the data-file changes |