]> granicus.if.org Git - postgresql/commit
Collect JIT instrumentation from workers.
authorAndres Freund <andres@anarazel.de>
Tue, 25 Sep 2018 19:54:29 +0000 (12:54 -0700)
committerAndres Freund <andres@anarazel.de>
Tue, 25 Sep 2018 20:12:44 +0000 (13:12 -0700)
commit33001fd7a7072d483272115a9376478fdc007fb9
tree6a01a567ac1b665c34a2a7e97ece0bb2ea35b503
parent5e22171310f8d7c82219a6b978440e5144e88683
Collect JIT instrumentation from workers.

Previously, when using parallel query, EXPLAIN (ANALYZE)'s JIT
compilation timings did not include the overhead from doing so on the
workers.  Fix that.

We do so by simply aggregating the cost of doing JIT compilation on
workers and the leader together. Arguably that's not quite accurate,
because the total time spend doing so is spent in parallel - but it's
hard to do much better.  For additional detail, when VERBOSE is
specified, the stats for workers are displayed separately.

Author: Amit Khandekar and Andres Freund
Discussion: https://postgr.es/m/CAJ3gD9eLrz51RK_gTkod+71iDcjpB_N8eC6vU2AW-VicsAERpQ@mail.gmail.com
Backpatch: 11-
contrib/auto_explain/auto_explain.c
src/backend/commands/explain.c
src/backend/executor/execMain.c
src/backend/executor/execParallel.c
src/backend/jit/jit.c
src/backend/jit/llvm/llvmjit.c
src/backend/jit/llvm/llvmjit_expr.c
src/include/commands/explain.h
src/include/executor/execParallel.h
src/include/jit/jit.h
src/include/nodes/execnodes.h