thunder.compile_stats

thunder.compile_stats(fn)[source]

Obtains the compilation statistics from a JITed function.

The compilation statistics (thunder.common.CompileStats) contain information about each compilation run - collected when a JITed function is called for the first time or with previously unseen state. This includes the cache of traces (pologues, computation, possibly backward and epilogue) and how they have been transformed and information about cache hits and misses and timings.

Return type:

Optional[CompileStats]