Method 1:
Code: Select all
sub main()
...
calltask task, taskStack
exit sub
...
end
Code: Select all
sub main()
...
task
...
end
With method one, that code section takes ~4ms (for unknown reasons, as it's just some lines of algebra).
With method two, that code section takes either 0.0 (i.e. <1.95ms) or 1.95ms, the task switching time.
Any thoughts on why different times are reported? Only task() is running both with both methods.
EDIT: I wrote "--thus it is also odd that execution time would be a multiple of task switch time", which is actually due to the Timer resolution; this statement is thus irrelevant.