Post Reply 
HP41 and MCODE XKD instructions in program mode
07-26-2016, 05:06 PM
Post: #3
RE: HP41 and MCODE XKD instructions in program mode
(07-26-2016 08:26 AM)Ángel Martin Wrote:  
(07-26-2016 03:49 AM)hth Wrote:  ......
Has this feature ever been used by some MCODE instruction?

Yes, I've seen that in a couple of functions from the NFCROM and others, where the documentation states its immediate execution character. But I didn't expect this not to be the case in RUN mode, which to me defeats the purpose of the setting.

Is that tested checking F13 only or both F13 and F4?

It has nothing to do with if your program is running or not. If you are in program edit mode (entering programs), the XKD test is right after the test for if the instruction is programmable (the first NOP). If it has a double NOP, it will GOTOC to the second of them (the intention being that it should happen immediately, like SST or RCL).

Outside program mode (the mode where we do normal calculations), this test is not done, so the XKD feature does not work. Instead you get the usual NULL test.

A small curiosity is that NFRPU is pushed on the stack after the NULL test, so a non-programmable XKD instruction will execute without NFRPU on the stack and cannot return using an RTN instruction, it must jump back.

To me, it looks like a nice feature that was not fully completed. It really should be XKD also outside program edit mode.
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: HP41 and MCODE XKD instructions in program mode - hth - 07-26-2016 05:06 PM



User(s) browsing this thread: 2 Guest(s)