@@ -1490,7 +1490,6 @@ rec_t *btr_root_raise_and_insert(
14901490 ulint **offsets, /* !< out: offsets on inserted record */
14911491 mem_heap_t **heap, /* !< in/out: pointer to memory heap, or NULL */
14921492 const dtuple_t *tuple, /* !< in: tuple to insert */
1493- ulint n_ext, /* !< in: number of externally stored columns */
14941493 mtr_t *mtr) /* !< in: mtr */
14951494{
14961495 dict_index_t *index;
@@ -1630,8 +1629,8 @@ rec_t *btr_root_raise_and_insert(
16301629
16311630 page_cur_set_before_first (root_block, page_cursor);
16321631
1633- node_ptr_rec = page_cur_tuple_insert (page_cursor, node_ptr, index, offsets,
1634- heap, 0 , mtr);
1632+ node_ptr_rec =
1633+ page_cur_tuple_insert (page_cursor, node_ptr, index, offsets, heap , mtr);
16351634
16361635 /* The root page should only contain the node pointer
16371636 to new_page at this point. Thus, the data should fit. */
@@ -1649,11 +1648,11 @@ rec_t *btr_root_raise_and_insert(
16491648 /* Split the child and insert tuple */
16501649 if (dict_index_is_spatial (index)) {
16511650 /* Split rtree page and insert tuple */
1652- return (rtr_page_split_and_insert (flags, cursor, offsets, heap, tuple,
1653- n_ext , mtr));
1651+ return (
1652+ rtr_page_split_and_insert (flags, cursor, offsets, heap, tuple , mtr));
16541653 } else {
1655- return (btr_page_split_and_insert (flags, cursor, offsets, heap, tuple,
1656- n_ext , mtr));
1654+ return (
1655+ btr_page_split_and_insert (flags, cursor, offsets, heap, tuple , mtr));
16571656 }
16581657}
16591658
@@ -1753,8 +1752,7 @@ ibool btr_page_get_split_rec_to_right(
17531752 the lower or upper half-page (determined by btr_page_tuple_smaller()) */
17541753static rec_t *btr_page_get_split_rec (
17551754 btr_cur_t *cursor, /* !< in: cursor at which insert should be made */
1756- const dtuple_t *tuple, /* !< in: tuple to insert */
1757- ulint n_ext) /* !< in: number of externally stored columns */
1755+ const dtuple_t *tuple) /* !< in: tuple to insert */
17581756{
17591757 page_t *page;
17601758 page_zip_des_t *page_zip;
@@ -1773,7 +1771,7 @@ static rec_t *btr_page_get_split_rec(
17731771
17741772 page = btr_cur_get_page (cursor);
17751773
1776- insert_size = rec_get_converted_size (cursor->index , tuple, n_ext );
1774+ insert_size = rec_get_converted_size (cursor->index , tuple);
17771775 free_space = page_get_free_space_of_empty (page_is_comp (page));
17781776
17791777 page_zip = btr_cur_get_page_zip (cursor);
@@ -1871,7 +1869,6 @@ static MY_ATTRIBUTE((warn_unused_result)) bool btr_page_insert_fits(
18711869 ulint **offsets, /* !< in: rec_get_offsets(
18721870 split_rec, cursor->index); out: garbage */
18731871 const dtuple_t *tuple, /* !< in: tuple to insert */
1874- ulint n_ext, /* !< in: number of externally stored columns */
18751872 mem_heap_t **heap) /* !< in: temporary memory heap */
18761873{
18771874 page_t *page;
@@ -1887,7 +1884,7 @@ static MY_ATTRIBUTE((warn_unused_result)) bool btr_page_insert_fits(
18871884 ut_ad (!split_rec || !page_is_comp (page) == !rec_offs_comp (*offsets));
18881885 ut_ad (!split_rec || rec_offs_validate (split_rec, cursor->index , *offsets));
18891886
1890- insert_size = rec_get_converted_size (cursor->index , tuple, n_ext );
1887+ insert_size = rec_get_converted_size (cursor->index , tuple);
18911888 free_space = page_get_free_space_of_empty (page_is_comp (page));
18921889
18931890 /* free_space is now the free space of a created new page */
@@ -1989,12 +1986,12 @@ void btr_insert_on_non_leaf_level_func(
19891986
19901987 err = btr_cur_optimistic_insert (
19911988 flags | BTR_NO_LOCKING_FLAG | BTR_KEEP_SYS_FLAG | BTR_NO_UNDO_LOG_FLAG,
1992- &cursor, &offsets, &heap, tuple, &rec, &dummy_big_rec, 0 , NULL , mtr);
1989+ &cursor, &offsets, &heap, tuple, &rec, &dummy_big_rec, NULL , mtr);
19931990
19941991 if (err == DB_FAIL) {
19951992 err = btr_cur_pessimistic_insert (
19961993 flags | BTR_NO_LOCKING_FLAG | BTR_KEEP_SYS_FLAG | BTR_NO_UNDO_LOG_FLAG,
1997- &cursor, &offsets, &heap, tuple, &rec, &dummy_big_rec, 0 , NULL , mtr);
1994+ &cursor, &offsets, &heap, tuple, &rec, &dummy_big_rec, NULL , mtr);
19981995 ut_a (err == DB_SUCCESS);
19991996 }
20001997
@@ -2181,15 +2178,13 @@ of a page.
21812178@param[out] offsets offsets on inserted record
21822179@param[in,out] heap memory heap for allocating offsets
21832180@param[in] tuple tuple to insert
2184- @param[in] n_ext number of externally stored columns
21852181@param[in,out] mtr mini-transaction
21862182@return inserted record (first record on the right sibling page);
21872183 the cursor will be positioned on the page infimum
21882184@retval NULL if the operation was not performed */
21892185static rec_t *btr_insert_into_right_sibling (uint32_t flags, btr_cur_t *cursor,
21902186 ulint **offsets, mem_heap_t *heap,
2191- const dtuple_t *tuple, ulint n_ext,
2192- mtr_t *mtr) {
2187+ const dtuple_t *tuple, mtr_t *mtr) {
21932188 buf_block_t *block = btr_cur_get_block (cursor);
21942189 page_t *page = buf_block_get_frame (block);
21952190 page_no_t next_page_no = btr_page_get_next (page, mtr);
@@ -2234,7 +2229,7 @@ static rec_t *btr_insert_into_right_sibling(uint32_t flags, btr_cur_t *cursor,
22342229 }
22352230
22362231 rec = page_cur_tuple_insert (&next_page_cursor, tuple, cursor->index , offsets,
2237- &heap, n_ext, mtr);
2232+ &heap, mtr);
22382233
22392234 if (rec == NULL ) {
22402235 if (is_leaf && next_block->page .size .is_compressed () &&
@@ -2307,7 +2302,6 @@ rec_t *btr_page_split_and_insert(
23072302 ulint **offsets, /* !< out: offsets on inserted record */
23082303 mem_heap_t **heap, /* !< in/out: pointer to memory heap, or NULL */
23092304 const dtuple_t *tuple, /* !< in: tuple to insert */
2310- ulint n_ext, /* !< in: number of externally stored columns */
23112305 mtr_t *mtr) /* !< in: mtr */
23122306{
23132307 buf_block_t *block;
@@ -2338,8 +2332,8 @@ rec_t *btr_page_split_and_insert(
23382332
23392333 if (dict_index_is_spatial (index)) {
23402334 /* Split rtree page and update parent */
2341- return (rtr_page_split_and_insert (flags, cursor, offsets, heap, tuple,
2342- n_ext , mtr));
2335+ return (
2336+ rtr_page_split_and_insert (flags, cursor, offsets, heap, tuple , mtr));
23432337 }
23442338
23452339 if (!*heap) {
@@ -2369,8 +2363,8 @@ rec_t *btr_page_split_and_insert(
23692363 ut_ad (!page_is_empty (page));
23702364
23712365 /* try to insert to the next page if possible before split */
2372- rec = btr_insert_into_right_sibling (flags, cursor, offsets, *heap, tuple,
2373- n_ext , mtr);
2366+ rec =
2367+ btr_insert_into_right_sibling (flags, cursor, offsets, *heap, tuple , mtr);
23742368
23752369 if (rec != NULL ) {
23762370 return (rec);
@@ -2386,7 +2380,7 @@ rec_t *btr_page_split_and_insert(
23862380 if (n_iterations > 0 ) {
23872381 direction = FSP_UP;
23882382 hint_page_no = page_no + 1 ;
2389- split_rec = btr_page_get_split_rec (cursor, tuple, n_ext );
2383+ split_rec = btr_page_get_split_rec (cursor, tuple);
23902384
23912385 if (split_rec == NULL ) {
23922386 insert_left =
@@ -2454,10 +2448,10 @@ rec_t *btr_page_split_and_insert(
24542448 insert_empty:
24552449 ut_ad (!split_rec);
24562450 ut_ad (!insert_left);
2457- buf = UT_NEW_ARRAY_NOKEY (
2458- byte, rec_get_converted_size (cursor->index , tuple, n_ext ));
2451+ buf =
2452+ UT_NEW_ARRAY_NOKEY ( byte, rec_get_converted_size (cursor->index , tuple));
24592453
2460- first_rec = rec_convert_dtuple_to_rec (buf, cursor->index , tuple, n_ext );
2454+ first_rec = rec_convert_dtuple_to_rec (buf, cursor->index , tuple);
24612455 move_limit = page_rec_get_next (btr_cur_get_rec (cursor));
24622456 }
24632457
@@ -2474,16 +2468,15 @@ rec_t *btr_page_split_and_insert(
24742468 if (split_rec) {
24752469 insert_will_fit =
24762470 !new_page_zip &&
2477- btr_page_insert_fits (cursor, split_rec, offsets, tuple, n_ext, heap);
2471+ btr_page_insert_fits (cursor, split_rec, offsets, tuple, heap);
24782472 } else {
24792473 if (!insert_left) {
24802474 UT_DELETE_ARRAY (buf);
24812475 buf = NULL ;
24822476 }
24832477
2484- insert_will_fit =
2485- !new_page_zip &&
2486- btr_page_insert_fits (cursor, NULL , offsets, tuple, n_ext, heap);
2478+ insert_will_fit = !new_page_zip &&
2479+ btr_page_insert_fits (cursor, NULL , offsets, tuple, heap);
24872480 }
24882481
24892482 if (!srv_read_only_mode && !cursor->index ->table ->is_intrinsic () &&
@@ -2608,7 +2601,7 @@ rec_t *btr_page_split_and_insert(
26082601 page_cur_search (insert_block, cursor->index , tuple, page_cursor);
26092602
26102603 rec = page_cur_tuple_insert (page_cursor, tuple, cursor->index , offsets, heap,
2611- n_ext, mtr);
2604+ mtr);
26122605
26132606#ifdef UNIV_ZIP_DEBUG
26142607 {
@@ -2635,7 +2628,7 @@ rec_t *btr_page_split_and_insert(
26352628 }
26362629
26372630 rec = page_cur_tuple_insert (page_cursor, tuple, cursor->index , offsets, heap,
2638- n_ext, mtr);
2631+ mtr);
26392632
26402633 if (rec == NULL ) {
26412634 /* The insert did not fit on the page: loop back to the
0 commit comments