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

More quick descriptors


diffs (57 lines):

diff --git a/sql/storage/bat/bat_storage.c b/sql/storage/bat/bat_storage.c
--- a/sql/storage/bat/bat_storage.c
+++ b/sql/storage/bat/bat_storage.c
@@ -973,11 +973,10 @@ cs_real_update_bats( column_storage *cs,
                        return LOG_ERR;
        }
        if (!cs->uvbid) {
-               BAT *cur = temp_descriptor(cs->bid);
+               BAT *cur = quick_descriptor(cs->bid);
                if (!cur)
                        return LOG_ERR;
                int type = cur->ttype;
-               bat_destroy(cur);
                cs->uvbid = e_bat(type);
                if (cs->uibid == BID_NIL || cs->uvbid == BID_NIL)
                        return LOG_ERR;
@@ -2184,12 +2183,7 @@ log_create_delta(sql_trans *tr, sql_delt
 static int
 new_persistent_delta( sql_delta *bat)
 {
-       BAT *b = temp_descriptor(bat->cs.bid);
-
-       if (b == NULL)
-               return LOG_ERR;
        bat->cs.ucnt = 0;
-       bat_destroy(b);
        return LOG_OK;
 }
 
@@ -2210,11 +2204,10 @@ copyBat (bat i, int type, oid seq)
 
        if (!i)
                return i;
-       tb = temp_descriptor(i);
+       tb = quick_descriptor(i);
        if (tb == NULL)
                return 0;
        b = BATconstant(seq, type, ATOMnilptr(type), BATcount(tb), PERSISTENT);
-       bat_destroy(tb);
        if (b == NULL)
                return 0;
 
@@ -2849,13 +2842,12 @@ clear_cs(sql_trans *tr, column_storage *
 
        (void)tr;
        if (cs->bid && renew) {
-               b = temp_descriptor(cs->bid);
+               b = quick_descriptor(cs->bid);
                if (b) {
                        sz += BATcount(b);
                        bat bid = cs->bid;
                        cs->bid = temp_copy(bid, true, temp); /* create empty 
copy */
                        temp_destroy(bid);
-                       bat_destroy(b);
                }
        }
        if (cs->uibid) {
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to