This is required in order to determine during disassembly whether a
Reg bead without associated DA bead is referring to a data register.
Details
- Reviewers
myhsu - Commits
- rG51884c6beff7: [M68k] Introduce DReg bead
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Does the remaining Reg (Beads) always mean address register? If that's the case, can we just rename it into AReg? Also, is it possible to just get rid of the DA Beads since we have separate DReg and AReg?
It acts like a default when decoding (in one of the later patches). The DA bead is still needed since it's used for instructions where it can be either an address or data register.
As it stands, I could rename it but it might be a bit misleading. (Existing cases which don't need a specific register kind would all use AReg.)
Alternatively, perhaps I could add AReg and enforce that DReg/AReg cannot be combined with DA and keep Reg separate, solely for use with DA. I didn't think of that at the time.
Ahh I see
Alternatively, perhaps I could add AReg and enforce that DReg/AReg cannot be combined with DA and keep Reg separate, solely for use with DA. I didn't think of that at the time.
Let's keep your current plan (i.e. only add DReg) for now. Since if Reg and DA are really needed I don't see a good reason to add another AReg if that doesn't really make implementing MCCodeEmitter or AsmParser easier.
llvm/lib/Target/M68k/M68kInstrArithmetic.td | ||
---|---|---|
548 | Can you move this and related changes to a separate patch? This seems irrelevant to the topic |
Fix one superfluous DReg: the rr arithmetic includes the DA bit for the operand already.
Can you move this and related changes to a separate patch? This seems irrelevant to the topic