SPRUI04F july 2015 – april 2023
At this point, the compiler has generated a CSV file for each C/C++ source file specified on the command line of the re-compile of the application. Each CSV file contains weighted call graph information about all of the call sites in each function defined in the C/C++ source file.
The program cache layout tool, clt6x, collects all of the weighted call graph information in these CSV files into a single, merged weighted call graph. The weighted call graph is processed to produce a preferred function order command file that is fed into the linker to guide the placement of the functions defined in your application source files. This is the syntax for clt6x:
clt6x *.csv -o forder.cmd |
The output of clt6x is a text file containing a sequence of --preferred_order=function specification options. By default, the name of the output file is forder.cmd, but you can specify your own file name with the -o option. The order in which functions appear in this file is their preferred function order as determined by the clt6x.
In general, the proximity of one function to another in the preferred function order list is a reflection of how often the two functions call each other. If two functions are very close to each other in the list, then the linker interprets this as a suggestion that the two functions should be placed very near to one another. Functions that are placed close together are less likely to create a cache conflict miss at run time when both functions are active at the same time. The overall effect should be an improvement in program instruction cache efficiency and performance.