Skip to content

Commit 888c2c3

Browse files
authored
Include inference time in --trace-compile-timing (#59220)
It's important for this measurement to include indirect compilation (not just "self" time), since the `--trace-compile` log only reports compilation triggers / entrypoints (not all compiled code).
1 parent cd44680 commit 888c2c3

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/gf.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3523,9 +3523,8 @@ jl_code_instance_t *jl_compile_method_internal(jl_method_instance_t *mi, size_t
35233523
}
35243524

35253525
JL_GC_PUSH1(&codeinst);
3526-
double compile_time = jl_hrtime();
35273526
int did_compile = jl_compile_codeinst(codeinst);
3528-
compile_time = jl_hrtime() - compile_time;
3527+
double compile_time = jl_hrtime() - start;
35293528

35303529
if (jl_atomic_load_relaxed(&codeinst->invoke) == NULL) {
35313530
// Something went wrong. Bail to the fallback path.

0 commit comments

Comments
 (0)