comparison lwasm/pass1.c @ 472:e97f9a302c6a

Add emuext pragma and associated instructions. This provides two emulator specific instructions ("log" and "debug") enabled by the "emuext" pragma. This is from a patch provided by tim Lindner <tlindner@macmess.org>. From Tim's submission: ---- I stole the whole patch from Erik Gavriluk. I hope he doesn't mind. :) The two instructions are "debug" and "log". They are enabled with pragmas. I also added them to the manual. Hopefully all is well. ---- Said Erik Gavriluk <erik@bombfactory.com> in response: ...happy to see them picked up in mainline (if you choose to do so)....
author William Astle <lost@l-w.ca>
date Thu, 01 Nov 2018 23:00:00 -0600
parents c8d4f3486ad7
children 74d0c394666e
comparison
equal deleted inserted replaced
471:ad0efd5835c3 472:e97f9a302c6a
292 if ((instab[opnum].flags & lwasm_insn_is6809conv) && !CURPRAGMA(cl, PRAGMA_6809CONV)) continue; 292 if ((instab[opnum].flags & lwasm_insn_is6809conv) && !CURPRAGMA(cl, PRAGMA_6809CONV)) continue;
293 // ignore 6809 convenience opcodes in 6309 mode 293 // ignore 6809 convenience opcodes in 6309 mode
294 if ((instab[opnum].flags & lwasm_insn_is6809conv) && !CURPRAGMA(cl, PRAGMA_6809)) continue; 294 if ((instab[opnum].flags & lwasm_insn_is6809conv) && !CURPRAGMA(cl, PRAGMA_6809)) continue;
295 // ignore 6309 convenience opcodes unless asked for 295 // ignore 6309 convenience opcodes unless asked for
296 if ((instab[opnum].flags & lwasm_insn_is6309conv) && !CURPRAGMA(cl, PRAGMA_6309CONV)) continue; 296 if ((instab[opnum].flags & lwasm_insn_is6309conv) && !CURPRAGMA(cl, PRAGMA_6309CONV)) continue;
297 // ignore emulator extension opcodes unless asked for
298 if ((instab[opnum].flags & lwasm_insn_isemuext) && !CURPRAGMA(cl, PRAGMA_EMUEXT)) continue;
297 299
298 if (!strcasecmp(instab[opnum].opcode, sym)) 300 if (!strcasecmp(instab[opnum].opcode, sym))
299 break; 301 break;
300 } 302 }
301 303