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

            Bug ID: 77472
           Summary: build of intel_drv.so (xf86-video-intel) takes over
                    13GB+ memory during lto1
           Product: gcc
           Version: 6.2.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: lto
          Assignee: unassigned at gcc dot gnu.org
          Reporter: sverd.johnsen at googlemail dot com
  Target Milestone: ---

gcc version 6.2.1 20160830 (GCC)

stumbled upon this by accident. should be buildable with no hassle on a
recent-ish distro

git clone git://anongit.freedesktop.org/xorg/driver/xf86-video-intel --depth 1
./autogen.sh
make CC="gcc -flto"

[...]

/usr/lib/gcc/x86_64-pc-linux-gnu/6.2.1/lto1 -quiet -dumpdir .libs/ -dumpbase
intel_drv.so.ltrans0 -mtune=generic -march=x86-64 -mtune=generic -march=x86-64
-auxbase-strip /tmp/ccc0HKj0.ltrans0.ltrans.o -g -O2 -O2 -fmath-errno
-fsigned-zeros -ftrapping-math -fno-trapv -fno-openmp -fno-openacc
-fno-fat-lto-objects -fPIC -fltrans @/tmp/ccXeZeQR -o /tmp/cchNXbJ0.s

lto1 stays stable at 4GB for a long time then slowly moves towards towards 13GB
or so at which point i stopped it manually since I didnt want to force the OOM
kill

in case you dont get to the point you might need to remove the always_inline
attr from the force_inline in src/sna/compiler.h

Reply via email to