bruc(at)stone(dot)congenomics(dot)com (Robert E. Bruccoleri) writes:
> For my immediate problem, would removing the spinlock acquisition
> be OK?
It'd be interesting to remove the marked lines:
bufHdr = &BufferDescriptors[buffer - 1];
- SpinAcquire(BufMgrLock);
if (bufHdr->tag.blockNum == blockNumber &&
RelFileNodeEquals(bufHdr->tag.rnode, relation->rd_node))
{
- SpinRelease(BufMgrLock);
return buffer;
}
- return ReadBufferWithBufferLock(relation, blockNumber, true);
and see how that affects your performance issue, if at all.
regards, tom lane