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

A question about using idata class

Hi,
I am new to C166 and doing a project with it. I've read in some papers that variables that need to have a quick access, can be defined in this class. I want to know what are these situations? And also what happens if we don't define these variables in idata? for example does it cause to malfunction of the program on not?
And also for example is it necessary to define an index variable (that is used frequently in the program) in idata class?

Thanks so much

  • And also what happens if we don't define these variables in idata? for example does it cause to malfunction of the program on not?

    The program will not malfunction.
    The concept of different memory types was invented because on some (most) processors there are different methods to access memory locations that trade off speed against address range. Compiler makers try to take this into account and offer users some control over which method is used.
    Remember what Donald Knuth said? "Premature optimization is the root of all evil". Forget about idata, build a working program. If it doesn't meet timing costraints, start looking for ways to optimize. That would be the time to see if idata would be of any help.