https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111523

qinzhao at gcc dot gnu.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |qinzhao at gcc dot gnu.org

--- Comment #2 from qinzhao at gcc dot gnu.org ---
(In reply to Hans-Peter Nilsson from comment #0)
thanks for filing this bug, and sorry for the late reply (I might miss the
original notification of this bug when it was opened last year)

from the description of the bug, it's not very clear on how to reproduce the
performance regression step by step. 

As a compiler engineer working in performance analysis for quite some years, I
suggest to use some performance analysis tools to locate the exact routines in
systemd that contribute to the regression. After these specific routines that
contribute to the major regression are identified, we can further narrow down
to the root cause, usually the following possibilities:

1. some large local array or local structure were initialized by this option,
the additional initialization insns cannot be eliminated by compiler
optimization. 
   if this is the case, we can add the following attribute:
"uninitialized
This attribute, attached to a variable with automatic storage, means that the
variable should not be automatically initialized by the compiler when the
option -ftrivial-auto-var-init presents.
"
to prevent those local array or structure variables from auto-initialization. 

2. there are some missing compiler optimization opportunities which should be
enabled to eliminate the overhead.

Reply via email to