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

            Bug ID: 128337
           Summary: -fanalyzer slow when compiling GNU gettext
           Product: gcc
           Version: 16.2.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: analyzer
          Assignee: dmalcolm at gcc dot gnu.org
          Reporter: bruno at clisp dot org
  Target Milestone: ---

Created attachment 66055
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=66055&action=edit
test case write-po.i (compressed)

gcc takes a long time (over 10 seconds on a fast machine) to compile GNU
gettext's write-po.c, a file with merely 55 KB and 25 functions.

How to reproduce:
Find attached write-po.i, the result of preprocessing it.

$ time gcc -fanalyzer -g -O2 -c write-po.i
10.9 sec
$ time gcc -g -O2 -c write-po.i
0.4 sec
$ time gcc -fanalyzer -O2 -c write-po.i
4.7 sec

So:
- Without -fanalyzer, the compilation is 20 times faster.
- Still with -fanalyzer, but without -g, the compilation is more than 2 times
faster. Why is the presence of debug information slowing down the analyzer by
more than a factor of 2 ??

Reply via email to