Changeset: 5b5ae6436336 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/5b5ae6436336
Modified Files:
        sql/storage/bat/res_table.c
Branch: Jul2021
Log Message:

keep small result sets cached (ie in memory until end of query)


diffs (20 lines):

diff --git a/sql/storage/bat/res_table.c b/sql/storage/bat/res_table.c
--- a/sql/storage/bat/res_table.c
+++ b/sql/storage/bat/res_table.c
@@ -105,6 +105,7 @@ res_col_create(sql_trans *tr, res_table 
                        t->nr_rows = 1;
                        BBPkeepref(t->order);
                }
+               cached = true; /* simply keep memory pointer for this small bat 
*/
        }
        c->b = b->batCacheid;
        c->cached = cached;
@@ -112,8 +113,6 @@ res_col_create(sql_trans *tr, res_table 
                c->p = (void*)b;
        else
                bat_incref(c->b);
-       if (mtype != TYPE_bat)
-               BBPunfix(c->b);
        t->cur_col++;
        assert(t->cur_col <= t->nr_cols);
        return c;
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to