Skip to content

M68K: fix PC-relative displacements and FTANH/FTST - #3191

Open
b1llow wants to merge 1 commit into
capstone-engine:nextfrom
b1llow:m68k-pcrel-detail
Open

b1llow wants to merge 1 commit into
capstone-engine:nextfrom
b1llow:m68k-pcrel-detail

Conversation

@b1llow

@b1llow b1llow commented Nov 26, 2026

Copy link
Copy Markdown
Contributor

Your checklist for this pull request

  • I've documented or updated the documentation of every API function and struct this PR changes.
  • I've added tests that prove my fix is effective or that my feature works (if possible)

Detailed description

Fix PC-relative displacements and FTANH/FTST

Add m68k_op_mem.pc_offset, the offset from the instruction address to
the first extension word of a PC-relative EA.

Test plan

Closing issues

@codecov

codecov Bot commented Nov 26, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 89.77273% with 9 lines in your changes missing coverage. Please review.
⚠️ Please upload report for BASE (next@2dd0215). Learn more about missing BASE report.

Files with missing lines Patch % Lines
arch/M68K/M68KDisassembler.c 88.37% 1 Missing and 4 partials ⚠️
cstool/cstool_m68k.c 0.00% 3 Missing ⚠️
suite/cstest/src/test_detail_m68k.c 66.66% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             next    #3191   +/-   ##
=======================================
  Coverage        ?   61.93%           
=======================================
  Files           ?      243           
  Lines           ?    56976           
  Branches        ?    10151           
=======================================
  Hits            ?    35290           
  Misses          ?    16485           
  Partials        ?     5201           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Comment thread arch/M68K/M68KInstPrinter.c Resolved
Comment thread arch/M68K/M68KDisassembler.c Resolved
Comment thread arch/M68K/M68KDisassembler.c Resolved
Comment thread arch/M68K/M68KDisassembler.c Resolved
Comment thread arch/M68K/M68KInstPrinter.c Resolved
Comment thread arch/M68K/M68KDisassembler.c Resolved
Comment thread arch/M68K/M68KDisassembler.c Resolved
Comment thread arch/M68K/M68KDisassembler.c Resolved
Comment thread arch/M68K/M68KDisassembler.c Resolved
Comment thread tests/details/m68k.yaml Resolved
Comment thread tests/details/m68k.yaml Resolved
- Add m68k_op_mem.pc_offset, the offset from the instruction address to
the first extension word of a PC-relative EA.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@b1llow
b1llow marked this pull request as ready for review November 26, 2026 20:07

This branch has not been deployed

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant