mingodad 204ee9d17b Add an option to output profiling/coverage info (basically function calls count and clock_t time spent).
There is an option to define how many samples to use with the definition of compile time macro "PROFILE_CALLS_SAMPLE" the default value is 10.
The code is guarded by a compile time macro "CONFIG_PROFILE_CALLS", to build execute "make CONFIG_PROFILE_CALLS=1".
When using the added option "-p" we can repeat it up to 3 times:
- "-p" -> Only update calls count and omit functions with 0 calls
- "-p -p" -> Update calls count and sampled time_spent  and omit functions with 0 calls
- "-p -p -p" -> Like the above but showing functions with 0 calls.
The output format:
=[ code_line call_count acumulated_time_spent average_time_spent function_name ]
[454	2	1	6	xfillArr]
2023-06-06 14:13:10 +02:00
2021-03-27 11:17:31 +01:00
2020-09-06 19:07:30 +02:00
2021-03-27 11:17:31 +01:00
2021-03-27 11:17:31 +01:00
2020-09-06 19:10:15 +02:00
2020-09-06 19:07:30 +02:00
2021-03-27 11:17:31 +01:00
2021-03-27 11:17:31 +01:00
2020-09-06 18:53:08 +02:00
2020-11-08 14:30:56 +01:00
2020-09-06 19:10:15 +02:00
2022-03-06 19:00:24 +01:00
2020-09-06 19:10:15 +02:00
2020-09-06 18:53:08 +02:00
2021-03-27 11:17:31 +01:00
2020-09-06 18:53:08 +02:00
2021-03-27 11:17:31 +01:00
2021-03-27 11:17:31 +01:00
2020-11-08 14:30:56 +01:00
2021-03-27 11:17:31 +01:00
2020-09-06 19:10:15 +02:00
2020-11-08 14:30:56 +01:00
2020-09-06 18:53:08 +02:00
2021-03-27 11:17:31 +01:00
2020-09-06 19:07:30 +02:00
2021-03-27 11:17:31 +01:00
2021-03-27 11:17:31 +01:00
2022-03-06 18:55:04 +01:00
2020-09-06 18:53:08 +02:00
2020-09-06 18:53:08 +02:00
2021-03-27 11:17:31 +01:00
2022-03-06 19:00:24 +01:00
2022-03-06 19:00:24 +01:00
2020-09-06 18:53:08 +02:00
2021-03-27 11:17:31 +01:00

The main documentation is in doc/quickjs.pdf or doc/quickjs.html.
Description
Public repository of the QuickJS Javascript Engine.
Readme MIT 28 MiB
Languages
C 94.1%
JavaScript 5.3%
Makefile 0.5%
Shell 0.1%