From 4e9512bec21be73e1b3b38edcb0fa23202099536 Mon Sep 17 00:00:00 2001 From: Eric Voskuil Date: Sun, 19 Jul 2026 20:03:02 -0400 Subject: [PATCH] Adapt to database ins/pont table consolidation. --- console/executor_dumps.cpp | 6 +-- console/executor_scans.cpp | 4 +- console/executor_test_reader.cpp | 2 +- console/localize.hpp | 66 ++++++++++++++++---------------- src/parser.cpp | 31 ++++----------- 5 files changed, 45 insertions(+), 64 deletions(-) diff --git a/console/executor_dumps.cpp b/console/executor_dumps.cpp index 2fc84b02..635ea76c 100644 --- a/console/executor_dumps.cpp +++ b/console/executor_dumps.cpp @@ -94,7 +94,6 @@ void executor::dump_body_sizes() const query_.header_body_size() % query_.txs_body_size() % query_.tx_body_size() % - query_.point_body_size() % query_.input_body_size() % query_.output_body_size() % query_.ins_body_size() % @@ -120,7 +119,6 @@ void executor::dump_records() const logger(format(BS_INFORMATION_RECORDS) % query_.header_records() % query_.tx_records() % - query_.point_records() % query_.ins_records() % query_.outs_records() % query_.candidate_records() % @@ -141,7 +139,7 @@ void executor::dump_buckets() const query_.header_buckets() % query_.txs_buckets() % query_.tx_buckets() % - query_.point_buckets() % + query_.ins_buckets() % query_.prevout_buckets() % query_.duplicate_buckets() % query_.strong_tx_buckets() % @@ -157,7 +155,7 @@ void executor::dump_collisions() const logger(format(BS_INFORMATION_COLLISION_RATES) % (to_double(query_.header_records()) / query_.header_buckets()) % (to_double(query_.tx_records()) / query_.tx_buckets()) % - (to_double(query_.point_records()) / query_.point_buckets()) % + (to_double(query_.ins_records()) / query_.ins_buckets()) % (to_double(query_.strong_tx_records()) / query_.strong_tx_buckets()) % (to_double(query_.tx_records()) / query_.validated_tx_buckets()) % (query_.address_enabled() ? (to_double(query_.address_records()) / diff --git a/console/executor_scans.cpp b/console/executor_scans.cpp index 7d733771..0a29a9ca 100644 --- a/console/executor_scans.cpp +++ b/console/executor_scans.cpp @@ -160,7 +160,7 @@ void executor::scan_buckets() const filled = zero; bucket = max_size_t; start = logger::now(); - while (!canceled() && (++bucket < query_.point_buckets())) + while (!canceled() && (++bucket < query_.ins_buckets())) { const auto top = query_.top_point(bucket); if (!top.is_terminal()) @@ -326,7 +326,7 @@ void executor::scan_collisions() const index = max_size_t; start = logger::now(); - const auto point_buckets = query_.point_buckets(); + const auto point_buckets = query_.ins_buckets(); std_vector spend(point_buckets, empty); auto inserts = zero; diff --git a/console/executor_test_reader.cpp b/console/executor_test_reader.cpp index 379a09c7..d95c6e92 100644 --- a/console/executor_test_reader.cpp +++ b/console/executor_test_reader.cpp @@ -195,7 +195,7 @@ void executor::read_test(const hash_digest&) const return; } - point_link pt_fk{}; + ins_link pt_fk{}; input_link in_fk{}; tx_link pt_tx_fk{}; diff --git a/console/localize.hpp b/console/localize.hpp index 5d191292..ba65a262 100644 --- a/console/localize.hpp +++ b/console/localize.hpp @@ -78,42 +78,40 @@ " header :%1%\n" \ " txs :%2%\n" \ " tx :%3%\n" \ - " point :%4%\n" \ - " input :%5%\n" \ - " output :%6%\n" \ - " ins :%7%\n" \ - " outs :%8%\n" \ - " candidate :%9%\n" \ - " confirmed :%10%\n" \ - " ecdsa :%11%\n" \ - " schnorr :%12%\n" \ - " silent :%13%\n" \ - " prevalid :%14%\n" \ - " prevout :%15%\n" \ - " duplicate :%16%\n" \ - " strong_tx :%17%\n" \ - " valid_bk :%18%\n" \ - " valid_tx :%19%\n" \ - " filter_bk :%20%\n" \ - " filter_tx :%21%\n" \ - " address :%22%" + " input :%4%\n" \ + " output :%5%\n" \ + " ins :%6%\n" \ + " outs :%7%\n" \ + " candidate :%8%\n" \ + " confirmed :%9%\n" \ + " ecdsa :%10%\n" \ + " schnorr :%11%\n" \ + " silent :%12%\n" \ + " prevalid :%13%\n" \ + " prevout :%14%\n" \ + " duplicate :%15%\n" \ + " strong_tx :%16%\n" \ + " valid_bk :%17%\n" \ + " valid_tx :%18%\n" \ + " filter_bk :%19%\n" \ + " filter_tx :%20%\n" \ + " address :%21%" #define BS_INFORMATION_RECORDS \ "Table records...\n" \ " header :%1%\n" \ " tx :%2%\n" \ - " point :%3%\n" \ - " ins :%4%\n" \ - " outs :%5%\n" \ - " candidate :%6%\n" \ - " confirmed :%7%\n" \ - " ecdsa :%8%\n" \ - " schnorr :%9%\n" \ - " silent :%10%\n" \ - " prevalid :%11%\n" \ - " duplicate :%12%\n" \ - " strong_tx :%13%\n" \ - " filter_bk :%14%\n" \ - " address :%15%" + " ins :%3%\n" \ + " outs :%4%\n" \ + " candidate :%5%\n" \ + " confirmed :%6%\n" \ + " ecdsa :%7%\n" \ + " schnorr :%8%\n" \ + " silent :%9%\n" \ + " prevalid :%10%\n" \ + " duplicate :%11%\n" \ + " strong_tx :%12%\n" \ + " filter_bk :%13%\n" \ + " address :%14%" #define BS_INFORMATION_SLABS \ "Table slabs..." #define BS_INFORMATION_SLABS_ROW \ @@ -127,7 +125,7 @@ " header :%1%\n" \ " txs :%2%\n" \ " tx :%3%\n" \ - " point :%4%\n" \ + " ins :%4%\n" \ " prevout :%5%\n" \ " duplicate :%6%\n" \ " strong_tx :%7%\n" \ @@ -140,7 +138,7 @@ "Collision rates...\n" \ " header :%1%\n" \ " tx :%2%\n" \ - " point :%3%\n" \ + " ins :%3%\n" \ " strong_tx :%4%\n" \ " valid_tx :%5%\n" \ " address :%6%" diff --git a/src/parser.cpp b/src/parser.cpp index 1216e7c2..1e06b6f7 100644 --- a/src/parser.cpp +++ b/src/parser.cpp @@ -109,12 +109,9 @@ parser::parser(system::chain::selection context, configured.database.output_size = 25'300'000'000; configured.database.output_rate = 5; - // point table set to 2.2LF @ ~900k. - configured.database.point_buckets = 1'365'977'136; - configured.database.point_size = 25'700'000'000; - configured.database.point_rate = 5; - - configured.database.ins_size = 8'550'000'000; + // ins table set to 2.2LF @ ~900k. + configured.database.ins_buckets = 1'365'977'136; + configured.database.ins_size = 34'250'000'000; configured.database.ins_rate = 5; configured.database.outs_size = 3'700'000'000; @@ -1489,28 +1486,16 @@ options_metadata parser::load_settings() THROWS "The percentage expansion of the archive_output table body, defaults to '5'." ) - /* point */ - ( - "database.point_buckets", - value(&configured.database.point_buckets), - "The number of buckets in the archive_point table head, defaults to '1365977136'." - ) - ( - "database.point_size", - value(&configured.database.point_size), - "The minimum allocation of the archive_point table body, defaults to '25700000000'." - ) + /* ins */ ( - "database.point_rate", - value(&configured.database.point_rate), - "The percentage expansion of the archive_point table body, defaults to '5'." + "database.ins_buckets", + value(&configured.database.ins_buckets), + "The number of buckets in the archive_ins table head, defaults to '1365977136'." ) - - /* ins */ ( "database.ins_size", value(&configured.database.ins_size), - "The minimum allocation of the archive_ins table body, defaults to '8550000000'." + "The minimum allocation of the archive_ins table body, defaults to '34250000000'." ) ( "database.ins_rate",