qtscript: Add a new API function, profile(),
to ensure gathering performance monitor statistics
for in-script function calls
qtscript: Use QElapsedTimer for high-resolution performance profiling
jscam: Split __camTacticsTick into smaller calls.

They are smoothed out across different frames
to improve performance. Exactly one group
is handled on every frame.

Add profile() calls for some important functions.

refs ticket:4234