-
-
Notifications
You must be signed in to change notification settings - Fork 727
Open
Labels
Description
We are trying to optimize libvips and its dependencies with PGO (Profile-guided optimization), but the library is crashing on load when built with GCC's PGO instrumentation - it's working fine for every other dependency of libvips (e.g. libwebp, cgif etc).
Is there a documented way to build libvips with GCC's PGO instrumentation?
To Reproduce
meson setup -Db_pgo=generate buildmeson compile -C build- Error:
Generating libvips/Vips-8.0.gir with a custom command (wrapped by meson to set env) FAILED: libvips/Vips-8.0.gir
GDB output
Starting program: /app/vips-8.17.3/build/tools/vips
Program received signal SIGSEGV, Segmentation fault.
0x00007ff388058718 in ?? ()
(gdb) bt
#0 0x00007ff388058718 in ?? ()
#1 0x0000000000000009 in ?? ()
#2 0x00007ff3888f466a in elf_machine_lazy_rel (skip_ifunc=<optimized out>, reloc=0x7ff387eed160, l_addr=<optimized out>, scope=<optimized out>, map=0x7ff3888e37e0) at ../sysdeps/x86_64/dl-machine.h:550
#3 elf_dynamic_do_Rela (skip_ifunc=<optimized out>, lazy=<optimized out>, nrelative=<optimized out>, relsize=<optimized out>, reladdr=<optimized out>, scope=<optimized out>, map=0x7ff3888e37e0) at ./elf/do-rel.h:99
#4 _dl_relocate_object (l=l@entry=0x7ff3888e37e0, scope=<optimized out>, reloc_mode=<optimized out>, consider_profiling=<optimized out>, consider_profiling@entry=0) at ./elf/dl-reloc.c:301
#5 0x00007ff388907789 in dl_main (phdr=<optimized out>, phnum=<optimized out>, user_entry=<optimized out>, auxv=<optimized out>) at ./elf/rtld.c:2311
#6 0x00007ff388903f46 in _dl_sysdep_start (start_argptr=start_argptr@entry=0x7ffe52856f90, dl_main=dl_main@entry=0x7ff388905af0 <dl_main>) at ../sysdeps/unix/sysv/linux/dl-sysdep.c:140
#7 0x00007ff38890575e in _dl_start_final (arg=0x7ffe52856f90) at ./elf/rtld.c:494
#8 _dl_start (arg=0x7ffe52856f90) at ./elf/rtld.c:581
#9 0x00007ff388904548 in _start () from /lib64/ld-linux-x86-64.so.2
#10 0x0000000000000001 in ?? ()
#11 0x00007ffe5285762c in ?? ()
#12 0x0000000000000000 in ?? ()
Environment
- OS: Ubuntu 24.04 (x86)
- Vips: v8.17.3
C compiler for the host machine: cc (gcc 13.3.0 "cc (Ubuntu 13.3.0-6ubuntu2~24.04) 13.3.0")
C linker for the host machine: cc ld.bfd 2.42
C++ compiler for the host machine: c++ (gcc 13.3.0 "c++ (Ubuntu 13.3.0-6ubuntu2~24.04) 13.3.0")
C++ linker for the host machine: c++ ld.bfd 2.42