Hello friends
I have encountered a very strange problem, I have keil with MDK3.08a version. When i compiled program and loaded in the target the execution speed of the program becomes considerably slower (not in debug mode). I have compared the speed with the previous version of keil (i don't remember may be 3.20).
Furthermore when i interchange the location of C file in the work space it effects the execution speed. When I compared the output hex file of the same project with interchanged c files position in work space, i found they were different.
Please help me out of this
Again, the whole point of any High-Level Language (HLL) is that you do not have control of the generated machine code - you delegate that task to the compiler.
Since you do not have control of the generated machine code, you do not have control of its execution speed!
Since you do not have control of the execution speed, you must not rely upon the execution timing in any way!
If you really do need to rely upon the execution timing, then you really must write it in assembler; or use some means that does not rely upon the execution timing - such as a hardware timer.