Language…
15 users online:  Alex,  AmperSam, Bonobi, BrandonBlank, DanMario24YT, Firstnamebutt,  FPzero, Heitor Porfirio, Humpty Dumpty Magazine, Jakeapus,  MarkAlarm, ojum,  Segment1Zone2, Snowfool948, Zavok - Guests: 160 - Bots: 153
Users: 62,912 (2,641 active)
Latest user: DEM1995

Is it considered bad form to use reserve instruction WDM / Opcode $42?

Before I decide to submit anything that takes advantage of it, I was wonder if it is considered a poor programming practice to use the reserved opcode "WDM". For those who don't know, opcode $42 is technically "reserved", which means it isn't used for anything. Essentially it acts like a NOP instruction with one key difference: WDM accepts a second byte, which it reads, but does nothing with. That means that, if put before a 1 byte instruction, it will "skip" over said instruction.

It could be used in a code like this:
Code
; .. something something
BPL +
    SEC
    WDM
+
CLC

Although I don't know if ASAR accepts WDM properly on its own like that, so I write the notably more ugly code
Code
BPL +
    SEC
    db $42 ; Skip the next instruction
+
CLC


I would understand if the community frowns upon its use -- it is obscure, not often useful and only saves one cycle and one byte over its alternative "BRA $01". I was just wondering because I had not seen it even mentioned before I started closely studying the technical documents on 65c816 ASM.
it'll also confuse debuggers because most of them have the option to break on WDM, which is actually pretty useful for simple breakpoints

also yeah asar automatically adds a 2nd byte to a plain WDM so you need to use db $42 to use that trick