[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Timings for 'make check' with and without symbols with position

From: Alan Mackenzie
Subject: Timings for 'make check' with and without symbols with position
Date: Sat, 26 Feb 2022 16:39:05 +0000

Hello Emacs.

I'm starting a new thread about this, since the old one (Subject: Time
to merge scratch/correct-warning-pos into master, perhaps?) has become
long, and we've drifted from the original topic.

Using perf, I've measured the difference in run time for 'make check'
between two comparable versions of Emacs, one with symbols with
position ("new"), the other without ("old").  They were both built
without native compilation, and their configurations were identical.
'make check' had already been run once, to compile (almost) all of the
test .elc files.

Short summary: The new build is slower than the old by 12.6%.  perf
counted 419k samples on the new, 372k samples on the old.

What is taking the extra time is largely the garbage collection:  I
filtered perf's output successively for the strings "mark" and "sweep",
and include those functions with at least 0.1% of the run time.

For "old":
 20.38%  emacs     emacs              [.] mark_object
  3.36%  emacs     emacs              [.] pdumper_marked_p_impl
  2.98%  emacs     emacs              [.] mark_char_table
  1.22%  emacs     emacs              [.] pdumper_set_marked_impl
  1.03%  emacs     emacs              [.] mark_vectorlike
  0.28%  emacs     emacs              [.] mark_compiled
  0.11%  emacs     emacs              [.] mark_interval_tree_1

  0.80%  emacs  emacs  [.] sweep_strings
  0.69%  emacs  emacs  [.] sweep_conses
  0.32%  emacs  emacs  [.] sweep_vectors
  0.12%  emacs  emacs  [.] sweep_intervals
 31.29%  total

For "new":
 23.17%  emacs  emacs         [.] mark_object
  3.97%  emacs  emacs         [.] pdumper_marked_p_impl
  3.79%  emacs  emacs         [.] mark_char_table
  1.46%  emacs  emacs         [.] pdumper_set_marked_impl
  1.22%  emacs  emacs         [.] mark_vectorlike
  0.32%  emacs  emacs         [.] mark_compiled

  0.76%  emacs  emacs  [.] sweep_strings
  0.66%  emacs  emacs  [.] sweep_conses
  0.42%  emacs  emacs  [.] sweep_vectors
  0.10%  emacs  emacs  [.] sweep_intervals
 35.87%  total

Increasing the new build's 35.87% by 12.6%, to give a fair comparison
with the old build, gives us 40.40%.  More precisely, the new build's
garbage collection took 40.40% of the old build's run time.

Thus garbage collection accounts for 40.40% - 31.29% = 9.11% of the
12.6% difference between the old and new builds.

Clearly, any attempt to speed up the new build will involve optimising
the garbage collection somehow.

Alan Mackenzie (Nuremberg, Germany).

reply via email to

[Prev in Thread] Current Thread [Next in Thread]