this is the output from running py-spy on a pants ...
# development
h
this is the output from running py-spy on a pants run with the daemon already warmed up
eyeballing this, it looks like a little more than half the time is occupied by stuff that happens before
pants_runner.py:run
, which is dominanted by importlib stuff
👍 1
and of the remaining time, we spend a small but noticeable chunk of time dealing with
OptionsBootstrapper
, and even bigger chunk of time setting up rust logging (probably becuase it has to do FFI stuff), and then actually running the
RemotePantsRunner
doesn't take all that long
is there a way to get py-spy to output times in seconds?
but anyway the whole run takes somewhat longer than a second - so human-noticeable latency, but a fifth of half of that is 100ms, which isn't too bad
(again eyeballing these times)
anyway for comparison, here's the same command without pantsd
(it's
./v2 --no-v2-ui lint src/python/pants/engine::
, which isn't that big)
pyspy-output.svg
still kind of a lot of time, relatively-speaking, spent in import lib stuff
👍 1