Skip to content

Move instruction profiling to a dedicated thread#526

Open
mohitejaikumar wants to merge 1 commit intotxtx:mainfrom
mohitejaikumar:feat/dedicated-profiling-thread
Open

Move instruction profiling to a dedicated thread#526
mohitejaikumar wants to merge 1 commit intotxtx:mainfrom
mohitejaikumar:feat/dedicated-profiling-thread

Conversation

@mohitejaikumar
Copy link

@mohitejaikumar mohitejaikumar commented Feb 8, 2026

Implements #320

  1. Added start_profiling_runloop that spawns a long-lived "Instruction Profiler" thread via hiro_system_kit::thread_named.
  2. ProfilingJob struct - Packages all data needed for profiling (cloned SVM, transaction, accounts, etc.) to send across the thread boundary.
  3. Added Option<Sender<ProfilingJob>> to SurfnetSvm.
  4. Refactored fetch_all_tx_accounts_then_process_tx_returning_profile_res to send profiling jobs to the dedicated thread, execute the transaction on the current thread, then collect profiling results — running both in parallel.
  5. setup_profiling helper - Extracted profiling channel setup into a reusable function called from both start_local_surfnet_runloop and tests.
  6. Added Clone to IndexedLoadedAddresses and TransactionLoadedAddresses to enable moving data into the profiling job.

@mohitejaikumar
Copy link
Author

@lgalabru I’d really appreciate your review and any feedback you may have.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant