Profiler is a very useful tool for programmers. TDL Profiler helps you to analyze and optimize your TDL code. The performance of the code snippet can be obtained using TDL profiler. The profiler provides information such as the time taken to evaluate a TDL artefact, the number of times the TDL artefact was executed and so on. The TDL artefact may be an expression, function, collection, remote call, a view change, or a Report/Form regeneration.
Download the sample TDL code here .
On this page
1. Open Tally.ERP 9 in Developer mode.
2. In the calculator panel, type the following commands.
Mode: Profile
Start
<Perform the operation which needs to be profiled>
Stop
Dump
Open


3. The log file opens.
Note : The commands are case insensitive.
The log file format is supported from Tally.ERP 9 Release 6.5.3 onwards.
The log file contains 3 sections:
This section details the order of execution of the TDL artefacts. In this section, a TDL artefact appears as many times as it was executed.
|
Column Title |
Description |
|
Exec. Order |
This column gives the order in which the TDL artefacts were executed after the profiler started. In the image below, the TDL artefact MyLedgerentriesSummary was the first one to execute which in turn called the collection MyVouchersCollection , hence the order of execution was 1 and 2 respectively. |
|
Depth |
This number indicates the level at which the TDL artefact was executed within a hierarchy or a block of code. For example, in the image below, MyLedgerentriesSummary was executed at Level 0 followed by MyVouchersCollection at Level 1. |
|
Total Time |
The total time taken to execute the TDL artefact along with its children |
|
Self Time |
The time taken to execute the TDL artefact itself (excluding the time taken to execute its children). |
|
Requestor Type/Requestor Name |
The context in which the TDL artefact was executed. In the image below, the collection MyLedgerentriesSummary was invoked by the part DashBoardLedgerAmount and hence this is the Requestor for the TDL artefact MyLedgerentriesSummary . |
|
TDL Artefact Type/TDL Artefact Name |
The TDL artefact that is being profiled. |
|
Result |
This applies to only TDL expressions and contains the result of its evaluation. |

The data in this section is grouped based on the Parent Hierarchy. For example, if a TDL artefact appears more than once under a parent hierarchy, then the data of the TDL artefact is grouped.
The columns Depth , Requestor Type , Requestor Name , TDL Artefact type , TDL Artefact Name together uniquely identify a parent. Each subsequent depth represents a child of the current depth.
Count represents the number of times the TDL artefact was executed and Failed Count represents the number of times the TDL artefact failed during execution.

The data in this section is grouped by the TDL artefacts. Here each TDL artefact appears only once.

|
Commands |
Description |
|
Start |
Start a new profiling session. |
|
Stop |
Stop data profiling |
|
Reset |
Discard the captured data. |
|
Status |
Check if the profiler is on/off |
|
Dump |
Dump the captured data to a log file excluding TDL artefacts which was executed in less than a millisecond. |
|
Dumpz |
Dump all the captured data irrespective of the time taken to execute. |
|
Open |
Open the last dumped log file within the current instance of Tally.ERP 9. |
|
Detailed |
This command toggles in-depth profiling on/off. By default, the detailed mode is off. When enabled, the profiler will also capture expression evaluations. |