• Michael A. Goulet's avatar
    Fix unnecessary pinning in `btreefile.LeafPage` · 21aed89e
    Michael A. Goulet authored and Michael A. Goulet's avatar Michael A. Goulet committed
    We pin an underlying page N times too many whenever we instantiate a new
    LeafPage class, due to the constructor of the BTreeFilePageTuple. What we
    want is a tuple that acts like a _weak_ reference to the underlying
    page, and only make it a _strong_ reference whenever this tuple escapes
    the scope of the btree-internal classes (e.g. in `BTreeFile.addTuple`).
    
    Right now, I just add an `unpin()` call in the constructor of the Tuple,
    and then pin it whenever I know that it escapes the scope of the btree
    package. Maybe there's a more graceful way of doing it. I have no idea.
    21aed89e
MaterializeNode.java 4.46 KB