Skip to content

Conversation

s-barannikov
Copy link
Contributor

@s-barannikov s-barannikov commented Sep 4, 2025

  • Remove custom decoders for these instructions
  • Instead, provide decoders for DREGS/IWREGS register classes
  • Change register pair encodings to simplify instruction descriptions
  • Add/fix a few clarifying comments

Copy link

github-actions bot commented Sep 4, 2025

✅ With the latest revision this PR passed the C/C++ code formatter.

@s-barannikov s-barannikov force-pushed the avr-decoder-3-reg-pairs branch from 4888336 to cdf546f Compare September 4, 2025 12:51
@s-barannikov s-barannikov changed the title [AVR] Refactor ADIW/SBIW/MOVW instruction descriptions [AVR] Refactor ADIW/SBIW/MOVW instruction descriptions (NFCI) Sep 4, 2025
@s-barannikov s-barannikov force-pushed the avr-decoder-3-reg-pairs branch 3 times, most recently from 71dc9df to 2ceb471 Compare September 4, 2025 16:14
uint64_t Address,
const MCDisassembler *Decoder) {
assert(isUInt<2>(RegNo));
Inst.addOperand(MCOperand::createReg(GPRPairDecoderTable[12 + RegNo]));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be better to add a comment line, something like

Only AVR::R25R24, AVR::R27R26, AVR::R29R28, AVR::R31R30 are legal.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added a comment

* Remove custom decoders for these instructions
* Instead, provide decoders for DREGS/IWREGS register classes
* Change register pair encodings to simplify instruction descriptions
@s-barannikov s-barannikov force-pushed the avr-decoder-3-reg-pairs branch from 2ceb471 to b826233 Compare September 5, 2025 08:21
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.

2 participants