clangd: `clangd` crashes with segmentation fault (Exact Parsing Error Location Identified, But Needs Expertise)
It appears to be a problem during background indexing.
File that I initially start clangd
with (one of the more complex files in the repository): controller.cpp.
Logs
I[21:02:59.690] clangd version 10.0.0 (https://github.com/llvm/llvm-project 3a843031a5ad83a00d2603f623881cb2b2bf719d)
I[21:02:59.690] PID: 6222
I[21:02:59.690] Working directory: /media/i/EXTERNAL/git-repos/eos
I[21:02:59.690] argv[0]: /home/i/install/bin/clangd-10.0.0
I[21:02:59.690] argv[1]: --log=verbose
I[21:02:59.690] argv[2]: -j=1
I[21:02:59.690] Starting LSP over stdin/stdout
V[21:02:59.691] <<< {"id":1,"jsonrpc":"2.0","method":"initialize","params":{"capabilities":{"textDocument":{"callHierarchy":{"dynamicRegistration":false},"codeAction":{"codeActionLiteralSupport":{"codeActionKind":{"valueSet":["","quickfix","refactor","refactor.extract","refactor.inline","refactor.rewrite","source","source.organizeImports"]}},"dynamicRegistration":true,"isPreferredSupport":true},"completion":{"completionItem":{"documentationFormat":["markdown"],"snippetSupport":true},"contextSupport":true},"declaration":{"linkSupport":true},"definition":{"linkSupport":true},"documentLink":{"dynamicRegistration":true,"tooltipSupport":true},"documentSymbol":{"hierarchicalDocumentSymbolSupport":true,"symbolKind":{"valueSet":[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26]}},"foldingRange":{"dynamicRegistration":true,"lineFoldingOnly":false,"rangeLimit":null},"formatting":{"dynamicRegistration":true},"hover":{"contentFormat":["markdown","plaintext"]},"implementation":{"linkSupport":true},"publishDiagnostics":{"relatedInformation":true,"tagSupport":{"valueSet":[1,2]},"versionSupport":true},"rangeFormatting":{"dynamicRegistration":true},"rename":{"dynamicRegistration":true,"prepareSupport":true},"semanticHighlightingCapabilities":{"semanticHighlighting":false},"signatureHelp":{"signatureInformation":{"parameterInformation":{"labelOffsetSupport":true}}},"synchronization":{"didSave":true,"willSave":true,"willSaveWaitUntil":true},"typeDefinition":{"linkSupport":true}},"window":{"workDoneProgress":true},"workspace":{"applyEdit":true,"configuration":true,"didChangeWatchedFiles":{"dynamicRegistration":true},"executeCommand":{"dynamicRegistration":false},"symbol":{"symbolKind":{"valueSet":[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26]}},"workspaceEdit":{"documentChanges":true,"resourceOperations":["create","rename","delete"]},"workspaceFolders":true}},"clientInfo":{"name":"emacs","version":"GNU Emacs 26.3.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 2.24.32)\n of 2020-01-11"},"initializationOptions":null,"processId":null,"rootPath":"/media/i/EXTERNAL/git-repos/eos","rootUri":"file:///media/i/EXTERNAL/git-repos/eos","workDoneToken":"1"}}
I[21:02:59.691] <-- initialize(1)
I[21:02:59.691] --> reply:initialize(1) 0 ms
V[21:02:59.691] >>> {"id":1,"jsonrpc":"2.0","result":{"capabilities":{"codeActionProvider":{"codeActionKinds":["quickfix","refactor","info"]},"completionProvider":{"resolveProvider":false,"triggerCharacters":[".",">",":"]},"declarationProvider":true,"definitionProvider":true,"documentFormattingProvider":true,"documentHighlightProvider":true,"documentLinkProvider":{"resolveProvider":false},"documentOnTypeFormattingProvider":{"firstTriggerCharacter":"\n","moreTriggerCharacter":[]},"documentRangeFormattingProvider":true,"documentSymbolProvider":true,"executeCommandProvider":{"commands":["clangd.applyFix","clangd.applyTweak"]},"hoverProvider":true,"referencesProvider":true,"renameProvider":{"prepareProvider":true},"selectionRangeProvider":true,"signatureHelpProvider":{"triggerCharacters":["(",","]},"textDocumentSync":2,"typeHierarchyProvider":true,"workspaceSymbolProvider":true}}}
V[21:03:00.409] <<< {"jsonrpc":"2.0","method":"initialized","params":{}}
I[21:03:00.409] <-- initialized
I[21:03:00.409] unhandled notification initialized
V[21:03:00.462] <<< {"jsonrpc":"2.0","method":"textDocument/didOpen","params":{"textDocument":{"languageId":"cpp","text":"#include <eosio/chain/controller.hpp>\n#include <eosio/chain/transaction_context.hpp>\n\n#include <eosio/chain/block_log.hpp>\n#include <eosio/chain/fork_database.hpp>\n#include <eosio/chain/exceptions.hpp>\n\n#include <eosio/chain/account_object.hpp>\n#include <eosio/chain/code_object.hpp>\n#include <eosio/chain/block_summary_object.hpp>\n#include <eosio/chain/eosio_contract.hpp>\n#include <eosio/chain/global_property_object.hpp>\n#include <eosio/chain/protocol_state_object.hpp>\n#include <eosio/chain/contract_table_objects.hpp>\n#include <eosio/chain/generated_transaction_object.hpp>\n#include <eosio/chain/transaction_object.hpp>\n#include <eosio/chain/reversible_block_object.hpp>\n#include <eosio/chain/genesis_intrinsics.hpp>\n#include <eosio/chain/whitelisted_intrinsics.hpp>\n#include <eosio/chain/database_header_object.hpp>\n\n#include <eosio/chain/protocol_feature_manager.hpp>\n#include <eosio/chain/authorization_manager.hpp>\n#include <eosio/chain/resource_limits.hpp>\n#include <eosio/chain/chain_snapshot.hpp>\n#include <eosio/chain/thread_utils.hpp>\n#include <eosio/chain/platform_timer.hpp>\n\n#include <chainbase/chainbase.hpp>\n#include <fc/io/json.hpp>\n#include <fc/log/logger_config.hpp>\n#include <fc/scoped_exit.hpp>\n#include <fc/variant_object.hpp>\n\n#include <new>\n\nnamespace eosio { namespace chain {\n\nusing resource_limits::resource_limits_manager;\n\nusing controller_index_set = index_set<\n account_index,\n account_metadata_index,\n account_ram_correction_index,\n global_property_multi_index,\n protocol_state_multi_index,\n dynamic_global_property_multi_index,\n block_summary_multi_index,\n transaction_multi_index,\n generated_transaction_multi_index,\n table_id_multi_index,\n code_index,\n database_header_multi_index\n>;\n\nusing contract_database_index_set = index_set<\n key_value_index,\n index64_index,\n index128_index,\n index256_index,\n index_double_index,\n index_long_double_index\n>;\n\nclass maybe_session {\n public:\n maybe_session() = default;\n\n maybe_session( maybe_session&& other)\n :_session(move(other._session))\n {\n }\n\n explicit maybe_session(database& db) {\n _session = db.start_undo_session(true);\n }\n\n maybe_session(const maybe_session&) = delete;\n\n void squash() {\n if (_session)\n _session->squash();\n }\n\n void undo() {\n if (_session)\n _session->undo();\n }\n\n void push() {\n if (_session)\n _session->push();\n }\n\n maybe_session& operator = ( maybe_session&& mv ) {\n if (mv._session) {\n _session = move(*mv._session);\n mv._session.reset();\n } else {\n _session.reset();\n }\n\n return *this;\n };\n\n private:\n optional<database::session> _session;\n};\n\nstruct building_block {\n building_block( const block_header_state& prev,\n block_timestamp_type when,\n uint16_t num_prev_blocks_to_confirm,\n const vector<digest_type>& new_protocol_feature_activations )\n :_pending_block_header_state( prev.next( when, num_prev_blocks_to_confirm ) )\n ,_new_protocol_feature_activations( new_protocol_feature_activations )\n {}\n\n pending_block_header_state _pending_block_header_state;\n optional<producer_authority_schedule> _new_pending_producer_schedule;\n vector<digest_type> _new_protocol_feature_activations;\n size_t _num_new_protocol_features_that_have_activated = 0;\n vector<transaction_metadata_ptr> _pending_trx_metas;\n vector<transaction_receipt> _pending_trx_receipts;\n vector<action_receipt> _actions;\n optional<checksum256_type> _transaction_mroot;\n};\n\nstruct assembled_block {\n block_id_type _id;\n pending_block_header_state _pending_block_header_state;\n vector<transaction_metadata_ptr> _trx_metas;\n signed_block_ptr _unsigned_block;\n\n // if the _unsigned_block pre-dates block-signing authorities this may be present.\n optional<producer_authority_schedule> _new_producer_authority_cache;\n};\n\nstruct completed_block {\n block_state_ptr _block_state;\n};\n\nusing block_stage_type = fc::static_variant<building_block, assembled_block, completed_block>;\n\nstruct pending_state {\n pending_state( maybe_session&& s, const block_header_state& prev,\n block_timestamp_type when,\n uint16_t num_prev_blocks_to_confirm,\n const vector<digest_type>& new_protocol_feature_activations )\n :_db_session( move(s) )\n ,_block_stage( building_block( prev, when, num_prev_blocks_to_confirm, new_protocol_feature_activations ) )\n {}\n\n maybe_session _db_session;\n block_stage_type _block_stage;\n controller::block_status _block_status = controller::block_status::incomplete;\n optional<block_id_type> _producer_block_id;\n\n /** @pre _block_stage cannot hold completed_block alternative */\n const pending_block_header_state& get_pending_block_header_state()const {\n if( _block_stage.contains<building_block>() )\n return _block_stage.get<building_block>()._pending_block_header_state;\n\n return _block_stage.get<assembled_block>()._pending_block_header_state;\n }\n\n const vector<transaction_receipt>& get_trx_receipts()const {\n if( _block_stage.contains<building_block>() )\n return _block_stage.get<building_block>()._pending_trx_receipts;\n\n if( _block_stage.contains<assembled_block>() )\n return _block_stage.get<assembled_block>()._unsigned_block->transactions;\n\n return _block_stage.get<completed_block>()._block_state->block->transactions;\n }\n\n vector<transaction_metadata_ptr> extract_trx_metas() {\n if( _block_stage.contains<building_block>() )\n return std::move( _block_stage.get<building_block>()._pending_trx_metas );\n\n if( _block_stage.contains<assembled_block>() )\n return std::move( _block_stage.get<assembled_block>()._trx_metas );\n\n return _block_stage.get<completed_block>()._block_state->extract_trxs_metas();\n }\n\n bool is_protocol_feature_activated( const digest_type& feature_digest )const {\n if( _block_stage.contains<building_block>() ) {\n auto& bb = _block_stage.get<building_block>();\n const auto& activated_features = bb._pending_block_header_state.prev_activated_protocol_features->protocol_features;\n\n if( activated_features.find( feature_digest ) != activated_features.end() ) return true;\n\n if( bb._num_new_protocol_features_that_have_activated == 0 ) return false;\n\n auto end = bb._new_protocol_feature_activations.begin() + bb._num_new_protocol_features_that_have_activated;\n return (std::find( bb._new_protocol_feature_activations.begin(), end, feature_digest ) != end);\n }\n\n if( _block_stage.contains<assembled_block>() ) {\n // Calling is_protocol_feature_activated during the assembled_block stage is not efficient.\n // We should avoid doing it.\n // In fact for now it isn't even implemented.\n EOS_THROW( misc_exception,\n \"checking if protocol feature is activated in the assembled_block stage is not yet supported\" );\n // TODO: implement this\n }\n\n const auto& activated_features = _block_stage.get<completed_block>()._block_state->activated_protocol_features->protocol_features;\n return (activated_features.find( feature_digest ) != activated_features.end());\n }\n\n void push() {\n _db_session.push();\n }\n};\n\nstruct controller_impl {\n\n // LLVM sets the new handler, we need to reset this to throw a bad_alloc exception so we can possibly exit cleanly\n // and not just abort.\n struct reset_new_handler {\n reset_new_handler() { std::set_new_handler([](){ throw std::bad_alloc(); }); }\n };\n\n reset_new_handler rnh; // placed here to allow for this to be set before constructing the other fields\n controller& self;\n chainbase::database db;\n chainbase::database reversible_blocks; ///< a special database to persist blocks that have successfully been applied but are still reversible\n block_log blog;\n optional<pending_state> pending;\n block_state_ptr head;\n fork_database fork_db;\n wasm_interface wasmif;\n resource_limits_manager resource_limits;\n authorization_manager authorization;\n protocol_feature_manager protocol_features;\n controller::config conf;\n const chain_id_type chain_id; // read by thread_pool threads, value will not be changed\n optional<fc::time_point> replay_head_time;\n db_read_mode read_mode = db_read_mode::SPECULATIVE;\n bool in_trx_requiring_checks = false; ///< if true, checks that are normally skipped on replay (e.g. auth checks) cannot be skipped\n optional<fc::microseconds> subjective_cpu_leeway;\n bool trusted_producer_light_validation = false;\n uint32_t snapshot_head_block = 0;\n named_thread_pool thread_pool;\n platform_timer timer;\n#if defined(EOSIO_EOS_VM_RUNTIME_ENABLED) || defined(EOSIO_EOS_VM_JIT_RUNTIME_ENABLED)\n vm::wasm_allocator wasm_alloc;\n#endif\n\n typedef pair<scope_name,action_name> handler_key;\n map< account_name, map<handler_key, apply_handler> > apply_handlers;\n unordered_map< builtin_protocol_feature_t, std::function<void(controller_impl&)>, enum_hash<builtin_protocol_feature_t> > protocol_feature_activation_handlers;\n\n void pop_block() {\n auto prev = fork_db.get_block( head->header.previous );\n\n if( !prev ) {\n EOS_ASSERT( fork_db.root()->id == head->header.previous, block_validate_exception, \"attempt to pop beyond last irreversible block\" );\n prev = fork_db.root();\n }\n\n if( const auto* b = reversible_blocks.find<reversible_block_object,by_num>(head->block_num) )\n {\n reversible_blocks.remove( *b );\n }\n\n if ( read_mode == db_read_mode::SPECULATIVE ) {\n EOS_ASSERT( head->block, block_validate_exception, \"attempting to pop a block that was sparsely loaded from a snapshot\");\n }\n\n head = prev;\n\n db.undo();\n\n protocol_features.popped_blocks_to( prev->block_num );\n }\n\n template<builtin_protocol_feature_t F>\n void on_activation();\n\n template<builtin_protocol_feature_t F>\n inline void set_activation_handler() {\n auto res = protocol_feature_activation_handlers.emplace( F, &controller_impl::on_activation<F> );\n EOS_ASSERT( res.second, misc_exception, \"attempting to set activation handler twice\" );\n }\n\n inline void trigger_activation_handler( builtin_protocol_feature_t f ) {\n auto itr = protocol_feature_activation_handlers.find( f );\n if( itr == protocol_feature_activation_handlers.end() ) return;\n (itr->second)( *this );\n }\n\n void set_apply_handler( account_name receiver, account_name contract, action_name action, apply_handler v ) {\n apply_handlers[receiver][make_pair(contract,action)] = v;\n }\n\n controller_impl( const controller::config& cfg, controller& s, protocol_feature_set&& pfs, const chain_id_type& chain_id )\n :rnh(),\n self(s),\n db( cfg.state_dir,\n cfg.read_only ? database::read_only : database::read_write,\n cfg.state_size, false, cfg.db_map_mode, cfg.db_hugepage_paths ),\n reversible_blocks( cfg.blocks_dir/config::reversible_blocks_dir_name,\n cfg.read_only ? database::read_only : database::read_write,\n cfg.reversible_cache_size, false, cfg.db_map_mode, cfg.db_hugepage_paths ),\n blog( cfg.blocks_dir ),\n fork_db( cfg.state_dir ),\n wasmif( cfg.wasm_runtime, cfg.eosvmoc_tierup, db, cfg.state_dir, cfg.eosvmoc_config ),\n resource_limits( db ),\n authorization( s, db ),\n protocol_features( std::move(pfs) ),\n conf( cfg ),\n chain_id( chain_id ),\n read_mode( cfg.read_mode ),\n thread_pool( \"chain\", cfg.thread_pool_size )\n {\n fork_db.open( [this]( block_timestamp_type timestamp,\n const flat_set<digest_type>& cur_features,\n const vector<digest_type>& new_features )\n { check_protocol_features( timestamp, cur_features, new_features ); }\n );\n\n set_activation_handler<builtin_protocol_feature_t::preactivate_feature>();\n set_activation_handler<builtin_protocol_feature_t::replace_deferred>();\n set_activation_handler<builtin_protocol_feature_t::get_sender>();\n set_activation_handler<builtin_protocol_feature_t::webauthn_key>();\n set_activation_handler<builtin_protocol_feature_t::wtmsig_block_signatures>();\n\n self.irreversible_block.connect([this](const block_state_ptr& bsp) {\n wasmif.current_lib(bsp->block_num);\n });\n\n\n#define SET_APP_HANDLER( receiver, contract, action) \\\n set_apply_handler( account_name(#receiver), account_name(#contract), action_name(#action), \\\n &BOOST_PP_CAT(apply_, BOOST_PP_CAT(contract, BOOST_PP_CAT(_,action) ) ) )\n\n SET_APP_HANDLER( eosio, eosio, newaccount );\n SET_APP_HANDLER( eosio, eosio, setcode );\n SET_APP_HANDLER( eosio, eosio, setabi );\n SET_APP_HANDLER( eosio, eosio, updateauth );\n SET_APP_HANDLER( eosio, eosio, deleteauth );\n SET_APP_HANDLER( eosio, eosio, linkauth );\n SET_APP_HANDLER( eosio, eosio, unlinkauth );\n/*\n SET_APP_HANDLER( eosio, eosio, postrecovery );\n SET_APP_HANDLER( eosio, eosio, passrecovery );\n SET_APP_HANDLER( eosio, eosio, vetorecovery );\n*/\n\n SET_APP_HANDLER( eosio, eosio, canceldelay );\n }\n\n /**\n * Plugins / observers listening to signals emited (such as accepted_transaction) might trigger\n * errors and throw exceptions. Unless those exceptions are caught it could impact consensus and/or\n * cause a node to fork.\n *\n * If it is ever desirable to let a signal handler bubble an exception out of this method\n * a full audit of its uses needs to be undertaken.\n *\n */\n template<typename Signal, typename Arg>\n void emit( const Signal& s, Arg&& a ) {\n try {\n s( std::forward<Arg>( a ));\n } catch (std::bad_alloc& e) {\n wlog( \"std::bad_alloc: ${w}\", (\"w\", e.what()) );\n throw e;\n } catch (boost::interprocess::bad_alloc& e) {\n wlog( \"boost::interprocess::bad alloc: ${w}\", (\"w\", e.what()) );\n throw e;\n } catch ( controller_emit_signal_exception& e ) {\n wlog( \"controller_emit_signal_exception: ${details}\", (\"details\", e.to_detail_string()) );\n throw e;\n } catch ( fc::exception& e ) {\n wlog( \"fc::exception: ${details}\", (\"details\", e.to_detail_string()) );\n } catch ( std::exception& e ) {\n wlog( \"std::exception: ${details}\", (\"details\", e.what()) );\n } catch ( ... ) {\n wlog( \"signal handler threw exception\" );\n }\n }\n\n void log_irreversible() {\n EOS_ASSERT( fork_db.root(), fork_database_exception, \"fork database not properly initialized\" );\n\n const auto& log_head = blog.head();\n\n auto lib_num = log_head ? log_head->block_num() : (blog.first_block_num() - 1);\n\n auto root_id = fork_db.root()->id;\n\n if( log_head ) {\n EOS_ASSERT( root_id == blog.head_id(), fork_database_exception, \"fork database root does not match block log head\" );\n } else {\n EOS_ASSERT( fork_db.root()->block_num == lib_num, fork_database_exception,\n \"empty block log expects the first appended block to build off a block that is not the fork database root\" );\n }\n\n auto fork_head = (read_mode == db_read_mode::IRREVERSIBLE) ? fork_db.pending_head() : fork_db.head();\n\n if( fork_head->dpos_irreversible_blocknum <= lib_num )\n return;\n\n const auto branch = fork_db.fetch_branch( fork_head->id, fork_head->dpos_irreversible_blocknum );\n try {\n const auto& rbi = reversible_blocks.get_index<reversible_block_index,by_num>();\n\n for( auto bitr = branch.rbegin(); bitr != branch.rend(); ++bitr ) {\n if( read_mode == db_read_mode::IRREVERSIBLE ) {\n apply_block( *bitr, controller::block_status::complete, trx_meta_cache_lookup{} );\n head = (*bitr);\n fork_db.mark_valid( head );\n }\n\n emit( self.irreversible_block, *bitr );\n\n db.commit( (*bitr)->block_num );\n root_id = (*bitr)->id;\n\n blog.append( (*bitr)->block );\n\n auto rbitr = rbi.begin();\n while( rbitr != rbi.end() && rbitr->blocknum <= (*bitr)->block_num ) {\n reversible_blocks.remove( *rbitr );\n rbitr = rbi.begin();\n }\n }\n } catch( fc::exception& ) {\n if( root_id != fork_db.root()->id ) {\n fork_db.advance_root( root_id );\n }\n throw;\n }\n\n //db.commit( fork_head->dpos_irreversible_blocknum ); // redundant\n\n if( root_id != fork_db.root()->id ) {\n fork_db.advance_root( root_id );\n }\n }\n\n /**\n * Sets fork database head to the genesis state.\n */\n void initialize_blockchain_state(const genesis_state& genesis) {\n wlog( \"Initializing new blockchain with genesis state\" );\n producer_authority_schedule initial_schedule = { 0, { producer_authority{config::system_account_name, block_signing_authority_v0{ 1, {{genesis.initial_key, 1}} } } } };\n legacy::producer_schedule_type initial_legacy_schedule{ 0, {{config::system_account_name, genesis.initial_key}} };\n\n block_header_state genheader;\n genheader.active_schedule = initial_schedule;\n genheader.pending_schedule.schedule = initial_schedule;\n // NOTE: if wtmsig block signatures are enabled at genesis time this should be the hash of a producer authority schedule\n genheader.pending_schedule.schedule_hash = fc::sha256::hash(initial_legacy_schedule);\n genheader.header.timestamp = genesis.initial_timestamp;\n genheader.header.action_mroot = genesis.compute_chain_id();\n genheader.id = genheader.header.id();\n genheader.block_num = genheader.header.block_num();\n\n head = std::make_shared<block_state>();\n static_cast<block_header_state&>(*head) = genheader;\n head->activated_protocol_features = std::make_shared<protocol_feature_activation_set>();\n head->block = std::make_shared<signed_block>(genheader.header);\n db.set_revision( head->block_num );\n initialize_database(genesis);\n }\n\n void replay(std::function<bool()> shutdown) {\n auto blog_head = blog.head();\n auto blog_head_time = blog_head->timestamp.to_time_point();\n replay_head_time = blog_head_time;\n auto start_block_num = head->block_num + 1;\n auto start = fc::time_point::now();\n\n std::exception_ptr except_ptr;\n\n if( start_block_num <= blog_head->block_num() ) {\n ilog( \"existing block log, attempting to replay from ${s} to ${n} blocks\",\n (\"s\", start_block_num)(\"n\", blog_head->block_num()) );\n try {\n while( auto next = blog.read_block_by_num( head->block_num + 1 ) ) {\n replay_push_block( next, controller::block_status::irreversible );\n if( next->block_num() % 500 == 0 ) {\n ilog( \"${n} of ${head}\", (\"n\", next->block_num())(\"head\", blog_head->block_num()) );\n if( shutdown() ) break;\n }\n }\n } catch( const database_guard_exception& e ) {\n except_ptr = std::current_exception();\n }\n ilog( \"${n} irreversible blocks replayed\", (\"n\", 1 + head->block_num - start_block_num) );\n\n auto pending_head = fork_db.pending_head();\n if( pending_head->block_num < head->block_num || head->block_num < fork_db.root()->block_num ) {\n ilog( \"resetting fork database with new last irreversible block as the new root: ${id}\",\n (\"id\", head->id) );\n fork_db.reset( *head );\n } else if( head->block_num != fork_db.root()->block_num ) {\n auto new_root = fork_db.search_on_branch( pending_head->id, head->block_num );\n EOS_ASSERT( new_root, fork_database_exception, \"unexpected error: could not find new LIB in fork database\" );\n ilog( \"advancing fork database root to new last irreversible block within existing fork database: ${id}\",\n (\"id\", new_root->id) );\n fork_db.mark_valid( new_root );\n fork_db.advance_root( new_root->id );\n }\n\n // if the irreverible log is played without undo sessions enabled, we need to sync the\n // revision ordinal to the appropriate expected value here.\n if( self.skip_db_sessions( controller::block_status::irreversible ) )\n db.set_revision( head->block_num );\n } else {\n ilog( \"no irreversible blocks need to be replayed\" );\n }\n\n if( !except_ptr && !shutdown() ) {\n int rev = 0;\n while( auto obj = reversible_blocks.find<reversible_block_object,by_num>(head->block_num+1) ) {\n ++rev;\n replay_push_block( obj->get_block(), controller::block_status::validated );\n }\n ilog( \"${n} reversible blocks replayed\", (\"n\",rev) );\n }\n\n auto end = fc::time_point::now();\n ilog( \"replayed ${n} blocks in ${duration} seconds, ${mspb} ms/block\",\n (\"n\", head->block_num + 1 - start_block_num)(\"duration\", (end-start).count()/1000000)\n (\"mspb\", ((end-start).count()/1000.0)/(head->block_num-start_block_num)) );\n replay_head_time.reset();\n\n if( except_ptr ) {\n std::rethrow_exception( except_ptr );\n }\n }\n\n void startup(std::function<bool()> shutdown, const snapshot_reader_ptr& snapshot) {\n EOS_ASSERT( snapshot, snapshot_exception, \"No snapshot reader provided\" );\n ilog( \"Starting initialization from snapshot, this may take a significant amount of time\" );\n try {\n snapshot->validate();\n if( blog.head() ) {\n read_from_snapshot( snapshot, blog.first_block_num(), blog.head()->block_num() );\n } else {\n read_from_snapshot( snapshot, 0, std::numeric_limits<uint32_t>::max() );\n const uint32_t lib_num = head->block_num;\n EOS_ASSERT( lib_num > 0, snapshot_exception,\n \"Snapshot indicates controller head at block number 0, but that is not allowed. \"\n \"Snapshot is invalid.\" );\n blog.reset( chain_id, lib_num + 1 );\n }\n const auto hash = calculate_integrity_hash();\n ilog( \"database initialized with hash: ${hash}\", (\"hash\", hash) );\n\n init(shutdown);\n } catch (boost::interprocess::bad_alloc& e) {\n elog( \"db storage not configured to have enough storage for the provided snapshot, please increase and retry snapshot\" );\n throw e;\n }\n\n ilog( \"Finished initialization from snapshot\" );\n }\n\n void startup(std::function<bool()> shutdown, const genesis_state& genesis) {\n EOS_ASSERT( db.revision() < 1, database_exception, \"This version of controller::startup only works with a fresh state database.\" );\n const auto& genesis_chain_id = genesis.compute_chain_id();\n EOS_ASSERT( genesis_chain_id == chain_id, chain_id_type_exception,\n \"genesis state provided to startup corresponds to a chain ID (${genesis_chain_id}) that does not match the chain ID that controller was constructed with (${controller_chain_id})\",\n (\"genesis_chain_id\", genesis_chain_id)(\"controller_chain_id\", chain_id)\n );\n\n if( fork_db.head() ) {\n if( read_mode == db_read_mode::IRREVERSIBLE && fork_db.head()->id != fork_db.root()->id ) {\n fork_db.rollback_head_to_root();\n }\n wlog( \"No existing chain state. Initializing fresh blockchain state.\" );\n } else {\n wlog( \"No existing chain state or fork database. Initializing fresh blockchain state and resetting fork database.\");\n }\n initialize_blockchain_state(genesis); // sets head to genesis state\n\n if( !fork_db.head() ) {\n fork_db.reset( *head );\n }\n\n if( blog.head() ) {\n EOS_ASSERT( blog.first_block_num() == 1, block_log_exception,\n \"block log does not start with genesis block\"\n );\n } else {\n blog.reset( genesis, head->block );\n }\n init(shutdown);\n }\n\n void startup(std::function<bool()> shutdown) {\n EOS_ASSERT( db.revision() >= 1, database_exception, \"This version of controller::startup does not work with a fresh state database.\" );\n EOS_ASSERT( fork_db.head(), fork_database_exception, \"No existing fork database despite existing chain state. Replay required.\" );\n\n uint32_t lib_num = fork_db.root()->block_num;\n auto first_block_num = blog.first_block_num();\n if( blog.head() ) {\n EOS_ASSERT( first_block_num <= lib_num && lib_num <= blog.head()->block_num(),\n block_log_exception,\n \"block log (ranging from ${block_log_first_num} to ${block_log_last_num}) does not contain the last irreversible block (${fork_db_lib})\",\n (\"block_log_first_num\", first_block_num)\n (\"block_log_last_num\", blog.head()->block_num())\n (\"fork_db_lib\", lib_num)\n );\n lib_num = blog.head()->block_num();\n } else {\n if( first_block_num != (lib_num + 1) ) {\n blog.reset( chain_id, lib_num + 1 );\n }\n }\n\n if( read_mode == db_read_mode::IRREVERSIBLE && fork_db.head()->id != fork_db.root()->id ) {\n fork_db.rollback_head_to_root();\n }\n head = fork_db.head();\n\n init(shutdown);\n }\n\n\n static auto validate_db_version( const chainbase::database& db ) {\n // check database version\n const auto& header_idx = db.get_index<database_header_multi_index>().indices().get<by_id>();\n\n EOS_ASSERT(header_idx.begin() != header_idx.end(), bad_database_version_exception,\n \"state database version pre-dates versioning, please restore from a compatible snapshot or replay!\");\n\n auto header_itr = header_idx.begin();\n header_itr->validate();\n\n return header_itr;\n }\n\n void init(std::function<bool()> shutdown) {\n uint32_t lib_num = (blog.head() ? blog.head()->block_num() : fork_db.root()->block_num);\n\n auto header_itr = validate_db_version( db );\n\n {\n const auto& state_chain_id = db.get<global_property_object>().chain_id;\n EOS_ASSERT( state_chain_id == chain_id, chain_id_type_exception,\n \"chain ID in state (${state_chain_id}) does not match the chain ID that controller was constructed with (${controller_chain_id})\",\n (\"state_chain_id\", state_chain_id)(\"controller_chain_id\", chain_id)\n );\n }\n\n // upgrade to the latest compatible version\n if (header_itr->version != database_header_object::current_version) {\n db.modify(*header_itr, [](auto& header) {\n header.version = database_header_object::current_version;\n });\n }\n\n // At this point head != nullptr && fork_db.head() != nullptr && fork_db.root() != nullptr.\n // Furthermore, fork_db.root()->block_num <= lib_num.\n // Also, even though blog.head() may still be nullptr, blog.first_block_num() is guaranteed to be lib_num + 1.\n\n EOS_ASSERT( db.revision() >= head->block_num, fork_database_exception,\n \"fork database head (${head}) is inconsistent with state (${db})\",\n (\"db\",db.revision())(\"head\",head->block_num) );\n\n if( db.revision() > head->block_num ) {\n wlog( \"database revision (${db}) is greater than head block number (${head}), \"\n \"attempting to undo pending changes\",\n (\"db\",db.revision())(\"head\",head->block_num) );\n }\n while( db.revision() > head->block_num ) {\n db.undo();\n }\n\n protocol_features.init( db );\n\n const auto& rbi = reversible_blocks.get_index<reversible_block_index,by_num>();\n auto last_block_num = lib_num;\n\n if( read_mode == db_read_mode::IRREVERSIBLE ) {\n // ensure there are no reversible blocks\n auto itr = rbi.begin();\n if( itr != rbi.end() ) {\n wlog( \"read_mode has changed to irreversible: erasing reversible blocks\" );\n }\n for( ; itr != rbi.end(); itr = rbi.begin() )\n reversible_blocks.remove( *itr );\n } else {\n auto itr = rbi.begin();\n for( ; itr != rbi.end() && itr->blocknum <= lib_num; itr = rbi.begin() )\n reversible_blocks.remove( *itr );\n\n EOS_ASSERT( itr == rbi.end() || itr->blocknum == lib_num + 1, reversible_blocks_exception,\n \"gap exists between last irreversible block (${lib}) and first reversible block (${first_reversible_block_num})\",\n (\"lib\", lib_num)(\"first_reversible_block_num\", itr->blocknum)\n );\n\n auto ritr = rbi.rbegin();\n\n if( ritr != rbi.rend() ) {\n last_block_num = ritr->blocknum;\n }\n\n EOS_ASSERT( head->block_num <= last_block_num, reversible_blocks_exception,\n \"head block (${head_num}) is greater than the last locally stored block (${last_block_num})\",\n (\"head_num\", head->block_num)(\"last_block_num\", last_block_num)\n );\n\n auto pending_head = fork_db.pending_head();\n\n if( ritr != rbi.rend()\n && lib_num < pending_head->block_num\n && pending_head->block_num <= last_block_num\n ) {\n auto rbitr = rbi.find( pending_head->block_num );\n EOS_ASSERT( rbitr != rbi.end(), reversible_blocks_exception, \"pending head block not found in reversible blocks\");\n auto rev_id = rbitr->get_block_id();\n EOS_ASSERT( rev_id == pending_head->id,\n reversible_blocks_exception,\n \"mismatch in block id of pending head block ${num} in reversible blocks database: \"\n \"expected: ${expected}, actual: ${actual}\",\n (\"num\", pending_head->block_num)(\"expected\", pending_head->id)(\"actual\", rev_id)\n );\n } else if( ritr != rbi.rend() && last_block_num < pending_head->block_num ) {\n const auto b = fork_db.search_on_branch( pending_head->id, last_block_num );\n FC_ASSERT( b, \"unexpected violation of invariants\" );\n auto rev_id = ritr->get_block_id();\n EOS_ASSERT( rev_id == b->id,\n reversible_blocks_exception,\n \"mismatch in block id of last block (${num}) in reversible blocks database: \"\n \"expected: ${expected}, actual: ${actual}\",\n (\"num\", last_block_num)(\"expected\", b->id)(\"actual\", rev_id)\n );\n }\n // else no checks needed since fork_db will be completely reset on replay anyway\n }\n\n if( last_block_num > head->block_num ) {\n replay( shutdown ); // replay any irreversible and reversible blocks ahead of current head\n }\n\n if( shutdown() ) return;\n\n if( read_mode != db_read_mode::IRREVERSIBLE\n && fork_db.pending_head()->id != fork_db.head()->id\n && fork_db.head()->id == fork_db.root()->id\n ) {\n wlog( \"read_mode has changed from irreversible: applying best branch from fork database\" );\n\n for( auto pending_head = fork_db.pending_head();\n pending_head->id != fork_db.head()->id;\n pending_head = fork_db.pending_head()\n ) {\n wlog( \"applying branch from fork database ending with block: ${id}\", (\"id\", pending_head->id) );\n maybe_switch_forks( pending_head, controller::block_status::complete, forked_branch_callback{}, trx_meta_cache_lookup{} );\n }\n }\n }\n\n ~controller_impl() {\n thread_pool.stop();\n pending.reset();\n }\n\n void add_indices() {\n reversible_blocks.add_index<reversible_block_index>();\n\n controller_index_set::add_indices(db);\n contract_database_index_set::add_indices(db);\n\n authorization.add_indices();\n resource_limits.add_indices();\n }\n\n void clear_all_undo() {\n // Rewind the database to the last irreversible block\n db.undo_all();\n /*\n FC_ASSERT(db.revision() == self.head_block_num(),\n \"Chainbase revision does not match head block num\",\n (\"rev\", db.revision())(\"head_block\", self.head_block_num()));\n */\n }\n\n void add_contract_tables_to_snapshot( const snapshot_writer_ptr& snapshot ) const {\n snapshot->write_section(\"contract_tables\", [this]( auto& section ) {\n index_utils<table_id_multi_index>::walk(db, [this, §ion]( const table_id_object& table_row ){\n // add a row for the table\n section.add_row(table_row, db);\n\n // followed by a size row and then N data rows for each type of table\n contract_database_index_set::walk_indices([this, §ion, &table_row]( auto utils ) {\n using utils_t = decltype(utils);\n using value_t = typename decltype(utils)::index_t::value_type;\n using by_table_id = object_to_table_id_tag_t<value_t>;\n\n auto tid_key = boost::make_tuple(table_row.id);\n auto next_tid_key = boost::make_tuple(table_id_object::id_type(table_row.id._id + 1));\n\n unsigned_int size = utils_t::template size_range<by_table_id>(db, tid_key, next_tid_key);\n section.add_row(size, db);\n\n utils_t::template walk_range<by_table_id>(db, tid_key, next_tid_key, [this, §ion]( const auto &row ) {\n section.add_row(row, db);\n });\n });\n });\n });\n }\n\n void read_contract_tables_from_snapshot( const snapshot_reader_ptr& snapshot ) {\n snapshot->read_section(\"contract_tables\", [this]( auto& section ) {\n bool more = !section.empty();\n while (more) {\n // read the row for the table\n table_id_object::id_type t_id;\n index_utils<table_id_multi_index>::create(db, [this, §ion, &t_id](auto& row) {\n section.read_row(row, db);\n t_id = row.id;\n });\n\n // read the size and data rows for each type of table\n contract_database_index_set::walk_indices([this, §ion, &t_id, &more](auto utils) {\n using utils_t = decltype(utils);\n\n unsigned_int size;\n more = section.read_row(size, db);\n\n for (size_t idx = 0; idx < size.value; idx++) {\n utils_t::create(db, [this, §ion, &more, &t_id](auto& row) {\n row.t_id = t_id;\n more = section.read_row(row, db);\n });\n }\n });\n }\n });\n }\n\n void add_to_snapshot( const snapshot_writer_ptr& snapshot ) const {\n snapshot->write_section<chain_snapshot_header>([this]( auto §ion ){\n section.add_row(chain_snapshot_header(), db);\n });\n\n snapshot->write_section<block_state>([this]( auto §ion ){\n section.template add_row<block_header_state>(*fork_db.head(), db);\n });\n\n controller_index_set::walk_indices([this, &snapshot]( auto utils ){\n using value_t = typename decltype(utils)::index_t::value_type;\n\n // skip the table_id_object as its inlined with contract tables section\n if (std::is_same<value_t, table_id_object>::value) {\n return;\n }\n\n // skip the database_header as it is only relevant to in-memory database\n if (std::is_same<value_t, database_header_object>::value) {\n return;\n }\n\n snapshot->write_section<value_t>([this]( auto& section ){\n decltype(utils)::walk(db, [this, §ion]( const auto &row ) {\n section.add_row(row, db);\n });\n });\n });\n\n add_contract_tables_to_snapshot(snapshot);\n\n authorization.add_to_snapshot(snapshot);\n resource_limits.add_to_snapshot(snapshot);\n }\n\n static fc::optional<genesis_state> extract_legacy_genesis_state( snapshot_reader& snapshot, uint32_t version ) {\n fc::optional<genesis_state> genesis;\n using v2 = legacy::snapshot_global_property_object_v2;\n\n if (std::clamp(version, v2::minimum_version, v2::maximum_version) == version ) {\n genesis.emplace();\n snapshot.read_section<genesis_state>([&genesis=*genesis]( auto §ion ){\n section.read_row(genesis);\n });\n }\n return genesis;\n }\n\n void read_from_snapshot( const snapshot_reader_ptr& snapshot, uint32_t blog_start, uint32_t blog_end ) {\n chain_snapshot_header header;\n snapshot->read_section<chain_snapshot_header>([this, &header]( auto §ion ){\n section.read_row(header, db);\n header.validate();\n });\n\n { /// load and upgrade the block header state\n block_header_state head_header_state;\n using v2 = legacy::snapshot_block_header_state_v2;\n\n if (std::clamp(header.version, v2::minimum_version, v2::maximum_version) == header.version ) {\n snapshot->read_section<block_state>([this, &head_header_state]( auto §ion ) {\n legacy::snapshot_block_header_state_v2 legacy_header_state;\n section.read_row(legacy_header_state, db);\n head_header_state = block_header_state(std::move(legacy_header_state));\n });\n } else {\n snapshot->read_section<block_state>([this,&head_header_state]( auto §ion ){\n section.read_row(head_header_state, db);\n });\n }\n\n snapshot_head_block = head_header_state.block_num;\n EOS_ASSERT( blog_start <= (snapshot_head_block + 1) && snapshot_head_block <= blog_end,\n block_log_exception,\n \"Block log is provided with snapshot but does not contain the head block from the snapshot nor a block right after it\",\n (\"snapshot_head_block\", snapshot_head_block)\n (\"block_log_first_num\", blog_start)\n (\"block_log_last_num\", blog_end)\n );\n\n fork_db.reset( head_header_state );\n head = fork_db.head();\n snapshot_head_block = head->block_num;\n\n }\n\n controller_index_set::walk_indices([this, &snapshot, &header]( auto utils ){\n using value_t = typename decltype(utils)::index_t::value_type;\n\n // skip the table_id_object as its inlined with contract tables section\n if (std::is_same<value_t, table_id_object>::value) {\n return;\n }\n\n // skip the database_header as it is only relevant to in-memory database\n if (std::is_same<value_t, database_header_object>::value) {\n return;\n }\n\n // special case for in-place upgrade of global_property_object\n if (std::is_same<value_t, global_property_object>::value) {\n using v2 = legacy::snapshot_global_property_object_v2;\n\n if (std::clamp(header.version, v2::minimum_version, v2::maximum_version) == header.version ) {\n fc::optional<genesis_state> genesis = extract_legacy_genesis_state(*snapshot, header.version);\n EOS_ASSERT( genesis, snapshot_exception,\n \"Snapshot indicates chain_snapshot_header version 2, but does not contain a genesis_state. \"\n \"It must be corrupted.\");\n snapshot->read_section<global_property_object>([&db=this->db,gs_chain_id=genesis->compute_chain_id()]( auto §ion ) {\n v2 legacy_global_properties;\n section.read_row(legacy_global_properties, db);\n\n db.create<global_property_object>([&legacy_global_properties,&gs_chain_id](auto& gpo ){\n gpo.initalize_from(legacy_global_properties, gs_chain_id);\n });\n });\n return; // early out to avoid default processing\n }\n }\n\n snapshot->read_section<value_t>([this]( auto& section ) {\n bool more = !section.empty();\n while(more) {\n decltype(utils)::create(db, [this, §ion, &more]( auto &row ) {\n more = section.read_row(row, db);\n });\n }\n });\n });\n\n read_contract_tables_from_snapshot(snapshot);\n\n authorization.read_from_snapshot(snapshot);\n resource_limits.read_from_snapshot(snapshot);\n\n db.set_revision( head->block_num );\n db.create<database_header_object>([](const auto& header){\n // nothing to do\n });\n\n const auto& gpo = db.get<global_property_object>();\n EOS_ASSERT( gpo.chain_id == chain_id, chain_id_type_exception,\n \"chain ID in snapshot (${snapshot_chain_id}) does not match the chain ID that controller was constructed with (${controller_chain_id})\",\n (\"snapshot_chain_id\", gpo.chain_id)(\"controller_chain_id\", chain_id)\n );\n }\n\n sha256 calculate_integrity_hash() const {\n sha256::encoder enc;\n auto hash_writer = std::make_shared<integrity_hash_snapshot_writer>(enc);\n add_to_snapshot(hash_writer);\n hash_writer->finalize();\n\n return enc.result();\n }\n\n void create_native_account( const fc::time_point& initial_timestamp, account_name name, const authority& owner, const authority& active, bool is_privileged = false ) {\n db.create<account_object>([&](auto& a) {\n a.name = name;\n a.creation_date = initial_timestamp;\n\n if( name == config::system_account_name ) {\n // The initial eosio ABI value affects consensus; see https://github.com/EOSIO/eos/issues/7794\n // TODO: This doesn't charge RAM; a fix requires a consensus upgrade.\n a.abi.resize(sizeof(eosio_abi_bin));\n memcpy(a.abi.data(), eosio_abi_bin, sizeof(eosio_abi_bin));\n }\n });\n db.create<account_metadata_object>([&](auto & a) {\n a.name = name;\n a.set_privileged( is_privileged );\n });\n\n const auto& owner_permission = authorization.create_permission(name, config::owner_name, 0,\n owner, initial_timestamp );\n const auto& active_permission = authorization.create_permission(name, config::active_name, owner_permission.id,\n active, initial_timestamp );\n\n resource_limits.initialize_account(name);\n\n int64_t ram_delta = config::overhead_per_account_ram_bytes;\n ram_delta += 2*config::billable_size_v<permission_object>;\n ram_delta += owner_permission.auth.get_billable_size();\n ram_delta += active_permission.auth.get_billable_size();\n\n resource_limits.add_pending_ram_usage(name, ram_delta);\n resource_limits.verify_account_ram_usage(name);\n }\n\n void initialize_database(const genesis_state& genesis) {\n // create the database header sigil\n db.create<database_header_object>([&]( auto& header ){\n // nothing to do for now\n });\n\n // Initialize block summary index\n for (int i = 0; i < 0x10000; i++)\n db.create<block_summary_object>([&](block_summary_object&) {});\n\n const auto& tapos_block_summary = db.get<block_summary_object>(1);\n db.modify( tapos_block_summary, [&]( auto& bs ) {\n bs.block_id = head->id;\n });\n\n genesis.initial_configuration.validate();\n db.create<global_property_object>([&genesis,&chain_id=this->chain_id](auto& gpo ){\n gpo.configuration = genesis.initial_configuration;\n gpo.chain_id = chain_id;\n });\n\n db.create<protocol_state_object>([&](auto& pso ){\n pso.num_supported_key_types = config::genesis_num_supported_key_types;\n for( const auto& i : genesis_intrinsics ) {\n add_intrinsic_to_whitelist( pso.whitelisted_intrinsics, i );\n }\n });\n\n db.create<dynamic_global_property_object>([](auto&){});\n\n authorization.initialize_database();\n resource_limits.initialize_database();\n\n authority system_auth(genesis.initial_key);\n create_native_account( genesis.initial_timestamp, config::system_account_name, system_auth, system_auth, true );\n\n auto empty_authority = authority(1, {}, {});\n auto active_producers_authority = authority(1, {}, {});\n active_producers_authority.accounts.push_back({{config::system_account_name, config::active_name}, 1});\n\n create_native_account( genesis.initial_timestamp, config::null_account_name, empty_authority, empty_authority );\n create_native_account( genesis.initial_timestamp, config::producers_account_name, empty_authority, active_producers_authority );\n const auto& active_permission = authorization.get_permission({config::producers_account_name, config::active_name});\n const auto& majority_permission = authorization.create_permission( config::producers_account_name,\n config::majority_producers_permission_name,\n active_permission.id,\n active_producers_authority,\n genesis.initial_timestamp );\n const auto& minority_permission = authorization.create_permission( config::producers_account_name,\n config::minority_producers_permission_name,\n majority_permission.id,\n active_producers_authority,\n genesis.initial_timestamp );\n }\n\n // The returned scoped_exit should not exceed the lifetime of the pending which existed when make_block_restore_point was called.\n fc::scoped_exit<std::function<void()>> make_block_restore_point() {\n auto& bb = pending->_block_stage.get<building_block>();\n auto orig_block_transactions_size = bb._pending_trx_receipts.size();\n auto orig_state_transactions_size = bb._pending_trx_metas.size();\n auto orig_state_actions_size = bb._actions.size();\n\n std::function<void()> callback = [this,\n orig_block_transactions_size,\n orig_state_transactions_size,\n orig_state_actions_size]()\n {\n auto& bb = pending->_block_stage.get<building_block>();\n bb._pending_trx_receipts.resize(orig_block_transactions_size);\n bb._pending_trx_metas.resize(orig_state_transactions_size);\n bb._actions.resize(orig_state_actions_size);\n };\n\n return fc::make_scoped_exit( std::move(callback) );\n }\n\n transaction_trace_ptr apply_onerror( const generated_transaction& gtrx,\n fc::time_point deadline,\n fc::time_point start,\n uint32_t& cpu_time_to_bill_us, // only set on failure\n uint32_t billed_cpu_time_us,\n bool explicit_billed_cpu_time = false,\n bool enforce_whiteblacklist = true\n )\n {\n signed_transaction etrx;\n // Deliver onerror action containing the failed deferred transaction directly back to the sender.\n etrx.actions.emplace_back( vector<permission_level>{{gtrx.sender, config::active_name}},\n onerror( gtrx.sender_id, gtrx.packed_trx.data(), gtrx.packed_trx.size() ) );\n if( self.is_builtin_activated( builtin_protocol_feature_t::no_duplicate_deferred_id ) ) {\n etrx.expiration = time_point_sec();\n etrx.ref_block_num = 0;\n etrx.ref_block_prefix = 0;\n } else {\n etrx.expiration = self.pending_block_time() + fc::microseconds(999'999); // Round up to nearest second to avoid appearing expired\n etrx.set_reference_block( self.head_block_id() );\n }\n\n transaction_checktime_timer trx_timer(timer);\n transaction_context trx_context( self, etrx, etrx.id(), std::move(trx_timer), start );\n trx_context.deadline = deadline;\n trx_context.explicit_billed_cpu_time = explicit_billed_cpu_time;\n trx_context.billed_cpu_time_us = billed_cpu_time_us;\n trx_context.enforce_whiteblacklist = enforce_whiteblacklist;\n transaction_trace_ptr trace = trx_context.trace;\n try {\n trx_context.init_for_implicit_trx();\n trx_context.published = gtrx.published;\n trx_context.execute_action( trx_context.schedule_action( etrx.actions.back(), gtrx.sender, false, 0, 0 ), 0 );\n trx_context.finalize(); // Automatically rounds up network and CPU usage in trace and bills payers if successful\n\n auto restore = make_block_restore_point();\n trace->receipt = push_receipt( gtrx.trx_id, transaction_receipt::soft_fail,\n trx_context.billed_cpu_time_us, trace->net_usage );\n fc::move_append( pending->_block_stage.get<building_block>()._actions, move(trx_context.executed) );\n\n trx_context.squash();\n restore.cancel();\n return trace;\n } catch( const disallowed_transaction_extensions_bad_block_exception& ) {\n throw;\n } catch( const protocol_feature_bad_block_exception& ) {\n throw;\n } catch( const fc::exception& e ) {\n cpu_time_to_bill_us = trx_context.update_billed_cpu_time( fc::time_point::now() );\n trace->error_code = controller::convert_exception_to_error_code( e );\n trace->except = e;\n trace->except_ptr = std::current_exception();\n }\n return trace;\n }\n\n int64_t remove_scheduled_transaction( const generated_transaction_object& gto ) {\n int64_t ram_delta = -(config::billable_size_v<generated_transaction_object> + gto.packed_trx.size());\n resource_limits.add_pending_ram_usage( gto.payer, ram_delta );\n // No need to verify_account_ram_usage since we are only reducing memory\n\n db.remove( gto );\n return ram_delta;\n }\n\n bool failure_is_subjective( const fc::exception& e ) const {\n auto code = e.code();\n return (code == subjective_block_production_exception::code_value)\n || (code == block_net_usage_exceeded::code_value)\n || (code == greylist_net_usage_exceeded::code_value)\n || (code == block_cpu_usage_exceeded::code_value)\n || (code == greylist_cpu_usage_exceeded::code_value)\n || (code == deadline_exception::code_value)\n || (code == leeway_deadline_exception::code_value)\n || (code == actor_whitelist_exception::code_value)\n || (code == actor_blacklist_exception::code_value)\n || (code == contract_whitelist_exception::code_value)\n || (code == contract_blacklist_exception::code_value)\n || (code == action_blacklist_exception::code_value)\n || (code == key_blacklist_exception::code_value)\n || (code == sig_variable_size_limit_exception::code_value);\n }\n\n bool scheduled_failure_is_subjective( const fc::exception& e ) const {\n auto code = e.code();\n return (code == tx_cpu_usage_exceeded::code_value)\n || failure_is_subjective(e);\n }\n\n transaction_trace_ptr push_scheduled_transaction( const transaction_id_type& trxid, fc::time_point deadline, uint32_t billed_cpu_time_us, bool explicit_billed_cpu_time = false ) {\n const auto& idx = db.get_index<generated_transaction_multi_index,by_trx_id>();\n auto itr = idx.find( trxid );\n EOS_ASSERT( itr != idx.end(), unknown_transaction_exception, \"unknown transaction\" );\n return push_scheduled_transaction( *itr, deadline, billed_cpu_time_us, explicit_billed_cpu_time );\n }\n\n transaction_trace_ptr push_scheduled_transaction( const generated_transaction_object& gto, fc::time_point deadline, uint32_t billed_cpu_time_us, bool explicit_billed_cpu_time = false )\n { try {\n\n const bool validating = !self.is_producing_block();\n EOS_ASSERT( !validating || explicit_billed_cpu_time, transaction_exception, \"validating requires explicit billing\" );\n\n maybe_session undo_session;\n if ( !self.skip_db_sessions() )\n undo_session = maybe_session(db);\n\n auto gtrx = generated_transaction(gto);\n\n // remove the generated transaction object after making a copy\n // this will ensure that anything which affects the GTO multi-index-container will not invalidate\n // data we need to successfully retire this transaction.\n //\n // IF the transaction FAILs in a subjective way, `undo_session` should expire without being squashed\n // resulting in the GTO being restored and available for a future block to retire.\n int64_t trx_removal_ram_delta = remove_scheduled_transaction(gto);\n\n fc::datastream<const char*> ds( gtrx.packed_trx.data(), gtrx.packed_trx.size() );\n\n EOS_ASSERT( gtrx.delay_until <= self.pending_block_time(), transaction_exception, \"this transaction isn't ready\",\n (\"gtrx.delay_until\",gtrx.delay_until)(\"pbt\",self.pending_block_time()) );\n\n signed_transaction dtrx;\n fc::raw::unpack(ds,static_cast<transaction&>(dtrx) );\n transaction_metadata_ptr trx = transaction_metadata::create_no_recover_keys( packed_transaction( dtrx ), transaction_metadata::trx_type::scheduled );\n trx->accepted = true;\n\n transaction_trace_ptr trace;\n if( gtrx.expiration < self.pending_block_time() ) {\n trace = std::make_shared<transaction_trace>();\n trace->id = gtrx.trx_id;\n trace->block_num = self.head_block_num() + 1;\n trace->block_time = self.pending_block_time();\n trace->producer_block_id = self.pending_producer_block_id();\n trace->scheduled = true;\n trace->receipt = push_receipt( gtrx.trx_id, transaction_receipt::expired, billed_cpu_time_us, 0 ); // expire the transaction\n trace->account_ram_delta = account_delta( gtrx.payer, trx_removal_ram_delta );\n emit( self.accepted_transaction, trx );\n emit( self.applied_transaction, std::tie(trace, dtrx) );\n undo_session.squash();\n return trace;\n }\n\n auto reset_in_trx_requiring_checks = fc::make_scoped_exit([old_value=in_trx_requiring_checks,this](){\n in_trx_requiring_checks = old_value;\n });\n in_trx_requiring_checks = true;\n\n uint32_t cpu_time_to_bill_us = billed_cpu_time_us;\n\n transaction_checktime_timer trx_timer(timer);\n transaction_context trx_context( self, dtrx, gtrx.trx_id, std::move(trx_timer) );\n trx_context.leeway = fc::microseconds(0); // avoid stealing cpu resource\n trx_context.deadline = deadline;\n trx_context.explicit_billed_cpu_time = explicit_billed_cpu_time;\n trx_context.billed_cpu_time_us = billed_cpu_time_us;\n trx_context.enforce_whiteblacklist = gtrx.sender.empty() ? true : !sender_avoids_whitelist_blacklist_enforcement( gtrx.sender );\n trace = trx_context.trace;\n try {\n trx_context.init_for_deferred_trx( gtrx.published );\n\n if( trx_context.enforce_whiteblacklist && pending->_block_status == controller::block_status::incomplete ) {\n flat_set<account_name> actors;\n for( const auto& act : trx_context.trx.actions ) {\n for( const auto& auth : act.authorization ) {\n actors.insert( auth.actor );\n }\n }\n check_actor_list( actors );\n }\n\n trx_context.exec();\n trx_context.finalize(); // Automatically rounds up network and CPU usage in trace and bills payers if successful\n\n auto restore = make_block_restore_point();\n\n trace->receipt = push_receipt( gtrx.trx_id,\n transaction_receipt::executed,\n trx_context.billed_cpu_time_us,\n trace->net_usage );\n\n fc::move_append( pending->_block_stage.get<building_block>()._actions, move(trx_context.executed) );\n\n trace->account_ram_delta = account_delta( gtrx.payer, trx_removal_ram_delta );\n\n emit( self.accepted_transaction, trx );\n emit( self.applied_transaction, std::tie(trace, dtrx) );\n\n trx_context.squash();\n undo_session.squash();\n\n restore.cancel();\n\n return trace;\n } catch( const disallowed_transaction_extensions_bad_block_exception& ) {\n throw;\n } catch( const protocol_feature_bad_block_exception& ) {\n throw;\n } catch( const fc::exception& e ) {\n cpu_time_to_bill_us = trx_context.update_billed_cpu_time( fc::time_point::now() );\n trace->error_code = controller::convert_exception_to_error_code( e );\n trace->except = e;\n trace->except_ptr = std::current_exception();\n trace->elapsed = fc::time_point::now() - trx_context.start;\n }\n trx_context.undo();\n\n // Only subjective OR soft OR hard failure logic below:\n\n if( gtrx.sender != account_name() && !(validating ? failure_is_subjective(*trace->except) : scheduled_failure_is_subjective(*trace->except))) {\n // Attempt error handling for the generated transaction.\n\n auto error_trace = apply_onerror( gtrx, deadline, trx_context.pseudo_start,\n cpu_time_to_bill_us, billed_cpu_time_us, explicit_billed_cpu_time,\n trx_context.enforce_whiteblacklist );\n error_trace->failed_dtrx_trace = trace;\n trace = error_trace;\n if( !trace->except_ptr ) {\n trace->account_ram_delta = account_delta( gtrx.payer, trx_removal_ram_delta );\n emit( self.accepted_transaction, trx );\n emit( self.applied_transaction, std::tie(trace, dtrx) );\n undo_session.squash();\n return trace;\n }\n trace->elapsed = fc::time_point::now() - trx_context.start;\n }\n\n // Only subjective OR hard failure logic below:\n\n // subjectivity changes based on producing vs validating\n bool subjective = false;\n if (validating) {\n subjective = failure_is_subjective(*trace->except);\n } else {\n subjective = scheduled_failure_is_subjective(*trace->except);\n }\n\n if ( !subjective ) {\n // hard failure logic\n\n if( !validating ) {\n auto& rl = self.get_mutable_resource_limits_manager();\n rl.update_account_usage( trx_context.bill_to_accounts, block_timestamp_type(self.pending_block_time()).slot );\n int64_t account_cpu_limit = 0;\n std::tie( std::ignore, account_cpu_limit, std::ignore, std::ignore ) = trx_context.max_bandwidth_billed_accounts_can_pay( true );\n\n uint32_t limited_cpu_time_to_bill_us = static_cast<uint32_t>( std::min(\n std::min( static_cast<int64_t>(cpu_time_to_bill_us), account_cpu_limit ),\n trx_context.initial_objective_duration_limit.count() ) );\n EOS_ASSERT( !explicit_billed_cpu_time || (cpu_time_to_bill_us == limited_cpu_time_to_bill_us),\n transaction_exception, \"cpu to bill ${cpu} != limited ${limit}\", (\"cpu\", cpu_time_to_bill_us)(\"limit\", limited_cpu_time_to_bill_us) );\n cpu_time_to_bill_us = limited_cpu_time_to_bill_us;\n }\n\n resource_limits.add_transaction_usage( trx_context.bill_to_accounts, cpu_time_to_bill_us, 0,\n block_timestamp_type(self.pending_block_time()).slot ); // Should never fail\n\n trace->receipt = push_receipt(gtrx.trx_id, transaction_receipt::hard_fail, cpu_time_to_bill_us, 0);\n trace->account_ram_delta = account_delta( gtrx.payer, trx_removal_ram_delta );\n\n emit( self.accepted_transaction, trx );\n emit( self.applied_transaction, std::tie(trace, dtrx) );\n\n undo_session.squash();\n } else {\n emit( self.accepted_transaction, trx );\n emit( self.applied_transaction, std::tie(trace, dtrx) );\n }\n\n return trace;\n } FC_CAPTURE_AND_RETHROW() } /// push_scheduled_transaction\n\n\n /**\n * Adds the transaction receipt to the pending block and returns it.\n */\n template<typename T>\n const transaction_receipt& push_receipt( const T& trx, transaction_receipt_header::status_enum status,\n uint64_t cpu_usage_us, uint64_t net_usage ) {\n uint64_t net_usage_words = net_usage / 8;\n EOS_ASSERT( net_usage_words*8 == net_usage, transaction_exception, \"net_usage is not divisible by 8\" );\n auto& receipts = pending->_block_stage.get<building_block>()._pending_trx_receipts;\n receipts.emplace_back( trx );\n transaction_receipt& r = receipts.back();\n r.cpu_usage_us = cpu_usage_us;\n r.net_usage_words = net_usage_words;\n r.status = status;\n return r;\n }\n\n /**\n * This is the entry point for new transactions to the block state. It will check authorization and\n * determine whether to execute it now or to delay it. Lastly it inserts a transaction receipt into\n * the pending block.\n */\n transaction_trace_ptr push_transaction( const transaction_metadata_ptr& trx,\n fc::time_point deadline,\n uint32_t billed_cpu_time_us,\n bool explicit_billed_cpu_time )\n {\n EOS_ASSERT(deadline != fc::time_point(), transaction_exception, \"deadline cannot be uninitialized\");\n\n transaction_trace_ptr trace;\n try {\n auto start = fc::time_point::now();\n const bool check_auth = !self.skip_auth_check() && !trx->implicit;\n const fc::microseconds sig_cpu_usage = trx->signature_cpu_usage();\n\n if( !explicit_billed_cpu_time ) {\n fc::microseconds already_consumed_time( EOS_PERCENT(sig_cpu_usage.count(), conf.sig_cpu_bill_pct) );\n\n if( start.time_since_epoch() < already_consumed_time ) {\n start = fc::time_point();\n } else {\n start -= already_consumed_time;\n }\n }\n\n const signed_transaction& trn = trx->packed_trx()->get_signed_transaction();\n transaction_checktime_timer trx_timer(timer);\n transaction_context trx_context(self, trn, trx->id(), std::move(trx_timer), start);\n if ((bool)subjective_cpu_leeway && pending->_block_status == controller::block_status::incomplete) {\n trx_context.leeway = *subjective_cpu_leeway;\n }\n trx_context.deadline = deadline;\n trx_context.explicit_billed_cpu_time = explicit_billed_cpu_time;\n trx_context.billed_cpu_time_us = billed_cpu_time_us;\n trace = trx_context.trace;\n try {\n if( trx->implicit ) {\n trx_context.init_for_implicit_trx();\n trx_context.enforce_whiteblacklist = false;\n } else {\n bool skip_recording = replay_head_time && (time_point(trn.expiration) <= *replay_head_time);\n trx_context.init_for_input_trx( trx->packed_trx()->get_unprunable_size(),\n trx->packed_trx()->get_prunable_size(),\n skip_recording);\n }\n\n trx_context.delay = fc::seconds(trn.delay_sec);\n\n if( check_auth ) {\n authorization.check_authorization(\n trn.actions,\n trx->recovered_keys(),\n {},\n trx_context.delay,\n [&trx_context](){ trx_context.checktime(); },\n false\n );\n }\n trx_context.exec();\n trx_context.finalize(); // Automatically rounds up network and CPU usage in trace and bills payers if successful\n\n auto restore = make_block_restore_point();\n\n if (!trx->implicit) {\n transaction_receipt::status_enum s = (trx_context.delay == fc::seconds(0))\n ? transaction_receipt::executed\n : transaction_receipt::delayed;\n trace->receipt = push_receipt(*trx->packed_trx(), s, trx_context.billed_cpu_time_us, trace->net_usage);\n trx->billed_cpu_time_us = trx_context.billed_cpu_time_us;\n pending->_block_stage.get<building_block>()._pending_trx_metas.emplace_back(trx);\n } else {\n transaction_receipt_header r;\n r.status = transaction_receipt::executed;\n r.cpu_usage_us = trx_context.billed_cpu_time_us;\n r.net_usage_words = trace->net_usage / 8;\n trace->receipt = r;\n }\n\n fc::move_append(pending->_block_stage.get<building_block>()._actions, move(trx_context.executed));\n\n // call the accept signal but only once for this transaction\n if (!trx->accepted) {\n trx->accepted = true;\n emit( self.accepted_transaction, trx);\n }\n\n emit(self.applied_transaction, std::tie(trace, trn));\n\n\n if ( read_mode != db_read_mode::SPECULATIVE && pending->_block_status == controller::block_status::incomplete ) {\n //this may happen automatically in destructor, but I prefere make it more explicit\n trx_context.undo();\n } else {\n restore.cancel();\n trx_context.squash();\n }\n\n return trace;\n } catch( const disallowed_transaction_extensions_bad_block_exception& ) {\n throw;\n } catch( const protocol_feature_bad_block_exception& ) {\n throw;\n } catch (const fc::exception& e) {\n trace->error_code = controller::convert_exception_to_error_code( e );\n trace->except = e;\n trace->except_ptr = std::current_exception();\n }\n\n emit( self.accepted_transaction, trx );\n emit( self.applied_transaction, std::tie(trace, trn) );\n\n return trace;\n } FC_CAPTURE_AND_RETHROW((trace))\n } /// push_transaction\n\n void start_block( block_timestamp_type when,\n uint16_t confirm_block_count,\n const vector<digest_type>& new_protocol_feature_activations,\n controller::block_status s,\n const optional<block_id_type>& producer_block_id )\n {\n EOS_ASSERT( !pending, block_validate_exception, \"pending block already exists\" );\n\n auto guard_pending = fc::make_scoped_exit([this, head_block_num=head->block_num](){\n protocol_features.popped_blocks_to( head_block_num );\n pending.reset();\n });\n\n if (!self.skip_db_sessions(s)) {\n EOS_ASSERT( db.revision() == head->block_num, database_exception, \"db revision is not on par with head block\",\n (\"db.revision()\", db.revision())(\"controller_head_block\", head->block_num)(\"fork_db_head_block\", fork_db.head()->block_num) );\n\n pending.emplace( maybe_session(db), *head, when, confirm_block_count, new_protocol_feature_activations );\n } else {\n pending.emplace( maybe_session(), *head, when, confirm_block_count, new_protocol_feature_activations );\n }\n\n pending->_block_status = s;\n pending->_producer_block_id = producer_block_id;\n\n auto& bb = pending->_block_stage.get<building_block>();\n const auto& pbhs = bb._pending_block_header_state;\n\n // modify state of speculative block only if we are in speculative read mode (otherwise we need clean state for head or read-only modes)\n if ( read_mode == db_read_mode::SPECULATIVE || pending->_block_status != controller::block_status::incomplete )\n {\n const auto& pso = db.get<protocol_state_object>();\n\n auto num_preactivated_protocol_features = pso.preactivated_protocol_features.size();\n bool handled_all_preactivated_features = (num_preactivated_protocol_features == 0);\n\n if( new_protocol_feature_activations.size() > 0 ) {\n flat_map<digest_type, bool> activated_protocol_features;\n activated_protocol_features.reserve( std::max( num_preactivated_protocol_features,\n new_protocol_feature_activations.size() ) );\n for( const auto& feature_digest : pso.preactivated_protocol_features ) {\n activated_protocol_features.emplace( feature_digest, false );\n }\n\n size_t num_preactivated_features_that_have_activated = 0;\n\n const auto& pfs = protocol_features.get_protocol_feature_set();\n for( const auto& feature_digest : new_protocol_feature_activations ) {\n const auto& f = pfs.get_protocol_feature( feature_digest );\n\n auto res = activated_protocol_features.emplace( feature_digest, true );\n if( res.second ) {\n // feature_digest was not preactivated\n EOS_ASSERT( !f.preactivation_required, protocol_feature_exception,\n \"attempted to activate protocol feature without prior required preactivation: ${digest}\",\n (\"digest\", feature_digest)\n );\n } else {\n EOS_ASSERT( !res.first->second, block_validate_exception,\n \"attempted duplicate activation within a single block: ${digest}\",\n (\"digest\", feature_digest)\n );\n // feature_digest was preactivated\n res.first->second = true;\n ++num_preactivated_features_that_have_activated;\n }\n\n if( f.builtin_feature ) {\n trigger_activation_handler( *f.builtin_feature );\n }\n\n protocol_features.activate_feature( feature_digest, pbhs.block_num );\n\n ++bb._num_new_protocol_features_that_have_activated;\n }\n\n if( num_preactivated_features_that_have_activated == num_preactivated_protocol_features ) {\n handled_all_preactivated_features = true;\n }\n }\n\n EOS_ASSERT( handled_all_preactivated_features, block_validate_exception,\n \"There are pre-activated protocol features that were not activated at the start of this block\"\n );\n\n if( new_protocol_feature_activations.size() > 0 ) {\n db.modify( pso, [&]( auto& ps ) {\n ps.preactivated_protocol_features.clear();\n\n ps.activated_protocol_features.reserve( ps.activated_protocol_features.size()\n + new_protocol_feature_activations.size() );\n for( const auto& feature_digest : new_protocol_feature_activations ) {\n ps.activated_protocol_features.emplace_back( feature_digest, pbhs.block_num );\n }\n });\n }\n\n const auto& gpo = db.get<global_property_object>();\n\n if( gpo.proposed_schedule_block_num.valid() && // if there is a proposed schedule that was proposed in a block ...\n ( *gpo.proposed_schedule_block_num <= pbhs.dpos_irreversible_blocknum ) && // ... that has now become irreversible ...\n pbhs.prev_pending_schedule.schedule.producers.size() == 0 // ... and there was room for a new pending schedule prior to any possible promotion\n )\n {\n // Promote proposed schedule to pending schedule.\n if( !replay_head_time ) {\n ilog( \"promoting proposed schedule (set in block ${proposed_num}) to pending; current block: ${n} lib: ${lib} schedule: ${schedule} \",\n (\"proposed_num\", *gpo.proposed_schedule_block_num)(\"n\", pbhs.block_num)\n (\"lib\", pbhs.dpos_irreversible_blocknum)\n (\"schedule\", producer_authority_schedule::from_shared(gpo.proposed_schedule) ) );\n }\n\n EOS_ASSERT( gpo.proposed_schedule.version == pbhs.active_schedule_version + 1,\n producer_schedule_exception, \"wrong producer schedule version specified\" );\n\n pending->_block_stage.get<building_block>()._new_pending_producer_schedule = producer_authority_schedule::from_shared(gpo.proposed_schedule);\n db.modify( gpo, [&]( auto& gp ) {\n gp.proposed_schedule_block_num = optional<block_num_type>();\n gp.proposed_schedule.version=0;\n gp.proposed_schedule.producers.clear();\n });\n }\n\n try {\n transaction_metadata_ptr onbtrx =\n transaction_metadata::create_no_recover_keys( packed_transaction( get_on_block_transaction() ), transaction_metadata::trx_type::implicit );\n auto reset_in_trx_requiring_checks = fc::make_scoped_exit([old_value=in_trx_requiring_checks,this](){\n in_trx_requiring_checks = old_value;\n });\n in_trx_requiring_checks = true;\n push_transaction( onbtrx, fc::time_point::maximum(), self.get_global_properties().configuration.min_transaction_cpu_usage, true );\n } catch( const std::bad_alloc& e ) {\n elog( \"on block transaction failed due to a std::bad_alloc\" );\n throw;\n } catch( const boost::interprocess::bad_alloc& e ) {\n elog( \"on block transaction failed due to a bad allocation\" );\n throw;\n } catch( const fc::exception& e ) {\n wlog( \"on block transaction failed, but shouldn't impact block generation, system contract needs update\" );\n edump((e.to_detail_string()));\n } catch( ... ) {\n elog( \"on block transaction failed due to unknown exception\" );\n }\n\n clear_expired_input_transactions();\n update_producers_authority();\n }\n\n guard_pending.cancel();\n } /// start_block\n\n void finalize_block()\n {\n EOS_ASSERT( pending, block_validate_exception, \"it is not valid to finalize when there is no pending block\");\n EOS_ASSERT( pending->_block_stage.contains<building_block>(), block_validate_exception, \"already called finalize_block\");\n\n try {\n\n auto& pbhs = pending->get_pending_block_header_state();\n\n // Update resource limits:\n resource_limits.process_account_limit_updates();\n const auto& chain_config = self.get_global_properties().configuration;\n uint64_t CPU_TARGET = EOS_PERCENT(chain_config.max_block_cpu_usage, chain_config.target_block_cpu_usage_pct);\n resource_limits.set_block_parameters(\n { CPU_TARGET, chain_config.max_block_cpu_usage, config::block_cpu_usage_average_window_ms / config::block_interval_ms, config::maximum_elastic_resource_multiplier, {99, 100}, {1000, 999}},\n {EOS_PERCENT(chain_config.max_block_net_usage, chain_config.target_block_net_usage_pct), chain_config.max_block_net_usage, config::block_size_average_window_ms / config::block_interval_ms, config::maximum_elastic_resource_multiplier, {99, 100}, {1000, 999}}\n );\n resource_limits.process_block_usage(pbhs.block_num);\n\n auto& bb = pending->_block_stage.get<building_block>();\n\n // Create (unsigned) block:\n auto block_ptr = std::make_shared<signed_block>( pbhs.make_block_header(\n bb._transaction_mroot ? *bb._transaction_mroot : calculate_trx_merkle( bb._pending_trx_receipts ),\n calculate_action_merkle(),\n bb._new_pending_producer_schedule,\n std::move( bb._new_protocol_feature_activations ),\n protocol_features.get_protocol_feature_set()\n ) );\n\n block_ptr->transactions = std::move( bb._pending_trx_receipts );\n\n auto id = block_ptr->id();\n\n // Update TaPoS table:\n create_block_summary( id );\n\n /*\n ilog( \"finalized block ${n} (${id}) at ${t} by ${p} (${signing_key}); schedule_version: ${v} lib: ${lib} #dtrxs: ${ndtrxs} ${np}\",\n (\"n\",pbhs.block_num)\n (\"id\",id)\n (\"t\",pbhs.timestamp)\n (\"p\",pbhs.producer)\n (\"signing_key\", pbhs.block_signing_key)\n (\"v\",pbhs.active_schedule_version)\n (\"lib\",pbhs.dpos_irreversible_blocknum)\n (\"ndtrxs\",db.get_index<generated_transaction_multi_index,by_trx_id>().size())\n (\"np\",block_ptr->new_producers)\n );\n */\n\n pending->_block_stage = assembled_block{\n id,\n std::move( bb._pending_block_header_state ),\n std::move( bb._pending_trx_metas ),\n std::move( block_ptr ),\n std::move( bb._new_pending_producer_schedule )\n };\n } FC_CAPTURE_AND_RETHROW() } /// finalize_block\n\n /**\n * @post regardless of the success of commit block there is no active pending block\n */\n void commit_block( bool add_to_fork_db ) {\n auto reset_pending_on_exit = fc::make_scoped_exit([this]{\n pending.reset();\n });\n\n try {\n EOS_ASSERT( pending->_block_stage.contains<completed_block>(), block_validate_exception,\n \"cannot call commit_block until pending block is completed\" );\n\n auto bsp = pending->_block_stage.get<completed_block>()._block_state;\n\n if( add_to_fork_db ) {\n fork_db.add( bsp );\n fork_db.mark_valid( bsp );\n emit( self.accepted_block_header, bsp );\n head = fork_db.head();\n EOS_ASSERT( bsp == head, fork_database_exception, \"committed block did not become the new head in fork database\");\n }\n\n if( !replay_head_time && read_mode != db_read_mode::IRREVERSIBLE ) {\n reversible_blocks.create<reversible_block_object>( [&]( auto& ubo ) {\n ubo.blocknum = bsp->block_num;\n ubo.set_block( bsp->block );\n });\n }\n\n emit( self.accepted_block, bsp );\n\n if( add_to_fork_db ) {\n log_irreversible();\n }\n } catch (...) {\n // dont bother resetting pending, instead abort the block\n reset_pending_on_exit.cancel();\n abort_block();\n throw;\n }\n\n // push the state for pending.\n pending->push();\n }\n\n /**\n * This method is called from other threads. The controller_impl should outlive those threads.\n * However, to avoid race conditions, it means that the behavior of this function should not change\n * after controller_impl construction.\n\n * This should not be an issue since the purpose of this function is to ensure all of the protocol features\n * in the supplied vector are recognized by the software, and the set of recognized protocol features is\n * determined at startup and cannot be changed without a restart.\n */\n void check_protocol_features( block_timestamp_type timestamp,\n const flat_set<digest_type>& currently_activated_protocol_features,\n const vector<digest_type>& new_protocol_features )\n {\n const auto& pfs = protocol_features.get_protocol_feature_set();\n\n for( auto itr = new_protocol_features.begin(); itr != new_protocol_features.end(); ++itr ) {\n const auto& f = *itr;\n\n auto status = pfs.is_recognized( f, timestamp );\n switch( status ) {\n case protocol_feature_set::recognized_t::unrecognized:\n EOS_THROW( protocol_feature_exception,\n \"protocol feature with digest '${digest}' is unrecognized\", (\"digest\", f) );\n break;\n case protocol_feature_set::recognized_t::disabled:\n EOS_THROW( protocol_feature_exception,\n \"protocol feature with digest '${digest}' is disabled\", (\"digest\", f) );\n break;\n case protocol_feature_set::recognized_t::too_early:\n EOS_THROW( protocol_feature_exception,\n \"${timestamp} is too early for the earliest allowed activation time of the protocol feature with digest '${digest}'\", (\"digest\", f)(\"timestamp\", timestamp) );\n break;\n case protocol_feature_set::recognized_t::ready:\n break;\n default:\n EOS_THROW( protocol_feature_exception, \"unexpected recognized_t status\" );\n break;\n }\n\n EOS_ASSERT( currently_activated_protocol_features.find( f ) == currently_activated_protocol_features.end(),\n protocol_feature_exception,\n \"protocol feature with digest '${digest}' has already been activated\",\n (\"digest\", f)\n );\n\n auto dependency_checker = [¤tly_activated_protocol_features, &new_protocol_features, &itr]\n ( const digest_type& f ) -> bool\n {\n if( currently_activated_protocol_features.find( f ) != currently_activated_protocol_features.end() )\n return true;\n\n return (std::find( new_protocol_features.begin(), itr, f ) != itr);\n };\n\n EOS_ASSERT( pfs.validate_dependencies( f, dependency_checker ), protocol_feature_exception,\n \"not all dependencies of protocol feature with digest '${digest}' have been activated\",\n (\"digest\", f)\n );\n }\n }\n\n void report_block_header_diff( const block_header& b, const block_header& ab ) {\n\n#define EOS_REPORT(DESC,A,B) \\\n if( A != B ) { \\\n elog(\"${desc}: ${bv} != ${abv}\", (\"desc\", DESC)(\"bv\", A)(\"abv\", B)); \\\n }\n\n EOS_REPORT( \"timestamp\", b.timestamp, ab.timestamp )\n EOS_REPORT( \"producer\", b.producer, ab.producer )\n EOS_REPORT( \"confirmed\", b.confirmed, ab.confirmed )\n EOS_REPORT( \"previous\", b.previous, ab.previous )\n EOS_REPORT( \"transaction_mroot\", b.transaction_mroot, ab.transaction_mroot )\n EOS_REPORT( \"action_mroot\", b.action_mroot, ab.action_mroot )\n EOS_REPORT( \"schedule_version\", b.schedule_version, ab.schedule_version )\n EOS_REPORT( \"new_producers\", b.new_producers, ab.new_producers )\n EOS_REPORT( \"header_extensions\", b.header_extensions, ab.header_extensions )\n\n#undef EOS_REPORT\n }\n\n\n void apply_block( const block_state_ptr& bsp, controller::block_status s, const trx_meta_cache_lookup& trx_lookup )\n { try {\n try {\n const signed_block_ptr& b = bsp->block;\n const auto& new_protocol_feature_activations = bsp->get_new_protocol_feature_activations();\n\n auto producer_block_id = b->id();\n start_block( b->timestamp, b->confirmed, new_protocol_feature_activations, s, producer_block_id);\n\n const bool existing_trxs_metas = !bsp->trxs_metas().empty();\n const bool pub_keys_recovered = bsp->is_pub_keys_recovered();\n const bool skip_auth_checks = self.skip_auth_check();\n std::vector<std::tuple<transaction_metadata_ptr, recover_keys_future>> trx_metas;\n bool use_bsp_cached = false;\n if( pub_keys_recovered || (skip_auth_checks && existing_trxs_metas) ) {\n use_bsp_cached = true;\n } else {\n trx_metas.reserve( b->transactions.size() );\n for( const auto& receipt : b->transactions ) {\n if( receipt.trx.contains<packed_transaction>()) {\n const auto& pt = receipt.trx.get<packed_transaction>();\n transaction_metadata_ptr trx_meta_ptr = trx_lookup ? trx_lookup( pt.id() ) : transaction_metadata_ptr{};\n if( trx_meta_ptr && ( skip_auth_checks || !trx_meta_ptr->recovered_keys().empty() ) ) {\n trx_metas.emplace_back( std::move( trx_meta_ptr ), recover_keys_future{} );\n } else if( skip_auth_checks ) {\n trx_metas.emplace_back(\n transaction_metadata::create_no_recover_keys( pt, transaction_metadata::trx_type::input ),\n recover_keys_future{} );\n } else {\n auto ptrx = std::make_shared<packed_transaction>( pt );\n auto fut = transaction_metadata::start_recover_keys(\n std::move( ptrx ), thread_pool.get_executor(), chain_id, microseconds::maximum() );\n trx_metas.emplace_back( transaction_metadata_ptr{}, std::move( fut ) );\n }\n }\n }\n }\n\n transaction_trace_ptr trace;\n\n size_t packed_idx = 0;\n for( const auto& receipt : b->transactions ) {\n const auto& trx_receipts = pending->_block_stage.get<building_block>()._pending_trx_receipts;\n auto num_pending_receipts = trx_receipts.size();\n if( receipt.trx.contains<packed_transaction>() ) {\n const auto& trx_meta = ( use_bsp_cached ? bsp->trxs_metas().at( packed_idx )\n : ( !!std::get<0>( trx_metas.at( packed_idx ) ) ?\n std::get<0>( trx_metas.at( packed_idx ) )\n : std::get<1>( trx_metas.at( packed_idx ) ).get() ) );\n trace = push_transaction( trx_meta, fc::time_point::maximum(), receipt.cpu_usage_us, true );\n ++packed_idx;\n } else if( receipt.trx.contains<transaction_id_type>() ) {\n trace = push_scheduled_transaction( receipt.trx.get<transaction_id_type>(), fc::time_point::maximum(), receipt.cpu_usage_us, true );\n } else {\n EOS_ASSERT( false, block_validate_exception, \"encountered unexpected receipt type\" );\n }\n\n bool transaction_failed = trace && trace->except;\n bool transaction_can_fail = receipt.status == transaction_receipt_header::hard_fail && receipt.trx.contains<transaction_id_type>();\n if( transaction_failed && !transaction_can_fail) {\n edump((*trace));\n throw *trace->except;\n }\n\n EOS_ASSERT( trx_receipts.size() > 0,\n block_validate_exception, \"expected a receipt\",\n (\"block\", *b)(\"expected_receipt\", receipt)\n );\n EOS_ASSERT( trx_receipts.size() == num_pending_receipts + 1,\n block_validate_exception, \"expected receipt was not added\",\n (\"block\", *b)(\"expected_receipt\", receipt)\n );\n const transaction_receipt_header& r = trx_receipts.back();\n EOS_ASSERT( r == static_cast<const transaction_receipt_header&>(receipt),\n block_validate_exception, \"receipt does not match\",\n (\"producer_receipt\", receipt)(\"validator_receipt\", trx_receipts.back()) );\n }\n\n // validated in create_block_state_future()\n pending->_block_stage.get<building_block>()._transaction_mroot = b->transaction_mroot;\n\n finalize_block();\n\n auto& ab = pending->_block_stage.get<assembled_block>();\n\n if( producer_block_id != ab._id ) {\n elog( \"Validation block id does not match producer block id\" );\n report_block_header_diff( *b, *ab._unsigned_block );\n // this implicitly asserts that all header fields (less the signature) are identical\n EOS_ASSERT( producer_block_id == ab._id, block_validate_exception, \"Block ID does not match\",\n (\"producer_block_id\", producer_block_id)(\"validator_block_id\", ab._id) );\n }\n\n if( !use_bsp_cached ) {\n bsp->set_trxs_metas( std::move( ab._trx_metas ), !skip_auth_checks );\n }\n // create completed_block with the existing block_state as we just verified it is the same as assembled_block\n pending->_block_stage = completed_block{ bsp };\n\n commit_block(false);\n return;\n } catch ( const fc::exception& e ) {\n edump((e.to_detail_string()));\n abort_block();\n throw;\n }\n } FC_CAPTURE_AND_RETHROW() } /// apply_block\n\n std::future<block_state_ptr> create_block_state_future( const signed_block_ptr& b ) {\n EOS_ASSERT( b, block_validate_exception, \"null block\" );\n\n auto id = b->id();\n\n // no reason for a block_state if fork_db already knows about block\n auto existing = fork_db.get_block( id );\n EOS_ASSERT( !existing, fork_database_exception, \"we already know about this block: ${id}\", (\"id\", id) );\n\n auto prev = fork_db.get_block_header( b->previous );\n EOS_ASSERT( prev, unlinkable_block_exception,\n \"unlinkable block ${id}\", (\"id\", id)(\"previous\", b->previous) );\n\n return async_thread_pool( thread_pool.get_executor(), [b, prev, control=this]() {\n const bool skip_validate_signee = false;\n\n auto trx_mroot = calculate_trx_merkle( b->transactions );\n EOS_ASSERT( b->transaction_mroot == trx_mroot, block_validate_exception,\n \"invalid block transaction merkle root ${b} != ${c}\", (\"b\", b->transaction_mroot)(\"c\", trx_mroot) );\n\n return std::make_shared<block_state>(\n *prev,\n move( b ),\n control->protocol_features.get_protocol_feature_set(),\n [control]( block_timestamp_type timestamp,\n const flat_set<digest_type>& cur_features,\n const vector<digest_type>& new_features )\n { control->check_protocol_features( timestamp, cur_features, new_features ); },\n skip_validate_signee\n );\n } );\n }\n\n void push_block( std::future<block_state_ptr>& block_state_future,\n const forked_branch_callback& forked_branch_cb, const trx_meta_cache_lookup& trx_lookup )\n {\n controller::block_status s = controller::block_status::complete;\n EOS_ASSERT(!pending, block_validate_exception, \"it is not valid to push a block when there is a pending block\");\n\n auto reset_prod_light_validation = fc::make_scoped_exit([old_value=trusted_producer_light_validation, this]() {\n trusted_producer_light_validation = old_value;\n });\n try {\n block_state_ptr bsp = block_state_future.get();\n const auto& b = bsp->block;\n\n emit( self.pre_accepted_block, b );\n\n fork_db.add( bsp );\n\n if (self.is_trusted_producer(b->producer)) {\n trusted_producer_light_validation = true;\n };\n\n emit( self.accepted_block_header, bsp );\n\n if( read_mode != db_read_mode::IRREVERSIBLE ) {\n maybe_switch_forks( fork_db.pending_head(), s, forked_branch_cb, trx_lookup );\n } else {\n log_irreversible();\n }\n\n } FC_LOG_AND_RETHROW( )\n }\n\n void replay_push_block( const signed_block_ptr& b, controller::block_status s ) {\n self.validate_db_available_size();\n self.validate_reversible_available_size();\n\n EOS_ASSERT(!pending, block_validate_exception, \"it is not valid to push a block when there is a pending block\");\n\n try {\n EOS_ASSERT( b, block_validate_exception, \"trying to push empty block\" );\n EOS_ASSERT( (s == controller::block_status::irreversible || s == controller::block_status::validated),\n block_validate_exception, \"invalid block status for replay\" );\n emit( self.pre_accepted_block, b );\n const bool skip_validate_signee = !conf.force_all_checks;\n\n auto bsp = std::make_shared<block_state>(\n *head,\n b,\n protocol_features.get_protocol_feature_set(),\n [this]( block_timestamp_type timestamp,\n const flat_set<digest_type>& cur_features,\n const vector<digest_type>& new_features )\n { check_protocol_features( timestamp, cur_features, new_features ); },\n skip_validate_signee\n );\n\n if( s != controller::block_status::irreversible ) {\n fork_db.add( bsp, true );\n }\n\n emit( self.accepted_block_header, bsp );\n\n if( s == controller::block_status::irreversible ) {\n apply_block( bsp, s, trx_meta_cache_lookup{} );\n head = bsp;\n\n // On replay, log_irreversible is not called and so no irreversible_block signal is emittted.\n // So emit it explicitly here.\n emit( self.irreversible_block, bsp );\n\n if (!self.skip_db_sessions(s)) {\n db.commit(bsp->block_num);\n }\n\n } else {\n EOS_ASSERT( read_mode != db_read_mode::IRREVERSIBLE, block_validate_exception,\n \"invariant failure: cannot replay reversible blocks while in irreversible mode\" );\n maybe_switch_forks( bsp, s, forked_branch_callback{}, trx_meta_cache_lookup{} );\n }\n\n } FC_LOG_AND_RETHROW( )\n }\n\n void maybe_switch_forks( const block_state_ptr& new_head, controller::block_status s,\n const forked_branch_callback& forked_branch_cb, const trx_meta_cache_lookup& trx_lookup )\n {\n bool head_changed = true;\n if( new_head->header.previous == head->id ) {\n try {\n apply_block( new_head, s, trx_lookup );\n fork_db.mark_valid( new_head );\n head = new_head;\n } catch ( const fc::exception& e ) {\n fork_db.remove( new_head->id );\n throw;\n }\n } else if( new_head->id != head->id ) {\n auto old_head = head;\n ilog(\"switching forks from ${current_head_id} (block number ${current_head_num}) to ${new_head_id} (block number ${new_head_num})\",\n (\"current_head_id\", head->id)(\"current_head_num\", head->block_num)(\"new_head_id\", new_head->id)(\"new_head_num\", new_head->block_num) );\n auto branches = fork_db.fetch_branch_from( new_head->id, head->id );\n\n if( branches.second.size() > 0 ) {\n for( auto itr = branches.second.begin(); itr != branches.second.end(); ++itr ) {\n pop_block();\n }\n EOS_ASSERT( self.head_block_id() == branches.second.back()->header.previous, fork_database_exception,\n \"loss of sync between fork_db and chainbase during fork switch\" ); // _should_ never fail\n\n if( forked_branch_cb ) forked_branch_cb( branches.second );\n }\n\n for( auto ritr = branches.first.rbegin(); ritr != branches.first.rend(); ++ritr ) {\n optional<fc::exception> except;\n try {\n apply_block( *ritr, (*ritr)->is_valid() ? controller::block_status::validated\n : controller::block_status::complete, trx_lookup );\n fork_db.mark_valid( *ritr );\n head = *ritr;\n } catch (const fc::exception& e) {\n except = e;\n }\n if( except ) {\n elog(\"exception thrown while switching forks ${e}\", (\"e\", except->to_detail_string()));\n\n // ritr currently points to the block that threw\n // Remove the block that threw and all forks built off it.\n fork_db.remove( (*ritr)->id );\n\n // pop all blocks from the bad fork, discarding their transactions\n // ritr base is a forward itr to the last block successfully applied\n auto applied_itr = ritr.base();\n for( auto itr = applied_itr; itr != branches.first.end(); ++itr ) {\n pop_block();\n }\n EOS_ASSERT( self.head_block_id() == branches.second.back()->header.previous, fork_database_exception,\n \"loss of sync between fork_db and chainbase during fork switch reversal\" ); // _should_ never fail\n\n // re-apply good blocks\n for( auto ritr = branches.second.rbegin(); ritr != branches.second.rend(); ++ritr ) {\n apply_block( *ritr, controller::block_status::validated /* we previously validated these blocks*/, trx_lookup );\n head = *ritr;\n }\n throw *except;\n } // end if exception\n } /// end for each block in branch\n\n ilog(\"successfully switched fork to new head ${new_head_id}\", (\"new_head_id\", new_head->id));\n } else {\n head_changed = false;\n }\n\n if( head_changed )\n log_irreversible();\n\n } /// push_block\n\n vector<transaction_metadata_ptr> abort_block() {\n vector<transaction_metadata_ptr> applied_trxs;\n if( pending ) {\n applied_trxs = pending->extract_trx_metas();\n pending.reset();\n protocol_features.popped_blocks_to( head->block_num );\n }\n return applied_trxs;\n }\n\n checksum256_type calculate_action_merkle() {\n vector<digest_type> action_digests;\n const auto& actions = pending->_block_stage.get<building_block>()._actions;\n action_digests.reserve( actions.size() );\n for( const auto& a : actions )\n action_digests.emplace_back( a.digest() );\n\n return merkle( move(action_digests) );\n }\n\n static checksum256_type calculate_trx_merkle( const vector<transaction_receipt>& trxs ) {\n vector<digest_type> trx_digests;\n trx_digests.reserve( trxs.size() );\n for( const auto& a : trxs )\n trx_digests.emplace_back( a.digest() );\n\n return merkle( move(trx_digests) );\n }\n\n void update_producers_authority() {\n const auto& producers = pending->get_pending_block_header_state().active_schedule.producers;\n\n auto update_permission = [&]( auto& permission, auto threshold ) {\n auto auth = authority( threshold, {}, {});\n for( auto& p : producers ) {\n auth.accounts.push_back({{p.producer_name, config::active_name}, 1});\n }\n\n if( static_cast<authority>(permission.auth) != auth ) { // TODO: use a more efficient way to check that authority has not changed\n db.modify(permission, [&]( auto& po ) {\n po.auth = auth;\n });\n }\n };\n\n uint32_t num_producers = producers.size();\n auto calculate_threshold = [=]( uint32_t numerator, uint32_t denominator ) {\n return ( (num_producers * numerator) / denominator ) + 1;\n };\n\n update_permission( authorization.get_permission({config::producers_account_name,\n config::active_name}),\n calculate_threshold( 2, 3 ) /* more than two-thirds */ );\n\n update_permission( authorization.get_permission({config::producers_account_name,\n config::majority_producers_permission_name}),\n calculate_threshold( 1, 2 ) /* more than one-half */ );\n\n update_permission( authorization.get_permission({config::producers_account_name,\n config::minority_producers_permission_name}),\n calculate_threshold( 1, 3 ) /* more than one-third */ );\n\n //TODO: Add tests\n }\n\n void create_block_summary(const block_id_type& id) {\n auto block_num = block_header::num_from_id(id);\n auto sid = block_num & 0xffff;\n db.modify( db.get<block_summary_object,by_id>(sid), [&](block_summary_object& bso ) {\n bso.block_id = id;\n });\n }\n\n\n void clear_expired_input_transactions() {\n //Look for expired transactions in the deduplication list, and remove them.\n auto& transaction_idx = db.get_mutable_index<transaction_multi_index>();\n const auto& dedupe_index = transaction_idx.indices().get<by_expiration>();\n auto now = self.pending_block_time();\n while( (!dedupe_index.empty()) && ( now > fc::time_point(dedupe_index.begin()->expiration) ) ) {\n transaction_idx.remove(*dedupe_index.begin());\n }\n }\n\n bool sender_avoids_whitelist_blacklist_enforcement( account_name sender )const {\n if( conf.sender_bypass_whiteblacklist.size() > 0 &&\n ( conf.sender_bypass_whiteblacklist.find( sender ) != conf.sender_bypass_whiteblacklist.end() ) )\n {\n return true;\n }\n\n return false;\n }\n\n void check_actor_list( const flat_set<account_name>& actors )const {\n if( actors.size() == 0 ) return;\n\n if( conf.actor_whitelist.size() > 0 ) {\n // throw if actors is not a subset of whitelist\n const auto& whitelist = conf.actor_whitelist;\n bool is_subset = true;\n\n // quick extents check, then brute force the check actors\n if (*actors.cbegin() >= *whitelist.cbegin() && *actors.crbegin() <= *whitelist.crbegin() ) {\n auto lower_bound = whitelist.cbegin();\n for (const auto& actor: actors) {\n lower_bound = std::lower_bound(lower_bound, whitelist.cend(), actor);\n\n // if the actor is not found, this is not a subset\n if (lower_bound == whitelist.cend() || *lower_bound != actor ) {\n is_subset = false;\n break;\n }\n\n // if the actor was found, we are guaranteed that other actors are either not present in the whitelist\n // or will be present in the range defined as [next actor,end)\n lower_bound = std::next(lower_bound);\n }\n } else {\n is_subset = false;\n }\n\n // helper lambda to lazily calculate the actors for error messaging\n static auto generate_missing_actors = [](const flat_set<account_name>& actors, const flat_set<account_name>& whitelist) -> vector<account_name> {\n vector<account_name> excluded;\n excluded.reserve( actors.size() );\n set_difference( actors.begin(), actors.end(),\n whitelist.begin(), whitelist.end(),\n std::back_inserter(excluded) );\n return excluded;\n };\n\n EOS_ASSERT( is_subset, actor_whitelist_exception,\n \"authorizing actor(s) in transaction are not on the actor whitelist: ${actors}\",\n (\"actors\", generate_missing_actors(actors, whitelist))\n );\n } else if( conf.actor_blacklist.size() > 0 ) {\n // throw if actors intersects blacklist\n const auto& blacklist = conf.actor_blacklist;\n bool intersects = false;\n\n // quick extents check then brute force check actors\n if( *actors.cbegin() <= *blacklist.crbegin() && *actors.crbegin() >= *blacklist.cbegin() ) {\n auto lower_bound = blacklist.cbegin();\n for (const auto& actor: actors) {\n lower_bound = std::lower_bound(lower_bound, blacklist.cend(), actor);\n\n // if the lower bound in the blacklist is at the end, all other actors are guaranteed to\n // not exist in the blacklist\n if (lower_bound == blacklist.cend()) {\n break;\n }\n\n // if the lower bound of an actor IS the actor, then we have an intersection\n if (*lower_bound == actor) {\n intersects = true;\n break;\n }\n }\n }\n\n // helper lambda to lazily calculate the actors for error messaging\n static auto generate_blacklisted_actors = [](const flat_set<account_name>& actors, const flat_set<account_name>& blacklist) -> vector<account_name> {\n vector<account_name> blacklisted;\n blacklisted.reserve( actors.size() );\n set_intersection( actors.begin(), actors.end(),\n blacklist.begin(), blacklist.end(),\n std::back_inserter(blacklisted)\n );\n return blacklisted;\n };\n\n EOS_ASSERT( !intersects, actor_blacklist_exception,\n \"authorizing actor(s) in transaction are on the actor blacklist: ${actors}\",\n (\"actors\", generate_blacklisted_actors(actors, blacklist))\n );\n }\n }\n\n void check_contract_list( account_name code )const {\n if( conf.contract_whitelist.size() > 0 ) {\n EOS_ASSERT( conf.contract_whitelist.find( code ) != conf.contract_whitelist.end(),\n contract_whitelist_exception,\n \"account '${code}' is not on the contract whitelist\", (\"code\", code)\n );\n } else if( conf.contract_blacklist.size() > 0 ) {\n EOS_ASSERT( conf.contract_blacklist.find( code ) == conf.contract_blacklist.end(),\n contract_blacklist_exception,\n \"account '${code}' is on the contract blacklist\", (\"code\", code)\n );\n }\n }\n\n void check_action_list( account_name code, action_name action )const {\n if( conf.action_blacklist.size() > 0 ) {\n EOS_ASSERT( conf.action_blacklist.find( std::make_pair(code, action) ) == conf.action_blacklist.end(),\n action_blacklist_exception,\n \"action '${code}::${action}' is on the action blacklist\",\n (\"code\", code)(\"action\", action)\n );\n }\n }\n\n void check_key_list( const public_key_type& key )const {\n if( conf.key_blacklist.size() > 0 ) {\n EOS_ASSERT( conf.key_blacklist.find( key ) == conf.key_blacklist.end(),\n key_blacklist_exception,\n \"public key '${key}' is on the key blacklist\",\n (\"key\", key)\n );\n }\n }\n\n /*\n bool should_check_tapos()const { return true; }\n\n void validate_tapos( const transaction& trx )const {\n if( !should_check_tapos() ) return;\n\n const auto& tapos_block_summary = db.get<block_summary_object>((uint16_t)trx.ref_block_num);\n\n //Verify TaPoS block summary has correct ID prefix, and that this block's time is not past the expiration\n EOS_ASSERT(trx.verify_reference_block(tapos_block_summary.block_id), invalid_ref_block_exception,\n \"Transaction's reference block did not match. Is this transaction from a different fork?\",\n (\"tapos_summary\", tapos_block_summary));\n }\n */\n\n\n /**\n * At the start of each block we notify the system contract with a transaction that passes in\n * the block header of the prior block (which is currently our head block)\n */\n signed_transaction get_on_block_transaction()\n {\n action on_block_act;\n on_block_act.account = config::system_account_name;\n on_block_act.name = N(onblock);\n on_block_act.authorization = vector<permission_level>{{config::system_account_name, config::active_name}};\n on_block_act.data = fc::raw::pack(self.head_block_header());\n\n signed_transaction trx;\n trx.actions.emplace_back(std::move(on_block_act));\n if( self.is_builtin_activated( builtin_protocol_feature_t::no_duplicate_deferred_id ) ) {\n trx.expiration = time_point_sec();\n trx.ref_block_num = 0;\n trx.ref_block_prefix = 0;\n } else {\n trx.expiration = self.pending_block_time() + fc::microseconds(999'999); // Round up to nearest second to avoid appearing expired\n trx.set_reference_block( self.head_block_id() );\n }\n return trx;\n }\n\n}; /// controller_impl\n\nconst resource_limits_manager& controller::get_resource_limits_manager()const\n{\n return my->resource_limits;\n}\nresource_limits_manager& controller::get_mutable_resource_limits_manager()\n{\n return my->resource_limits;\n}\n\nconst authorization_manager& controller::get_authorization_manager()const\n{\n return my->authorization;\n}\nauthorization_manager& controller::get_mutable_authorization_manager()\n{\n return my->authorization;\n}\n\nconst protocol_feature_manager& controller::get_protocol_feature_manager()const\n{\n return my->protocol_features;\n}\n\ncontroller::controller( const controller::config& cfg, const chain_id_type& chain_id )\n:my( new controller_impl( cfg, *this, protocol_feature_set{}, chain_id ) )\n{\n}\n\ncontroller::controller( const config& cfg, protocol_feature_set&& pfs, const chain_id_type& chain_id )\n:my( new controller_impl( cfg, *this, std::move(pfs), chain_id ) )\n{\n}\n\ncontroller::~controller() {\n my->abort_block();\n /* Shouldn't be needed anymore.\n //close fork_db here, because it can generate \"irreversible\" signal to this controller,\n //in case if read-mode == IRREVERSIBLE, we will apply latest irreversible block\n //for that we need 'my' to be valid pointer pointing to valid controller_impl.\n my->fork_db.close();\n */\n}\n\nvoid controller::add_indices() {\n my->add_indices();\n}\n\nvoid controller::startup( std::function<bool()> shutdown, const snapshot_reader_ptr& snapshot ) {\n my->startup(shutdown, snapshot);\n}\n\nvoid controller::startup( std::function<bool()> shutdown, const genesis_state& genesis ) {\n my->startup(shutdown, genesis);\n}\n\nvoid controller::startup( std::function<bool()> shutdown ) {\n my->startup(shutdown);\n}\n\nconst chainbase::database& controller::db()const { return my->db; }\n\nchainbase::database& controller::mutable_db()const { return my->db; }\n\nconst fork_database& controller::fork_db()const { return my->fork_db; }\n\nvoid controller::preactivate_feature( const digest_type& feature_digest ) {\n const auto& pfs = my->protocol_features.get_protocol_feature_set();\n auto cur_time = pending_block_time();\n\n auto status = pfs.is_recognized( feature_digest, cur_time );\n switch( status ) {\n case protocol_feature_set::recognized_t::unrecognized:\n if( is_producing_block() ) {\n EOS_THROW( subjective_block_production_exception,\n \"protocol feature with digest '${digest}' is unrecognized\", (\"digest\", feature_digest) );\n } else {\n EOS_THROW( protocol_feature_bad_block_exception,\n \"protocol feature with digest '${digest}' is unrecognized\", (\"digest\", feature_digest) );\n }\n break;\n case protocol_feature_set::recognized_t::disabled:\n if( is_producing_block() ) {\n EOS_THROW( subjective_block_production_exception,\n \"protocol feature with digest '${digest}' is disabled\", (\"digest\", feature_digest) );\n } else {\n EOS_THROW( protocol_feature_bad_block_exception,\n \"protocol feature with digest '${digest}' is disabled\", (\"digest\", feature_digest) );\n }\n break;\n case protocol_feature_set::recognized_t::too_early:\n if( is_producing_block() ) {\n EOS_THROW( subjective_block_production_exception,\n \"${timestamp} is too early for the earliest allowed activation time of the protocol feature with digest '${digest}'\", (\"digest\", feature_digest)(\"timestamp\", cur_time) );\n } else {\n EOS_THROW( protocol_feature_bad_block_exception,\n \"${timestamp} is too early for the earliest allowed activation time of the protocol feature with digest '${digest}'\", (\"digest\", feature_digest)(\"timestamp\", cur_time) );\n }\n break;\n case protocol_feature_set::recognized_t::ready:\n break;\n default:\n if( is_producing_block() ) {\n EOS_THROW( subjective_block_production_exception, \"unexpected recognized_t status\" );\n } else {\n EOS_THROW( protocol_feature_bad_block_exception, \"unexpected recognized_t status\" );\n }\n break;\n }\n\n // The above failures depend on subjective information.\n // Because of deferred transactions, this complicates things considerably.\n\n // If producing a block, we throw a subjective failure if the feature is not properly recognized in order\n // to try to avoid retiring into a block a deferred transacton driven by subjective information.\n\n // But it is still possible for a producer to retire a deferred transaction that deals with this subjective\n // information. If they recognized the feature, they would retire it successfully, but a validator that\n // does not recognize the feature should reject the entire block (not just fail the deferred transaction).\n // Even if they don't recognize the feature, the producer could change their nodeos code to treat it like an\n // objective failure thus leading the deferred transaction to retire with soft_fail or hard_fail.\n // In this case, validators that don't recognize the feature would reject the whole block immediately, and\n // validators that do recognize the feature would likely lead to a different retire status which would\n // ultimately cause a validation failure and thus rejection of the block.\n // In either case, it results in rejection of the block which is the desired behavior in this scenario.\n\n // If the feature is properly recognized by producer and validator, we have dealt with the subjectivity and\n // now only consider the remaining failure modes which are deterministic and objective.\n // Thus the exceptions that can be thrown below can be regular objective exceptions\n // that do not cause immediate rejection of the block.\n\n EOS_ASSERT( !is_protocol_feature_activated( feature_digest ),\n protocol_feature_exception,\n \"protocol feature with digest '${digest}' is already activated\",\n (\"digest\", feature_digest)\n );\n\n const auto& pso = my->db.get<protocol_state_object>();\n\n EOS_ASSERT( std::find( pso.preactivated_protocol_features.begin(),\n pso.preactivated_protocol_features.end(),\n feature_digest\n ) == pso.preactivated_protocol_features.end(),\n protocol_feature_exception,\n \"protocol feature with digest '${digest}' is already pre-activated\",\n (\"digest\", feature_digest)\n );\n\n auto dependency_checker = [&]( const digest_type& d ) -> bool\n {\n if( is_protocol_feature_activated( d ) ) return true;\n\n return ( std::find( pso.preactivated_protocol_features.begin(),\n pso.preactivated_protocol_features.end(),\n d ) != pso.preactivated_protocol_features.end() );\n };\n\n EOS_ASSERT( pfs.validate_dependencies( feature_digest, dependency_checker ),\n protocol_feature_exception,\n \"not all dependencies of protocol feature with digest '${digest}' have been activated or pre-activated\",\n (\"digest\", feature_digest)\n );\n\n my->db.modify( pso, [&]( auto& ps ) {\n ps.preactivated_protocol_features.push_back( feature_digest );\n } );\n}\n\nvector<digest_type> controller::get_preactivated_protocol_features()const {\n const auto& pso = my->db.get<protocol_state_object>();\n\n if( pso.preactivated_protocol_features.size() == 0 ) return {};\n\n vector<digest_type> preactivated_protocol_features;\n\n for( const auto& f : pso.preactivated_protocol_features ) {\n preactivated_protocol_features.emplace_back( f );\n }\n\n return preactivated_protocol_features;\n}\n\nvoid controller::validate_protocol_features( const vector<digest_type>& features_to_activate )const {\n my->check_protocol_features( my->head->header.timestamp,\n my->head->activated_protocol_features->protocol_features,\n features_to_activate );\n}\n\nvoid controller::start_block( block_timestamp_type when, uint16_t confirm_block_count )\n{\n validate_db_available_size();\n\n EOS_ASSERT( !my->pending, block_validate_exception, \"pending block already exists\" );\n\n vector<digest_type> new_protocol_feature_activations;\n\n const auto& pso = my->db.get<protocol_state_object>();\n if( pso.preactivated_protocol_features.size() > 0 ) {\n for( const auto& f : pso.preactivated_protocol_features ) {\n new_protocol_feature_activations.emplace_back( f );\n }\n }\n\n if( new_protocol_feature_activations.size() > 0 ) {\n validate_protocol_features( new_protocol_feature_activations );\n }\n\n my->start_block( when, confirm_block_count, new_protocol_feature_activations,\n block_status::incomplete, optional<block_id_type>() );\n}\n\nvoid controller::start_block( block_timestamp_type when,\n uint16_t confirm_block_count,\n const vector<digest_type>& new_protocol_feature_activations )\n{\n validate_db_available_size();\n\n if( new_protocol_feature_activations.size() > 0 ) {\n validate_protocol_features( new_protocol_feature_activations );\n }\n\n my->start_block( when, confirm_block_count, new_protocol_feature_activations,\n block_status::incomplete, optional<block_id_type>() );\n}\n\nblock_state_ptr controller::finalize_block( const signer_callback_type& signer_callback ) {\n validate_db_available_size();\n\n my->finalize_block();\n\n auto& ab = my->pending->_block_stage.get<assembled_block>();\n\n auto bsp = std::make_shared<block_state>(\n std::move( ab._pending_block_header_state ),\n std::move( ab._unsigned_block ),\n std::move( ab._trx_metas ),\n my->protocol_features.get_protocol_feature_set(),\n []( block_timestamp_type timestamp,\n const flat_set<digest_type>& cur_features,\n const vector<digest_type>& new_features )\n {},\n signer_callback\n );\n\n my->pending->_block_stage = completed_block{ bsp };\n\n return bsp;\n}\n\nvoid controller::commit_block() {\n validate_db_available_size();\n validate_reversible_available_size();\n my->commit_block(true);\n}\n\nvector<transaction_metadata_ptr> controller::abort_block() {\n return my->abort_block();\n}\n\nboost::asio::io_context& controller::get_thread_pool() {\n return my->thread_pool.get_executor();\n}\n\nstd::future<block_state_ptr> controller::create_block_state_future( const signed_block_ptr& b ) {\n return my->create_block_state_future( b );\n}\n\nvoid controller::push_block( std::future<block_state_ptr>& block_state_future,\n const forked_branch_callback& forked_branch_cb, const trx_meta_cache_lookup& trx_lookup )\n{\n validate_db_available_size();\n validate_reversible_available_size();\n my->push_block( block_state_future, forked_branch_cb, trx_lookup );\n}\n\ntransaction_trace_ptr controller::push_transaction( const transaction_metadata_ptr& trx, fc::time_point deadline,\n uint32_t billed_cpu_time_us, bool explicit_billed_cpu_time ) {\n validate_db_available_size();\n EOS_ASSERT( get_read_mode() != db_read_mode::IRREVERSIBLE, transaction_type_exception, \"push transaction not allowed in irreversible mode\" );\n EOS_ASSERT( trx && !trx->implicit && !trx->scheduled, transaction_type_exception, \"Implicit/Scheduled transaction not allowed\" );\n return my->push_transaction(trx, deadline, billed_cpu_time_us, explicit_billed_cpu_time );\n}\n\ntransaction_trace_ptr controller::push_scheduled_transaction( const transaction_id_type& trxid, fc::time_point deadline,\n uint32_t billed_cpu_time_us, bool explicit_billed_cpu_time )\n{\n EOS_ASSERT( get_read_mode() != db_read_mode::IRREVERSIBLE, transaction_type_exception, \"push scheduled transaction not allowed in irreversible mode\" );\n validate_db_available_size();\n return my->push_scheduled_transaction( trxid, deadline, billed_cpu_time_us, explicit_billed_cpu_time );\n}\n\nconst flat_set<account_name>& controller::get_actor_whitelist() const {\n return my->conf.actor_whitelist;\n}\nconst flat_set<account_name>& controller::get_actor_blacklist() const {\n return my->conf.actor_blacklist;\n}\nconst flat_set<account_name>& controller::get_contract_whitelist() const {\n return my->conf.contract_whitelist;\n}\nconst flat_set<account_name>& controller::get_contract_blacklist() const {\n return my->conf.contract_blacklist;\n}\nconst flat_set< pair<account_name, action_name> >& controller::get_action_blacklist() const {\n return my->conf.action_blacklist;\n}\nconst flat_set<public_key_type>& controller::get_key_blacklist() const {\n return my->conf.key_blacklist;\n}\n\nvoid controller::set_actor_whitelist( const flat_set<account_name>& new_actor_whitelist ) {\n my->conf.actor_whitelist = new_actor_whitelist;\n}\nvoid controller::set_actor_blacklist( const flat_set<account_name>& new_actor_blacklist ) {\n my->conf.actor_blacklist = new_actor_blacklist;\n}\nvoid controller::set_contract_whitelist( const flat_set<account_name>& new_contract_whitelist ) {\n my->conf.contract_whitelist = new_contract_whitelist;\n}\nvoid controller::set_contract_blacklist( const flat_set<account_name>& new_contract_blacklist ) {\n my->conf.contract_blacklist = new_contract_blacklist;\n}\nvoid controller::set_action_blacklist( const flat_set< pair<account_name, action_name> >& new_action_blacklist ) {\n for (auto& act: new_action_blacklist) {\n EOS_ASSERT(act.first != account_name(), name_type_exception, \"Action blacklist - contract name should not be empty\");\n EOS_ASSERT(act.second != action_name(), action_type_exception, \"Action blacklist - action name should not be empty\");\n }\n my->conf.action_blacklist = new_action_blacklist;\n}\nvoid controller::set_key_blacklist( const flat_set<public_key_type>& new_key_blacklist ) {\n my->conf.key_blacklist = new_key_blacklist;\n}\n\nuint32_t controller::head_block_num()const {\n return my->head->block_num;\n}\ntime_point controller::head_block_time()const {\n return my->head->header.timestamp;\n}\nblock_id_type controller::head_block_id()const {\n return my->head->id;\n}\naccount_name controller::head_block_producer()const {\n return my->head->header.producer;\n}\nconst block_header& controller::head_block_header()const {\n return my->head->header;\n}\nblock_state_ptr controller::head_block_state()const {\n return my->head;\n}\n\nuint32_t controller::fork_db_head_block_num()const {\n return my->fork_db.head()->block_num;\n}\n\nblock_id_type controller::fork_db_head_block_id()const {\n return my->fork_db.head()->id;\n}\n\ntime_point controller::fork_db_head_block_time()const {\n return my->fork_db.head()->header.timestamp;\n}\n\naccount_name controller::fork_db_head_block_producer()const {\n return my->fork_db.head()->header.producer;\n}\n\nuint32_t controller::fork_db_pending_head_block_num()const {\n return my->fork_db.pending_head()->block_num;\n}\n\nblock_id_type controller::fork_db_pending_head_block_id()const {\n return my->fork_db.pending_head()->id;\n}\n\ntime_point controller::fork_db_pending_head_block_time()const {\n return my->fork_db.pending_head()->header.timestamp;\n}\n\naccount_name controller::fork_db_pending_head_block_producer()const {\n return my->fork_db.pending_head()->header.producer;\n}\n\ntime_point controller::pending_block_time()const {\n EOS_ASSERT( my->pending, block_validate_exception, \"no pending block\" );\n\n if( my->pending->_block_stage.contains<completed_block>() )\n return my->pending->_block_stage.get<completed_block>()._block_state->header.timestamp;\n\n return my->pending->get_pending_block_header_state().timestamp;\n}\n\naccount_name controller::pending_block_producer()const {\n EOS_ASSERT( my->pending, block_validate_exception, \"no pending block\" );\n\n if( my->pending->_block_stage.contains<completed_block>() )\n return my->pending->_block_stage.get<completed_block>()._block_state->header.producer;\n\n return my->pending->get_pending_block_header_state().producer;\n}\n\nconst block_signing_authority& controller::pending_block_signing_authority()const {\n EOS_ASSERT( my->pending, block_validate_exception, \"no pending block\" );\n\n if( my->pending->_block_stage.contains<completed_block>() )\n return my->pending->_block_stage.get<completed_block>()._block_state->valid_block_signing_authority;\n\n return my->pending->get_pending_block_header_state().valid_block_signing_authority;\n}\n\noptional<block_id_type> controller::pending_producer_block_id()const {\n EOS_ASSERT( my->pending, block_validate_exception, \"no pending block\" );\n return my->pending->_producer_block_id;\n}\n\nconst vector<transaction_receipt>& controller::get_pending_trx_receipts()const {\n EOS_ASSERT( my->pending, block_validate_exception, \"no pending block\" );\n return my->pending->get_trx_receipts();\n}\n\nuint32_t controller::last_irreversible_block_num() const {\n return my->fork_db.root()->block_num;\n}\n\nblock_id_type controller::last_irreversible_block_id() const {\n auto lib_num = last_irreversible_block_num();\n\n return get_block_id_for_num( lib_num );\n}\n\ntime_point controller::last_irreversible_block_time() const {\n return my->fork_db.root()->header.timestamp.to_time_point();\n}\n\n\nconst dynamic_global_property_object& controller::get_dynamic_global_properties()const {\n return my->db.get<dynamic_global_property_object>();\n}\nconst global_property_object& controller::get_global_properties()const {\n return my->db.get<global_property_object>();\n}\n\nsigned_block_ptr controller::fetch_block_by_id( block_id_type id )const {\n auto state = my->fork_db.get_block(id);\n if( state && state->block ) return state->block;\n auto bptr = fetch_block_by_number( block_header::num_from_id(id) );\n if( bptr && bptr->id() == id ) return bptr;\n return signed_block_ptr();\n}\n\nsigned_block_ptr controller::fetch_block_by_number( uint32_t block_num )const { try {\n auto blk_state = fetch_block_state_by_number( block_num );\n if( blk_state ) {\n return blk_state->block;\n }\n\n return my->blog.read_block_by_num(block_num);\n} FC_CAPTURE_AND_RETHROW( (block_num) ) }\n\nblock_state_ptr controller::fetch_block_state_by_id( block_id_type id )const {\n auto state = my->fork_db.get_block(id);\n return state;\n}\n\nblock_state_ptr controller::fetch_block_state_by_number( uint32_t block_num )const { try {\n const auto& rev_blocks = my->reversible_blocks.get_index<reversible_block_index,by_num>();\n auto objitr = rev_blocks.find(block_num);\n\n if( objitr == rev_blocks.end() ) {\n if( my->read_mode == db_read_mode::IRREVERSIBLE ) {\n return my->fork_db.search_on_branch( my->fork_db.pending_head()->id, block_num );\n } else {\n return block_state_ptr();\n }\n }\n\n return my->fork_db.get_block( objitr->get_block_id() );\n} FC_CAPTURE_AND_RETHROW( (block_num) ) }\n\nblock_id_type controller::get_block_id_for_num( uint32_t block_num )const { try {\n const auto& tapos_block_summary = db().get<block_summary_object>((uint16_t)block_num);\n\n if( block_header::num_from_id(tapos_block_summary.block_id) == block_num )\n return tapos_block_summary.block_id;\n\n const auto& blog_head = my->blog.head();\n\n bool find_in_blog = (blog_head && block_num <= blog_head->block_num());\n\n if( !find_in_blog ) {\n if( my->read_mode != db_read_mode::IRREVERSIBLE ) {\n const auto& rev_blocks = my->reversible_blocks.get_index<reversible_block_index,by_num>();\n auto objitr = rev_blocks.find(block_num);\n if( objitr != rev_blocks.end() ) {\n return objitr->get_block_id();\n }\n } else {\n auto bsp = my->fork_db.search_on_branch( my->fork_db.pending_head()->id, block_num );\n\n if( bsp ) return bsp->id;\n }\n }\n\n auto id = my->blog.read_block_id_by_num(block_num);\n\n EOS_ASSERT( BOOST_LIKELY( id != block_id_type() ), unknown_block_exception,\n \"Could not find block: ${block}\", (\"block\", block_num) );\n\n return id;\n} FC_CAPTURE_AND_RETHROW( (block_num) ) }\n\nsha256 controller::calculate_integrity_hash()const { try {\n return my->calculate_integrity_hash();\n} FC_LOG_AND_RETHROW() }\n\nvoid controller::write_snapshot( const snapshot_writer_ptr& snapshot ) const {\n EOS_ASSERT( !my->pending, block_validate_exception, \"cannot take a consistent snapshot with a pending block\" );\n return my->add_to_snapshot(snapshot);\n}\n\nint64_t controller::set_proposed_producers( vector<producer_authority> producers ) {\n const auto& gpo = get_global_properties();\n auto cur_block_num = head_block_num() + 1;\n\n if( producers.size() == 0 && is_builtin_activated( builtin_protocol_feature_t::disallow_empty_producer_schedule ) ) {\n return -1;\n }\n\n if( gpo.proposed_schedule_block_num.valid() ) {\n if( *gpo.proposed_schedule_block_num != cur_block_num )\n return -1; // there is already a proposed schedule set in a previous block, wait for it to become pending\n\n if( std::equal( producers.begin(), producers.end(),\n gpo.proposed_schedule.producers.begin(), gpo.proposed_schedule.producers.end() ) )\n return -1; // the proposed producer schedule does not change\n }\n\n producer_authority_schedule sch;\n\n decltype(sch.producers.cend()) end;\n decltype(end) begin;\n\n const auto& pending_sch = pending_producers();\n\n if( pending_sch.producers.size() == 0 ) {\n const auto& active_sch = active_producers();\n begin = active_sch.producers.begin();\n end = active_sch.producers.end();\n sch.version = active_sch.version + 1;\n } else {\n begin = pending_sch.producers.begin();\n end = pending_sch.producers.end();\n sch.version = pending_sch.version + 1;\n }\n\n if( std::equal( producers.begin(), producers.end(), begin, end ) )\n return -1; // the producer schedule would not change\n\n sch.producers = std::move(producers);\n\n int64_t version = sch.version;\n\n ilog( \"proposed producer schedule with version ${v}\", (\"v\", version) );\n\n my->db.modify( gpo, [&]( auto& gp ) {\n gp.proposed_schedule_block_num = cur_block_num;\n gp.proposed_schedule = sch.to_shared(gp.proposed_schedule.producers.get_allocator());\n });\n return version;\n}\n\nconst producer_authority_schedule& controller::active_producers()const {\n if( !(my->pending) )\n return my->head->active_schedule;\n\n if( my->pending->_block_stage.contains<completed_block>() )\n return my->pending->_block_stage.get<completed_block>()._block_state->active_schedule;\n\n return my->pending->get_pending_block_header_state().active_schedule;\n}\n\nconst producer_authority_schedule& controller::pending_producers()const {\n if( !(my->pending) )\n return my->head->pending_schedule.schedule;\n\n if( my->pending->_block_stage.contains<completed_block>() )\n return my->pending->_block_stage.get<completed_block>()._block_state->pending_schedule.schedule;\n\n if( my->pending->_block_stage.contains<assembled_block>() ) {\n const auto& new_prods_cache = my->pending->_block_stage.get<assembled_block>()._new_producer_authority_cache;\n if( new_prods_cache ) {\n return *new_prods_cache;\n }\n }\n\n const auto& bb = my->pending->_block_stage.get<building_block>();\n\n if( bb._new_pending_producer_schedule )\n return *bb._new_pending_producer_schedule;\n\n return bb._pending_block_header_state.prev_pending_schedule.schedule;\n}\n\noptional<producer_authority_schedule> controller::proposed_producers()const {\n const auto& gpo = get_global_properties();\n if( !gpo.proposed_schedule_block_num.valid() )\n return optional<producer_authority_schedule>();\n\n return producer_authority_schedule::from_shared(gpo.proposed_schedule);\n}\n\nbool controller::light_validation_allowed(bool replay_opts_disabled_by_policy) const {\n if (!my->pending || my->in_trx_requiring_checks) {\n return false;\n }\n\n const auto pb_status = my->pending->_block_status;\n\n // in a pending irreversible or previously validated block and we have forcing all checks\n const bool consider_skipping_on_replay = (pb_status == block_status::irreversible || pb_status == block_status::validated) && !replay_opts_disabled_by_policy;\n\n // OR in a signed block and in light validation mode\n const bool consider_skipping_on_validate = (pb_status == block_status::complete &&\n (my->conf.block_validation_mode == validation_mode::LIGHT || my->trusted_producer_light_validation));\n\n return consider_skipping_on_replay || consider_skipping_on_validate;\n}\n\n\nbool controller::skip_auth_check() const {\n return light_validation_allowed(my->conf.force_all_checks);\n}\n\nbool controller::skip_db_sessions( block_status bs ) const {\n bool consider_skipping = bs == block_status::irreversible;\n return consider_skipping\n && !my->conf.disable_replay_opts\n && !my->in_trx_requiring_checks;\n}\n\nbool controller::skip_db_sessions( ) const {\n if (my->pending) {\n return skip_db_sessions(my->pending->_block_status);\n } else {\n return false;\n }\n}\n\nbool controller::skip_trx_checks() const {\n return light_validation_allowed(my->conf.disable_replay_opts);\n}\n\nbool controller::is_trusted_producer( const account_name& producer) const {\n return get_validation_mode() == chain::validation_mode::LIGHT || my->conf.trusted_producers.count(producer);\n}\n\nbool controller::contracts_console()const {\n return my->conf.contracts_console;\n}\n\nchain_id_type controller::get_chain_id()const {\n return my->chain_id;\n}\n\ndb_read_mode controller::get_read_mode()const {\n return my->read_mode;\n}\n\nvalidation_mode controller::get_validation_mode()const {\n return my->conf.block_validation_mode;\n}\n\nconst apply_handler* controller::find_apply_handler( account_name receiver, account_name scope, action_name act ) const\n{\n auto native_handler_scope = my->apply_handlers.find( receiver );\n if( native_handler_scope != my->apply_handlers.end() ) {\n auto handler = native_handler_scope->second.find( make_pair( scope, act ) );\n if( handler != native_handler_scope->second.end() )\n return &handler->second;\n }\n return nullptr;\n}\nwasm_interface& controller::get_wasm_interface() {\n return my->wasmif;\n}\n\nconst account_object& controller::get_account( account_name name )const\n{ try {\n return my->db.get<account_object, by_name>(name);\n} FC_CAPTURE_AND_RETHROW( (name) ) }\n\nbool controller::sender_avoids_whitelist_blacklist_enforcement( account_name sender )const {\n return my->sender_avoids_whitelist_blacklist_enforcement( sender );\n}\n\nvoid controller::check_actor_list( const flat_set<account_name>& actors )const {\n my->check_actor_list( actors );\n}\n\nvoid controller::check_contract_list( account_name code )const {\n my->check_contract_list( code );\n}\n\nvoid controller::check_action_list( account_name code, action_name action )const {\n my->check_action_list( code, action );\n}\n\nvoid controller::check_key_list( const public_key_type& key )const {\n my->check_key_list( key );\n}\n\nbool controller::is_building_block()const {\n return my->pending.valid();\n}\n\nbool controller::is_producing_block()const {\n if( !my->pending ) return false;\n\n return (my->pending->_block_status == block_status::incomplete);\n}\n\nbool controller::is_ram_billing_in_notify_allowed()const {\n return my->conf.disable_all_subjective_mitigations || !is_producing_block() || my->conf.allow_ram_billing_in_notify;\n}\n\nuint32_t controller::configured_subjective_signature_length_limit()const {\n return my->conf.maximum_variable_signature_length;\n}\n\nvoid controller::validate_expiration( const transaction& trx )const { try {\n const auto& chain_configuration = get_global_properties().configuration;\n\n EOS_ASSERT( time_point(trx.expiration) >= pending_block_time(),\n expired_tx_exception,\n \"transaction has expired, \"\n \"expiration is ${trx.expiration} and pending block time is ${pending_block_time}\",\n (\"trx.expiration\",trx.expiration)(\"pending_block_time\",pending_block_time()));\n EOS_ASSERT( time_point(trx.expiration) <= pending_block_time() + fc::seconds(chain_configuration.max_transaction_lifetime),\n tx_exp_too_far_exception,\n \"Transaction expiration is too far in the future relative to the reference time of ${reference_time}, \"\n \"expiration is ${trx.expiration} and the maximum transaction lifetime is ${max_til_exp} seconds\",\n (\"trx.expiration\",trx.expiration)(\"reference_time\",pending_block_time())\n (\"max_til_exp\",chain_configuration.max_transaction_lifetime) );\n} FC_CAPTURE_AND_RETHROW((trx)) }\n\nvoid controller::validate_tapos( const transaction& trx )const { try {\n const auto& tapos_block_summary = db().get<block_summary_object>((uint16_t)trx.ref_block_num);\n\n //Verify TaPoS block summary has correct ID prefix, and that this block's time is not past the expiration\n EOS_ASSERT(trx.verify_reference_block(tapos_block_summary.block_id), invalid_ref_block_exception,\n \"Transaction's reference block did not match. Is this transaction from a different fork?\",\n (\"tapos_summary\", tapos_block_summary));\n} FC_CAPTURE_AND_RETHROW() }\n\nvoid controller::validate_db_available_size() const {\n const auto free = db().get_segment_manager()->get_free_memory();\n const auto guard = my->conf.state_guard_size;\n EOS_ASSERT(free >= guard, database_guard_exception, \"database free: ${f}, guard size: ${g}\", (\"f\", free)(\"g\",guard));\n}\n\nvoid controller::validate_reversible_available_size() const {\n const auto free = my->reversible_blocks.get_segment_manager()->get_free_memory();\n const auto guard = my->conf.reversible_guard_size;\n EOS_ASSERT(free >= guard, reversible_guard_exception, \"reversible free: ${f}, guard size: ${g}\", (\"f\", free)(\"g\",guard));\n}\n\nbool controller::is_protocol_feature_activated( const digest_type& feature_digest )const {\n if( my->pending )\n return my->pending->is_protocol_feature_activated( feature_digest );\n\n const auto& activated_features = my->head->activated_protocol_features->protocol_features;\n return (activated_features.find( feature_digest ) != activated_features.end());\n}\n\nbool controller::is_builtin_activated( builtin_protocol_feature_t f )const {\n uint32_t current_block_num = head_block_num();\n\n if( my->pending ) {\n ++current_block_num;\n }\n\n return my->protocol_features.is_builtin_activated( f, current_block_num );\n}\n\nbool controller::is_known_unexpired_transaction( const transaction_id_type& id) const {\n return db().find<transaction_object, by_trx_id>(id);\n}\n\nvoid controller::set_subjective_cpu_leeway(fc::microseconds leeway) {\n my->subjective_cpu_leeway = leeway;\n}\n\nfc::optional<fc::microseconds> controller::get_subjective_cpu_leeway() const {\n return my->subjective_cpu_leeway;\n}\n\nvoid controller::set_greylist_limit( uint32_t limit ) {\n EOS_ASSERT( 0 < limit && limit <= chain::config::maximum_elastic_resource_multiplier,\n misc_exception,\n \"Invalid limit (${limit}) passed into set_greylist_limit. \"\n \"Must be between 1 and ${max}.\",\n (\"limit\", limit)(\"max\", chain::config::maximum_elastic_resource_multiplier)\n );\n my->conf.greylist_limit = limit;\n}\n\nuint32_t controller::get_greylist_limit()const {\n return my->conf.greylist_limit;\n}\n\nvoid controller::add_resource_greylist(const account_name &name) {\n my->conf.resource_greylist.insert(name);\n}\n\nvoid controller::remove_resource_greylist(const account_name &name) {\n my->conf.resource_greylist.erase(name);\n}\n\nbool controller::is_resource_greylisted(const account_name &name) const {\n return my->conf.resource_greylist.find(name) != my->conf.resource_greylist.end();\n}\n\nconst flat_set<account_name> &controller::get_resource_greylist() const {\n return my->conf.resource_greylist;\n}\n\n\nvoid controller::add_to_ram_correction( account_name account, uint64_t ram_bytes ) {\n if( auto ptr = my->db.find<account_ram_correction_object, by_name>( account ) ) {\n my->db.modify<account_ram_correction_object>( *ptr, [&]( auto& rco ) {\n rco.ram_correction += ram_bytes;\n } );\n } else {\n my->db.create<account_ram_correction_object>( [&]( auto& rco ) {\n rco.name = account;\n rco.ram_correction = ram_bytes;\n } );\n }\n}\n\nbool controller::all_subjective_mitigations_disabled()const {\n return my->conf.disable_all_subjective_mitigations;\n}\n\n#if defined(EOSIO_EOS_VM_RUNTIME_ENABLED) || defined(EOSIO_EOS_VM_JIT_RUNTIME_ENABLED)\nvm::wasm_allocator& controller::get_wasm_allocator() {\n return my->wasm_alloc;\n}\n#endif\n\nfc::optional<uint64_t> controller::convert_exception_to_error_code( const fc::exception& e ) {\n const chain_exception* e_ptr = dynamic_cast<const chain_exception*>( &e );\n\n if( e_ptr == nullptr ) return {};\n\n if( !e_ptr->error_code ) return static_cast<uint64_t>(system_error_code::generic_system_error);\n\n return e_ptr->error_code;\n}\n\nchain_id_type controller::extract_chain_id(snapshot_reader& snapshot) {\n chain_snapshot_header header;\n snapshot.read_section<chain_snapshot_header>([&header]( auto §ion ){\n section.read_row(header);\n header.validate();\n });\n\n // check if this is a legacy version of the snapshot, which has a genesis state instead of chain id\n fc::optional<genesis_state> genesis = controller_impl::extract_legacy_genesis_state(snapshot, header.version);\n if (genesis) {\n return genesis->compute_chain_id();\n }\n\n chain_id_type chain_id;\n snapshot.read_section<global_property_object>([&chain_id]( auto §ion ){\n snapshot_global_property_object global_properties;\n section.read_row(global_properties);\n chain_id = global_properties.chain_id;\n });\n return chain_id;\n}\n\nfc::optional<chain_id_type> controller::extract_chain_id_from_db( const path& state_dir ) {\n try {\n chainbase::database db( state_dir, chainbase::database::read_only );\n\n db.add_index<database_header_multi_index>();\n db.add_index<global_property_multi_index>();\n\n controller_impl::validate_db_version( db );\n\n if( db.revision() < 1 ) return {};\n\n return db.get<global_property_object>().chain_id;\n } catch( const bad_database_version_exception& ) {\n throw;\n } catch( ... ) {\n }\n\n return {};\n}\n\n/// Protocol feature activation handlers:\n\ntemplate<>\nvoid controller_impl::on_activation<builtin_protocol_feature_t::preactivate_feature>() {\n db.modify( db.get<protocol_state_object>(), [&]( auto& ps ) {\n add_intrinsic_to_whitelist( ps.whitelisted_intrinsics, \"preactivate_feature\" );\n add_intrinsic_to_whitelist( ps.whitelisted_intrinsics, \"is_feature_activated\" );\n } );\n}\n\ntemplate<>\nvoid controller_impl::on_activation<builtin_protocol_feature_t::get_sender>() {\n db.modify( db.get<protocol_state_object>(), [&]( auto& ps ) {\n add_intrinsic_to_whitelist( ps.whitelisted_intrinsics, \"get_sender\" );\n } );\n}\n\ntemplate<>\nvoid controller_impl::on_activation<builtin_protocol_feature_t::replace_deferred>() {\n const auto& indx = db.get_index<account_ram_correction_index, by_id>();\n for( auto itr = indx.begin(); itr != indx.end(); itr = indx.begin() ) {\n int64_t current_ram_usage = resource_limits.get_account_ram_usage( itr->name );\n int64_t ram_delta = -static_cast<int64_t>(itr->ram_correction);\n if( itr->ram_correction > static_cast<uint64_t>(current_ram_usage) ) {\n ram_delta = -current_ram_usage;\n elog( \"account ${name} was to be reduced by ${adjust} bytes of RAM despite only using ${current} bytes of RAM\",\n (\"name\", itr->name)(\"adjust\", itr->ram_correction)(\"current\", current_ram_usage) );\n }\n\n resource_limits.add_pending_ram_usage( itr->name, ram_delta );\n db.remove( *itr );\n }\n}\n\ntemplate<>\nvoid controller_impl::on_activation<builtin_protocol_feature_t::webauthn_key>() {\n db.modify( db.get<protocol_state_object>(), [&]( auto& ps ) {\n ps.num_supported_key_types = 3;\n } );\n}\n\ntemplate<>\nvoid controller_impl::on_activation<builtin_protocol_feature_t::wtmsig_block_signatures>() {\n db.modify( db.get<protocol_state_object>(), [&]( auto& ps ) {\n add_intrinsic_to_whitelist( ps.whitelisted_intrinsics, \"set_proposed_producers_ex\" );\n } );\n}\n\n\n\n/// End of protocol feature activation handlers\n\n} } /// eosio::chain\n","uri":"file:///home/i/0EXTERNAL/git-repos/eos/libraries/chain/controller.cpp","version":0}}}
I[21:03:00.618] <-- textDocument/didOpen
V[21:03:00.620] <<< {"id":2,"jsonrpc":"2.0","method":"textDocument/documentLink","params":{"textDocument":{"uri":"file:///home/i/0EXTERNAL/git-repos/eos/libraries/chain/controller.cpp"}}}
I[21:03:00.620] <-- textDocument/documentLink(2)
V[21:03:00.620] <<< {"id":3,"jsonrpc":"2.0","method":"textDocument/documentHighlight","params":{"position":{"character":0,"line":0},"textDocument":{"uri":"file:///home/i/0EXTERNAL/git-repos/eos/libraries/chain/controller.cpp"}}}
I[21:03:00.620] <-- textDocument/documentHighlight(3)
I[21:03:00.642] Enqueueing 621 commands for indexing
V[21:03:00.642] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/login_plugin/login_plugin.cpp
V[21:03:00.642] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_isSignalingNaN.c
V[21:03:00.642] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_roundToInt.c
V[21:03:00.642] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_lt_quiet.c
V[21:03:00.642] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_add.c
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_to_i64_r_minMag.c
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/transaction_context.cpp
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE/s_propagateNaNExtF80UI.c
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_lt.c
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/protocol_feature_tests.cpp
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/ui32_to_extF80M.c
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/float_literals.cpp
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/Runtime/Intrinsics.cpp
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_lt_quiet.c
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_eq.c
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/builtins/floatuntidf.c
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/wallet_plugin/yubihsm_wallet.cpp
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chainbase/test/test.cpp
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/elliptic_common.cpp
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/binary-leb128.cpp
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_to_i64.c
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/common.cc
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_mulAdd.c
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_le_quiet.c
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/public_key.cpp
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE/s_f64UIToCommonNaN.c
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_lt_quiet.c
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/f64_cmp.cpp
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/builtins/fixunstfti.c
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_countLeadingZeros64.c
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/IR/Validate.cpp
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/restart_chain_tests.cpp
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_rem.c
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/tests/get_table_tests.cpp
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/abi_serializer.cpp
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE/s_f128UIToCommonNaN.c
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_to_ui32_r_minMag.c
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/whitelisted_intrinsics.cpp
V[21:03:00.643] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_le.c
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/binary-writer-spec.cc
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/prebuilt/wast-lexer-gen.cc
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_roundToInt.c
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_to_i64.c
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_mulAdd.c
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_normSubnormalF128Sig.c
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/chain_id_type.cpp
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/ram_tests.cpp
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/wast_to_wasm.cpp
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/resource_limits.cpp
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/test_control_plugin/test_control_plugin.cpp
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/merkle.cpp
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/block_tests.cpp
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/ui32_to_f64.c
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_sqrt.c
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_sqrt.c
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/Logging/Logging.cpp
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/token.cc
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/programs/keosd/main.cpp
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_to_i64.c
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/testing/tester.cpp
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/const.cpp
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_add256M.c
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/test/static_variant/test_static_variant.cpp
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_to_f32.c
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/wallet_plugin/wallet_manager.cpp
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/yubihsm/common/rand.c
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/signature.cpp
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/expr-visitor.cc
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/stack.cpp
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/city.cpp
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/ui64_to_f128M.c
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/type-checker.cc
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/bigint.cpp
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_to_i32.c
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_eq_signaling.c
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_to_ui64_r_minMag.c
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_to_i32.c
V[21:03:00.644] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/i64_to_extF80M.c
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/apply_context.cpp
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_addMagsExtF80.c
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/base64.cpp
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/state_history_plugin/state_history_plugin_abi.cpp
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/string.cpp
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/io/fstream.cpp
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/chain_config.cpp
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_to_ui32_r_minMag.c
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/f64.cpp
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/ui64_to_extF80M.c
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/color.cc
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/transaction_metadata.cpp
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/utf8.cc
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_le128.c
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_to_f64.c
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_roundToUI32.c
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/tracing.cc
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_eq.c
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_le_quiet.c
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/hash-util.cc
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE/s_commonNaNToF64UI.c
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/binding-hash.cc
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/nop.cpp
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_to_f16.c
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/binary-reader-logging.cc
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_normSubnormalF16Sig.c
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/unwind.cpp
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/ui64_to_f32.c
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/binary.cc
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/block_log.cpp
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_to_f128M.c
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/trace_api_plugin/trace_api_plugin.cpp
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/forked_tests.cpp
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_subMagsExtF80.c
V[21:03:00.645] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/i64_to_f64.c
V[21:03:00.646] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_to_i32_r_minMag.c
V[21:03:00.646] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/builtins/fixdfti.c
V[21:03:00.646] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/protocol_feature_manager.cpp
V[21:03:00.646] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_to_f32.c
V[21:03:00.646] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_roundPackToF64.c
V[21:03:00.650] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/lexer-source-line-finder.cc
V[21:03:00.650] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_isSignalingNaN.c
V[21:03:00.650] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_to_ui64.c
V[21:03:00.650] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/misc_tests.cpp
V[21:03:00.650] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/sha256.cpp
V[21:03:00.650] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/br_table.cpp
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_lt.c
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/log/console_appender.cpp
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/trace_api_plugin/store_provider.cpp
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/wallet_plugin/wallet_plugin.cpp
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/genesis_intrinsics.cpp
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/secp256k1/upstream/src/secp256k1.c
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/payloadless_tests.cpp
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/dh.cpp
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_subMagsF32.c
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_to_f128.c
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_div.c
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/i64_to_extF80.c
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/wallet_plugin/wallet.cpp
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_add.c
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/ui64_to_f16.c
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_le_quiet.c
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/conversions.cpp
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/variant_object.cpp
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_to_i64_r_minMag.c
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_isSignalingNaN.c
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_isSignalingNaN.c
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_to_f128.c
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/block_header.cpp
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_shiftRightJam128Extra.c
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_shortShiftLeft128.c
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/special_accounts_tests.cpp
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_le_quiet.c
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/float_memory.cpp
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/yubihsm/common/hash.c
V[21:03:00.651] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_to_f16.c
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_addMagsF32.c
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/test/io/test_cfile.cpp
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE/softfloat_raiseFlags.c
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/i32_to_extF80.c
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_le.c
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/transaction.cpp
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_le_quiet.c
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_sqrt.c
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/i32_to_f32.c
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_to_f32.c
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/Platform/POSIX.cpp
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_roundToInt.c
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/local_tee.cpp
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_mul128To256M.c
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_normRoundPackToF64.c
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/test/test_base64.cpp
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/log/appender.cpp
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/Runtime/WAVMIntrinsics.cpp
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_shiftRightJam256M.c
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_subMagsF16.c
V[21:03:00.657] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/ui32_to_f128M.c
V[21:03:00.658] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/filesystem.cpp
V[21:03:00.658] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_mulAddF32.c
V[21:03:00.658] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_to_ui64.c
V[21:03:00.658] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_to_f32.c
V[21:03:00.658] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_to_f16.c
V[21:03:00.658] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_to_ui32_r_minMag.c
V[21:03:00.658] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_mul.c
V[21:03:00.658] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/authorization_manager.cpp
V[21:03:00.658] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/WAST/NFA.cpp
V[21:03:00.658] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/binary-reader.cc
V[21:03:00.658] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_eq_signaling.c
V[21:03:00.658] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/currency_tests.cpp
V[21:03:00.658] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/rand.cpp
V[21:03:00.658] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/resource_limits_test.cpp
V[21:03:00.658] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_addMagsF16.c
V[21:03:00.663] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_to_f128.c
V[21:03:00.663] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/state_history_plugin/state_history_plugin.cpp
V[21:03:00.663] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_roundToInt.c
V[21:03:00.663] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_to_ui64.c
V[21:03:00.663] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/resolve-names.cc
V[21:03:00.663] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_to_extF80M.c
V[21:03:00.663] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/binary-reader-interp.cc
V[21:03:00.663] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/i32_to_f16.c
V[21:03:00.663] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_to_f16.c
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/net_plugin/net_plugin.cpp
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE/f128M_isSignalingNaN.c
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/trace_api_plugin/test/test_data_handlers.cpp
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/feature.cc
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/hex.cpp
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/binary.cpp
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_to_ui32.c
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/history_api_plugin/history_api_plugin.cpp
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/align.cpp
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/br_if.cpp
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/break-drop.cpp
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/opcode-code-table.c
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/trace_api_plugin/abi_data_handler.cpp
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/custom.cpp
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_mul.c
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/trace_api_plugin/request_handler.cpp
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/br.cpp
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_to_ui32.c
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/store.cpp
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_eq.c
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/memory_trap.cpp
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_mulAddF16.c
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/f64_bitwise.cpp
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/int_exprs.cpp
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/loop.cpp
V[21:03:00.664] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_to_f128M.c
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_to_f16.c
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/main.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/f32_bitwise.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/protocol_feature_activation.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/address.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_to_ui32.c
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/elliptic_impl_priv.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/io/console.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/platform_timer_posix.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/sha1.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/func.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/func_ptrs.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/aes.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/WASM/WASMSerialization.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/network/url.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/block.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/log/logger.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/programs/eosio-launcher/main.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/openssl.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/i64_to_f128M.c
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_addMagsF128.c
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/_digest_common.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_subMagsF128.c
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/f32.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/WAST/Parse.cpp
V[21:03:00.670] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/yubihsm/lib/tests/test_parsing.c
V[21:03:00.671] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/testing/tester_network.cpp
V[21:03:00.671] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_lt.c
V[21:03:00.671] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/wasm_tests.cpp
V[21:03:00.671] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/wat-writer.cc
V[21:03:00.671] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/tests/wallet_tests.cpp
V[21:03:00.671] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/yubihsm/aes_cmac/aes.c
V[21:03:00.671] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_lt_quiet.c
V[21:03:00.671] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/utf8.cpp
V[21:03:00.671] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_to_i32_r_minMag.c
V[21:03:00.671] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_sub.c
V[21:03:00.671] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/trace_api_plugin/test/test_extraction.cpp
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/database_tests.cpp
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/appbase/examples/main.cpp
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/apply-names.cc
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/float_exprs.cpp
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE/s_commonNaNToF32UI.c
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chainbase/src/pinnable_mapped_file.cpp
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/literal.cc
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/binary-writer.cc
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/network/resolve.cpp
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/webassembly/wabt.cpp
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/call_indirect.cpp
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/opcode.cc
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/unapplied_transaction_queue_tests.cpp
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/wallet_api_plugin/wallet_api_plugin.cpp
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_to_ui32.c
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/i64_to_f128.c
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_sqrt.c
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/snapshot_tests.cpp
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/select.cpp
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_le.c
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_eq_signaling.c
V[21:03:00.676] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_shortShiftRightJam64.c
V[21:03:00.677] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/snapshot.cpp
V[21:03:00.677] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/trace_api_plugin/test/test_configuration_utils.cpp
V[21:03:00.677] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE/s_f16UIToCommonNaN.c
V[21:03:00.677] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_normSubnormalExtF80Sig.c
V[21:03:00.677] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/trace_api_plugin/test/test_trace_file.cpp
V[21:03:00.677] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/base58.cpp
V[21:03:00.677] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/bootseq_tests.cpp
V[21:03:00.677] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_sub.c
V[21:03:00.677] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_roundToI32.c
V[21:03:00.677] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/eosio_contract.cpp
V[21:03:00.677] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/yubihsm/common/pkcs5.c
V[21:03:00.677] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/yubihsm/lib/tests/test_pbkdf2.c
V[21:03:00.677] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_to_i32.c
V[21:03:00.677] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_rem.c
I[21:03:00.646] Updating file /home/i/0EXTERNAL/git-repos/eos/libraries/chain/controller.cpp with command
[/home/i/0EXTERNAL/git-repos/eos/Release/libraries/chain]
/home/i/install/bin/clang++ --driver-mode=g++ -DEOSIO_WABT_RUNTIME_ENABLED -I/home/i/0EXTERNAL/git-repos/eos/libraries/chain/include -I/home/i/0EXTERNAL/git-repos/eos/Release/libraries/chain/include -I/home/i/0EXTERNAL/git-repos/eos/libraries/chain/../wasm-jit/Include -I/home/i/0EXTERNAL/git-repos/eos/libraries/chain/libraries/eos-vm/include -I/home/i/0EXTERNAL/git-repos/eos/libraries/wabt -I/home/i/0EXTERNAL/git-repos/eos/Release/libraries/wabt -I/home/i/0EXTERNAL/git-repos/eos/libraries/fc/include -I/home/i/0EXTERNAL/git-repos/eos/libraries/fc/vendor/websocketpp -I/home/i/0EXTERNAL/git-repos/eos/libraries/fc/secp256k1/upstream -I/home/i/0EXTERNAL/git-repos/eos/libraries/fc/secp256k1/upstream/include -I/home/i/0EXTERNAL/git-repos/eos/libraries/chainbase/include -I/home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/Runtime/../../../chain/include -I/home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/include -I/home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE -I/home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/build/Linux-x86_64-GCC -I/home/i/0EXTERNAL/git-repos/eos/libraries/builtins -I/home/i/0EXTERNAL/git-repos/eos/libraries/builtins../softfloat/source/include -isystem /home/i/2boosts/boost_1_71_0 -Wall -Wno-invalid-partial-specialization -O3 -DNDEBUG -pthread -std=gnu++17 -o CMakeFiles/eosio_chain.dir/controller.cpp.o -c /home/i/0EXTERNAL/git-repos/eos/libraries/chain/controller.cpp -fsyntax-only -resource-dir=/media/i/EXTERNAL/downloads/clangd_10rc3/lib/clang/10.0.0
V[21:03:00.688] Driver produced command: cc1 -cc1 -triple x86_64-unknown-linux-gnu -fsyntax-only -disable-free -disable-llvm-verifier -discard-value-names -main-file-name controller.cpp -mrelocation-model static -mthread-model posix -mframe-pointer=none -fmath-errno -fno-rounding-math -masm-verbose -mconstructor-aliases -munwind-tables -target-cpu x86-64 -dwarf-column-info -fno-split-dwarf-inlining -debugger-tuning=gdb -resource-dir /media/i/EXTERNAL/downloads/clangd_10rc3/lib/clang/10.0.0 -isystem /home/i/2boosts/boost_1_71_0 -D EOSIO_WABT_RUNTIME_ENABLED -I /home/i/0EXTERNAL/git-repos/eos/libraries/chain/include -I /home/i/0EXTERNAL/git-repos/eos/Release/libraries/chain/include -I /home/i/0EXTERNAL/git-repos/eos/libraries/chain/../wasm-jit/Include -I /home/i/0EXTERNAL/git-repos/eos/libraries/chain/libraries/eos-vm/include -I /home/i/0EXTERNAL/git-repos/eos/libraries/wabt -I /home/i/0EXTERNAL/git-repos/eos/Release/libraries/wabt -I /home/i/0EXTERNAL/git-repos/eos/libraries/fc/include -I /home/i/0EXTERNAL/git-repos/eos/libraries/fc/vendor/websocketpp -I /home/i/0EXTERNAL/git-repos/eos/libraries/fc/secp256k1/upstream -I /home/i/0EXTERNAL/git-repos/eos/libraries/fc/secp256k1/upstream/include -I /home/i/0EXTERNAL/git-repos/eos/libraries/chainbase/include -I /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/Runtime/../../../chain/include -I /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/include -I /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE -I /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/build/Linux-x86_64-GCC -I /home/i/0EXTERNAL/git-repos/eos/libraries/builtins -I /home/i/0EXTERNAL/git-repos/eos/libraries/builtins../softfloat/source/include -D NDEBUG -internal-isystem /usr/lib/gcc/x86_64-linux-gnu/7.4.0/../../../../include/c++/7.4.0 -internal-isystem /usr/lib/gcc/x86_64-linux-gnu/7.4.0/../../../../include/x86_64-linux-gnu/c++/7.4.0 -internal-isystem /usr/lib/gcc/x86_64-linux-gnu/7.4.0/../../../../include/x86_64-linux-gnu/c++/7.4.0 -internal-isystem /usr/lib/gcc/x86_64-linux-gnu/7.4.0/../../../../include/c++/7.4.0/backward -internal-isystem /usr/local/include -internal-isystem /media/i/EXTERNAL/downloads/clangd_10rc3/lib/clang/10.0.0/include -internal-externc-isystem /usr/include/x86_64-linux-gnu -internal-externc-isystem /include -internal-externc-isystem /usr/include -O3 -Wall -Wno-invalid-partial-specialization -std=gnu++17 -fdeprecated-macro -fdebug-compilation-dir /home/i/0EXTERNAL/git-repos/eos/Release/libraries/chain -ferror-limit 19 -fmessage-length 0 -pthread -fgnuc-version=4.2.1 -fobjc-runtime=gcc -fcxx-exceptions -fexceptions -fdiagnostics-show-option -vectorize-loops -vectorize-slp -faddrsig -x c++ /home/i/0EXTERNAL/git-repos/eos/libraries/chain/controller.cpp
V[21:03:00.689] Building first preamble for /home/i/0EXTERNAL/git-repos/eos/libraries/chain/controller.cpp
V[21:03:00.688] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/sha224.cpp
V[21:03:00.689] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_to_ui64_r_minMag.c
V[21:03:00.689] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/log/logger_config.cpp
V[21:03:00.689] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/name.cpp
V[21:03:00.689] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_roundToInt.c
V[21:03:00.689] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/elliptic_secp256k1.cpp
V[21:03:00.689] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/controller.cpp
V[21:03:00.689] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/IR/Types.cpp
V[21:03:00.689] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/compress/zlib.cpp
V[21:03:00.690] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_to_f128M.c
V[21:03:00.690] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_mul128By32.c
V[21:03:00.690] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE/s_propagateNaNF64UI.c
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/net_api_plugin/net_api_plugin.cpp
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/block_state.cpp
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/version/src/version.cpp
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/endianness.cpp
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/ui64_to_f128.c
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_lt128.c
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/http_plugin/http_plugin.cpp
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_to_f64.c
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/WAST/Regexp.cpp
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE/s_commonNaNToExtF80UI.c
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/elliptic_r1.cpp
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/eosio_contract_abi.cpp
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_mul.c
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/test/crypto/test_cypher_suites.cpp
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/builtins/fixunsdfti.c
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/appbase/application.cpp
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/float_misc.cpp
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_to_i64.c
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/variant.cpp
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_mulAdd.c
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_to_i64.c
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_mulAdd.c
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_rem.c
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_to_i64_r_minMag.c
V[21:03:00.696] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/interprocess/mmap_struct.cpp
V[21:03:00.697] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/builtins/fixsfti.c
V[21:03:00.697] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/WAST/Print.cpp
V[21:03:00.697] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/network/udp_socket.cpp
V[21:03:00.697] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_mul.c
V[21:03:00.697] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/return.cpp
V[21:03:00.697] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/exception.cpp
V[21:03:00.697] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/error-formatter.cc
V[21:03:00.697] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/db_size_api_plugin/db_size_api_plugin.cpp
V[21:03:00.697] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_eq.c
V[21:03:00.697] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_roundToUI64.c
V[21:03:00.697] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_sqrt.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_shiftRightJam32.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_to_i64_r_minMag.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_to_i32.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_eq_signaling.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/labels.cpp
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/memory_grow.cpp
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/chain_plugin/chain_plugin.cpp
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/ripemd160.cpp
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/WAST/ParseTests.cpp
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_to_extF80M.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/ui64_to_f64.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/yubihsm/aes_cmac/aes_cmac.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/i32_to_f128M.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_mul.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/whitelist_blacklist_tests.cpp
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE/s_f32UIToCommonNaN.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/api_tests.cpp
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/ui64_to_extF80.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/start.cpp
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/io/json.cpp
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_to_f64.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_shortShiftRightJam128.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/wasm_eosio_validation.cpp
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/test/crypto/test_webauthn.cpp
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_isSignalingNaN.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_lt_quiet.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_sub128.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE/s_commonNaNToF128UI.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_to_i32.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/test/network/test_message_buffer.cpp
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/yubihsm/lib/error.c
V[21:03:00.703] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_shiftRightJam128.c
V[21:03:00.704] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_roundToInt.c
V[21:03:00.704] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE/s_commonNaNToF16UI.c
V[21:03:00.704] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/ui32_to_extF80.c
V[21:03:00.709] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_countLeadingZeros32.c
V[21:03:00.709] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/option-parser.cc
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_mulAddF128.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/test_control_api_plugin/test_control_api_plugin.cpp
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_mul.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_to_extF80.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/switch.cpp
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_lt.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/sha512.cpp
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_approxRecip32_1.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_subMagsF64.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_sub.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/yubihsm/lib/yubihsm.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_to_f64.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_to_i32.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/load.cpp
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/left-to-right.cpp
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_le_quiet.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_to_i64_r_minMag.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_to_f128.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE/s_propagateNaNF128UI.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/ui32_to_f32.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_div.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_to_ui32_r_minMag.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/yubihsm/lib/tests/test_usb_url.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_addMagsF64.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_sub.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_add.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/delay_tests.cpp
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/Runtime/ObjectGC.cpp
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_normRoundPackToF128.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_to_i32.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/blowfish.cpp
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE/extF80M_isSignalingNaN.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/i32_to_f64.c
V[21:03:00.710] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_le.c
V[21:03:00.717] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/producer_schedule.cpp
V[21:03:00.717] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_to_f64.c
V[21:03:00.717] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/platform_timer_accuracy.cpp
V[21:03:00.717] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/fork_test_utilities.cpp
V[21:03:00.717] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/log/log_message.cpp
V[21:03:00.717] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/f32_cmp.cpp
V[21:03:00.717] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_countLeadingZeros16.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/WAST/ParseFunction.cpp
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_lt.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/config.cc
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_rem.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/i64.cpp
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/producer_api_plugin/producer_api_plugin.cpp
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE/s_extF80UIToCommonNaN.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/builtins/fixtfti.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_normRoundPackToExtF80.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/fork_database.cpp
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_mulAddF64.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_countLeadingZeros8.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_sub.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_roundPackToF128.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_to_extF80M.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_to_i64_r_minMag.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_to_ui64_r_minMag.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/WAST/ParseNumbers.cpp
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_eq128.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_div.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_to_i32_r_minMag.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_to_f64.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/block.cpp
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_add.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_to_i64_r_minMag.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/WAST/ParseModule.cpp
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_approxRecip_1Ks.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_rem.c
V[21:03:00.718] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/local_get.cpp
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/ui32_to_f16.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/ir.cc
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_shortShiftRightJam128Extra.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/IR/DisassemblyNames.cpp
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_to_f32.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/auth_tests.cpp
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_to_f32.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_eq_signaling.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_to_ui64_r_minMag.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_le.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/main.cpp
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/memory_redundancy.cpp
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/block_timestamp_tests.cpp
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_mul64To128.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_to_i32_r_minMag.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_lt.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_sub.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/wasm_eosio_injection.cpp
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/real128.cpp
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_mul64ByShifted32To128.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_to_ui64.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_rem.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/yubihsm/lib/tests/test_util.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_add128.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_to_ui64.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE/s_propagateNaNF32UI.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/abi_tests.cpp
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/producer_plugin/producer_plugin.cpp
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/tests/chain_plugin_tests.cpp
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/call.cpp
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/i64_to_f32.c
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/type.cpp
V[21:03:00.725] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/generate-names.cc
V[21:03:00.726] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/IR/Operators.cpp
V[21:03:00.726] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/leb128.cc
V[21:03:00.726] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_eq.c
V[21:03:00.733] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_roundPackToF32.c
V[21:03:00.733] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_to_ui64.c
V[21:03:00.733] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_sqrt.c
V[21:03:00.733] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/chain_api_plugin/chain_api_plugin.cpp
V[21:03:00.733] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_to_ui32.c
V[21:03:00.733] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/i32_to_f128.c
V[21:03:00.733] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_lt_quiet.c
V[21:03:00.733] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_normSubnormalF64Sig.c
V[21:03:00.733] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/crc.cpp
V[21:03:00.733] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/producer_schedule_tests.cpp
V[21:03:00.733] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/tests/main.cpp
V[21:03:00.733] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_le.c
V[21:03:00.733] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/test/variant/test_variant.cpp
V[21:03:00.733] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_to_f16.c
V[21:03:00.733] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/network/ip.cpp
V[21:03:00.733] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_to_ui64_r_minMag.c
V[21:03:00.733] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_rem.c
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/yubihsm/lib/yubihsm_usb.c
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/fac.cpp
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/yubihsm/lib/lib_util.c
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/filenames.cc
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/log/gelf_appender.cpp
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/lexer-source.cc
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/unittests/eosio.token_tests.cpp
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/unreachable.cpp
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/wasm_interface.cpp
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_approxRecipSqrt32_1.c
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/trace.cpp
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/private_key.cpp
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/i64_to_f16.c
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_to_i32_r_minMag.c
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_eq.c
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/ui32_to_f128.c
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_le_quiet.c
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chainbase/test/grow_shrink.cpp
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/uint128.cpp
V[21:03:00.734] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/io/varint.cpp
V[21:03:00.740] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/WAST/Lexer.cpp
V[21:03:00.740] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_roundPackToF16.c
V[21:03:00.740] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/block_header_state.cpp
V[21:03:00.740] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/wast-parser.cc
V[21:03:00.740] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/eosio_contract_abi_bin.cpp
V[21:03:00.740] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_eq_signaling.c
V[21:03:00.740] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/forward.cpp
V[21:03:00.740] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/memory.cpp
V[21:03:00.740] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_to_ui64.c
V[21:03:00.740] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_mul.c
V[21:03:00.740] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_eq_signaling.c
V[21:03:00.740] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/thread_utils.cpp
V[21:03:00.740] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/programs/eosio-blocklog/main.cpp
V[21:03:00.740] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_to_ui64_r_minMag.c
V[21:03:00.740] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_roundToInt.c
V[21:03:00.740] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_to_extF80.c
V[21:03:00.740] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_normRoundPackToF32.c
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/binary-reader-ir.cc
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_lt.c
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/builtins/fixunssfti.c
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_div.c
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_roundToI64.c
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/elliptic_webauthn.cpp
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/asset.cpp
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_to_ui32.c
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_add.c
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/builtins/floattidf.c
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_to_i64.c
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_mulAdd.c
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/string-view.cc
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_shortShiftRight128.c
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_to_i32_r_minMag.c
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_to_ui32_r_minMag.c
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/validator.cc
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/time.cpp
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/genesis_state.cpp
V[21:03:00.741] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_eq.c
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/crypto/base36.cpp
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/globals.cpp
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/compress/smaz.cpp
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_to_i32_r_minMag.c
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/programs/nodeos/main.cpp
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/programs/cleos/httpc.cpp
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/http_client_plugin/http_client_plugin.cpp
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_div.c
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_normSubnormalF32Sig.c
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_to_extF80.c
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_le.c
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80M_lt_quiet.c
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_add.c
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_to_ui32.c
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/yubihsm/lib/yubihsm_libusb.c
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_approxRecipSqrt_1Ks.c
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_to_ui32_r_minMag.c
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/Platform/Windows.cpp
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_sqrt.c
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/io/datastream.cpp
V[21:03:00.748] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chain/protocol_state_object.cpp
V[21:03:00.749] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/trace_api_plugin/test/test_responses.cpp
V[21:03:00.749] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_shortShiftRightJam64Extra.c
V[21:03:00.749] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_normRoundPackToF16.c
V[21:03:00.749] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/int_literals.cpp
V[21:03:00.750] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/interp.cc
V[21:03:00.750] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f32_to_extF80.c
V[21:03:00.750] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/if.cpp
V[21:03:00.750] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_to_ui64_r_minMag.c
V[21:03:00.750] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/softfloat_state.c
V[21:03:00.750] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_div.c
V[21:03:00.750] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_shiftRightJam64Extra.c
V[21:03:00.750] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/history_plugin/history_plugin.cpp
V[21:03:00.750] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_add.c
V[21:03:00.750] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/8086-SSE/s_propagateNaNF16UI.c
V[21:03:00.750] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/chainbase/src/chainbase.cpp
V[21:03:00.755] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wabt/src/stream.cc
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_sub256M.c
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/traps.cpp
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/interprocess/file_mapping.cpp
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/i32.cpp
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/yubihsm/lib/yubihsm_curl.c
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/memory_size.cpp
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_shiftRightJam64.c
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/network/platform_root_ca.cpp
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_to_i64.c
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/fc/src/network/http/http_client.cpp
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/wasm-jit/Source/Runtime/Linker.cpp
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_sub.c
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/programs/cleos/main.cpp
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/local_set.cpp
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/plugins/txn_test_gen_plugin/txn_test_gen_plugin.cpp
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128M_to_extF80M.c
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/s_roundPackToExtF80.c
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_to_f128M.c
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/i32_to_extF80M.c
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f64_to_ui32_r_minMag.c
V[21:03:00.756] Failed to load shard: /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/extF80_div.c
V[21:03:00.853] Indexing /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_eq.c (digest:=FB1CE81D7354E185)
I[21:03:00.943] Indexed /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f128_eq.c (459 symbols, 2005 refs, 25 files)
V[21:03:00.970] BackgroundIndex: building version 1 after indexing enough files
V[21:03:00.989] BackgroundIndex: serving version 1 (876084 bytes)
V[21:03:00.989] Indexing /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_to_ui32_r_minMag.c (digest:=6133B899D8D178E7)
I[21:03:01.035] Indexed /home/i/0EXTERNAL/git-repos/eos/libraries/softfloat/source/f16_to_ui32_r_minMag.c (459 symbols, 1945 refs, 25 files)
V[21:03:01.037] Indexing /home/i/0EXTERNAL/git-repos/eos/libraries/chain/asset.cpp (digest:=40A5FF311BCDEBF6)
I[21:03:18.713] Indexed /home/i/0EXTERNAL/git-repos/eos/libraries/chain/asset.cpp (50974 symbols, 211469 refs, 1782 files)
V[21:03:20.218] Indexing /home/i/0EXTERNAL/git-repos/eos/unittests/auth_tests.cpp (digest:=4C530589BF6A351F)
I[21:03:38.413] Indexed /home/i/0EXTERNAL/git-repos/eos/unittests/auth_tests.cpp (62745 symbols, 214145 refs, 2079 files)
V[21:03:38.818] Indexing /home/i/0EXTERNAL/git-repos/eos/eosio-wasm-spec-tests/generated-tests/i32.cpp (digest:=4DD125E8F0E66FD6)
V[21:03:42.743] index AST for /home/i/0EXTERNAL/git-repos/eos/libraries/chain/controller.cpp (main=false):
symbol slab: 80109 symbols, 22784685 bytes
ref slab: 0 symbols, 0 refs, 136 bytes
relations slab: 3610 relations, 69656 bytes
V[21:03:44.182] Built preamble of size 99138000 for file /home/i/0EXTERNAL/git-repos/eos/libraries/chain/controller.cpp
#0 0x00000000004b09e4 PrintStackTrace /home/runner/work/clangd/clangd/llvm-project/llvm/lib/Support/Unix/Signals.inc:564:13
#1 0x00000000004b09e4 PrintStackTraceSignalHandler(void*) /home/runner/work/clangd/clangd/llvm-project/llvm/lib/Support/Unix/Signals.inc:624:3
#2 0x00000000004ae8fc llvm::sys::RunSignalHandlers() /home/runner/work/clangd/clangd/llvm-project/llvm/lib/Support/Signals.cpp:69:18
#3 0x00000000004b0dac SignalHandler(int) /home/runner/work/clangd/clangd/llvm-project/llvm/lib/Support/Unix/Signals.inc:396:3
#4 0x00007fabd8101890 __restore_rt (/lib/x86_64-linux-gnu/libpthread.so.0+0x12890)
#5 0x00000000004e84f6 clang::ASTContext::getTypeInfoImpl(clang::Type const*) const /home/runner/work/clangd/clangd/llvm-project/clang/include/clang/AST/Type.h:0:0
#6 0x00000000004e909d clang::ASTContext::getTypeInfo(clang::Type const*) const /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/ASTContext.cpp:1909:17
#7 0x00000000004e940c clang::ASTContext::getTypeAlignInChars(clang::Type const*) const /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/ASTContext.cpp:2392:30
#8 0x00000000005ff956 VisitUnaryExprOrTypeTraitExpr /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/ExprConstant.cpp:0:0
#9 0x00000000005ff956 clang::StmtVisitorBase<llvm::make_const_ptr, (anonymous namespace)::IntExprEvaluator, bool>::Visit(clang::Stmt const*) /home/runner/work/clangd/clangd/clangd_10rc3/tools/clang/include/clang/AST/StmtNodes.inc:1331:1
#10 0x00000000005d4e13 Evaluate(clang::APValue&, (anonymous namespace)::EvalInfo&, clang::Expr const*) /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/ExprConstant.cpp:13547:9
#11 0x00000000005d71c0 EvaluateAsRValue((anonymous namespace)::EvalInfo&, clang::Expr const*, clang::APValue&) /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/ExprConstant.cpp:13655:9
#12 0x00000000005d6d8e APInt /home/runner/work/clangd/clangd/llvm-project/llvm/include/llvm/ADT/APInt.h:321:44
#13 0x00000000005d6d8e APSInt /home/runner/work/clangd/clangd/llvm-project/llvm/include/llvm/ADT/APSInt.h:21:22
#14 0x00000000005d6d8e clang::Expr::EvaluateKnownConstInt(clang::ASTContext const&, llvm::SmallVectorImpl<std::pair<clang::SourceLocation, clang::PartialDiagnostic> >*) const /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/ExprConstant.cpp:13970:10
#15 0x000000000053c74a isSingleWord /home/runner/work/clangd/clangd/llvm-project/llvm/include/llvm/ADT/APInt.h:114:47
#16 0x000000000053c74a getZExtValue /home/runner/work/clangd/clangd/llvm-project/llvm/include/llvm/ADT/APInt.h:1621:9
#17 0x000000000053c74a clang::AlignedAttr::getAlignment(clang::ASTContext&) const /home/runner/work/clangd/clangd/clangd_10rc3/tools/clang/include/clang/AST/AttrImpl.inc:703:70
#18 0x0000000000585e17 max<unsigned int> /usr/bin/../lib/gcc/x86_64-linux-gnu/9/../../../../include/c++/9/bits/stl_algobase.h:227:15
#19 0x0000000000585e17 clang::Decl::getMaxAlignment() const /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/DeclBase.cpp:394:13
#20 0x00000000006bf574 (anonymous namespace)::ItaniumRecordLayoutBuilder::LayoutField(clang::FieldDecl const*, bool) /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/RecordLayoutBuilder.cpp:1840:33
#21 0x00000000006bac65 (anonymous namespace)::ItaniumRecordLayoutBuilder::LayoutFields(clang::RecordDecl const*) /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/RecordLayoutBuilder.cpp:1383:5
#22 0x00000000006b4fb1 Layout /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/RecordLayoutBuilder.cpp:1321:20
#23 0x00000000006b4fb1 clang::ASTContext::getASTRecordLayout(clang::RecordDecl const*) const /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/RecordLayoutBuilder.cpp:3069:15
#24 0x00000000006b3889 ComputeEmptySubobjectSizes /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/RecordLayoutBuilder.cpp:216:45
#25 0x00000000006b3889 EmptySubobjectMap /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/RecordLayoutBuilder.cpp:171:7
#26 0x00000000006b3889 clang::ASTContext::getASTRecordLayout(clang::RecordDecl const*) const /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/RecordLayoutBuilder.cpp:3067:25
#27 0x00000000004e8555 clang::ASTContext::getTypeInfoImpl(clang::Type const*) const /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/ASTContext.cpp:2246:37
#28 0x00000000004e909d clang::ASTContext::getTypeInfo(clang::Type const*) const /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/ASTContext.cpp:1909:17
#29 0x00000000004e8501 clang::ASTContext::getTypeInfoImpl(clang::Type const*) const /home/runner/work/clangd/clangd/llvm-project/clang/include/clang/AST/Type.h:0:0
#30 0x00000000004e909d clang::ASTContext::getTypeInfo(clang::Type const*) const /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/ASTContext.cpp:1909:17
#31 0x00000000004e8f7e clang::ASTContext::getTypeInfoInChars(clang::Type const*) const /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/ASTContext.cpp:1861:19
#32 0x00000000005e8082 HandleSizeof((anonymous namespace)::EvalInfo&, clang::SourceLocation, clang::QualType, clang::CharUnits&) /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/ExprConstant.cpp:2767:8
#33 0x000000000060004f VisitUnaryExprOrTypeTraitExpr /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/ExprConstant.cpp:12193:9
#34 0x000000000060004f clang::StmtVisitorBase<llvm::make_const_ptr, (anonymous namespace)::IntExprEvaluator, bool>::Visit(clang::Stmt const*) /home/runner/work/clangd/clangd/clangd_10rc3/tools/clang/include/clang/AST/StmtNodes.inc:1331:1
#35 0x00000000005d4e13 Evaluate(clang::APValue&, (anonymous namespace)::EvalInfo&, clang::Expr const*) /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/ExprConstant.cpp:13547:9
#36 0x00000000005d4ad9 clang::Expr::EvaluateAsConstantExpr(clang::Expr::EvalResult&, clang::Expr::ConstExprUsage, clang::ASTContext const&) const /home/runner/work/clangd/clangd/llvm-project/clang/lib/AST/ExprConstant.cpp:13838:43
#37 0x00000000017b7be4 CheckConvertedConstantExpression(clang::Sema&, clang::Expr*, clang::QualType, clang::APValue&, clang::Sema::CCEKind, bool) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/SemaOverload.cpp:5640:69
#38 0x000000000183b007 clang::Sema::CheckTemplateArgument(clang::NonTypeTemplateParmDecl*, clang::QualType, clang::Expr*, clang::TemplateArgument&, clang::Sema::CheckTemplateArgumentKind) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/SemaTemplate.cpp:6682:28
#39 0x0000000001851d96 clang::Sema::CheckTemplateArgument(clang::NamedDecl*, clang::TemplateArgumentLoc&, clang::NamedDecl*, clang::SourceLocation, clang::SourceLocation, unsigned int, llvm::SmallVectorImpl<clang::TemplateArgument>&, clang::Sema::CheckTemplateArgumentKind) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/SemaTemplate.cpp:5165:11
#40 0x00000000018466ae clang::Sema::CheckTemplateArgumentList(clang::TemplateDecl*, clang::SourceLocation, clang::TemplateArgumentListInfo&, bool, llvm::SmallVectorImpl<clang::TemplateArgument>&, bool, bool*) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/SemaTemplate.cpp:5477:11
#41 0x0000000001844d36 clang::Sema::CheckTemplateIdType(clang::TemplateName, clang::SourceLocation, clang::TemplateArgumentListInfo&) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/SemaTemplate.cpp:3439:7
#42 0x0000000001923623 RebuildTemplateSpecializationType /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/TreeTransform.h:13434:18
#43 0x0000000001923623 clang::TreeTransform<(anonymous namespace)::TemplateInstantiator>::TransformTemplateSpecializationType(clang::TypeLocBuilder&, clang::TemplateSpecializationTypeLoc, clang::TemplateName) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/TreeTransform.h:6176:18
#44 0x00000000019224f2 clang::TreeTransform<(anonymous namespace)::TemplateInstantiator>::TransformTSIInObjectScope(clang::TypeLoc, clang::QualType, clang::NamedDecl*, clang::CXXScopeSpec&) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/TreeTransform.h:4572:27
#45 0x0000000001916cf5 TransformTypeInObjectScope /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/TreeTransform.h:4534:7
#46 0x0000000001916cf5 clang::TreeTransform<(anonymous namespace)::TemplateInstantiator>::TransformNestedNameSpecifierLoc(clang::NestedNameSpecifierLoc, clang::QualType, clang::NamedDecl*) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/TreeTransform.h:3808:20
#47 0x000000000192a8a7 operator bool /home/runner/work/clangd/clangd/llvm-project/clang/include/clang/AST/NestedNameSpecifier.h:259:43
#48 0x000000000192a8a7 clang::TreeTransform<(anonymous namespace)::TemplateInstantiator>::TransformDependentNameType(clang::TypeLocBuilder&, clang::DependentNameTypeLoc, bool) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/TreeTransform.h:6430:8
#49 0x0000000001908df2 isNull /home/runner/work/clangd/clangd/llvm-project/llvm/include/llvm/ADT/PointerUnion.h:179:33
#50 0x0000000001908df2 isNull /home/runner/work/clangd/clangd/llvm-project/clang/include/clang/AST/Type.h:720:31
#51 0x0000000001908df2 clang::TreeTransform<(anonymous namespace)::TemplateInstantiator>::TransformType(clang::TypeSourceInfo*) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/TreeTransform.h:4350:14
#52 0x0000000001908b19 clang::Sema::SubstType(clang::TypeSourceInfo*, clang::MultiLevelTemplateArgumentList const&, clang::SourceLocation, clang::DeclarationName, bool) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/SemaTemplateInstantiate.cpp:0:0
#53 0x000000000193aa6d clang::TemplateDeclInstantiator::InstantiateTypedefNameDecl(clang::TypedefNameDecl*, bool) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/SemaTemplateInstantiateDecl.cpp:744:10
#54 0x000000000193c05e clang::TemplateDeclInstantiator::VisitTypedefDecl(clang::TypedefDecl*) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/SemaTemplateInstantiateDecl.cpp:815:19
#55 0x0000000001911073 clang::Sema::InstantiateClass(clang::SourceLocation, clang::CXXRecordDecl*, clang::CXXRecordDecl*, clang::MultiLevelTemplateArgumentList const&, clang::TemplateSpecializationKind, bool) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/SemaTemplateInstantiate.cpp:2652:9
#56 0x00000000019128af clang::Sema::InstantiateClassTemplateSpecialization(clang::SourceLocation, clang::ClassTemplateSpecializationDecl*, clang::TemplateSpecializationKind, bool) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/SemaTemplateInstantiate.cpp:3119:10
#57 0x000000000199866e operator() /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/SemaType.cpp:8169:11
#58 0x000000000199866e void llvm::function_ref<void ()>::callback_fn<clang::Sema::RequireCompleteTypeImpl(clang::SourceLocation, clang::QualType, clang::Sema::TypeDiagnoser*)::$_3>(long) /home/runner/work/clangd/clangd/llvm-project/llvm/include/llvm/ADT/STLExtras.h:108:12
#59 0x000000000130a0eb clang::Sema::runWithSufficientStackSpace(clang::SourceLocation, llvm::function_ref<void ()>) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/Sema.cpp:426:1
#60 0x0000000001988a68 clang::Sema::RequireCompleteTypeImpl(clang::SourceLocation, clang::QualType, clang::Sema::TypeDiagnoser*) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/SemaType.cpp:8197:11
#61 0x0000000001987f7f clang::Sema::RequireCompleteType(clang::SourceLocation, clang::QualType, clang::Sema::TypeDiagnoser&) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/SemaType.cpp:7921:7
#62 0x0000000001974c82 clang::Sema::RequireCompleteType(clang::SourceLocation, clang::QualType, unsigned int) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/SemaType.cpp:8239:1
#63 0x00000000014413bd clang::Sema::CheckFieldDecl(clang::DeclarationName, clang::QualType, clang::TypeSourceInfo*, clang::RecordDecl*, clang::SourceLocation, bool, clang::Expr*, clang::InClassInitStyle, clang::SourceLocation, clang::AccessSpecifier, clang::NamedDecl*, clang::Declarator*) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/SemaDecl.cpp:16148:9
#64 0x00000000014411b4 clang::Sema::HandleField(clang::Scope*, clang::RecordDecl*, clang::SourceLocation, clang::Declarator&, clang::Expr*, clang::InClassInitStyle, clang::AccessSpecifier) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/SemaDecl.cpp:16097:7
#65 0x000000000150e3ce clang::Sema::ActOnCXXMemberDeclarator(clang::Scope*, clang::AccessSpecifier, clang::Declarator&, llvm::MutableArrayRef<clang::TemplateParameterList*>, clang::Expr*, clang::VirtSpecifiers const&, clang::InClassInitStyle) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Sema/SemaDeclCXX.cpp:3347:16
#66 0x0000000001117921 clang::Parser::ParseCXXClassMemberDeclaration(clang::AccessSpecifier, clang::ParsedAttributes&, clang::Parser::ParsedTemplateInfo const&, clang::ParsingDeclRAIIObject*) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/ParseDeclCXX.cpp:2816:26
#67 0x000000000111a008 empty /home/runner/work/clangd/clangd/llvm-project/llvm/include/llvm/ADT/SmallVector.h:55:47
#68 0x000000000111a008 clear /home/runner/work/clangd/clangd/llvm-project/clang/include/clang/Parse/Parser.h:345:20
#69 0x000000000111a008 ~ParenBraceBracketBalancer /home/runner/work/clangd/clangd/llvm-project/clang/include/clang/Parse/RAIIObjectsForParser.h:352:23
#70 0x000000000111a008 clang::Parser::ParseCXXClassMemberDeclarationWithPragmas(clang::AccessSpecifier&, clang::Parser::ParsedAttributesWithRange&, clang::TypeSpecifierType, clang::Decl*) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/ParseDeclCXX.cpp:3159:1
#71 0x0000000001114377 clang::Parser::ParseCXXMemberSpecification(clang::SourceLocation, clang::SourceLocation, clang::Parser::ParsedAttributesWithRange&, unsigned int, clang::Decl*) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/ParseDeclCXX.cpp:3337:7
#72 0x0000000001112067 clang::Parser::ParseClassSpecifier(clang::tok::TokenKind, clang::SourceLocation, clang::DeclSpec&, clang::Parser::ParsedTemplateInfo const&, clang::AccessSpecifier, bool, clang::Parser::DeclSpecContext, clang::Parser::ParsedAttributesWithRange&) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/ParseDeclCXX.cpp:0:7
#73 0x00000000010f3c27 getPointer /home/runner/work/clangd/clangd/llvm-project/llvm/include/llvm/ADT/PointerIntPair.h:59:58
#74 0x00000000010f3c27 isNull /home/runner/work/clangd/clangd/llvm-project/llvm/include/llvm/ADT/PointerUnion.h:179:43
#75 0x00000000010f3c27 empty /home/runner/work/clangd/clangd/llvm-project/llvm/include/llvm/ADT/TinyPtrVector.h:166:13
#76 0x00000000010f3c27 empty /home/runner/work/clangd/clangd/llvm-project/clang/include/clang/Sema/ParsedAttr.h:733:40
#77 0x00000000010f3c27 clang::Parser::ParseDeclarationSpecifiers(clang::DeclSpec&, clang::Parser::ParsedTemplateInfo const&, clang::AccessSpecifier, clang::Parser::DeclSpecContext, clang::Parser::LateParsedAttrList*) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/ParseDecl.cpp:3938:23
#78 0x00000000010ddf5a clang::Parser::ParseDeclOrFunctionDefInternal(clang::Parser::ParsedAttributesWithRange&, clang::ParsingDeclSpec&, clang::AccessSpecifier) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/Parser.cpp:1010:10
#79 0x00000000010ddd25 clang::Parser::ParseDeclarationOrFunctionDefinition(clang::Parser::ParsedAttributesWithRange&, clang::ParsingDeclSpec*, clang::AccessSpecifier) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/Parser.cpp:1115:12
#80 0x00000000010dcd6e clang::Parser::ParseExternalDeclaration(clang::Parser::ParsedAttributesWithRange&, clang::ParsingDeclSpec*) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/Parser.cpp:935:12
#81 0x000000000110b74a ~AttributePool /home/runner/work/clangd/clangd/llvm-project/clang/include/clang/Sema/ParsedAttr.h:629:22
#82 0x000000000110b74a ~ParsedAttributes /home/runner/work/clangd/clangd/llvm-project/clang/include/clang/Sema/ParsedAttr.h:824:7
#83 0x000000000110b74a clang::Parser::ParseInnerNamespace(llvm::SmallVector<clang::Parser::InnerNamespaceInfo, 4u> const&, unsigned int, clang::SourceLocation&, clang::ParsedAttributes&, clang::BalancedDelimiterTracker&) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/ParseDeclCXX.cpp:247:5
#84 0x000000000110b32e Exit /home/runner/work/clangd/clangd/llvm-project/clang/include/clang/Parse/Parser.h:1049:11
#85 0x000000000110b32e clang::Parser::ParseNamespace(clang::DeclaratorContext, clang::SourceLocation&, clang::SourceLocation) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/ParseDeclCXX.cpp:227:18
#86 0x00000000010f336d clang::Parser::ParseDeclaration(clang::DeclaratorContext, clang::SourceLocation&, clang::Parser::ParsedAttributesWithRange&, clang::SourceLocation*) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/ParseDecl.cpp:0:0
#87 0x00000000010dc270 clang::Parser::ParseExternalDeclaration(clang::Parser::ParsedAttributesWithRange&, clang::ParsingDeclSpec*) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/Parser.cpp:0:3
#88 0x000000000110b74a ~AttributePool /home/runner/work/clangd/clangd/llvm-project/clang/include/clang/Sema/ParsedAttr.h:629:22
#89 0x000000000110b74a ~ParsedAttributes /home/runner/work/clangd/clangd/llvm-project/clang/include/clang/Sema/ParsedAttr.h:824:7
#90 0x000000000110b74a clang::Parser::ParseInnerNamespace(llvm::SmallVector<clang::Parser::InnerNamespaceInfo, 4u> const&, unsigned int, clang::SourceLocation&, clang::ParsedAttributes&, clang::BalancedDelimiterTracker&) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/ParseDeclCXX.cpp:247:5
#91 0x000000000110b32e Exit /home/runner/work/clangd/clangd/llvm-project/clang/include/clang/Parse/Parser.h:1049:11
#92 0x000000000110b32e clang::Parser::ParseNamespace(clang::DeclaratorContext, clang::SourceLocation&, clang::SourceLocation) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/ParseDeclCXX.cpp:227:18
#93 0x00000000010f336d clang::Parser::ParseDeclaration(clang::DeclaratorContext, clang::SourceLocation&, clang::Parser::ParsedAttributesWithRange&, clang::SourceLocation*) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/ParseDecl.cpp:0:0
#94 0x00000000010dc270 clang::Parser::ParseExternalDeclaration(clang::Parser::ParsedAttributesWithRange&, clang::ParsingDeclSpec*) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/Parser.cpp:0:3
#95 0x00000000010dae68 clang::Parser::ParseTopLevelDecl(clang::OpaquePtr<clang::DeclGroupRef>&, bool) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/Parser.cpp:686:10
#96 0x00000000010da987 clang::Parser::ParseFirstTopLevelDecl(clang::OpaquePtr<clang::DeclGroupRef>&) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/Parser.cpp:564:26
#97 0x00000000010d6235 clang::ParseAST(clang::Sema&, bool, bool) /home/runner/work/clangd/clangd/llvm-project/clang/lib/Parse/ParseAST.cpp:157:25
#98 0x0000000000f54631 clang::FrontendAction::Execute() /home/runner/work/clangd/clangd/llvm-project/clang/lib/Frontend/FrontendAction.cpp:940:10
#99 0x0000000000999d3f getPtr /home/runner/work/clangd/clangd/llvm-project/llvm/include/llvm/Support/Error.h:273:42
#100 0x0000000000999d3f operator bool /home/runner/work/clangd/clangd/llvm-project/llvm/include/llvm/Support/Error.h:236:16
#101 0x0000000000999d3f clang::clangd::ParsedAST::build(std::unique_ptr<clang::CompilerInvocation, std::default_delete<clang::CompilerInvocation> >, llvm::ArrayRef<clang::clangd::Diag>, std::shared_ptr<clang::clangd::PreambleData const>, std::unique_ptr<llvm::MemoryBuffer, std::default_delete<llvm::MemoryBuffer> >, llvm::IntrusiveRefCntPtr<llvm::vfs::FileSystem>, clang::clangd::SymbolIndex const*, clang::clangd::ParseOptions const&) /home/runner/work/clangd/clangd/llvm-project/clang-tools-extra/clangd/ParsedAST.cpp:366:19
#102 0x000000000099bbcc release /home/runner/work/clangd/clangd/llvm-project/llvm/include/llvm/ADT/IntrusiveRefCntPtr.h:188:9
#103 0x000000000099bbcc ~IntrusiveRefCntPtr /home/runner/work/clangd/clangd/llvm-project/llvm/include/llvm/ADT/IntrusiveRefCntPtr.h:156:27
#104 0x000000000099bbcc clang::clangd::buildAST(llvm::StringRef, std::unique_ptr<clang::CompilerInvocation, std::default_delete<clang::CompilerInvocation> >, llvm::ArrayRef<clang::clangd::Diag>, clang::clangd::ParseInputs const&, std::shared_ptr<clang::clangd::PreambleData const>) /home/runner/work/clangd/cla
Process clangd stderr finished
System information
Output of clangd --version
:
clangd version 10.0.0 (https://github.com/llvm/llvm-project 3a843031a5ad83a00d2603f623881cb2b2bf719d)
Editor/LSP plugin: lsp-mode
Operating system:
i@debord:~$ cat /etc/os-release
NAME="Linux Mint"
VERSION="19.1 (Tessa)"
ID=linuxmint
ID_LIKE=ubuntu
PRETTY_NAME="Linux Mint 19.1"
VERSION_ID="19.1"
HOME_URL="https://www.linuxmint.com/"
SUPPORT_URL="https://forums.ubuntu.com/"
BUG_REPORT_URL="http://linuxmint-troubleshooting-guide.readthedocs.io/en/latest/"
PRIVACY_POLICY_URL="https://www.linuxmint.com/"
VERSION_CODENAME=tessa
UBUNTU_CODENAME=bionic
i@debord:~$
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 28 (4 by maintainers)
Commits related to this issue
- [clang] Persist Attr::IsPackExpansion into the PCH Summary: Fixes https://github.com/clangd/clangd/issues/309 Subscribers: ilya-biryukov, kadircet, usaxena95, cfe-commits Tags: #clang Differential... — committed to arichardson/llvm-project by HighCommander4 4 years ago
- [clang] Persist Attr::IsPackExpansion into the PCH Summary: Fixes https://github.com/clangd/clangd/issues/309 Subscribers: ilya-biryukov, kadircet, usaxena95, cfe-commits Tags: #clang Differential... — committed to llvm/llvm-project by HighCommander4 4 years ago
- [clang] Persist Attr::IsPackExpansion into the PCH Summary: Fixes https://github.com/clangd/clangd/issues/309 Subscribers: ilya-biryukov, kadircet, usaxena95, cfe-commits Tags: #clang Differential... — committed to ajohnson-uoregon/clang-rewrite-only by HighCommander4 4 years ago
- [clang] Persist Attr::IsPackExpansion into the PCH Summary: Fixes https://github.com/clangd/clangd/issues/309 Subscribers: ilya-biryukov, kadircet, usaxena95, cfe-commits Tags: #clang Differential... — committed to draperlaboratory/hope-llvm-project by HighCommander4 4 years ago
This patch fixes the issue for me locally.
(We should keep the issue open until the patch actually lands.)
it shouldn’t
that’s still a lot, ideally you should be able to trim it down to a few constructs, e.g. some template class, with a specialization. but afterwards the idea would be to either squint at the relevant parts of the parser hard enough, attach a debugger and put breakpoints in accordance with the stack trace above, or printf debugging.
that’s also one way to go, you can try getting a clang build at the same revision as the clangd you are using and check whether it crashes while compiling this code with the same compile commands mentioned in clangd’s log. if so, you can even try automated tools like creduce to get a minimal crasher.