Date: Tue, 09 Apr 2013 16:18:00 -0500 From: Joshua Isom <jrisom@gmail.com> To: freebsd-hackers@freebsd.org Subject: Re: GSOC 2013 project " Kernel Size Reduction for Embedded System " Message-ID: <51648588.7010209@gmail.com> In-Reply-To: <92799D4C-797C-4304-B299-DD1DBA49CFFC@FreeBSD.org> References: <CAOhv3dpTM9J9oiLpdw8xOAToXT_tQ3VW4Mv1F%2B8n7xhG%2BJK93w@mail.gmail.com> <alpine.BSF.2.00.1304091935490.13342@wojtek.tensor.gdynia.pl> <516452C7.7040607@mu.org> <alpine.BSF.2.00.1304091953060.13438@wojtek.tensor.gdynia.pl> <CAOjFWZ6ytuKFHYBvrNTMwK8f=_ZDnGY5-naVqscC6YWZ33P8UA@mail.gmail.com> <92799D4C-797C-4304-B299-DD1DBA49CFFC@FreeBSD.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On 4/9/2013 1:47 PM, Edward Tomasz NapieraĆa wrote: > In order to optimize - in this case for size - we need a way to measure > what should we focus on, and it looks like we don't have it yet. > > Would it be possible to write a tool - e.g. by instrumenting LLVM - that > would make it possible to calculate, for every function in the call graph, > the amount of code in that function and everything it "pulls in", i.e. all > the code paths that it might call. When we have that, clustering the graph > should give us some idea what to focus on. > > Or perhaps such a tool already exists? > Would clang's LTO help for size? I know work's starting on the bsd elftools ld, but I doubt it has any LTO support yet. Running -Os on the kernel as a whole instead of object files could probably help a lot also. I might try to set it up and see a size comparision. Also, what about the userland? Linux got popular for embedded partly for busybox and uclibc. If Linux didn't exist, someone would have ported minix instead.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?51648588.7010209>