We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
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?
"dual DPTR is on and they aren't used" As quoted earlier, C51 only ever uses the extra DPTR(s) in the specific Library functions; nowhere else.
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.