Nowhere, and nothing defines that. Correct tick counting is not implemented in uCsim (except s51). It counts 1 clock (tick) for every instruction which will be unreal especially when lot of jumps happen.

Oh, I don't expect ucSim to fully and exactly replicate STM8 behaviour, including pipelining behaviour (with stalls/flushing delays). I think that is too much to expect. One would only expect it to simulate the nominal number of cycles for all instructions.

To compare quality of two programs, I recommend to use vclk instead (available in sim_vclk variable), it will be sum of the FETCH, READ, and WRITE operations.

This is confusing. What is the difference between 'vclks' and 'clks', and why are there two separate values?

If this sim_vclk value (which I assume one accesses with an "info variables sim_vclk" command) is a more accurate representation of how many cycles instructions are consuming, then why do ucSim timers (whose stated purpose are "measure execution time and profiling") measure a different clocks/cycles figure that can be inaccurate and not necessarily representative of the nominal behaviour of the real chip?

BTW, is there any way to get "info variables sim_vclk" to display its values in decimal? And perhaps without the second caption line of text?

Regards,
Basil


_______________________________________________
Sdcc-user mailing list
Sdcc-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sdcc-user

Reply via email to