Skip to content

feat(tui): add code block and subroutine cycle analysis (v / V) - #4

Merged
mikolas merged 1 commit into
masterfrom
feat/block-cycles
Oct 26, 2026
Merged

mikolas merged 1 commit into
masterfrom
feat/block-cycles

Conversation

@mikolas

@mikolas mikolas commented Oct 26, 2026

Copy link
Copy Markdown
Owner

Summary

  • Range Selection Cycle & Bus Aggregation (v): When selecting a range containing CODE instructions, the SELECT: status bar now displays the total byte span, instruction count, and aggregated MC68000 execution cycles + (R/W) bus words (including min-max ranges for branch/variable-timing instructions).
  • Subroutine Selection & Cycle Analysis (V): Pressing V (Shift+v) selects (or toggles off) the enclosing subroutine from its entry instruction through its final return/tail-call terminator (skipping interior rts/jmp/bra instructions bypassed by forward conditional/unconditional branches).
  • Fix FunctionLabelAddrs(): Exclude CODE_BRANCH xrefs from FunctionLabelAddrs() so local branch target labels (LAB_xxxx) are not misclassified as subroutine starts in V selection or the f Functions modal.
  • Tests & Docs: Added TestBlockAndSubroutineCycles in internal/tui/tui_test.go and updated MANUAL.md and README.md.

Aggregate MC68000 execution cycles and 16-bit bus R/W word counts in the TUI status bar across any selected code range ('v') or the enclosing subroutine ('V' / SelectSubroutine), with branch-skip-aware subroutine boundary detection and CODE_BRANCH filtering in FunctionLabelAddrs.
@mikolas
mikolas merged commit 13bcf0f into master Oct 26, 2026
8 checks passed
@mikolas
mikolas deleted the feat/block-cycles branch October 26, 2026 14:40
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