diff options
author | unknown <monty@mishka.local> | 2004-04-26 15:53:31 +0300 |
---|---|---|
committer | unknown <monty@mishka.local> | 2004-04-26 15:53:31 +0300 |
commit | 1065f2bbd66ac4b1161f5c188171a54cbad5b422 (patch) | |
tree | 25e3315af05fa92d20d2ad1d812882957c400337 /innobase/row/row0purge.c | |
parent | 0ba6cb48d84f1ff951d09871a96be6cdef3f2c3c (diff) | |
parent | 6366a9090c7fc24f0e13b5b9d73d6777dcda9d9e (diff) | |
download | mariadb-git-1065f2bbd66ac4b1161f5c188171a54cbad5b422.tar.gz |
Merge with 4.0
innobase/dict/dict0boot.c:
Auto merged
innobase/dict/dict0load.c:
Auto merged
innobase/dict/dict0mem.c:
Auto merged
innobase/fut/fut0lst.c:
Auto merged
innobase/include/buf0lru.h:
Auto merged
innobase/include/dict0mem.h:
Auto merged
innobase/include/fsp0fsp.h:
Auto merged
innobase/include/ha0ha.h:
Auto merged
innobase/include/ibuf0ibuf.h:
Auto merged
innobase/include/lock0lock.h:
Auto merged
innobase/include/log0log.h:
Auto merged
innobase/include/mem0pool.h:
Auto merged
innobase/include/mtr0mtr.h:
Auto merged
innobase/include/os0file.h:
Auto merged
innobase/include/rem0rec.h:
Auto merged
innobase/include/rem0rec.ic:
Auto merged
innobase/include/srv0srv.h:
Auto merged
innobase/include/sync0sync.h:
Auto merged
innobase/include/trx0sys.h:
Auto merged
innobase/include/ut0byte.h:
Auto merged
innobase/include/ut0ut.h:
Auto merged
innobase/mem/mem0pool.c:
Auto merged
innobase/mtr/mtr0mtr.c:
Auto merged
innobase/os/os0proc.c:
Auto merged
innobase/pars/lexyy.c:
Auto merged
innobase/pars/pars0opt.c:
Auto merged
innobase/row/row0ins.c:
Auto merged
innobase/row/row0purge.c:
Auto merged
innobase/row/row0uins.c:
Auto merged
innobase/row/row0umod.c:
Auto merged
innobase/row/row0undo.c:
Auto merged
innobase/row/row0upd.c:
Auto merged
innobase/trx/trx0purge.c:
Auto merged
innobase/trx/trx0roll.c:
Auto merged
innobase/trx/trx0sys.c:
Auto merged
innobase/trx/trx0undo.c:
Auto merged
innobase/ut/ut0byte.c:
Auto merged
pstack/bucomm.h:
Auto merged
pstack/budbg.h:
Auto merged
sql/item_sum.h:
Auto merged
sql/slave.cc:
Auto merged
sql/sql_db.cc:
Auto merged
support-files/mysql.spec.sh:
Auto merged
tests/insert_test.c:
Auto merged
mysql-test/t/func_group.test:
Merge with 4.0
Put 4.1 tests lasts
sql/ha_innodb.cc:
Merge with 4.0
Added checking of results from my_malloc()
BitKeeper/etc/logging_ok:
Logging to logging@openlogging.org accepted
Diffstat (limited to 'innobase/row/row0purge.c')
-rw-r--r-- | innobase/row/row0purge.c | 48 |
1 files changed, 18 insertions, 30 deletions
diff --git a/innobase/row/row0purge.c b/innobase/row/row0purge.c index a409b64f8e4..8f5f0831dc6 100644 --- a/innobase/row/row0purge.c +++ b/innobase/row/row0purge.c @@ -91,7 +91,6 @@ row_purge_remove_clust_if_poss_low( /* out: TRUE if success, or if not found, or if modified after the delete marking */ purge_node_t* node, /* in: row purge node */ - que_thr_t* thr, /* in: query thread */ ulint mode) /* in: BTR_MODIFY_LEAF or BTR_MODIFY_TREE */ { dict_index_t* index; @@ -101,8 +100,6 @@ row_purge_remove_clust_if_poss_low( ulint err; mtr_t mtr; - UT_NOT_USED(thr); - index = dict_table_get_first_index(node->table); pcur = &(node->pcur); @@ -156,23 +153,20 @@ static void row_purge_remove_clust_if_poss( /*===========================*/ - purge_node_t* node, /* in: row purge node */ - que_thr_t* thr) /* in: query thread */ + purge_node_t* node) /* in: row purge node */ { ibool success; ulint n_tries = 0; -/* printf("Purge: Removing clustered record\n"); */ +/* fputs("Purge: Removing clustered record\n", stderr); */ - success = row_purge_remove_clust_if_poss_low(node, thr, - BTR_MODIFY_LEAF); + success = row_purge_remove_clust_if_poss_low(node, BTR_MODIFY_LEAF); if (success) { return; } retry: - success = row_purge_remove_clust_if_poss_low(node, thr, - BTR_MODIFY_TREE); + success = row_purge_remove_clust_if_poss_low(node, BTR_MODIFY_TREE); /* The delete operation may fail if we have little file space left: TODO: easiest to crash the database and restart with more file space */ @@ -196,7 +190,6 @@ row_purge_remove_sec_if_poss_low( /*=============================*/ /* out: TRUE if success or if not found */ purge_node_t* node, /* in: row purge node */ - que_thr_t* thr, /* in: query thread */ dict_index_t* index, /* in: index */ dtuple_t* entry, /* in: index entry */ ulint mode) /* in: latch mode BTR_MODIFY_LEAF or @@ -211,8 +204,6 @@ row_purge_remove_sec_if_poss_low( mtr_t mtr; mtr_t* mtr_vers; - UT_NOT_USED(thr); - log_free_check(); mtr_start(&mtr); @@ -221,7 +212,7 @@ row_purge_remove_sec_if_poss_low( if (!found) { /* Not found */ - /* printf("PURGE:........sec entry not found\n"); */ + /* fputs("PURGE:........sec entry not found\n", stderr); */ /* dtuple_print(entry); */ btr_pcur_close(&pcur); @@ -284,23 +275,22 @@ void row_purge_remove_sec_if_poss( /*=========================*/ purge_node_t* node, /* in: row purge node */ - que_thr_t* thr, /* in: query thread */ dict_index_t* index, /* in: index */ dtuple_t* entry) /* in: index entry */ { ibool success; ulint n_tries = 0; -/* printf("Purge: Removing secondary record\n"); */ +/* fputs("Purge: Removing secondary record\n", stderr); */ - success = row_purge_remove_sec_if_poss_low(node, thr, index, entry, + success = row_purge_remove_sec_if_poss_low(node, index, entry, BTR_MODIFY_LEAF); if (success) { return; } retry: - success = row_purge_remove_sec_if_poss_low(node, thr, index, entry, + success = row_purge_remove_sec_if_poss_low(node, index, entry, BTR_MODIFY_TREE); /* The delete operation may fail if we have little file space left: TODO: easiest to crash the database @@ -324,14 +314,13 @@ static void row_purge_del_mark( /*===============*/ - purge_node_t* node, /* in: row purge node */ - que_thr_t* thr) /* in: query thread */ + purge_node_t* node) /* in: row purge node */ { mem_heap_t* heap; dtuple_t* entry; dict_index_t* index; - ut_ad(node && thr); + ut_ad(node); heap = mem_heap_create(1024); @@ -341,14 +330,14 @@ row_purge_del_mark( /* Build the index entry */ entry = row_build_index_entry(node->row, index, heap); - row_purge_remove_sec_if_poss(node, thr, index, entry); + row_purge_remove_sec_if_poss(node, index, entry); node->index = dict_table_get_next_index(node->index); } mem_heap_free(heap); - row_purge_remove_clust_if_poss(node, thr); + row_purge_remove_clust_if_poss(node); } /*************************************************************** @@ -358,8 +347,7 @@ static void row_purge_upd_exist_or_extern( /*==========================*/ - purge_node_t* node, /* in: row purge node */ - que_thr_t* thr) /* in: query thread */ + purge_node_t* node) /* in: row purge node */ { mem_heap_t* heap; dtuple_t* entry; @@ -375,7 +363,7 @@ row_purge_upd_exist_or_extern( ulint i; mtr_t mtr; - ut_ad(node && thr); + ut_ad(node); if (node->rec_type == TRX_UNDO_UPD_DEL_REC) { @@ -392,7 +380,7 @@ row_purge_upd_exist_or_extern( /* Build the older version of the index entry */ entry = row_build_index_entry(node->row, index, heap); - row_purge_remove_sec_if_poss(node, thr, index, entry); + row_purge_remove_sec_if_poss(node, index, entry); } node->index = dict_table_get_next_index(node->index); @@ -519,7 +507,7 @@ row_purge_parse_undo_rec( mutex_enter(&(dict_sys->mutex)); - node->table = dict_table_get_on_id_low(table_id, thr_get_trx(thr)); + node->table = dict_table_get_on_id_low(table_id, trx); mutex_exit(&(dict_sys->mutex)); @@ -619,12 +607,12 @@ row_purge( dict_table_get_first_index(node->table)); if (node->rec_type == TRX_UNDO_DEL_MARK_REC) { - row_purge_del_mark(node, thr); + row_purge_del_mark(node); } else if (updated_extern || node->rec_type == TRX_UNDO_UPD_EXIST_REC) { - row_purge_upd_exist_or_extern(node, thr); + row_purge_upd_exist_or_extern(node); } if (node->found_clust) { |