I have not used PDATA before, so this may be a silly question. Can I set up PDATA dynamically (within the code) to any 256-byte chunk of xdata? So I can change where the PDATA is "looking" in xdata on the fly, and subsequently have byte addressing (and hopefully faster writes within a loop) for any 256-byte section of xdata at a time?
Ho-hum. What it is to be world-famous... (or is that infamous...?)
I took some time out to explore the benefits of using P2 in memcpy() and sure enough, in cases of a copy from CODE to XDATA or XDATA to XDATA there is a very significant speed bonus. Futhermore, looking through my recent applications, I see that these transfers are very common. Also, the compiler frequently calls memcpy() even when it is not explicitly mentioned in the source. For example, memcpy() is used to copy or initialise structures. It seems to me that a byte to save a shadow of P2 and a couple of exta instructions in an interrupt such as:
PUSH P2_shadow ... POP P2