On Fri, Apr 29, 2016 at 04:43:56PM +1000, David Gwynne wrote: > > > On 28 Apr 2016, at 22:49, Mark Kettenis <mark.kette...@xs4all.nl> wrote: > > > >> Date: Thu, 28 Apr 2016 13:50:53 +0200 > >> From: Martin Pieuchot <m...@openbsd.org> > >> > >> The reason why we do not use 'static' in the kernel is no longer valid > >> since all our platforms are ELF. ddb(4) handle them just fine. > >> > >> Here's an example after setting 'static' in the uhci(4) driver: > >> > >> $ nm /bsd |grep uhci_poll_hub > >> ffffffff81107080 t uhci_poll_hub > >> > >> $ nm /obsd |grep uhci_poll_hub > >> ffffffff81107080 T uhci_poll_hub > >> > >> Diff below convert and unify all the Makefile.$arch to no longer remove > >> local symbols. > >> > >> ok? > > > > In principle this diff is fine. I don't expect the symbol tables to > > grow too much by this. > > > > However, using static in the kernel is still bad. The compiler will > > optimize away static functions, and when that happens they won't show > > up in the backtraces. > > can we throw in -fno-inline to prevent that? or do we not trust gcc?
that would completely disable inlining, even for inline functions. -Otto