I do such things like:
move.l myptr(PC),D0
beq .nullptr
move.l D0,A0
in the 2nd example could always use tst.l D0 anyway.
flags are set for free when moving to an address register. Also note the first line, I always write relocatable code.
In other news, I've been thinking about a RISC instruction set for internal use in a 68k core for some time. I think we can identify a few obvious simplifications:
1. tread An and Dn identically (use extra instructions if different behaviour is required)
2. only MOVE can use as either source or destination operand (load/store architecture)
3. all other instructions register-register, or "quick" short-constant source operands
4. spare "temporary" registers for internal use.
we could map 68k instructions to short sequences of internal instructions, and design those instructions to give the shortest sequences.