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

            Bug ID: 109612
           Summary: Adding -g makes compilation 220 times slower
           Product: gcc
           Version: 13.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: debug
          Assignee: unassigned at gcc dot gnu.org
          Reporter: dcb314 at hotmail dot com
  Target Milestone: ---

Created attachment 54913
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=54913&action=edit
C source code

The attached C code, when compiled by -g, takes a long time:

$ (ulimit -t 120; time /home/dcb36/gcc/results/bin/gcc    -O3 -w -c bug909.c)

real    0m0.496s
user    0m0.472s
sys     0m0.013s
$ (ulimit -t 120; time /home/dcb36/gcc/results/bin/gcc  -g  -O3 -w -c bug909.c)

real    1m48.669s
user    1m44.093s
sys     0m3.329s

$  /home/dcb36/gcc/results/bin/gcc   -v
Using built-in specs.
COLLECT_GCC=/home/dcb36/gcc/results/bin/gcc
COLLECT_LTO_WRAPPER=/home/dcb36/gcc/results.20230424.asan.ubsan/libexec/gcc/x86_64-pc-linux-gnu/14.0.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: ../trunk.year/configure
--prefix=/home/dcb36/gcc/results.20230424.asan.ubsan --disable-multilib
--disable-bootstrap --with-build-config=bootstrap-asan
--with-build-config=bootstrap-ubsan --with-pkgversion=ff8f95449350372b
--enable-checking=df,extra,fold,rtl,yes --enable-languages=c,c++,fortran
Thread model: posix
Supported LTO compression algorithms: zlib zstd
gcc version 14.0.0 20230424 (experimental) (ff8f95449350372b) 
$

Reply via email to