Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
Postgres FD Implementation
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Abuhujair Javed
Postgres FD Implementation
Commits
b0327159
Commit
b0327159
authored
Apr 03, 2008
by
Tom Lane
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove heap_release_fetch, which is no longer used anywhere; this simplifies
heap_fetch a little.
parent
d3bf8c70
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
33 deletions
+4
-33
src/backend/access/heap/heapam.c
src/backend/access/heap/heapam.c
+3
-29
src/include/access/heapam.h
src/include/access/heapam.h
+1
-4
No files found.
src/backend/access/heap/heapam.c
View file @
b0327159
...
@@ -8,7 +8,7 @@
...
@@ -8,7 +8,7 @@
*
*
*
*
* IDENTIFICATION
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/access/heap/heapam.c,v 1.25
4 2008/03/26 21:10:37 alvherre
Exp $
* $PostgreSQL: pgsql/src/backend/access/heap/heapam.c,v 1.25
5 2008/04/03 17:12:27 tgl
Exp $
*
*
*
*
* INTERFACE ROUTINES
* INTERFACE ROUTINES
...
@@ -1334,30 +1334,6 @@ heap_fetch(Relation relation,
...
@@ -1334,30 +1334,6 @@ heap_fetch(Relation relation,
Buffer
*
userbuf
,
Buffer
*
userbuf
,
bool
keep_buf
,
bool
keep_buf
,
Relation
stats_relation
)
Relation
stats_relation
)
{
/* Assume *userbuf is undefined on entry */
*
userbuf
=
InvalidBuffer
;
return
heap_release_fetch
(
relation
,
snapshot
,
tuple
,
userbuf
,
keep_buf
,
stats_relation
);
}
/*
* heap_release_fetch - retrieve tuple with given tid
*
* This has the same API as heap_fetch except that if *userbuf is not
* InvalidBuffer on entry, that buffer will be released before reading
* the new page. This saves a separate ReleaseBuffer step and hence
* one entry into the bufmgr when looping through multiple fetches.
* Also, if *userbuf is the same buffer that holds the target tuple,
* we avoid bufmgr manipulation altogether.
*/
bool
heap_release_fetch
(
Relation
relation
,
Snapshot
snapshot
,
HeapTuple
tuple
,
Buffer
*
userbuf
,
bool
keep_buf
,
Relation
stats_relation
)
{
{
ItemPointer
tid
=
&
(
tuple
->
t_self
);
ItemPointer
tid
=
&
(
tuple
->
t_self
);
ItemId
lp
;
ItemId
lp
;
...
@@ -1367,11 +1343,9 @@ heap_release_fetch(Relation relation,
...
@@ -1367,11 +1343,9 @@ heap_release_fetch(Relation relation,
bool
valid
;
bool
valid
;
/*
/*
* get the buffer from the relation descriptor. Note that this does a
* Fetch and pin the appropriate page of the relation.
* buffer pin, and releases the old *userbuf if not InvalidBuffer.
*/
*/
buffer
=
ReleaseAndReadBuffer
(
*
userbuf
,
relation
,
buffer
=
ReadBuffer
(
relation
,
ItemPointerGetBlockNumber
(
tid
));
ItemPointerGetBlockNumber
(
tid
));
/*
/*
* Need share lock on buffer to examine tuple commit status.
* Need share lock on buffer to examine tuple commit status.
...
...
src/include/access/heapam.h
View file @
b0327159
...
@@ -7,7 +7,7 @@
...
@@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2008, PostgreSQL Global Development Group
* Portions Copyright (c) 1996-2008, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
* Portions Copyright (c) 1994, Regents of the University of California
*
*
* $PostgreSQL: pgsql/src/include/access/heapam.h,v 1.13
2 2008/03/26 21:10:39 alvherre
Exp $
* $PostgreSQL: pgsql/src/include/access/heapam.h,v 1.13
3 2008/04/03 17:12:27 tgl
Exp $
*
*
*-------------------------------------------------------------------------
*-------------------------------------------------------------------------
*/
*/
...
@@ -153,9 +153,6 @@ extern HeapTuple heap_getnext(HeapScanDesc scan, ScanDirection direction);
...
@@ -153,9 +153,6 @@ extern HeapTuple heap_getnext(HeapScanDesc scan, ScanDirection direction);
extern
bool
heap_fetch
(
Relation
relation
,
Snapshot
snapshot
,
extern
bool
heap_fetch
(
Relation
relation
,
Snapshot
snapshot
,
HeapTuple
tuple
,
Buffer
*
userbuf
,
bool
keep_buf
,
HeapTuple
tuple
,
Buffer
*
userbuf
,
bool
keep_buf
,
Relation
stats_relation
);
Relation
stats_relation
);
extern
bool
heap_release_fetch
(
Relation
relation
,
Snapshot
snapshot
,
HeapTuple
tuple
,
Buffer
*
userbuf
,
bool
keep_buf
,
Relation
stats_relation
);
extern
bool
heap_hot_search_buffer
(
ItemPointer
tid
,
Buffer
buffer
,
extern
bool
heap_hot_search_buffer
(
ItemPointer
tid
,
Buffer
buffer
,
Snapshot
snapshot
,
bool
*
all_dead
);
Snapshot
snapshot
,
bool
*
all_dead
);
extern
bool
heap_hot_search
(
ItemPointer
tid
,
Relation
relation
,
extern
bool
heap_hot_search
(
ItemPointer
tid
,
Relation
relation
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment