From 906548202b2b4a2e91e82c3c99dbdf6535caf23c Mon Sep 17 00:00:00 2001 From: Emilia Hane Date: Thu, 22 Feb 2024 19:58:35 +0100 Subject: [PATCH] Fix merge conflicts --- .../net/network/src/transactions/constants.rs | 195 ++++++++++++------ .../net/network/src/transactions/fetcher.rs | 16 +- crates/net/network/src/transactions/mod.rs | 9 +- rustc-ice-2024-02-18T21_57_12-20464.txt | 61 ------ 4 files changed, 153 insertions(+), 128 deletions(-) delete mode 100644 rustc-ice-2024-02-18T21_57_12-20464.txt diff --git a/crates/net/network/src/transactions/constants.rs b/crates/net/network/src/transactions/constants.rs index 06457d67b903..47895ad8f353 100644 --- a/crates/net/network/src/transactions/constants.rs +++ b/crates/net/network/src/transactions/constants.rs @@ -2,56 +2,63 @@ /// Soft limit for the number of hashes in a /// [`NewPooledTransactionHashes`](reth_eth_wire::NewPooledTransactionHashes) broadcast message. +/// /// Spec'd at 4096 hashes. /// /// pub const SOFT_LIMIT_COUNT_HASHES_IN_NEW_POOLED_TRANSACTIONS_BROADCAST_MESSAGE: usize = 4096; /// Default soft limit for the byte size of a [`Transactions`](reth_eth_wire::Transactions) -/// broadcast message. Default is 128 KiB. +/// broadcast message. +/// +/// Default is 128 KiB. pub const DEFAULT_SOFT_LIMIT_BYTE_SIZE_TRANSACTIONS_BROADCAST_MESSAGE: usize = 128 * 1024; /* ================ REQUEST-RESPONSE ================ */ /// Recommended soft limit for the number of hashes in a -/// [`GetPooledTransactions`](reth_eth_wire::GetPooledTransactions) request. Spec'd at 256 hashes -/// (8 KiB). +/// [`GetPooledTransactions`](reth_eth_wire::GetPooledTransactions) request. +/// +/// Spec'd at 256 hashes (8 KiB). /// /// pub const SOFT_LIMIT_COUNT_HASHES_IN_GET_POOLED_TRANSACTIONS_REQUEST: usize = 256; /// Soft limit for the byte size of a [`PooledTransactions`](reth_eth_wire::PooledTransactions) /// response on assembling a [`GetPooledTransactions`](reth_eth_wire::GetPooledTransactions) -/// request. Spec'd at 2 MiB. +/// request. +/// +/// Spec'd at 2 MiB. /// /// . pub const SOFT_LIMIT_BYTE_SIZE_POOLED_TRANSACTIONS_RESPONSE: usize = 2 * 1024 * 1024; -/// Constants used by [`TransactionsManager`](crate::transactions::TransactionsManager). pub mod tx_manager { use super::SOFT_LIMIT_COUNT_HASHES_IN_NEW_POOLED_TRANSACTIONS_BROADCAST_MESSAGE; - /// Default limit for number of transactions to keep track of for a single peer, for - /// transactions that the peer's pool and local pool have in common. Default is 10 KiB. - pub const DEFAULT_CAPACITY_CACHE_SEEN_BY_PEER_AND_IN_POOL: usize = 10 * 1024; + /// Default limit for number of transactions to keep track of for a single peer. + /// + /// Default is 10 KiB. + pub const DEFAULT_CAPACITY_CACHE_SEEN_BY_PEER: usize = 10 * 1024; - /// Default limit for the number of transactions to keep track of for a single peer, for - /// transactions that are in the peer's pool but maybe not in the local pool yet. - pub const DEFAULT_CAPACITY_CACHE_SENT_BY_PEER_AND_MAYBE_IN_POOL: usize = 10 * 1024; - - /// Default maximum pending pool imports to tolerate. Default is equivalent to the number of - /// hashes in one full announcement, which is spec'd at 4096 hashes, so 4096 pending pool - /// imports. + /// Default maximum pending pool imports to tolerate. + /// + /// Default is equivalent to the number of hashes in one full announcement, which is spec'd at + /// 4096 hashes, so 4096 pending pool imports. pub const DEFAULT_MAX_COUNT_PENDING_POOL_IMPORTS: usize = SOFT_LIMIT_COUNT_HASHES_IN_NEW_POOLED_TRANSACTIONS_BROADCAST_MESSAGE; - /// Default limit for number of bad imports to keep track of. Default is 10 KiB. + /// Default limit for number of bad imports to keep track of. + /// + /// Default is 10 KiB. pub const DEFAULT_CAPACITY_CACHE_BAD_IMPORTS: usize = 100 * 1024; } -/// Constants used by [`TransactionFetcher`](crate::transactions::TransactionFetcher). pub mod tx_fetcher { - use crate::peers::{DEFAULT_MAX_COUNT_PEERS_INBOUND, DEFAULT_MAX_COUNT_PEERS_OUTBOUND}; + use crate::{ + peers::{DEFAULT_MAX_COUNT_PEERS_INBOUND, DEFAULT_MAX_COUNT_PEERS_OUTBOUND}, + transactions::fetcher::TransactionFetcherInfo, + }; use super::{ SOFT_LIMIT_BYTE_SIZE_POOLED_TRANSACTIONS_RESPONSE, @@ -65,35 +72,43 @@ pub mod tx_fetcher { /// [`PooledTransactions`](reth_eth_wire::PooledTransactions) response on assembling a /// [`GetPooledTransactions`](reth_eth_wire::PooledTransactions) request. This defaults to less /// than the [`SOFT_LIMIT_BYTE_SIZE_POOLED_TRANSACTIONS_RESPONSE`], at 2 MiB, used when - /// assembling a [`PooledTransactions`](reth_eth_wire::PooledTransactions) response. Default - /// is 128 KiB. - pub const DEFAULT_SOFT_LIMIT_BYTE_SIZE_POOLED_TRANSACTIONS_RESPONSE_ON_PACK_GET_POOLED_TRANSACTIONS_REQUEST: usize = 128 * 1024; + /// assembling a [`PooledTransactions`](reth_eth_wire::PooledTransactions) response. + /// + /// Default is 128 KiB. + pub const DEFAULT_SOFT_LIMIT_BYTE_SIZE_POOLED_TRANSACTIONS_RESP_ON_PACK_GET_POOLED_TRANSACTIONS_REQ: usize = 128 * 1024; /* ==================== RETRIES ==================== */ - /// Default maximum request retires per [`TxHash`](reth_primitives::TxHash). Note, this is reset - /// should the [`TxHash`](reth_primitives::TxHash) re-appear in an announcement after it has - /// been evicted from the hashes pending fetch cache, i.e. the counter is restarted. If this - /// happens, it is likely a very popular transaction, that should and can indeed be fetched - /// hence this behaviour is favourable. Default is 2 retries. + /// Default maximum request retires per [`TxHash`](reth_primitives::TxHash). Note, this is + /// reset should the [`TxHash`](reth_primitives::TxHash) re-appear in an announcement after it + /// has been evicted from the hashes pending fetch cache, i.e. the counter is restarted. If + /// this happens, it is likely a very popular transaction, that should and can indeed be + /// fetched hence this behaviour is favourable. + /// + /// Default is 2 retries. pub const DEFAULT_MAX_RETRIES: u8 = 2; /// Default number of alternative peers to keep track of for each transaction pending fetch. At /// most [`DEFAULT_MAX_RETRIES`], which defaults to 2 peers, can ever be needed per peer. - /// Default is the sum of [`DEFAULT_MAX_RETRIES`] and + /// + /// Default is the sum of [`DEFAULT_MAX_RETRIES`] an /// [`DEFAULT_MARGINAL_COUNT_FALLBACK_PEERS`], which defaults to 1 peer, so 3 peers. pub const DEFAULT_MAX_COUNT_FALLBACK_PEERS: u8 = DEFAULT_MAX_RETRIES + DEFAULT_MARGINAL_COUNT_FALLBACK_PEERS; /// Default marginal on fallback peers. This is the case, since a transaction is only requested - /// once from each individual peer. Default is 1 peer. - pub const DEFAULT_MARGINAL_COUNT_FALLBACK_PEERS: u8 = 1; + /// once from each individual peer. + /// + /// Default is 1 peer. + const DEFAULT_MARGINAL_COUNT_FALLBACK_PEERS: u8 = 1; /* ==================== CONCURRENCY ==================== */ /// Default maximum concurrent [`GetPooledTransactions`](reth_eth_wire::GetPooledTransactions) - /// requests. Default is the product of [`DEFAULT_MAX_COUNT_CONCURRENT_REQUESTS_PER_PEER`], - /// which defaults to 1 request, and the sum of [`DEFAULT_MAX_COUNT_PEERS_INBOUND`] and + /// requests. + /// + /// Default is the product of [`DEFAULT_MAX_COUNT_CONCURRENT_REQUESTS_PER_PEER`], which + /// defaults to 1 request, and the sum of [`DEFAULT_MAX_COUNT_PEERS_INBOUND`] and /// [`DEFAULT_MAX_COUNT_PEERS_OUTBOUND`], which default to 30 and 100 peers respectively, so /// 130 requests. pub const DEFAULT_MAX_COUNT_CONCURRENT_REQUESTS: u32 = @@ -101,36 +116,43 @@ pub mod tx_fetcher { /// Default maximum number of concurrent /// [`GetPooledTransactions`](reth_eth_wire::GetPooledTransactions)s to allow per peer. This - /// number reflects concurrent requests for different hashes. Default is 1 request. + /// number reflects concurrent requests for different hashes. + /// + /// Default is 1 request. pub const DEFAULT_MAX_COUNT_CONCURRENT_REQUESTS_PER_PEER: u8 = 1; /* =============== HASHES PENDING FETCH ================ */ /// Default limit for number of transactions waiting for an idle peer to be fetched from. + /// /// Default is 100 times the [`SOFT_LIMIT_COUNT_HASHES_IN_GET_POOLED_TRANSACTIONS_REQUEST`], /// which defaults to 256 hashes, so 25 600 hashes. pub const DEFAULT_MAX_CAPACITY_CACHE_PENDING_FETCH: usize = 100 * SOFT_LIMIT_COUNT_HASHES_IN_GET_POOLED_TRANSACTIONS_REQUEST; - /// Default maximum number of hashes pending fetch to tolerate at any time. Default is half of - /// [`DEFAULT_MAX_CAPACITY_CACHE_PENDING_FETCH`], which defaults to 25 600 hashes, so 12 800 - /// hashes. + /// Default maximum number of hashes pending fetch to tolerate at any time. + /// + /// Default is half of [`DEFAULT_MAX_CAPACITY_CACHE_PENDING_FETCH`], which defaults to 25 600 + /// hashes, so 12 800 hashes. pub const DEFAULT_MAX_COUNT_PENDING_FETCH: usize = DEFAULT_MAX_CAPACITY_CACHE_PENDING_FETCH / 2; /* ====== LIMITED CAPACITY ON FETCH PENDING HASHES ====== */ /// Default budget for finding an idle fallback peer for any hash pending fetch, when said - /// search is budget constrained. Default is a sixth of [`DEFAULT_MAX_COUNT_PENDING_FETCH`], - /// which defaults to 12 800 hashes (the breadth of the search), divided by - /// [`DEFAULT_MAX_COUNT_FALLBACK_PEERS`], which defaults to 3 peers (the depth of the search), - /// so the 711 lru hashes in the pending hashes cache. + /// search is budget constrained. + /// + /// Default is a sixth of [`DEFAULT_MAX_COUNT_PENDING_FETCH`], which defaults to 12 800 hashes + /// (the breadth of the search), divided by [`DEFAULT_MAX_COUNT_FALLBACK_PEERS`], which + /// defaults to 3 peers (the depth of the search), so the 711 lru hashes in the pending hashes + /// cache. pub const DEFAULT_BUDGET_FIND_IDLE_FALLBACK_PEER: usize = DEFAULT_MAX_COUNT_PENDING_FETCH / 6 / DEFAULT_MAX_COUNT_FALLBACK_PEERS as usize; /// Default budget for finding hashes in the intersection of transactions announced by a peer - /// and in the cache of hashes pending fetch, when said search is budget constrained. Default - /// is a sixth of [`DEFAULT_MAX_COUNT_PENDING_FETCH`], which defaults to 12 800 hashes (the - /// breadth of the search), so 2133 lru hashes in the pending hashes cache. + /// and in the cache of hashes pending fetch, when said search is budget constrained. + /// + /// Default is a sixth of [`DEFAULT_MAX_COUNT_PENDING_FETCH`], which defaults to 12 800 hashes + /// (the breadth of the search), so 2133 lru hashes in the pending hashes cache. pub const DEFAULT_BUDGET_FIND_INTERSECTION_ANNOUNCED_BY_PEER_AND_PENDING_FETCH: usize = DEFAULT_MAX_COUNT_PENDING_FETCH / 6; @@ -138,64 +160,109 @@ pub mod tx_fetcher { /// Default soft limit for the number of hashes in a /// [`GetPooledTransactions`](reth_eth_wire::GetPooledTransactions) request, when it is filled - /// from hashes pending fetch. Default is half of the - /// [`SOFT_LIMIT_COUNT_HASHES_IN_GET_POOLED_TRANSACTIONS_REQUEST`] which by spec is 256 - /// hashes, so 128 hashes. + /// from hashes pending fetch. + /// + /// Default is half of the [`SOFT_LIMIT_COUNT_HASHES_IN_GET_POOLED_TRANSACTIONS_REQUEST`] + /// which by spec is 256 hashes, so 128 hashes. pub const DEFAULT_SOFT_LIMIT_COUNT_HASHES_IN_GET_POOLED_TRANSACTIONS_REQUEST_ON_FETCH_PENDING_HASHES: usize = SOFT_LIMIT_COUNT_HASHES_IN_GET_POOLED_TRANSACTIONS_REQUEST / 2; /// Default soft limit for a [`PooledTransactions`](reth_eth_wire::PooledTransactions) response /// when it's used as expected response in calibrating the filling of a /// [`GetPooledTransactions`](reth_eth_wire::GetPooledTransactions) request, when the request - /// is filled from hashes pending fetch. Default is half of - /// [`DEFAULT_SOFT_LIMIT_BYTE_SIZE_POOLED_TRANSACTIONS_RESPONSE_ON_PACK_GET_POOLED_TRANSACTIONS_REQUEST`], + /// is filled from hashes pending fetch. + /// + /// Default is half of + /// [`DEFAULT_SOFT_LIMIT_BYTE_SIZE_POOLED_TRANSACTIONS_RESP_ON_PACK_GET_POOLED_TRANSACTIONS_REQ`], /// which defaults to 128 KiB, so 64 KiB. pub const DEFAULT_SOFT_LIMIT_BYTE_SIZE_POOLED_TRANSACTIONS_RESPONSE_ON_FETCH_PENDING_HASHES: - usize = DEFAULT_SOFT_LIMIT_BYTE_SIZE_POOLED_TRANSACTIONS_RESPONSE_ON_PACK_GET_POOLED_TRANSACTIONS_REQUEST / 2; - - /// Default max inflight request when fetching pending hashes. Default is half of - /// [`DEFAULT_MAX_COUNT_CONCURRENT_REQUESTS`], which defaults to 130 requests, so 65 requests. + usize = + DEFAULT_SOFT_LIMIT_BYTE_SIZE_POOLED_TRANSACTIONS_RESP_ON_PACK_GET_POOLED_TRANSACTIONS_REQ / + 2; + + /// Default max inflight request when fetching pending hashes. + /// + /// Default is half of [`DEFAULT_MAX_COUNT_CONCURRENT_REQUESTS`], which defaults to 130 + /// requests, so 65 requests. pub const DEFAULT_MAX_COUNT_INFLIGHT_REQUESTS_ON_FETCH_PENDING_HASHES: usize = DEFAULT_MAX_COUNT_CONCURRENT_REQUESTS as usize / 2; /// Default divisor of the max inflight request when calculating search breadth of the search /// for any idle peer to which to send a request filled with hashes pending fetch. The max - /// inflight requests is configured in - /// [`TransactionFetcherInfo`](crate::transactions::fetcher::TransactionFetcherInfo). Default - /// is 3 requests. + /// inflight requests is configured in [`TransactionFetcherInfo`]. + /// + /// Default is 3 requests. pub const DEFAULT_DIVISOR_MAX_COUNT_INFLIGHT_REQUESTS_ON_FIND_IDLE_PEER: usize = 3; /// Default divisor of the max inflight request when calculating search breadth of the search /// for the intersection of hashes announced by a peer and hashes pending fetch. The max - /// inflight requests is configured in - /// [`TransactionFetcherInfo`](crate::transactions::fetcher::TransactionFetcherInfo). Default - /// is 2 requests. + /// inflight requests is configured in [`TransactionFetcherInfo`]. + /// + /// Default is 2 requests. pub const DEFAULT_DIVISOR_MAX_COUNT_INFLIGHT_REQUESTS_ON_FIND_INTERSECTION: usize = 2; // Default divisor to the max pending pool imports when calculating search breadth of the /// search for any idle peer to which to send a request filled with hashes pending fetch. /// The max pending pool imports is configured in - /// [`PendingPoolImportsInfo`](crate::transactions::PendingPoolImportsInfo). Default - /// is 4 requests. + /// [`PendingPoolImportsInfo`](crate::transactions::PendingPoolImportsInfo). + /// + /// Default is 4 requests. pub const DEFAULT_DIVISOR_MAX_COUNT_PENDING_POOL_IMPORTS_ON_FIND_IDLE_PEER: usize = 4; /// Default divisor to the max pending pool imports when calculating search breadth of the /// search for any idle peer to which to send a request filled with hashes pending fetch. /// The max pending pool imports is configured in - /// [`PendingPoolImportsInfo`](crate::transactions::PendingPoolImportsInfo). Default - /// is 3 requests. + /// [`PendingPoolImportsInfo`](crate::transactions::PendingPoolImportsInfo). + /// + /// Default is 3 requests. pub const DEFAULT_DIVISOR_MAX_COUNT_PENDING_POOL_IMPORTS_ON_FIND_INTERSECTION: usize = 3; /* ================== ROUGH MEASURES ================== */ - /// Average byte size of an encoded transaction. Default is - /// [`SOFT_LIMIT_BYTE_SIZE_POOLED_TRANSACTIONS_RESPONSE`], which defaults to 2 MiB, + /// Average byte size of an encoded transaction. + /// + /// Default is [`SOFT_LIMIT_BYTE_SIZE_POOLED_TRANSACTIONS_RESPONSE`], which defaults to 2 MiB, /// divided by [`SOFT_LIMIT_COUNT_HASHES_IN_NEW_POOLED_TRANSACTIONS_BROADCAST_MESSAGE`], which /// is spec'd at 4096 hashes, so 521 bytes. pub const AVERAGE_BYTE_SIZE_TX_ENCODED: usize = SOFT_LIMIT_BYTE_SIZE_POOLED_TRANSACTIONS_RESPONSE / SOFT_LIMIT_COUNT_HASHES_IN_NEW_POOLED_TRANSACTIONS_BROADCAST_MESSAGE; - /// Median observed size in bytes of a small encoded legacy transaction. Default is 120 bytes. + /// Median observed size in bytes of a small encoded legacy transaction. + /// + /// Default is 120 bytes. pub const MEDIAN_BYTE_SIZE_SMALL_LEGACY_TX_ENCODED: usize = 120; + + /// Marginal on the number of hashes to preallocate memory for in a + /// [`GetPooledTransactions`](reth_eth_wire::GetPooledTransactions) request, when packed + /// according to the [`Eth68`](reth_eth_wire::EthVersion::Eth68) protocol version. To make + /// sure enough memory is preallocated in most cases, it's sensible to use a margin. This, + /// since the capacity is calculated based on median value + /// [`MEDIAN_BYTE_SIZE_SMALL_LEGACY_TX_ENCODED`]. There may otherwise be a noteworthy number of + /// cases where just 1 or 2 bytes too little memory is preallocated. + /// + /// Default is 8 hashes. + pub const DEFAULT_MARGINAL_COUNT_HASHES_GET_POOLED_TRANSACTIONS_REQUEST: usize = 8; + + /// Returns the approx number of transaction hashes that a + /// [`GetPooledTransactions`](reth_eth_wire::GetPooledTransactions) request will have capacity + /// for w.r.t. the [`Eth68`](reth_eth_wire::EthVersion::Eth68) protocol version. This is useful + /// for preallocating memory. + pub const fn approx_capacity_get_pooled_transactions_req_eth68( + info: &TransactionFetcherInfo, + ) -> usize { + let max_size_expected_response = + info.soft_limit_byte_size_pooled_transactions_response_on_pack_request; + + max_size_expected_response / MEDIAN_BYTE_SIZE_SMALL_LEGACY_TX_ENCODED + + DEFAULT_MARGINAL_COUNT_HASHES_GET_POOLED_TRANSACTIONS_REQUEST + } + + /// Returns the approx number of transactions that a + /// [`GetPooledTransactions`](reth_eth_wire::GetPooledTransactions) request will + /// have capacity for w.r.t. the [`Eth66`](reth_eth_wire::EthVersion::Eth66) protocol version. + /// This is useful for preallocating memory. + pub const fn approx_capacity_get_pooled_transactions_req_eth66() -> usize { + SOFT_LIMIT_COUNT_HASHES_IN_GET_POOLED_TRANSACTIONS_REQUEST + } } diff --git a/crates/net/network/src/transactions/fetcher.rs b/crates/net/network/src/transactions/fetcher.rs index b65740fcde41..3fe42e7e655c 100644 --- a/crates/net/network/src/transactions/fetcher.rs +++ b/crates/net/network/src/transactions/fetcher.rs @@ -395,7 +395,8 @@ impl TransactionFetcher { // try free active peers self.try_drain_inflight_requests(cx); - let mut hashes_to_request = RequestTxHashes::with_capacity(32); + let init_capacity_req = approx_capacity_get_pooled_transactions_req_eth68(&self.info); + let mut hashes_to_request = RequestTxHashes::with_capacity(init_capacity_req); let is_session_active = |peer_id: &PeerId| peers.contains_key(peer_id); // budget to look for an idle peer before giving up @@ -842,6 +843,19 @@ impl TransactionFetcher { } } + /// Returns the approx number of transactions that a [`GetPooledTransactions`] request will + /// have capacity for w.r.t. the given version of the protocol. + pub fn approx_capacity_get_pooled_transactions_req( + &self, + announcement_version: EthVersion, + ) -> usize { + if announcement_version.is_eth68() { + approx_capacity_get_pooled_transactions_req_eth68(&self.info) + } else { + approx_capacity_get_pooled_transactions_req_eth66() + } + } + /// Processes a resolved [`GetPooledTransactions`] request. Queues the outcome as a /// [`FetchEvent`], which will then be streamed by /// [`TransactionsManager`](super::TransactionsManager). diff --git a/crates/net/network/src/transactions/mod.rs b/crates/net/network/src/transactions/mod.rs index 1c311b70f296..11140c22e5ac 100644 --- a/crates/net/network/src/transactions/mod.rs +++ b/crates/net/network/src/transactions/mod.rs @@ -720,11 +720,16 @@ where return } - // load message version before announcement data is destructed in packing + // load message version before announcement data type is destructed in packing let msg_version = valid_announcement_data.msg_version(); + // // demand recommended soft limit on response, however the peer may enforce an arbitrary // limit on the response (2MB) - let mut hashes_to_request = RequestTxHashes::with_capacity(valid_announcement_data.len()); + // + // request buffer is shrunk via call to pack request! + let init_capacity_req = + self.transaction_fetcher.approx_capacity_get_pooled_transactions_req(msg_version); + let mut hashes_to_request = RequestTxHashes::with_capacity(init_capacity_req); let surplus_hashes = self.transaction_fetcher.pack_request(&mut hashes_to_request, valid_announcement_data); hashes_to_request.shrink_to_fit(); diff --git a/rustc-ice-2024-02-18T21_57_12-20464.txt b/rustc-ice-2024-02-18T21_57_12-20464.txt deleted file mode 100644 index aa209e2a4679..000000000000 --- a/rustc-ice-2024-02-18T21_57_12-20464.txt +++ /dev/null @@ -1,61 +0,0 @@ -thread 'main' panicked at src/tools/rustfmt/src/parse/session.rs:42:9: -silent emitter attempted to translate a diagnostic -stack backtrace: - 0: 0x105988338 - std::backtrace::Backtrace::create::h0fab15b28f02ee90 - 1: 0x10ed7cb14 - std[498b2361584da694]::panicking::update_hook::>::{closure#0} - 2: 0x1059a1128 - std::panicking::rust_panic_with_hook::hcd6cd3c8638ff9c9 - 3: 0x1059a0ac0 - std::panicking::begin_panic_handler::{{closure}}::h898760ccc010b5f6 - 4: 0x10599e424 - std::sys_common::backtrace::__rust_end_short_backtrace::h003142bc802218b9 - 5: 0x1059a0864 - _rust_begin_unwind - 6: 0x1059fbc14 - core::panicking::panic_fmt::ha2a8c2c955279123 - 7: 0x1047fab18 - ::fallback_fluent_bundle - 8: 0x1047ef2d4 - ::translate_message - 9: 0x10fd7daf0 - ::eagerly_translate::, rustc_errors[4e3da3b411c6d7f9]::diagnostic::DiagnosticArgValue>> - 10: 0x10fd376e4 - ::add_to_diagnostic_with::<::subdiagnostic::{closure#0}> - 11: 0x10fd37478 - ::into_diagnostic - 12: 0x10fd09118 - ::report_unknown_prefix - 13: 0x10fd05f1c - ::next_token - 14: 0x10fd8bc8c - ::bump - 15: 0x10fd8a930 - ::parse_token_trees - 16: 0x10fd8a9c4 - ::parse_token_trees - 17: 0x10fd8a720 - ::parse_all_token_trees - 18: 0x10fd0bd6c - rustc_parse[1a12595a5b95f93a]::maybe_file_to_stream - 19: 0x10fd0ba3c - rustc_parse[1a12595a5b95f93a]::maybe_source_file_to_parser - 20: 0x104863ee0 - ::parse_crate - 21: 0x104861bbc - rustfmt_nightly[7da0fe633313b04f]::formatting::format_project::>> - 22: 0x10474b7a4 - >::with::<>>::format_input_inner::{closure#0}, core[3992d5f9f39637df]::result::Result> - 23: 0x1047deb44 - rustc_span[8e1d581ad6d6c104]::create_session_if_not_set_then::, >>::format_input_inner::{closure#0}> - 24: 0x10485c720 - std[498b2361584da694]::panicking::try::, rustfmt_nightly[7da0fe633313b04f]::format_snippet::{closure#0}> - 25: 0x104775320 - rustfmt_nightly[7da0fe633313b04f]::format_snippet - 26: 0x104775718 - rustfmt_nightly[7da0fe633313b04f]::format_code_block - 27: 0x104754f84 - rustfmt_nightly[7da0fe633313b04f]::comment::rewrite_comment_inner - 28: 0x1047520fc - rustfmt_nightly[7da0fe633313b04f]::comment::identify_comment - 29: 0x10478ce9c - ::process_comment - 30: 0x10478c040 - ::format_missing_indent - 31: 0x1047962d4 - ::push_rewrite - 32: 0x104797788 - ::walk_stmts - 33: 0x104797bf8 - ::walk_stmts - 34: 0x1047916a0 - ::visit_block - 35: 0x1047939c4 - ::visit_fn - 36: 0x1047956f0 - ::visit_assoc_item - 37: 0x10478a2cc - ::visit_impl_items - 38: 0x104803b64 - rustfmt_nightly[7da0fe633313b04f]::items::format_impl - 39: 0x104798130 - ::with_context::<::visit_item::{closure#0}> - 40: 0x10479471c - ::visit_item - 41: 0x10478dcd0 - ::visit_items_with_reordering - 42: 0x104797e64 - ::format_separate_mod - 43: 0x1046a187c - rustfmt_nightly[7da0fe633313b04f]::formatting::format_project::> - 44: 0x10469d98c - >::with::<>::format_input_inner::{closure#0}, core[3992d5f9f39637df]::result::Result> - 45: 0x10469eb84 - >::format_input_inner - 46: 0x1046983e8 - rustfmt[f5bf4537e9fc9dac]::format_and_emit_report:: - 47: 0x10469ba24 - >::override_config:: - 48: 0x104697518 - rustfmt[f5bf4537e9fc9dac]::execute - 49: 0x104695a20 - rustfmt[f5bf4537e9fc9dac]::main - 50: 0x1046a69f8 - std[498b2361584da694]::sys_common::backtrace::__rust_begin_short_backtrace:: - 51: 0x1046aa7ac - std[498b2361584da694]::rt::lang_start::<()>::{closure#0} - 52: 0x105986de4 - std::rt::lang_start_internal::h457a376925c3005b - 53: 0x104698e84 - _main - - -rustc version: 1.78.0-nightly (6672c16af 2024-02-17) -platform: aarch64-apple-darwin \ No newline at end of file