This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Dual DPTR push in ISR - why?

I'm looking to optimize an ISR written in C and wondered why version 6.21 pushes both DPTR when it doesn't use them both?

Parents Reply Children
  • I repeat, that the absence of the memmove, memcmp, strcpy, and strcmp library functions in a ISR, is NOT suffcient for turning off the "dual DPTR option" only in the ISR. If you do, you can generate a very nasty bug.

    Of course this program failure can only occur if another task call these library rountines, or if you play around with the dptr selector yourself. (If you are not doing this, then why are you even using the "dual DPTR option"?)

    Think twice before you turn off this option only in an ISR.