On Tue, Aug 29, 2017 at 3:23 PM, Nick Clifton <ni...@redhat.com> wrote: > Hi Jozef, > >> As reported in PR80993, enabling lto causes interrupt handlers to be >> removed. This patch marks interrupt handlers as used, preventing them >> from being optimized out. >> >> If the attached patch is acceptable, I would appreciate if someone could >> commit it for me, as I do not have write access. > > Approved and applied. Thanks for fixing this bug.
Humm... don't you have to register interrupt handlers somehow? That is, I fail to see why it is not the users responsibility to mark things as used if they are used in a way GCC (and the linker plugin) doesn't see? Anyway, I guess this side-effect should be documented. It also will prevent GCC from making the symbol hidden in case it resides in a shared library IIRC. Richard. > Cheers > Nick > >